Boost C++ Libraries: Ticket #1228: bug in toolset gcc + HP/UX PA-RSIC https://svn.boost.org/trac10/ticket/1228 <p> On HP/UX PA-RSIC only aCC (HP compiler) version 3.x is available form HP. It is not able to compile to compile boost. aCC version 6.x and newer will never be ported to HP/UX PA-RISC. gcc is available for this platform - I suggest this should be the default compiler (PA-RISC not Itanium version of HP/UX). The config scripts pass wrong linker flags (which are only valid for gnu linker which is not available on the target platform). So the compilation failed. </p> <p> I provide two patches with following modifiactions: </p> <ul><li>gcc.jam: <ul><li>threading support (from gcc version 3.x up -&gt; compiler version needs to be checked in the file -&gt; not done yet) </li><li>enable build of shared libraries as default </li><li>change shared libraries extension to .sl </li><li>pass required '-fPIC' </li><li>add correct5 linker flags for HP/UX linker </li></ul></li></ul><ul><li>site_config.jam <ul><li>use HP/UX linker for gcc on HP/UX (but it needs a modification because I could not find out how to get the os version from bjam language -&gt; os.version seams not to work) </li></ul></li></ul><p> kind regards, Oliver </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/1228 Trac 1.4.3 anonymous Mon, 03 Sep 2007 14:17:33 GMT attachment set https://svn.boost.org/trac10/ticket/1228 https://svn.boost.org/trac10/ticket/1228 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">gcc.jam.patch</span> </li> </ul> Ticket anonymous Mon, 03 Sep 2007 14:18:26 GMT attachment set https://svn.boost.org/trac10/ticket/1228 https://svn.boost.org/trac10/ticket/1228 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">site-config.jam.patch</span> </li> </ul> Ticket oliver.kowalke@… Tue, 04 Sep 2007 12:02:36 GMT <link>https://svn.boost.org/trac10/ticket/1228#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1228#comment:1</guid> <description> <p> gcc.jam.2.patch contains another compiler option in order to compile date_time library on HPUX </p> </description> <category>Ticket</category> </item> <item> <author>oliver.kowalke@…</author> <pubDate>Wed, 05 Sep 2007 08:31:27 GMT</pubDate> <title>attachment set https://svn.boost.org/trac10/ticket/1228 https://svn.boost.org/trac10/ticket/1228 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">gcc.jam.2.patch</span> </li> </ul> <p> some corrections </p> Ticket Boris Gubenko Wed, 26 Sep 2007 16:00:53 GMT attachment set https://svn.boost.org/trac10/ticket/1228 https://svn.boost.org/trac10/ticket/1228 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">gcc.jam.3.patch</span> </li> </ul> <p> patch for gcc.jam tested on both HP-UX/ia64 and HP-UX PA-RISC </p> Ticket Boris Gubenko Wed, 26 Sep 2007 16:17:40 GMT <link>https://svn.boost.org/trac10/ticket/1228#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1228#comment:2</guid> <description> <p> I've just added attachement: gcc.jam.3.patch. This patch was tested on both HP-UX/ia64 and PA-RISC with gcc 4.2.1 and 3.4.2, respectively. The results are on the web: see tables for runner_id HP-UX_ia64_gcc and HP-UX_pa_risc_gcc, respectively. Oliver did independent testing on PA-RISC with gcc 3.4.4 and confirmed that modified gcc.jam works. </p> <p> Both Oliver and I agree that modified gcc.jam which adds support for HP-UX, both ia64 and PA-RISC, is ready for the prime time. Please review changes and, if they look OK, either apply the patch or let me know and I'll check gcc.jam in myself. </p> <p> Thanks, </p> <blockquote> <p> Boris </p> </blockquote> </description> <category>Ticket</category> </item> <item> <dc:creator>Vladimir Prus</dc:creator> <pubDate>Mon, 01 Oct 2007 17:39:40 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/1228#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1228#comment:3</guid> <description> <p> I have applied the gcc.jam patch, thanks. I did not apply site-config.jam patch -- first, it appears to be against already modified version -- the one in SVN has nothing but copyright, and second, the file is intentionally empty. Finally, you comment say you've changed the extension of shared lib files on HP-UX, and I don't see any such change -- did you forgot to attach something? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Boris Gubenko</dc:creator> <pubDate>Mon, 01 Oct 2007 18:13:16 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/1228#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1228#comment:4</guid> <description> <p> Thanks for applying the patch (and for moving flags gcc.link OPTIONS &lt;runtime-link&gt;static to a more logical spot). </p> <p> As for the file extension, Oliver and I have discussed this issue and have agreed that this is more of a "cosmetic" one because the existing file extension: .so, common to all Unix platforms, does not prevent Linker or loader on HP-UX from linking/activating shared Boost libraries. This is why I did not do anything about file extension in the patch for gcc.jam. </p> <p> If we want to change file extension for Boost shared libraries on HP-UX (and I'm not sure we do), it is more than just gcc.jam and it deserves a separate ticket, I believe. </p> <p> Thanks again, </p> <blockquote> <p> Boris </p> </blockquote> </description> <category>Ticket</category> </item> <item> <dc:creator>Vladimir Prus</dc:creator> <pubDate>Mon, 01 Oct 2007 18:21:57 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/1228#comment:5 https://svn.boost.org/trac10/ticket/1228#comment:5 <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> Okay, I'm closing this issue. Thanks. </p> Ticket Oliver Tue, 02 Oct 2007 06:34:38 GMT <link>https://svn.boost.org/trac10/ticket/1228#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1228#comment:6</guid> <description> <blockquote class="citation"> <p> I did not apply site-config.jam patch -- first, it appears to be against already modified version -- the one in SVN has nothing but copyright, and second, the file is intentionally empty. </p> </blockquote> <p> Isn't it required that I put 'using gcc : : : &lt;compileflags&gt;"-fPIC" ;' into site-config.jam or user-config.jam in order to get the possition idepended code? Oliver </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Vladimir Prus</dc:creator> <pubDate>Tue, 02 Oct 2007 06:44:22 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/1228#comment:7 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1228#comment:7</guid> <description> <p> Usually, -fPIC is needed only for shared libraries. This is handled by this code: </p> <pre class="wiki"> flags gcc.compile OPTIONS &lt;link&gt;shared : -fPIC ; </pre><p> is there a reason this is not sufficient on HP-UX? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Oliver</dc:creator> <pubDate>Tue, 02 Oct 2007 06:58:46 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/1228#comment:8 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1228#comment:8</guid> <description> <p> Yes - I've checked it. The patch works. Thanks! Oliver </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Boris Gubenko</dc:creator> <pubDate>Tue, 02 Oct 2007 11:55:06 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/1228#comment:9 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1228#comment:9</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/1228#comment:7" title="Comment 7">vladimir_prus</a>: </p> <blockquote class="citation"> <p> Usually, -fPIC is needed only for shared libraries. This is handled by this code: </p> <pre class="wiki"> flags gcc.compile OPTIONS &lt;link&gt;shared : -fPIC ; </pre><p> is there a reason this is not sufficient on HP-UX? </p> </blockquote> <p> Just for the record: on HP-UX/PA-RISC, -fPIC on the compile command is not sufficient. On this platform, when building shared library, -fPIC should also be explicitly specified on the link command. This is handled by: </p> <blockquote> <p> flags $(toolset).link OPTIONS $(condition)/&lt;link&gt;shared : -fPIC </p> <blockquote> <p> : unchecked ; </p> </blockquote> </blockquote> <p> inside 'case hpux :'. </p> <p> On HP-UX/ia64, -fPIC is not necessary, but specifying it does not do any harm. </p> <p> Thanks, </p> <blockquote> <p> Boris </p> </blockquote> </description> <category>Ticket</category> </item> </channel> </rss>