Boost C++ Libraries: Ticket #5048: compilation error under ia64 HP-UX11i with gcc-4.4.0 https://svn.boost.org/trac10/ticket/5048 <p> The error is: </p> <p> « In file included from libs/filesystem/v3/src/utf8_codecvt_facet.cpp:19: ./libs/detail/utf8_codecvt_facet.cpp:255:7: error: missing binary operator before token "(" </p> <blockquote> <p> "g++" -ftemplate-depth-128 -O0 -fno-inline -Wall -g -pthread -fPIC -mlp64 -DBOOST_ALL_NO_LIB=1 -DBOOST_FILESYSTEM_DYN_LINK=1 -DBOOST_SYSTEM_DYN_LINK=1 -I"." -c -o "bin.v2/libs/filesystem/build/gcc-4.4.0/debug/threading-multi/v3/src/utf8_codecvt_facet.o" "libs/filesystem/v3/src/utf8_codecvt_facet.cpp" </p> </blockquote> <p> ...failed gcc.compile.c++ bin.v2/libs/filesystem/build/gcc-4.4.0/debug/threading-multi/v3/src/utf8_codecvt_facet.o... » </p> <p> I solved the problem with the attached patch </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/5048 Trac 1.4.3 ruipfernandes@… Fri, 07 Jan 2011 15:31:40 GMT attachment set https://svn.boost.org/trac10/ticket/5048 https://svn.boost.org/trac10/ticket/5048 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">boost_1_45_filesystem_gcc_hpux_patch</span> </li> </ul> <p> patch </p> Ticket Beman Dawes Mon, 10 Jan 2011 02:34:52 GMT <link>https://svn.boost.org/trac10/ticket/5048#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/5048#comment:1</guid> <description> <p> Fixing the problem by defining _INCLUDE_STDC<span class="underline">SOURCE_199901 in the jamfile solves the problem for those who use Boost.Build, but doesn't solve it for those who build via some other build system. </span></p> <p> The preferred fix would be to add a #define _INCLUDE_STDC<span class="underline">SOURCE_199901 somewhere, perhaps &lt;boost/config/platform/hpux.hpp&gt;. </span></p> <p> Is that a workable solution? What does _INCLUDE_STDC<span class="underline">SOURCE_199901 actually do? </span></p> <p> --Beman </p> </description> <category>Ticket</category> </item> <item> <author>ruipfernandes@…</author> <pubDate>Mon, 10 Jan 2011 11:59:37 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/5048#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/5048#comment:2</guid> <description> <p> Indeed, changing the jam file isn't the best way. </p> <p> Answering your questions: a) yes, defining in &lt;boost/config/platform/hpux.hpp&gt; works fine; b) the reason why the definition is required is referred in file wchar.h, as follows: </p> <p> /* C99 stds require WCHAR_MAX and WCHAR_MIN to be macros which </p> <blockquote> <p> can be used in #if constructs, hence, can't have casts Retaining the old macros for compatibility </p> </blockquote> <blockquote> <p> */ </p> </blockquote> <p> # if defined(_INCLUDE_STDC<span class="underline">SOURCE_199901) # define WCHAR_MAX UINT_MAX /* max value of an unsigned integer */ # define WCHAR_MIN 0 # else # define WCHAR_MAX (wchar_t)UINT_MAX /* max value of an unsigned integer */ # define WCHAR_MIN (wchar_t)0 # endif </span></p> </description> <category>Ticket</category> </item> <item> <dc:creator>Beman Dawes</dc:creator> <pubDate>Thu, 09 Jun 2011 19:43:47 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/5048#comment:3 https://svn.boost.org/trac10/ticket/5048#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> <p> (In <a class="changeset" href="https://svn.boost.org/trac10/changeset/72521" title="Fix #5048, for HP-UX">[72521]</a>) Fix <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/5048" title="#5048: Bugs: compilation error under ia64 HP-UX11i with gcc-4.4.0 (closed: fixed)">#5048</a>, for HP-UX </p> Ticket ruipfernandes@… Mon, 28 Jan 2013 13:54:15 GMT <link>https://svn.boost.org/trac10/ticket/5048#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/5048#comment:4</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/5048#comment:3" title="Comment 3">bemandawes</a>: </p> <blockquote class="citation"> <p> (In <a class="changeset" href="https://svn.boost.org/trac10/changeset/72521" title="Fix #5048, for HP-UX">[72521]</a>) Fix <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/5048" title="#5048: Bugs: compilation error under ia64 HP-UX11i with gcc-4.4.0 (closed: fixed)">#5048</a>, for HP-UX </p> </blockquote> <p> I'm updating from 1.45 to 1.52 now and I can tell this does not solve the problem. For some reason the define is required before getting to include this header. To compile successfully I had to define _INCLUDE_STDCSOURCE_199901 globally. </p> </description> <category>Ticket</category> </item> <item> <author>ruipfernandes@…</author> <pubDate>Mon, 28 Jan 2013 13:55:49 GMT</pubDate> <title>status, version changed; resolution deleted https://svn.boost.org/trac10/ticket/5048#comment:5 https://svn.boost.org/trac10/ticket/5048#comment:5 <ul> <li><strong>status</strong> <span class="trac-field-old">closed</span> → <span class="trac-field-new">reopened</span> </li> <li><strong>version</strong> <span class="trac-field-old">Boost 1.45.0</span> → <span class="trac-field-new">Boost 1.52.0</span> </li> <li><strong>resolution</strong> <span class="trac-field-deleted">fixed</span> </li> </ul> Ticket anonymous Tue, 12 Mar 2013 12:43:14 GMT <link>https://svn.boost.org/trac10/ticket/5048#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/5048#comment:6</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/5048#comment:4" title="Comment 4">ruipfernandes@…</a>: </p> <blockquote class="citation"> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/5048#comment:3" title="Comment 3">bemandawes</a>: </p> <blockquote class="citation"> <p> (In <a class="changeset" href="https://svn.boost.org/trac10/changeset/72521" title="Fix #5048, for HP-UX">[72521]</a>) Fix <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/5048" title="#5048: Bugs: compilation error under ia64 HP-UX11i with gcc-4.4.0 (closed: fixed)">#5048</a>, for HP-UX </p> </blockquote> <p> I'm updating from 1.45 to 1.52 now and I can tell this does not solve the problem. For some reason the define is required before getting to include this header. To compile successfully I had to define _INCLUDE_STDCSOURCE_199901 globally. </p> </blockquote> <p> I found what the problem is: the define is misspelled. Please fix to: _INCLUDE_STDC<span class="underline">SOURCE_199901 </span></p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Tue, 12 Mar 2013 12:44:11 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/5048#comment:7 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/5048#comment:7</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/5048#comment:6" title="Comment 6">anonymous</a>: </p> <blockquote class="citation"> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/5048#comment:4" title="Comment 4">ruipfernandes@…</a>: </p> <blockquote class="citation"> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/5048#comment:3" title="Comment 3">bemandawes</a>: </p> <blockquote class="citation"> <p> (In <a class="changeset" href="https://svn.boost.org/trac10/changeset/72521" title="Fix #5048, for HP-UX">[72521]</a>) Fix <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/5048" title="#5048: Bugs: compilation error under ia64 HP-UX11i with gcc-4.4.0 (closed: fixed)">#5048</a>, for HP-UX </p> </blockquote> <p> I'm updating from 1.45 to 1.52 now and I can tell this does not solve the problem. For some reason the define is required before getting to include this header. To compile successfully I had to define _INCLUDE_STDCSOURCE_199901 globally. </p> </blockquote> <p> I found what the problem is: the define is misspelled. Please fix to: </p> </blockquote> <pre class="wiki">_INCLUDE_STDC__SOURCE_199901 </pre> </description> <category>Ticket</category> </item> <item> <dc:creator>Beman Dawes</dc:creator> <pubDate>Fri, 15 Mar 2013 18:10:51 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/5048#comment:8 https://svn.boost.org/trac10/ticket/5048#comment:8 <ul> <li><strong>status</strong> <span class="trac-field-old">reopened</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> <p> (In <a class="changeset" href="https://svn.boost.org/trac10/changeset/83443" title="For HP-UX/GCC only, define _INCLUDE_STDC__SOURCE_199901 as a build ...">[83443]</a>) For HP-UX/GCC only, define _INCLUDE_STDC<span class="underline">SOURCE_199901 as a build requirement. Fix <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/5048" title="#5048: Bugs: compilation error under ia64 HP-UX11i with gcc-4.4.0 (closed: fixed)">#5048</a>. </span></p> Ticket