Re: decyphering ld's cryptic error messages
Re: decyphering ld's cryptic error messages
- Subject: Re: decyphering ld's cryptic error messages
- From: Stefan Werner <email@hidden>
- Date: Wed, 3 Aug 2005 18:06:28 +0200
Hi,
Date: Wed, 3 Aug 2005 12:20:02 +0200
From: Andreas Grosam <email@hidden>
I've spent the last few days reading man pages, FAQs and forums like
crazy, trying to resolve a simple linker error, linking my C++ app
against a static build of wxWidgets:
ld: Undefined symbols:
__ZTV14wxMenuItemList
Most likely, the symbol is just not *accessible* from another dynamic
shared object, because the symbol __ZTV14wxMenuItemList has not been
"exported". Since this is a vtable you need to export the whole class.
Are you talking about dynamic linking? I'm using a static build of
wxWidgets, I thought exporting symbols is only necessary for dylibs.
Please see also:
<http://developer.apple.com/releasenotes/DeveloperTools/GCC4.html>
<http://gcc.gnu.org/wiki/Visibility>
Thanks for these pointers, I'll have a look.
Note, for the GCC4 compiler all symbols will be exported by default.
I'm using gcc3.3, and to AFAIK exporting all symbols is the default
here too.
However, in XCode the default build settings for building a shared lib
is that all symbols will be "hidden".
Does this apply to both static and dynamic libraries?
So - either you change the
corresponding build settings (not recommeded) or you explicitly define
the visibility attribute in your source code - which i would do.
Both solutions sound not that exciting to me - if possible, I'd love
to use an unmodified wxWidgets to make it easier to upgrade to newer
versions.
Thanks for your help,
Stefan
_______________________________________________
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