Boost C++ Libraries: Ticket #883: errors when build with Apache stdcxx https://svn.boost.org/trac10/ticket/883 <pre class="wiki">I have been working on the Apache C++ Standard Library project (STDCXX): http://incubator.apache.org/stdcxx/ I've trying to compile the boost library with stdcxx. The details can be found here: http://mail-archives.apache.org/mod_mbox/incubator-stdcxx-dev/200704.mbox/% 3c7BDB2168BEAEF14C98F1901FD2DE64386573EB@epmsa009.minsk.epam.com%3e Boost version: 1.33.1 STDCXX version: 4.2 I've got the following errors in boost/regex/v4/regex_workaround.hpp and boost/regex/v4/fileiter.hpp: D:\_Libs\boost_1_33_1\boost/regex/v4/regex_workaround.hpp(145) : error C2653: 'stdext' : is not a class or namespace name D:\_Libs\boost_1_33_1\boost/regex/v4/regex_replace.hpp(44) : see reference to function template instantiation 'OutputIterator boost::re_detail::copy&lt;BidirectionalIterator,OutputIterator&gt;(InputIterator,InputIterator,OutputIterator)' being compiled with [ OutputIterator=boost::re_detail::string_out_iterator&lt;std::string&gt;, BidirectionalIterator=__rw::__rw_debug_iter&lt;std::basic_string&lt;char,std::char_traits&lt;char&gt;,std::allocator&lt;char&gt;&gt;,const char *,char *&gt;, InputIterator=__rw::__rw_debug_iter&lt;std::basic_string&lt;char,std::char_traits&lt;char&gt;,std::allocator&lt;char&gt;&gt;,const char *,char *&gt; ] D:\_Libs\boost_1_33_1\libs\regex\build\../src/cregex.cpp(446) : see reference to function template instantiation 'OutputIterator boost::regex_replace&lt;boost::re_detail::string_out_iterator&lt;S&gt;,__rw::__rw_debug_iter&lt;_Container,_Iterator,_MutableIterator&gt;,boost::regex_traits&lt;charT&gt;,char&gt;(OutputIterator,BidirectionalIterator,BidirectionalIterator,const boost::basic_regex&lt;charT,traits&gt; &amp;,const charT *,boost::regex_constants::match_flag_type)' being compiled with [ OutputIterator=boost::re_detail::string_out_iterator&lt;std::string&gt;, S=std::string, _Container=std::basic_string&lt;char,std::char_traits&lt;char&gt;,std::allocator&lt;char&gt;&gt;, _Iterator=const char *, _MutableIterator=char *, charT=char, BidirectionalIterator=__rw::__rw_debug_iter&lt;std::basic_string&lt;char,std::char_traits&lt;char&gt;,std::allocator&lt;char&gt;&gt;,const char *,char *&gt;, traits=boost::regex_traits&lt;char&gt; ] D:\_Libs\boost_1_33_1\boost/regex/v4/regex_workaround.hpp(145) : error C3861: 'unchecked_copy': identifier not found D:\_Libs\boost_1_33_1\boost/regex/v4/regex_workaround.hpp(145) : error C2653: 'stdext' : is not a class or namespace name D:\_Libs\boost_1_33_1\boost/regex/v4/regex_replace.hpp(44) : see reference to function template instantiation 'OutputIterator boost::re_detail::copy&lt;BidirectionalIterator,OutputIterator&gt;(InputIterator,InputIterator,OutputIterator)' being compiled with [ OutputIterator=boost::re_detail::string_out_iterator&lt;std::string&gt;, BidirectionalIterator=const char *, InputIterator=const char * ] D:\_Libs\boost_1_33_1\libs\regex\build\../src/cregex.cpp(456) : see reference to function template instantiation 'OutputIterator boost::regex_replace&lt;boost::re_detail::string_out_iterator&lt;S&gt;,const char*,boost::regex_traits&lt;charT&gt;,char&gt;(OutputIterator,BidirectionalIterator,BidirectionalIterator,const boost::basic_regex&lt;charT,traits&gt; &amp;,const charT *,boost::regex_constants::match_flag_type)' being compiled with [ OutputIterator=boost::re_detail::string_out_iterator&lt;std::string&gt;, S=std::string, charT=char, BidirectionalIterator=const char *, traits=boost::regex_traits&lt;char&gt; ] D:\_Libs\boost_1_33_1\boost/regex/v4/regex_workaround.hpp(145) : error C3861: 'unchecked_copy': identifier not found CALL "D:\Program Files\Microsoft Visual Studio 8\Common7\Tools\..\..\VC\bin\vcvars32.BAT" &gt;nul "D:\Program Files\Microsoft Visual Studio 8\Common7\Tools\..\..\VC\bin\cl" /Zm800 -nologo /EHsc -c -DBOOST_REGEX_CONFIG_INFO=1 -D_RWSTDDEBUG /Z7 /Od /Ob0 /EHsc /GR /MTd /Zc:forScope /Zc:wchar_t -I"bin\boost\libs\regex\build" -I"D:\_Projects\stdcxx_working\include" -I"D:\_Projects\stdcxx_working\include\ansi" -I"D:\_Projects\stdcxx_working\build\msvc-8.0\15s\include" -I"D:\_Libs\boost_1_33_1" -Fo"bin\boost\libs\regex\build\libboost_regex.lib\vc-8_0-stdcxx\debug\runtime-link-static\threading-multi\cregex.obj" -Tp"D:\_Libs\boost_1_33_1\libs\regex\build\../src/cregex.cpp" D:\_Libs\boost_1_33_1\boost/regex/v4/fileiter.hpp(331) : error C2039: 'ptrdiff_t' : is not a member of 'std' D:\_Libs\boost_1_33_1\boost/regex/v4/fileiter.hpp(378) : error C2039: 'ptrdiff_t' : is not a member of 'std' CALL "D:\Program Files\Microsoft Visual Studio 8\Common7\Tools\..\..\VC\bin\vcvars32.BAT" &gt;nul "D:\Program Files\Microsoft Visual Studio 8\Common7\Tools\..\..\VC\bin\cl" /Zm800 -nologo /EHsc -c -DBOOST_REGEX_CONFIG_INFO=1 -D_RWSTDDEBUG /Z7 /Od /Ob0 /EHsc /GR /MTd /Zc:forScope /Zc:wchar_t -I"bin\boost\libs\regex\build" -I"D:\_Projects\stdcxx_working\include" -I"D:\_Projects\stdcxx_working\include\ansi" -I"D:\_Projects\stdcxx_working\build\msvc-8.0\15s\include" -I"D:\_Libs\boost_1_33_1" -Fo"bin\boost\libs\regex\build\libboost_regex.lib\vc-8_0-stdcxx\debug\runtime-link-static\threading-multi\fileiter.obj" -Tp"D:\_Libs\boost_1_33_1\libs\regex\build\../src/fileiter.cpp" I propose to #include &lt;cstddef&gt; in fileiter.hpp to define the std::ptrdiff_t. And also I propose to change the line 131 in regex_workaround.hpp from #if BOOST_WORKAROUND(BOOST_MSVC,&gt;=1400) to the #if BOOST_WORKAROUND(BOOST_MSVC,&gt;=1400) &amp;&amp; defined(BOOST_DINKUMWARE_STDLIB) </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/883 Trac 1.4.3 John Maddock Wed, 04 Apr 2007 10:01:26 GMT <link>https://svn.boost.org/trac10/ticket/883#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/883#comment:1</guid> <description> <pre class="wiki">Logged In: YES user_id=14804 Originator: NO Will apply to cvs head: it's too late for 1.34 though I'm afraid :-( </pre> </description> <category>Ticket</category> </item> <item> <dc:creator>farid_zaripov</dc:creator> <pubDate>Wed, 04 Apr 2007 15:32:12 GMT</pubDate> <title>status changed https://svn.boost.org/trac10/ticket/883#comment:2 https://svn.boost.org/trac10/ticket/883#comment:2 <ul> <li><strong>status</strong> <span class="trac-field-old">assigned</span> → <span class="trac-field-new">closed</span> </li> </ul> <pre class="wiki">Logged In: YES user_id=1760091 Originator: YES In addition the Apache stdcxx provide the only one wchar_t (as compiler native type or as typedef to unsigned short depending from compiler options). I think the RogueWave STL does the same, so I propose the following changes in boost/regex/config.hpp: ---------------- --- config.hpp Wed Aug 24 12:58:50 2005 +++ D:\_Libs\boost_1_33_1\boost\regex\config.hpp Wed Apr 04 13:04:27 2007 @@ -152,7 +152,7 @@ * of the non-inline functions in the library, so that users can still link to the lib, * irrespective of whether their own code is built with /Zc:wchar_t. */ -#if defined(__cplusplus) &amp;&amp; (defined(BOOST_MSVC) || defined(__ICL)) &amp;&amp; !defined(BOOST_NO_INTRINSIC_WCHAR_T) &amp;&amp; defined(BOOST_WINDOWS) &amp;&amp; !defined(__SGI_STL_PORT) &amp;&amp; !defined(_STLPORT_VERSION) +#if defined(__cplusplus) &amp;&amp; (defined(BOOST_MSVC) || defined(__ICL)) &amp;&amp; !defined(BOOST_NO_INTRINSIC_WCHAR_T) &amp;&amp; defined(BOOST_WINDOWS) &amp;&amp; !defined(__SGI_STL_PORT) &amp;&amp; !defined(_STLPORT_VERSION) &amp;&amp; !defined(BOOST_RWSTD_VER) # define BOOST_REGEX_HAS_OTHER_WCHAR_T # ifdef BOOST_MSVC # pragma warning(push) ---------------- </pre> Ticket farid_zaripov Tue, 05 Jun 2007 17:01:02 GMT <link>https://svn.boost.org/trac10/ticket/883#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/883#comment:3</guid> <description> <p> The cross-reference link to the Apache STDCXX issue tracker: <a class="ext-link" href="http://issues.apache.org/jira/browse/STDCXX-430"><span class="icon">​</span>http://issues.apache.org/jira/browse/STDCXX-430</a> </p> </description> <category>Ticket</category> </item> <item> <dc:creator>John Maddock</dc:creator> <pubDate>Mon, 10 Sep 2007 10:46:29 GMT</pubDate> <title>status, resolution, description changed; severity set https://svn.boost.org/trac10/ticket/883#comment:4 https://svn.boost.org/trac10/ticket/883#comment:4 <ul> <li><strong>status</strong> <span class="trac-field-old">assigned</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> <span class="trac-field-old">Accepted</span> → <span class="trac-field-new">fixed</span> </li> <li><strong>description</strong> modified (<a href="/trac10/ticket/883?action=diff&amp;version=4">diff</a>) </li> <li><strong>severity</strong> → <span class="trac-field-new">Problem</span> </li> </ul> <p> Patch now applied to SVN trunk: apologies for the delay. </p> Ticket