Don't add default lib dirs to LIBRARY_SEARCH_PATHS in xcode projects
Having hard-coded absolute paths in the xcode project breaks switching
between iOS and simulator builds.
Fixes: QTBUG-77804
Change-Id: Ib655bfc774b92c413a7b94ba4d005b6e1c4d2905
(cherry picked from commit 97465b1540)
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
bb10
parent
7b82d27429
commit
abfb1b8665
|
|
@ -875,6 +875,7 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
|
|||
}
|
||||
|
||||
if(!project->isActiveConfig("staticlib")) { //DUMP LIBRARIES
|
||||
const ProStringList defaultLibDirs = project->values("QMAKE_DEFAULT_LIBDIRS");
|
||||
ProStringList &libdirs = project->values("QMAKE_PBX_LIBPATHS"),
|
||||
&frameworkdirs = project->values("QMAKE_FRAMEWORKPATH");
|
||||
static const char * const libs[] = { "LIBS", "LIBS_PRIVATE",
|
||||
|
|
@ -967,8 +968,10 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
|
|||
}
|
||||
if(slsh != -1) {
|
||||
const QString path = QFileInfo(library.left(slsh)).absoluteFilePath();
|
||||
if(!path.isEmpty() && !libdirs.contains(path))
|
||||
if (!path.isEmpty() && !libdirs.contains(path)
|
||||
&& !defaultLibDirs.contains(path)) {
|
||||
libdirs += path;
|
||||
}
|
||||
}
|
||||
library = fileFixify(library, FileFixifyFromOutdir | FileFixifyAbsolute);
|
||||
QString key = keyFor(library);
|
||||
|
|
|
|||
Loading…
Reference in New Issue