Project using Boost won't build with Xcode 4; complains about "global weak symbols"

Hi all. I'm using Boost in an iPhone app as a statically linked lib, and after updating to Xcode 4 the project won't build. It fails with this: *ld: bad codegen, pointer diff in boost::system::error_category:* *:error_category()to global weak symbol vtable for boost::system::error_**categoryfor architecture i386* Happens for both simulator and device, after the same project built fine under previous Xcodes. Anybody have some insight on this and a solution? Thanks! Gavin

I'm using Boost in an iPhone app as a statically linked lib, and after updating to Xcode 4 the project won't build. It fails with this:
ld: bad codegen, pointer diff in boost::system::error_category: :error_category()to global weak symbol vtable for boost::system::error_categoryfor architecture i386
Happens for both simulator and device, after the same project built fine under previous Xcodes.
Anybody have some insight on this and a solution?
I've also upgraded to Xcode4, and I'm struggling the same problems. So far, I've rebuilt boost with the new tool-chain, and I'm playing "Inline methods hidden" and "Symbols hidden by default" options of my project - it eliminates some linker errors, but adds some other...

Thanks for your response, Igor. If nothing else, I'm glad to hear I'm not the only one dealing with this. I'm now trying to move the necessary Boost source into my project and build it directly instead of linking to a lib. I need ASIO and System. The error of the moment is "system_error' is not a member of 'boost::system". If anyone has hints about compiling (non-header-only) parts of Boost directly in a project, I'd appreciate hearing them.

Don't know if this'll help, but I was able to get our project building by including the necessary parts of Boost in the project directly and building them along with our app. You might want to try that.
participants (2)
-
G S
-
Igor R