Re: Xcode 2.2: /usr/bin/ld: Undefined symbols: __Unwind_Resume
Re: Xcode 2.2: /usr/bin/ld: Undefined symbols: __Unwind_Resume
- Subject: Re: Xcode 2.2: /usr/bin/ld: Undefined symbols: __Unwind_Resume
- From: Dave McCaldon <email@hidden>
- Date: Mon, 21 Nov 2005 13:38:47 -0500
It's a bit of a catch-22.
Hmmm ... the problem is that this is actually an apache module built by apxs, which in turn uses their own libtool (in $PREFIX/build) to do the actual linking.
Are there any LDOPTS I can pass to make ld be in "C++" mode?
I guess I can edit the libtool script, but then I'm not sure I'll be able to compile C-only modules anymore!
Thanks.
On Nov 21, 2005, at 12:58 PM, Eric Albert wrote: On Nov 21, 2005, at 9:49 AM, Dave McCaldon wrote: Since upgrading to Xcode 2.2, I now get the following error when building a shared library project:
/usr/bin/ld: Undefined symbols: __Unwind_Resume collect2: ld returned 1 exit status
I've seen references suggesting to remove /usr/local/lib/libgcc.dylib, but I don't have that.
This is usually the result of having C++ code in your project but using gcc (not g++) as the linker. In Xcode, which ensures that g++ is used to link if it knows you have any C++ files, this typically can only arise when you use C++ in a static library that you're linking in, but all of the source files in your project are C files.
The simplest solution is to either change the type of a trivial file in your project to 'sourcecode.cpp.cpp' or to add a custom variable of LD to your target settings with a value of 'g++'. Either one should work.
Hope this helps, Eric
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden