Boost C++ Libraries: Ticket #7647: b2 incompatible with _STLP_LIB_NAME_MOTIF in stlport (no library names flexibility) - fatal error LNK1181: cannot open input file 'stlportstld.5.2.lib https://svn.boost.org/trac10/ticket/7647 <p> B2 seems too rigid with the searched libraries names used for stlport. It causes problems for someone who needs to use names a suffix _STLP_LIB_NAME_MOTIF that is not empty (see stlport/stl/config/user-config.h). </p> <p> Here I explain the context the context. I've tried (succcessfully) to build boost_1_52 with stlport.5.2.1 with Microsoft vs 2010 (vc10) </p> <p> I've essentially used what suggested in <a class="ext-link" href="http://www.lenholgate.com/blog/2010/07/stlport-521-and-vs2010-and-x64.html"><span class="icon">​</span>http://www.lenholgate.com/blog/2010/07/stlport-521-and-vs2010-and-x64.html</a>. <br /> The author of the pages uses _STLP_LIB_NAME_MOTIF in order to specify the compiler's name in the library name, which is what I need too. </p> <p> To build with stlport I've followed the usual procedure: </p> <p> 1- added in tools/build/v2/user-config.jam the lines<br /> </p> <blockquote> <p> using msvc : 10.0 ; using stlport : 5.2.1 : &lt;my_path_to_stlport&gt;/STLport-5.2.1/stlport : &lt;my_path_to_stlport&gt;/STLport-5.2.1/lib/vc10 ; </p> </blockquote> <p> 2- and issued the command:<br /> .\tools\build\v2\b2.exe stdlib=stlport-5.2.1 toolset=msvc-10.0 debug/define=_STLP_DEBUG release --build-type=complete stage </p> <p> What I get is a linking error to the stlport libraries when doing link=shared threading=multi (for example with --with-system)<br /> the message error is: LINK : fatal error LNK1181: cannot open input file 'stlportstld.5.2.lib' </p> <p> This is because stlport.jam ((probably this jam file) <strong>forces</strong> the link to the stlport with its own names, therefore <strong>bypassing</strong> what is specified in the file STLport-5.2.1\stlport\stl\config\_auto_link.h </p> <p> I wonder why this choice, considering that life was beautiful years ago when this everything was delegated to stlport\stl\config\_auto_link.h. I imagine you had your own reasons. </p> <p> <br /> <br /> </p> <p> Things therefore work if I do:<br /> </p> <p> tools/build/v2/user-config.jam:<br /> </p> <blockquote> <p> using msvc : 10.0 ; using stlport : vc10.5.2.1 : &lt;my_path_to_stlport&gt;/STLport-5.2.1/stlport : &lt;my_path_to_stlport&gt;/STLport-5.2.1/lib/vc10 ; </p> </blockquote> <p> and issue the command:<br /> </p> <blockquote> <p> .\tools\build\v2\b2.exe stdlib=stlport-vc10.5.2.1 toolset=msvc-10.0 debug/define=_STLP_DEBUG release --build-type=complete stage </p> </blockquote> <p> But still there is one strange behaviour which is problematic.<br /> </p> <p> Let's take tools/build/v2/user-config.jam again<br /> </p> <blockquote> <p> with<br /> </p> <blockquote> <p> using stlport : 5.2.1 : ....<br /> the library searched was stlportstld.5.2.lib </p> </blockquote> </blockquote> <p> <br /> </p> <blockquote> <p> with<br /> </p> <blockquote> <p> using stlport : vc10.5.2.1 : ....<br /> the library searched was stlportstldvc10.5.2.lib </p> </blockquote> </blockquote> <p> <br /> </p> <blockquote> <p> with<br /> </p> <blockquote> <p> using stlport : xyz.5.2.1 : ....<br /> the library searched was stlportstldvc10.5.2.lib i.e. not stlportstldxyz.5.2.lib <br /> </p> </blockquote> </blockquote> <p> And this is a problem, as people may want to build to the stlport libraries also when their name name is modified according to the _STLP_LIB_NAME_MOTIF macro in stlport/stl/config/user-config.h. Hope this will be fixed, if you agree this is a limitation. Again, I wish everything would be left to what is specified in STLport-5.2.1\stlport\stl\config\_auto_link.h </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/7647 Trac 1.4.3 Marcello Pietrobon <marcello.pietrobon@…> Sat, 10 Nov 2012 23:59:35 GMT <link>https://svn.boost.org/trac10/ticket/7647#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7647#comment:1</guid> <description> <p> I have checked again this ticket I made and actually I see that the statement I made: <br /> <em>This is because stlport.jam ((probably this jam file) <strong>forces</strong> the link to the stlport with its own names, therefore <strong>bypassing</strong> what is specified in the file STLport-5.2.1\stlport\stl\config\_auto_link.h</em> <br /> is not true. </p> <p> I made a different change in STLport-5.2.1\stlport\stl\config\_auto_link.h and things work fine now. </p> <p> I still find there is something puzzling with a jam file (stlport.jam?), because it's still true the part that I wrote above that I'm repeating here: </p> <pre class="wiki">with using stlport : 5.2.1 : .... the library searched was stlportstld.5.2.lib with using stlport : vc10.5.2.1 : .... the library searched was stlportstldvc10.5.2.lib with using stlport : xyz.5.2.1 : .... the library searched was stlportstldvc10.5.2.lib i.e. not stlportstldxyz.5.2.lib </pre><p> Unfortunately I don't have time to further investigate the reason of this behaviour. Thanks. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>viboes</dc:creator> <pubDate>Thu, 03 Jan 2013 16:42:25 GMT</pubDate> <title>component changed; owner set https://svn.boost.org/trac10/ticket/7647#comment:2 https://svn.boost.org/trac10/ticket/7647#comment:2 <ul> <li><strong>owner</strong> set to <span class="trac-author">Vladimir Prus</span> </li> <li><strong>component</strong> <span class="trac-field-old">Building Boost</span> → <span class="trac-field-new">build</span> </li> </ul> Ticket