I had to find this out through experimentation and trial and error. I was unable to find any documentation out there for this afaik; if there is, I would be happy to see it.
You'll have to manually edit your project.pbxproj
file. Find the setting you want to change (making sure it belongs to the correct target and configuration), and change it from
LIBRARY_SEARCH_PATHS = (
/library/search/path/1,
/library/search/path/2,
/library/search/path/3,
);
to
"LIBRARY_SEARCH_PATHS[sdk=iphonesimulator*][arch=x86_64]" = (
/library/search/path/1,
/library/search/path/2,
/library/search/path/3,
);
A few things to note:
- When you add an option, make sure you add quotation marks, otherwise Xcode will not be able to parse the
project.pbxproj
file.
- If you need to add more than one specific option, add another square-bracket delimited item like so
[arch=x86_64]
.
The full list of sdk
s (as of this writing) comprise
iphonesimulator
iphoneos
watchos
watchsimulator
appletvos
appletvsimulator
macosx
Edit: Please also note that the build system distinguishes between iphoneos
(iOS device) and iphonesimulator
, so if a build isn't working, double check your [sdk=...]
settings!