Xcode uses the wrong version of lib because of hidden search paths?
Xcode uses the wrong version of lib because of hidden search paths?
- Subject: Xcode uses the wrong version of lib because of hidden search paths?
- From: G S <email@hidden>
- Date: Mon, 23 Aug 2010 20:20:15 -0700
Hi all.
I built two versions of a lib, one for iOS device (v. 4) and one for
the simulator. Of course, I have to swap them when changing build
targets and compiling (BTW, is there a better solution?). When
building for the device, the compiler complained that the lib didn't
contain the right architecture. Then I noticed that the path to the
complained-about lib wasn't the one included in the project at all.
An examination of the Xcode project file reveals that, when you add
files to Frameworks, Xcode adds library search paths to the project:
/* Begin XCBuildConfiguration section */
1D6058940D05DD3E006BFB54 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COPY_PHASE_STRIP = NO;
GCC_DYNAMIC_NO_PIC = NO;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Stpix_Prefix.pch;
INFOPLIST_FILE = "Stpix-Info.plist";
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/libs/Release-iphonesimulator\"",
"\"$(SRCROOT)/libs/Release-iphoneos\"",
);
If you have libs with the same name, Xcode will use the wrong one if
its directory appears first in the search paths, apparently. It isn't
using the full path of the file that's included in the project.
Does anyone know if this bug's already filed? This is in Xcode 3.2.3.
_______________________________________________
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