Re: Problem excluding /usr/local/lib
Re: Problem excluding /usr/local/lib
- Subject: Re: Problem excluding /usr/local/lib
- From: Rick Altherr <email@hidden>
- Date: Tue, 26 Feb 2008 12:23:59 -0800
On Feb 26, 2008, at 12:03 PM, David Hoerl wrote:
I build and install my own libtiff.a/dylib in /usr/local/lib, which
causes a known conflict when including one (or more) of Apple's
Frameworks (have a open bug on this, others have reported the same
problem on this forum).
Right now, this is biting me as I am trying to build someone else's
framework, and I am struggling to get around this.
My goal is to exclude /usr/local/lib from the load line. Since this
is hardcoded into gcc's ld, I have to exclude the standard
directories with "-Z" and then include the ones I want later.
"Link with Standard Libraries" is unchecked.
I don't think you want that unchecked. You just want to change the
search paths for ld, not the standard libraries that are linked against.
In "Other Linker Flags", I put this:
-Z -L/usr/lib -F/Library/Frameworks -F/System/Library/Frameworks
Do a clean all first, then rebuild. Some library is not getting
picked up, but I cannot see how this could possibly be in /usr/local/
lib. There must be another standard search path I'm missing, but I
don't know what it is.
David
PS: this the failing ld line, and a few of the messages:
cd /Volumes/Data/Users/dhoerl/Development/ObjC-appscript/objc-
appscript/src/Appscript
/Developer/usr/bin/gcc-4.0 -o /Volumes/Data/Users/dhoerl/
Development/ObjC-appscript/objc-appscript/src/Appscript/build/
Appscript.build/Release/Appscript.build/Objects-normal/ppc/Appscript
-L/Volumes/Data/Users/dhoerl/Development/ObjC-appscript/objc-
appscript/src/Appscript/build/Release -L/Developer/SDKs/
MacOSX10.4u.sdk/usr/lib -F/Volumes/Data/Users/dhoerl/Development/
ObjC-appscript/objc-appscript/src/Appscript/build/Release -filelist /
Volumes/Data/Users/dhoerl/Development/ObjC-appscript/objc-appscript/
src/Appscript/build/Appscript.build/Release/Appscript.build/Objects-
normal/ppc/Appscript.LinkFileList -framework Carbon -framework
CoreFoundation -framework Foundation -arch ppc -Wl,-single_module -
compatibility_version 1 -current_version 1 -install_name /Volumes/
Data/Users/dhoerl/Library/Frameworks/Appscript.framework/Versions/A/
Appscript -dynamiclib -nostdlib -mmacosx-version-min=10.4 -Z -L/usr/
lib -F/Library/Frameworks -F/System/Library/Frameworks -isysroot /
Developer/SDKs/MacOSX10.4u.sdk
Undefined symbols:
"_mach_port_allocate", referenced from:
_AEMSendMessageThreadSafe in sendthreadsafe.o
"_pthread_key_create", referenced from:
_InitRoutine in sendthreadsafe.o
"_pthread_mutex_unlock", referenced from:
These are all defined in libSystem.dylib. Since you aren't linking
against the standard libraries, you would need to explicitly link
against libSystem with a -lSystem. I think you probably just want to
check the link with standard libraries option.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
@apple.com
This email sent to email@hidden
--
Rick Altherr
Architecture and Performance Group
email@hidden
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
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