diff options
author | Oswald Buddenhagen <oswald.buddenhagen@digia.com> | 2012-11-26 20:56:50 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-11-27 19:31:21 +0100 |
commit | 80b99a6dd74c07a1140ab14459b73171b9e681dc (patch) | |
tree | 638485e95c568cee04db2f8c7f073369d4a04095 /qmake/generators | |
parent | 8c0787a8a9f1c485d62cb7bdefeb07a70beff5e7 (diff) |
assign MAKEFILE even in non-subdirs Makefiles
this is necessary for having a clean way to recurse even from leaf
makefiles.
the location where the variable is written in the makefile is somewhat
bizarre, but the code is so convoluted that finding a better place would
mean either a lot of duplication or a lot of prior refactoring.
Change-Id: I68e4cf7e3814f6c60b2e3421d69775c993dafb23
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Diffstat (limited to 'qmake/generators')
-rw-r--r-- | qmake/generators/makefile.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp index d6e5eb8898..22772f8392 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp @@ -2192,6 +2192,11 @@ MakefileGenerator::writeStubMakefile(QTextStream &t) bool MakefileGenerator::writeMakefile(QTextStream &t) { + QString ofile = Option::fixPathToTargetOS(Option::output.fileName()); + if (ofile.lastIndexOf(Option::dir_sep) != -1) + ofile.remove(0, ofile.lastIndexOf(Option::dir_sep) +1); + t << "MAKEFILE = " << ofile << endl << endl; + t << "####### Compile" << endl << endl; writeObj(t, "SOURCES"); writeObj(t, "GENERATED_SOURCES"); |