diff options
Diffstat (limited to 'qmake')
-rw-r--r-- | qmake/generators/makefile.cpp | 11 | ||||
-rw-r--r-- | qmake/generators/metamakefile.cpp | 13 | ||||
-rw-r--r-- | qmake/generators/unix/unixmake.cpp | 2 | ||||
-rw-r--r-- | qmake/generators/unix/unixmake2.cpp | 1 | ||||
-rw-r--r-- | qmake/project.cpp | 10 | ||||
-rw-r--r-- | qmake/qmake.pri | 1 |
6 files changed, 16 insertions, 22 deletions
diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp index 5f38bc7..b68f66c 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp @@ -291,7 +291,6 @@ MakefileGenerator::initOutPaths() if(Option::fixPathToLocalOS(d.absolutePath()) == Option::fixPathToLocalOS(Option::output_dir)) v.remove("DESTDIR"); } - QDir::current().cd(currentDir); } QMakeProject @@ -1948,7 +1947,8 @@ MakefileGenerator::writeExtraCompilerTargets(QTextStream &t) for(int i = 0; i < pre_deps.size(); ++i) deps += replaceExtraCompilerVariables(pre_deps.at(i), (*input), out); } - QString cmd; + QString cmd = replaceExtraCompilerVariables(tmp_cmd, (*input), out); + // NOTE: The var -> QMAKE_COMP_var replace feature is unsupported, do not use! if (isForSymbianSbsv2()) { // In sbsv2 the command inputs and outputs need to use absolute paths cmd = replaceExtraCompilerVariables(tmp_cmd, @@ -2538,7 +2538,12 @@ MakefileGenerator::writeSubTargets(QTextStream &t, QList<MakefileGenerator::SubT t << suffix << ":"; for(int target = 0; target < targets.size(); ++target) { - QString targetRule = targets.at(target)->target + "-" + suffix; + SubTarget *subTarget = targets.at(target); + if((suffix == "make_first" || suffix == "make_default") + && project->values(subTarget->name + ".CONFIG").indexOf("no_default_target") != -1) { + continue; + } + QString targetRule = subTarget->target + "-" + suffix; if(flags & SubTargetOrdered) targetRule += "-ordered"; t << " " << targetRule; diff --git a/qmake/generators/metamakefile.cpp b/qmake/generators/metamakefile.cpp index 5a77271..5494b5d 100644 --- a/qmake/generators/metamakefile.cpp +++ b/qmake/generators/metamakefile.cpp @@ -290,12 +290,11 @@ SubdirsMetaMakefileGenerator::init() if(Option::recursive) { QString old_output_dir = QDir::cleanPath(Option::output_dir); - if(!old_output_dir.endsWith('/')) - old_output_dir += '/'; QString old_output = Option::output.fileName(); QString oldpwd = QDir::cleanPath(qmake_getpwd()); - if(!oldpwd.endsWith('/')) - oldpwd += '/'; + QString thispwd = oldpwd; + if(!thispwd.endsWith('/')) + thispwd += '/'; const QStringList &subdirs = project->values("SUBDIRS"); static int recurseDepth = -1; ++recurseDepth; @@ -315,8 +314,8 @@ SubdirsMetaMakefileGenerator::init() sub_name = subdir.baseName(); if(!subdir.isRelative()) { //we can try to make it relative QString subdir_path = subdir.filePath(); - if(subdir_path.startsWith(oldpwd)) - subdir = QFileInfo(subdir_path.mid(oldpwd.length())); + if(subdir_path.startsWith(thispwd)) + subdir = QFileInfo(subdir_path.mid(thispwd.length())); } //handle sub project @@ -333,8 +332,6 @@ SubdirsMetaMakefileGenerator::init() } qmake_setpwd(sub->input_dir); Option::output_dir = sub->output_dir; - if(Option::output_dir.at(Option::output_dir.length()-1) != QLatin1Char('/')) - Option::output_dir += QLatin1Char('/'); sub_proj->read(subdir.fileName()); if(!sub_proj->variables()["QMAKE_FAILED_REQUIREMENTS"].isEmpty()) { fprintf(stderr, "Project file(%s) not recursed because all requirements not met:\n\t%s\n", diff --git a/qmake/generators/unix/unixmake.cpp b/qmake/generators/unix/unixmake.cpp index 1f02fb5..4970dc8 100644 --- a/qmake/generators/unix/unixmake.cpp +++ b/qmake/generators/unix/unixmake.cpp @@ -763,7 +763,7 @@ UnixMakefileGenerator::defaultInstall(const QString &t) if(!project->isEmpty("QMAKE_RANLIB")) ret += QString("\n\t$(RANLIB) \"") + dst_targ + "\""; } else if(!project->isActiveConfig("debug") && !project->isActiveConfig("nostrip") && !project->isEmpty("QMAKE_STRIP")) { - ret += "\n\t-" + var("QMAKE_STRIP"); + ret += "\n\t-$(STRIP)"; if(project->first("TEMPLATE") == "lib" && !project->isEmpty("QMAKE_STRIPFLAGS_LIB")) ret += " " + var("QMAKE_STRIPFLAGS_LIB"); else if(project->first("TEMPLATE") == "app" && !project->isEmpty("QMAKE_STRIPFLAGS_APP")) diff --git a/qmake/generators/unix/unixmake2.cpp b/qmake/generators/unix/unixmake2.cpp index 585ab55..9787075 100644 --- a/qmake/generators/unix/unixmake2.cpp +++ b/qmake/generators/unix/unixmake2.cpp @@ -163,6 +163,7 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t) t << "SED = " << var("QMAKE_STREAM_EDITOR") << endl; t << "COPY_FILE = " << var("QMAKE_COPY_FILE") << endl; t << "COPY_DIR = " << var("QMAKE_COPY_DIR") << endl; + t << "STRIP = " << var("QMAKE_STRIP") << endl; t << "INSTALL_FILE = " << var("QMAKE_INSTALL_FILE") << endl; t << "INSTALL_DIR = " << var("QMAKE_INSTALL_DIR") << endl; t << "INSTALL_PROGRAM = " << var("QMAKE_INSTALL_PROGRAM") << endl; diff --git a/qmake/project.cpp b/qmake/project.cpp index 7cd4c08..8bae781 100644 --- a/qmake/project.cpp +++ b/qmake/project.cpp @@ -241,14 +241,6 @@ static QScriptValue qscript_projectWrapper(QScriptEngine *eng, QMakeProject *pro return ret; } -static QScriptValue qscript_toArray(QScriptEngine *eng, const QStringList &elts) -{ - QScriptValue a = eng->newArray(); - for (int i = 0; i < elts.count(); ++i) - a.setProperty(i, QScriptValue(eng, elts.at(i))); - return a; -} - QT_END_NAMESPACE #endif @@ -2556,7 +2548,7 @@ QMakeProject::doProjectTest(QString func, QList<QStringList> args_list, QMap<QSt if(ok) { // do integer compare int lhs_int = lhs.toInt(&ok); if(ok) { - if(func == "greaterThan") + if(func_t == T_GREATERTHAN) return lhs_int > rhs_int; return lhs_int < rhs_int; } diff --git a/qmake/qmake.pri b/qmake/qmake.pri index 4e58732..2304fab 100644 --- a/qmake/qmake.pri +++ b/qmake/qmake.pri @@ -96,7 +96,6 @@ bootstrap { #Qt code qfile.h \ qabstractfileengine.h \ qfileinfo.h \ - qfileinfo_p.h \ qglobal.h \ qnumeric.h \ qhash.h \ |