diff options
author | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2015-05-20 10:48:20 +0200 |
---|---|---|
committer | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2015-05-20 18:11:44 +0000 |
commit | 12106b66b927749d0c81d59535d854520e8f26ba (patch) | |
tree | ffba1b9b72b67bd11dc1e6400e875b41fd316a30 /qmake | |
parent | 6e3ba36a067f180c530f6c2116a97f78b1bf7cc8 (diff) | |
download | qtbase-12106b66b927749d0c81d59535d854520e8f26ba.tar.gz |
move symlinking loop into the symlink container emptiness conditional
it obviously makes no sense to set up the loop if the container is empty.
as we now have that conditional anyway ...
Change-Id: I6d95c0102734852443c188012bfcb076d879581e
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Diffstat (limited to 'qmake')
-rw-r--r-- | qmake/generators/unix/unixmake2.cpp | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/qmake/generators/unix/unixmake2.cpp b/qmake/generators/unix/unixmake2.cpp index 98a01b21aa..92a7876784 100644 --- a/qmake/generators/unix/unixmake2.cpp +++ b/qmake/generators/unix/unixmake2.cpp @@ -922,17 +922,18 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t) } } } - QString bundle_dir_f = escapeFilePath(bundle_dir); - QHash<QString, QString>::ConstIterator symIt = symlinks.constBegin(), - symEnd = symlinks.constEnd(); - for (; symIt != symEnd; ++symIt) { - bundledFiles << symIt.key(); - alldeps << symIt.key(); - t << escapeDependencyPath(symIt.key()) << ":\n\t" - << mkdir_p_asstring(bundle_dir) << "\n\t" - << "@$(SYMLINK) " << escapeFilePath(symIt.value()) << ' ' << bundle_dir_f << endl; - } if (!symlinks.isEmpty()) { + QString bundle_dir_f = escapeFilePath(bundle_dir); + QHash<QString, QString>::ConstIterator symIt = symlinks.constBegin(), + symEnd = symlinks.constEnd(); + for (; symIt != symEnd; ++symIt) { + bundledFiles << symIt.key(); + alldeps << symIt.key(); + t << escapeDependencyPath(symIt.key()) << ":\n\t" + << mkdir_p_asstring(bundle_dir) << "\n\t" + << "@$(SYMLINK) " << escapeFilePath(symIt.value()) << ' ' << bundle_dir_f << endl; + } + QString currentLink = bundle_dir + "Versions/Current"; QString currentLink_f = escapeDependencyPath(currentLink); bundledFiles << currentLink; |