Boost C++ Libraries: Ticket #4664: libboost_zlib + libboost_iostreams - link error (XCode, MacOSX) https://svn.boost.org/trac10/ticket/4664 <p> String for build boost: </p> <p> sudo bjam toolset=darwin architecture=combined address-model=32 threading=multi link=static runtime-link=static -sNO_COMPRESSION=0 -sNO_ZLIB=0 -sZLIB_SOURCE="../../../../../zlib123" stage </p> <p> After building I linking this libraries into my application: libboost_iostreams.a libboost_zlib.a </p> <p> But linker say: </p> <p> Undefined symbols: "std::bad_alloc::what() const", referenced from: vtable for boost::exception_detail::error_info_injector&lt;std::bad_alloc&gt;in libboost_iostreams.a(zlib.o) vtable for boost::exception_detail::clone_impl&lt;boost::exception_detail::error_info_injector&lt;std::bad_alloc&gt; &gt;in libboost_iostreams.a(zlib.o) </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/4664 Trac 1.4.3 Vicente Botet <vicente.botet@…> Tue, 07 Dec 2010 20:05:55 GMT <link>https://svn.boost.org/trac10/ticket/4664#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/4664#comment:1</guid> <description> <p> "std::bad_alloc::what() const" is part of the standard library. Please check if you are linking with. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Fri, 31 Dec 2010 15:21:54 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/4664#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/4664#comment:2</guid> <description> <p> Can confirm the problem here, for me this occurs when compiling with gcc 4.2 against the MacOS 10.5 SDK (and MACOSX_DEPLOYMENT_TARGET=10.5). </p> <p> Linking works if I compile with gcc 4.0, but then another libstdc++ symbol can not be resolved at runtime on MacOS 10.5 (Symbol not found: <span class="underline">ZNKSt9exception4whatEv). </span></p> <p> This is probably caused by ABI incompatibilites between gcc 4.0 and gcc 4.2, if anyone has any suggestions how to build boost on MacOS 10.5 with gcc 4.2 this would be appreciated. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Mon, 17 Jan 2011 23:21:04 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/4664#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/4664#comment:3</guid> <description> <p> I got the same error. But I "solved" it in this way: use boost 1.42 rather than 1.44 or 1.45. I use gcc 4.2. I have tried boot 1.44 and 1.45. They both give me a linker error. By 1.45, I got this instead: </p> <p> boost::iostreams::detail::bzip2_base::check_end(char const*, char const*)", referenced from: boost::iostreams::detail::bzip2_decompressor_impl&lt;std::allocator&lt;char&gt; &gt;::filter(char const*&amp;, char const*, char*&amp;, char*, bool)in main.o ld: symbol(s) not found </p> <p> Has something changed from 1.42 to 1.44? Anybody know how to let boost 1.45 works with zlib / libbzip2 ? </p> </description> <category>Ticket</category> </item> <item> <author>Walter Warniaha <walter.warniaha@…></author> <pubDate>Sun, 30 Jan 2011 17:14:17 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/4664#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/4664#comment:4</guid> <description> <p> The 10.5 and 10.6 SDK bad_alloc class differs by the method "what". My guess is that boost is compiling against the 10.6 header files when asked to use the 10.5 SDK. </p> </description> <category>Ticket</category> </item> </channel> </rss>