diff options
author | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2016-04-29 11:34:14 +0200 |
---|---|---|
committer | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2016-05-02 18:34:59 +0000 |
commit | 49f92f9ab75f5fcc086543d9dbcc025c37677715 (patch) | |
tree | 8e8f91f60611b421f1c069dba5da6e35bfda031e /qmake | |
parent | ce044ce3482b5abc85ecaf42842df1d4a5ad7806 (diff) |
add some missing filename expandos to extra compilers
- QMAKE_FILE_IN_EXT as an alias for QMAKE_FILE_EXT, for consistency with
QMAKE_FILE_IN_BASE
- QMAKE_FILE_IN_NAME to make pairing _EXT/_BASE to get a full name
unnecessary (finally ...), and make use of it
- QMAKE_FILE_OUT_PATH, because i'll need it
Change-Id: I3d91ddb84f9cce52a665d562da11d165c92550c8
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Diffstat (limited to 'qmake')
-rw-r--r-- | qmake/generators/makefile.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp index 66d0b91d61..a596474669 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp @@ -1619,7 +1619,7 @@ MakefileGenerator::replaceExtraCompilerVariables( base = fi.fileName(); val += base; } - } else if(var == QLatin1String("QMAKE_FILE_EXT")) { + } else if (var == QLatin1String("QMAKE_FILE_EXT") || var == QLatin1String("QMAKE_FILE_IN_EXT")) { filePath = true; for(int i = 0; i < in.size(); ++i) { QFileInfo fi(fileInfo(Option::normalizePath(in.at(i)))); @@ -1632,6 +1632,10 @@ MakefileGenerator::replaceExtraCompilerVariables( ext = fi.fileName().remove(0, baseLen); val += ext; } + } else if (var == QLatin1String("QMAKE_FILE_IN_NAME")) { + filePath = true; + for (int i = 0; i < in.size(); ++i) + val += fileInfo(Option::normalizePath(in.at(i))).fileName(); } else if(var == QLatin1String("QMAKE_FILE_PATH") || var == QLatin1String("QMAKE_FILE_IN_PATH")) { filePath = true; for(int i = 0; i < in.size(); ++i) @@ -1648,6 +1652,10 @@ MakefileGenerator::replaceExtraCompilerVariables( filePath = true; const ProKey funcname = var.mid(20).toKey(); val += project->expand(funcname, QList<ProStringList>() << ProStringList(out)); + } else if (var == QLatin1String("QMAKE_FILE_OUT_PATH")) { + filePath = true; + for (int i = 0; i < out.size(); ++i) + val += fileInfo(Option::normalizePath(out.at(i))).path(); } else if(var == QLatin1String("QMAKE_FILE_OUT")) { filePath = true; for(int i = 0; i < out.size(); ++i) |