diff options
author | Liang Qi <liang.qi@theqtcompany.com> | 2015-11-18 09:01:51 +0100 |
---|---|---|
committer | Liang Qi <liang.qi@theqtcompany.com> | 2015-11-18 09:01:51 +0100 |
commit | c7934f2489e2eb9a539206bab35f335b1943c5bd (patch) | |
tree | a27d0ed6c001fe9432e2a0f28fb935acf9e4c65f /qmake/generators/mac/pbuilder_pbx.cpp | |
parent | f40593b11199fbef886bfcb6b210a214d8c3adf3 (diff) | |
parent | 08f9a1bd6ab9b1777ee5ba163d75e5c848c39eb4 (diff) |
Merge remote-tracking branch 'origin/5.6' into dev
Conflicts:
src/corelib/io/qprocess.cpp
src/corelib/io/qprocess_unix.cpp
src/network/kernel/qnetworkinterface_winrt.cpp
tools/configure/configureapp.cpp
Change-Id: I47df00a01597d2e63b334b492b3b4221b29f58ea
Diffstat (limited to 'qmake/generators/mac/pbuilder_pbx.cpp')
-rw-r--r-- | qmake/generators/mac/pbuilder_pbx.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/qmake/generators/mac/pbuilder_pbx.cpp b/qmake/generators/mac/pbuilder_pbx.cpp index ccb3cfe810..42dd6c8aeb 100644 --- a/qmake/generators/mac/pbuilder_pbx.cpp +++ b/qmake/generators/mac/pbuilder_pbx.cpp @@ -853,8 +853,15 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t) QString librarySuffix = project->first("QMAKE_XCODE_LIBRARY_SUFFIX").toQString(); suffixSetting = "$(" + suffixSetting + ")"; if (!librarySuffix.isEmpty()) { - library.replace(librarySuffix, suffixSetting); - name.remove(librarySuffix); + int pos = library.lastIndexOf(librarySuffix + '.'); + if (pos == -1) { + warn_msg(WarnLogic, "Failed to find expected suffix '%s' for library '%s'.", + qPrintable(librarySuffix), qPrintable(library)); + } else { + library.replace(pos, librarySuffix.length(), suffixSetting); + if (name.endsWith(librarySuffix)) + name.chop(librarySuffix.length()); + } } else { library.replace(name, name + suffixSetting); } |