Undefined lookup, ObjC, and 64-bit
Undefined lookup, ObjC, and 64-bit
- Subject: Undefined lookup, ObjC, and 64-bit
- From: Nick Zitzmann <email@hidden>
- Date: Sat, 10 May 2008 16:35:39 -0600
I've got an application that loads some bundles. The bundles each
contain an ObjC class that subclasses an abstract class that exists in
the application. The bundles are compiled with the "-undefined
dynamic_lookup" linker flag so that the linker will link the code
without the presence of the superclass in the bundle.
This works fine when the app is running as 32-bit, but when it's
running in 64-bit, the app fails to load the bundles, and generates a
warning like this:
2008-05-10 00:45:42.856 TestApp[28170:813] Error loading /Users/
nickzman/Build/Debug/TestApp.app/Contents/Resources/MyPlugin.bundle/
Contents/MacOS/MyBundle: dlopen(/Users/nickzman/Build/Debug/
TestApp.app/Contents/Resources/MyPlugin.bundle/Contents/MacOS/
MyBundle, 265): Symbol not found: _OBJC_CLASS_$_PluginSuperclass
Referenced from: /Users/nickzman/Build/Debug/TestApp.app/Contents/
Resources/MyPlugin.bundle/Contents/MacOS/MyBundle
Expected in: dynamic lookup
Yes, both the app and the plugins are being built using the same
architecture (x86_64). And yes, PluginSuperclass does exist in the
app. So now I need to know:
1. Why does this happen in 64-bit but not 32-bit?
2. How do I fix this without building the abstract superclass into
each bundle (which is wasteful)?
Nick Zitzmann
<http://seiryu.home.comcast.net/>
S/MIME signature available upon request
_______________________________________________
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