diff options
author | Jake Petroules <jake.petroules@qt.io> | 2016-06-10 20:15:12 -0700 |
---|---|---|
committer | Jake Petroules <jake.petroules@qt.io> | 2016-06-15 22:18:29 +0000 |
commit | 05bd88bdd86b8204623ef4719cbe244d391edeac (patch) | |
tree | d925a1ee17621bc03a81ddd872fb5594570f119a /qmake/generators/unix/unixmake.cpp | |
parent | 792947da7e366c30ce1ecf0a365de6cf113fc35e (diff) |
Fix an issue causing qmake to generate corrupt Makefiles.
This resolves an issue where qmake would generate a Makefile with an
install command immediately followed by a test command, with no
intermediary newline and tab to separate them.
Task-number: QTBUG-54035
Change-Id: I7f9226f25e92b49ce689d252e9c4a58b877f2972
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Diffstat (limited to 'qmake/generators/unix/unixmake.cpp')
-rw-r--r-- | qmake/generators/unix/unixmake.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/qmake/generators/unix/unixmake.cpp b/qmake/generators/unix/unixmake.cpp index d2483459d8..122ecb0caa 100644 --- a/qmake/generators/unix/unixmake.cpp +++ b/qmake/generators/unix/unixmake.cpp @@ -606,8 +606,11 @@ UnixMakefileGenerator::defaultInstall(const QString &t) } else if (project->first("TEMPLATE") == "lib" && project->isActiveConfig("staticlib")) { copy_cmd += "-$(INSTALL_FILE) " + src_targ + ' ' + dst_targ; } else if (!isAux) { - if (bundle == SlicedBundle) - ret += mkdir_p_asstring("\"`dirname " + dst_targ + "`\"", false) + "\n\t"; + if (bundle == SlicedBundle) { + if (!ret.isEmpty()) + ret += "\n\t"; + ret += mkdir_p_asstring("\"`dirname " + dst_targ + "`\"", false); + } copy_cmd += "-$(INSTALL_PROGRAM) " + src_targ + ' ' + dst_targ; } if(project->first("TEMPLATE") == "lib" && !project->isActiveConfig("staticlib") |