Use QStringList::join(QChar) overload where applicable [qmake]

This is an automated change performing the following replacements:
                    join\("(.)"\) -> join('\1')
  join\(QLatin1String\("(.)"\)\)  -> join(QLatin1Char('\1'))
  join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))

Change-Id: I9c9964703dedfdab6e7bfac80be22bd5570e2e49
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
This commit is contained in:
Marc Mutz 2012-05-18 20:00:23 +02:00 committed by The Qt Project
parent cbf447069c
commit f4d47945ba
12 changed files with 61 additions and 61 deletions

View File

@ -437,11 +437,11 @@ MakefileGenerator::init()
ProValueMap &v = project->variables(); ProValueMap &v = project->variables();
chkdir = v["QMAKE_CHK_DIR_EXISTS"].join(" "); chkdir = v["QMAKE_CHK_DIR_EXISTS"].join(' ');
chkfile = v["QMAKE_CHK_FILE_EXISTS"].join(" "); chkfile = v["QMAKE_CHK_FILE_EXISTS"].join(' ');
if (chkfile.isEmpty()) // Backwards compat with Qt4 specs if (chkfile.isEmpty()) // Backwards compat with Qt4 specs
chkfile = isWindowsShell() ? "if not exist" : "test -f"; chkfile = isWindowsShell() ? "if not exist" : "test -f";
chkglue = v["QMAKE_CHK_EXISTS_GLUE"].join(" "); chkglue = v["QMAKE_CHK_EXISTS_GLUE"].join(' ');
if (chkglue.isEmpty()) // Backwards compat with Qt4 specs if (chkglue.isEmpty()) // Backwards compat with Qt4 specs
chkglue = isWindowsShell() ? "" : "|| "; chkglue = isWindowsShell() ? "" : "|| ";
@ -987,13 +987,13 @@ MakefileGenerator::writePrlFile(QTextStream &t)
t << "QMAKE_PRL_SOURCE_DIR = " << project->first("QMAKE_ABSOLUTE_SOURCE_PATH") << endl; t << "QMAKE_PRL_SOURCE_DIR = " << project->first("QMAKE_ABSOLUTE_SOURCE_PATH") << endl;
t << "QMAKE_PRL_TARGET = " << target << endl; t << "QMAKE_PRL_TARGET = " << target << endl;
if(!project->isEmpty("PRL_EXPORT_DEFINES")) if(!project->isEmpty("PRL_EXPORT_DEFINES"))
t << "QMAKE_PRL_DEFINES = " << project->values("PRL_EXPORT_DEFINES").join(" ") << endl; t << "QMAKE_PRL_DEFINES = " << project->values("PRL_EXPORT_DEFINES").join(' ') << endl;
if(!project->isEmpty("PRL_EXPORT_CFLAGS")) if(!project->isEmpty("PRL_EXPORT_CFLAGS"))
t << "QMAKE_PRL_CFLAGS = " << project->values("PRL_EXPORT_CFLAGS").join(" ") << endl; t << "QMAKE_PRL_CFLAGS = " << project->values("PRL_EXPORT_CFLAGS").join(' ') << endl;
if(!project->isEmpty("PRL_EXPORT_CXXFLAGS")) if(!project->isEmpty("PRL_EXPORT_CXXFLAGS"))
t << "QMAKE_PRL_CXXFLAGS = " << project->values("PRL_EXPORT_CXXFLAGS").join(" ") << endl; t << "QMAKE_PRL_CXXFLAGS = " << project->values("PRL_EXPORT_CXXFLAGS").join(' ') << endl;
if(!project->isEmpty("CONFIG")) if(!project->isEmpty("CONFIG"))
t << "QMAKE_PRL_CONFIG = " << project->values("CONFIG").join(" ") << endl; t << "QMAKE_PRL_CONFIG = " << project->values("CONFIG").join(' ') << endl;
if(!project->isEmpty("TARGET_VERSION_EXT")) if(!project->isEmpty("TARGET_VERSION_EXT"))
t << "QMAKE_PRL_VERSION = " << project->first("TARGET_VERSION_EXT") << endl; t << "QMAKE_PRL_VERSION = " << project->first("TARGET_VERSION_EXT") << endl;
else if(!project->isEmpty("VERSION")) else if(!project->isEmpty("VERSION"))
@ -1008,7 +1008,7 @@ MakefileGenerator::writePrlFile(QTextStream &t)
libs << "QMAKE_LIBS_PRIVATE"; libs << "QMAKE_LIBS_PRIVATE";
t << "QMAKE_PRL_LIBS = "; t << "QMAKE_PRL_LIBS = ";
for (ProStringList::Iterator it = libs.begin(); it != libs.end(); ++it) for (ProStringList::Iterator it = libs.begin(); it != libs.end(); ++it)
t << project->values((*it).toKey()).join(" ").replace('\\', "\\\\") << " "; t << project->values((*it).toKey()).join(' ').replace('\\', "\\\\") << " ";
t << endl; t << endl;
} }
} }
@ -1234,7 +1234,7 @@ MakefileGenerator::writeInstalls(QTextStream &t, bool noBuild)
tmp2 = project->values(ProKey(*it + ".commands")); //to allow compatible name tmp2 = project->values(ProKey(*it + ".commands")); //to allow compatible name
if (!tmp2.isEmpty()) { if (!tmp2.isEmpty()) {
do_default = false; do_default = false;
inst << tmp2.join(" "); inst << tmp2.join(' ');
} }
//masks //masks
tmp2 = findFilesInVPATH(project->values(ProKey(*it + ".files")), VPATH_NoFixify); tmp2 = findFilesInVPATH(project->values(ProKey(*it + ".files")), VPATH_NoFixify);
@ -1359,7 +1359,7 @@ MakefileGenerator::writeInstalls(QTextStream &t, bool noBuild)
target = defaultInstall((*it).toQString()); target = defaultInstall((*it).toQString());
else else
target = inst.join("\n\t"); target = inst.join("\n\t");
QString puninst = project->values(ProKey(*it + ".uninstall")).join(" "); QString puninst = project->values(ProKey(*it + ".uninstall")).join(' ');
if (!puninst.isEmpty()) if (!puninst.isEmpty())
uninst << puninst; uninst << puninst;
@ -1658,7 +1658,7 @@ MakefileGenerator::replaceExtraCompilerVariables(const QString &orig_var, const
fullVal += escapeFilePath(file); fullVal += escapeFilePath(file);
} }
} else { } else {
fullVal = val.join(" "); fullVal = val.join(' ');
} }
ret.replace(rep, reg_var.matchedLength(), fullVal); ret.replace(rep, reg_var.matchedLength(), fullVal);
rep += fullVal.length(); rep += fullVal.length();
@ -1751,7 +1751,7 @@ MakefileGenerator::verifyExtraCompiler(const ProString &comp, const QString &fil
} }
if(argv0 != -1) { if(argv0 != -1) {
cmdline[argv0] = Option::fixPathToTargetOS(cmdline.at(argv0).toQString(), false); cmdline[argv0] = Option::fixPathToTargetOS(cmdline.at(argv0).toQString(), false);
tmp_cmd = cmdline.join(" "); tmp_cmd = cmdline.join(' ');
} }
} }
@ -1825,7 +1825,7 @@ MakefileGenerator::writeExtraCompilerTargets(QTextStream &t)
int argv0 = findExecutable(cmdline); int argv0 = findExecutable(cmdline);
if(argv0 != -1) { if(argv0 != -1) {
cmdline[argv0] = escapeFilePath(Option::fixPathToTargetOS(cmdline.at(argv0), false)); cmdline[argv0] = escapeFilePath(Option::fixPathToTargetOS(cmdline.at(argv0), false));
tmp_cmd = cmdline.join(" "); tmp_cmd = cmdline.join(' ');
} }
} }
QString tmp_dep_cmd; QString tmp_dep_cmd;
@ -1851,7 +1851,7 @@ MakefileGenerator::writeExtraCompilerTargets(QTextStream &t)
QFileInfo cmdFileInfo(arg); QFileInfo cmdFileInfo(arg);
if (!cmdFileInfo.isAbsolute() || cmdFileInfo.exists()) { if (!cmdFileInfo.isAbsolute() || cmdFileInfo.exists()) {
cmdline[argv0] = arg; cmdline[argv0] = arg;
tmp_dep_cmd = cmdline.join(" "); tmp_dep_cmd = cmdline.join(' ');
} }
} }
dep_cd_cmd = QLatin1String("cd ") dep_cd_cmd = QLatin1String("cd ")
@ -1888,8 +1888,8 @@ MakefileGenerator::writeExtraCompilerTargets(QTextStream &t)
t << endl; t << endl;
if (config.indexOf("no_clean") == -1) { if (config.indexOf("no_clean") == -1) {
QString tmp_clean = project->values(ProKey(*it + ".clean")).join(" "); QString tmp_clean = project->values(ProKey(*it + ".clean")).join(' ');
QString tmp_clean_cmds = project->values(ProKey(*it + ".clean_commands")).join(" "); QString tmp_clean_cmds = project->values(ProKey(*it + ".clean_commands")).join(' ');
if(!tmp_inputs.isEmpty()) if(!tmp_inputs.isEmpty())
clean_targets += QString("compiler_" + (*it) + "_clean "); clean_targets += QString("compiler_" + (*it) + "_clean ");
t << "compiler_" << (*it) << "_clean:"; t << "compiler_" << (*it) << "_clean:";
@ -2162,7 +2162,7 @@ MakefileGenerator::writeExtraVariables(QTextStream &t)
for (ProStringList::ConstIterator exp_it = exports.begin(); exp_it != exports.end(); ++exp_it) { for (ProStringList::ConstIterator exp_it = exports.begin(); exp_it != exports.end(); ++exp_it) {
QRegExp rx((*exp_it).toQString(), Qt::CaseInsensitive, QRegExp::Wildcard); QRegExp rx((*exp_it).toQString(), Qt::CaseInsensitive, QRegExp::Wildcard);
if (rx.exactMatch(it.key().toQString())) if (rx.exactMatch(it.key().toQString()))
outlist << ("EXPORT_" + it.key() + " = " + it.value().join(" ")); outlist << ("EXPORT_" + it.key() + " = " + it.value().join(' '));
} }
} }
if (!outlist.isEmpty()) { if (!outlist.isEmpty()) {
@ -2675,7 +2675,7 @@ MakefileGenerator::writeMakeQmake(QTextStream &t, bool noDummyQmakeAll)
if(project->isEmpty("QMAKE_FAILED_REQUIREMENTS") && !project->isEmpty("QMAKE_INTERNAL_PRL_FILE")) { if(project->isEmpty("QMAKE_FAILED_REQUIREMENTS") && !project->isEmpty("QMAKE_INTERNAL_PRL_FILE")) {
QStringList files = fileFixify(Option::mkfile::project_files); QStringList files = fileFixify(Option::mkfile::project_files);
t << escapeDependencyPath(project->first("QMAKE_INTERNAL_PRL_FILE").toQString()) << ": " << "\n\t" t << escapeDependencyPath(project->first("QMAKE_INTERNAL_PRL_FILE").toQString()) << ": " << "\n\t"
<< "@$(QMAKE) -prl " << buildArgs() << " " << files.join(" ") << endl; << "@$(QMAKE) -prl " << buildArgs() << " " << files.join(' ') << endl;
} }
QString qmake = build_args(); QString qmake = build_args();
@ -3181,7 +3181,7 @@ MakefileGenerator::writePkgConfigFile()
const ProStringList &pkgconfig_vars = project->values("QMAKE_PKGCONFIG_VARIABLES"); const ProStringList &pkgconfig_vars = project->values("QMAKE_PKGCONFIG_VARIABLES");
for(int i = 0; i < pkgconfig_vars.size(); ++i) { for(int i = 0; i < pkgconfig_vars.size(); ++i) {
const ProString &var = project->first(ProKey(pkgconfig_vars.at(i) + ".name")); const ProString &var = project->first(ProKey(pkgconfig_vars.at(i) + ".name"));
QString val = project->values(ProKey(pkgconfig_vars.at(i) + ".value")).join(" "); QString val = project->values(ProKey(pkgconfig_vars.at(i) + ".value")).join(' ');
if(var.isEmpty()) if(var.isEmpty())
continue; continue;
if(val.isEmpty()) { if(val.isEmpty()) {
@ -3206,7 +3206,7 @@ MakefileGenerator::writePkgConfigFile()
name.replace(0, 1, name[0].toUpper()); name.replace(0, 1, name[0].toUpper());
} }
t << "Name: " << name << endl; t << "Name: " << name << endl;
QString desc = project->values("QMAKE_PKGCONFIG_DESCRIPTION").join(" "); QString desc = project->values("QMAKE_PKGCONFIG_DESCRIPTION").join(' ');
if(desc.isEmpty()) { if(desc.isEmpty()) {
if(name.isEmpty()) { if(name.isEmpty()) {
desc = project->first("QMAKE_ORIG_TARGET").toQString().toLower(); desc = project->first("QMAKE_ORIG_TARGET").toQString().toLower();
@ -3259,7 +3259,7 @@ MakefileGenerator::writePkgConfigFile()
libs << "QMAKE_LFLAGS_THREAD"; //not sure about this one, but what about things like -pthread? libs << "QMAKE_LFLAGS_THREAD"; //not sure about this one, but what about things like -pthread?
t << "Libs.private: "; t << "Libs.private: ";
for (ProStringList::ConstIterator it = libs.begin(); it != libs.end(); ++it) { for (ProStringList::ConstIterator it = libs.begin(); it != libs.end(); ++it) {
t << project->values((*it).toKey()).join(" ") << " "; t << project->values((*it).toKey()).join(' ') << " ";
} }
t << endl; t << endl;
@ -3268,13 +3268,13 @@ MakefileGenerator::writePkgConfigFile()
t << "Cflags: " t << "Cflags: "
// << var("QMAKE_CXXFLAGS") << " " // << var("QMAKE_CXXFLAGS") << " "
<< varGlue("PRL_EXPORT_DEFINES","-D"," -D"," ") << varGlue("PRL_EXPORT_DEFINES","-D"," -D"," ")
<< project->values("PRL_EXPORT_CXXFLAGS").join(" ") << project->values("PRL_EXPORT_CXXFLAGS").join(' ')
<< project->values("QMAKE_PKGCONFIG_CFLAGS").join(" ") << project->values("QMAKE_PKGCONFIG_CFLAGS").join(' ')
// << varGlue("DEFINES","-D"," -D"," ") // << varGlue("DEFINES","-D"," -D"," ")
<< " -I${includedir}" << endl; << " -I${includedir}" << endl;
// requires // requires
const QString requires = project->values("QMAKE_PKGCONFIG_REQUIRES").join(" "); const QString requires = project->values("QMAKE_PKGCONFIG_REQUIRES").join(' ');
if (!requires.isEmpty()) { if (!requires.isEmpty()) {
t << "Requires: " << requires << endl; t << "Requires: " << requires << endl;
} }

View File

@ -828,7 +828,7 @@ void QMakeSourceFileInfo::saveCache(const QString &cf)
stream << verify.count() << endl; stream << verify.count() << endl;
for(QMap<QString, QStringList>::iterator it = verify.begin(); for(QMap<QString, QStringList>::iterator it = verify.begin();
it != verify.end(); ++it) { it != verify.end(); ++it) {
stream << it.key() << endl << it.value().join(";") << endl; stream << it.key() << endl << it.value().join(';') << endl;
} }
stream << endl; stream << endl;
} }

View File

@ -334,7 +334,7 @@ SubdirsMetaMakefileGenerator::init()
if (!sub_proj->isEmpty("QMAKE_FAILED_REQUIREMENTS")) { if (!sub_proj->isEmpty("QMAKE_FAILED_REQUIREMENTS")) {
fprintf(stderr, "Project file(%s) not recursed because all requirements not met:\n\t%s\n", fprintf(stderr, "Project file(%s) not recursed because all requirements not met:\n\t%s\n",
subdir.fileName().toLatin1().constData(), subdir.fileName().toLatin1().constData(),
sub_proj->values("QMAKE_FAILED_REQUIREMENTS").join(" ").toLatin1().constData()); sub_proj->values("QMAKE_FAILED_REQUIREMENTS").join(' ').toLatin1().constData());
delete sub; delete sub;
delete sub_proj; delete sub_proj;
Option::output_dir = old_output_dir; Option::output_dir = old_output_dir;

View File

@ -470,7 +470,7 @@ ProjectGenerator::getWritableVar(const char *vk, bool)
ret = v.left(v.length() - 7) + " = "; ret = v.left(v.length() - 7) + " = ";
else else
ret = v + " += "; ret = v + " += ";
QString join = vals.join(" "); QString join = vals.join(' ');
if(ret.length() + join.length() > 80) { if(ret.length() + join.length() > 80) {
QString spaces; QString spaces;
for(int i = 0; i < ret.length(); i++) for(int i = 0; i < ret.length(); i++)

View File

@ -327,7 +327,7 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
QStringList deps = findDependencies((*it).toQString()).filter(QRegExp( QStringList deps = findDependencies((*it).toQString()).filter(QRegExp(
"((^|/)" + Option::h_moc_mod + "|" + Option::cpp_moc_ext + "$)")); "((^|/)" + Option::h_moc_mod + "|" + Option::cpp_moc_ext + "$)"));
if(!deps.isEmpty()) if(!deps.isEmpty())
t << d_file << ": " << deps.join(" ") << endl; t << d_file << ": " << deps.join(' ') << endl;
t << "-include " << d_file << endl; t << "-include " << d_file << endl;
project->values("QMAKE_DISTCLEAN") += d_file; project->values("QMAKE_DISTCLEAN") += d_file;
} }
@ -642,10 +642,10 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
t << destdir << "$(TARGET): " << var("PRE_TARGETDEPS") t << destdir << "$(TARGET): " << var("PRE_TARGETDEPS")
<< " " << var("POST_TARGETDEPS") << valList(build) << "\n\t"; << " " << var("POST_TARGETDEPS") << valList(build) << "\n\t";
ar = project->first("QMAKE_AR_CMD").toQString(); ar = project->first("QMAKE_AR_CMD").toQString();
ar = ar.replace("$(OBJECTS)", build.join(" ")); ar = ar.replace("$(OBJECTS)", build.join(' '));
} else { } else {
t << (*libit) << ": " << valList(build) << "\n\t"; t << (*libit) << ": " << valList(build) << "\n\t";
ar = "$(AR) " + (*libit) + " " + build.join(" "); ar = "$(AR) " + (*libit) + " " + build.join(' ');
} }
if(!destdir.isEmpty()) if(!destdir.isEmpty())
t << mkdir_p_asstring(destdir) << "\n\t"; t << mkdir_p_asstring(destdir) << "\n\t";
@ -807,7 +807,7 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
const ProStringList &val = project->values((*var_it).toKey()); const ProStringList &val = project->values((*var_it).toKey());
if(val.isEmpty()) if(val.isEmpty())
continue; continue;
t << "$(COPY_FILE) --parents " << val.join(" ") << " " << ddir_c << Option::dir_sep << " && "; t << "$(COPY_FILE) --parents " << val.join(' ') << " " << ddir_c << Option::dir_sep << " && ";
} }
} }
} }
@ -877,7 +877,7 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
precomp_files += precomph_out_dir + header_prefix + "objective-c++" + header_suffix; precomp_files += precomph_out_dir + header_prefix + "objective-c++" + header_suffix;
} }
} }
t << "-$(DEL_FILE) " << precomp_files.join(" ") << "\n\t"; t << "-$(DEL_FILE) " << precomp_files.join(' ') << "\n\t";
} }
if(!project->isEmpty("IMAGES")) if(!project->isEmpty("IMAGES"))
t << varGlue("QMAKE_IMAGE_COLLECTION", "\t-$(DEL_FILE) ", " ", "") << "\n\t"; t << varGlue("QMAKE_IMAGE_COLLECTION", "\t-$(DEL_FILE) ", " ", "") << "\n\t";
@ -1326,7 +1326,7 @@ UnixMakefileGenerator::writeLibtoolFile()
libs << "QMAKE_LIBS"; //obvious one libs << "QMAKE_LIBS"; //obvious one
t << "dependency_libs='"; t << "dependency_libs='";
for (ProStringList::ConstIterator it = libs.begin(); it != libs.end(); ++it) for (ProStringList::ConstIterator it = libs.begin(); it != libs.end(); ++it)
t << project->values((*it).toKey()).join(" ") << " "; t << project->values((*it).toKey()).join(' ') << " ";
t << "'\n\n"; t << "'\n\n";
t << "# Version information for " << lname << "\n"; t << "# Version information for " << lname << "\n";

View File

@ -363,7 +363,7 @@ void MingwMakefileGenerator::writeObjectsPart(QTextStream &t)
// QMAKE_LIB is used for win32, including mingw, whereas QMAKE_AR is used on Unix. // QMAKE_LIB is used for win32, including mingw, whereas QMAKE_AR is used on Unix.
if (project->isActiveConfig("rvct_linker")) { if (project->isActiveConfig("rvct_linker")) {
createRvctObjectScriptFile(ar_script_file, project->values("OBJECTS")); createRvctObjectScriptFile(ar_script_file, project->values("OBJECTS"));
QString ar_cmd = project->values("QMAKE_LIB").join(" "); QString ar_cmd = project->values("QMAKE_LIB").join(' ');
if (ar_cmd.isEmpty()) if (ar_cmd.isEmpty())
ar_cmd = "armar --create"; ar_cmd = "armar --create";
objectsLinkLine = ar_cmd + " " + var("DEST_TARGET") + " --via " + escapeFilePath(ar_script_file); objectsLinkLine = ar_cmd + " " + var("DEST_TARGET") + " --via " + escapeFilePath(ar_script_file);

View File

@ -82,8 +82,8 @@ NmakeMakefileGenerator::writeMakefile(QTextStream &t)
if (variables["QMAKESPEC"].first().contains("wince", Qt::CaseInsensitive)) { if (variables["QMAKESPEC"].first().contains("wince", Qt::CaseInsensitive)) {
CeSdkHandler sdkhandler; CeSdkHandler sdkhandler;
sdkhandler.parse(); sdkhandler.parse();
const QString sdkName = variables["CE_SDK"].join(" ") const QString sdkName = variables["CE_SDK"].join(' ')
+ " (" + variables["CE_ARCH"].join(" ") + ")"; + " (" + variables["CE_ARCH"].join(' ') + ")";
const QList<CeSdkInfo> sdkList = sdkhandler.listAll(); const QList<CeSdkInfo> sdkList = sdkhandler.listAll();
CeSdkInfo sdk; CeSdkInfo sdk;
foreach (const CeSdkInfo &info, sdkList) { foreach (const CeSdkInfo &info, sdkList) {

View File

@ -2169,7 +2169,7 @@ bool VCFilter::addExtraCompiler(const VCFilterFile &info)
bool hasBuiltIn = false; bool hasBuiltIn = false;
if (!objectMappedFile.isEmpty()) { if (!objectMappedFile.isEmpty()) {
hasBuiltIn = Project->hasBuiltinCompiler(objectMappedFile.at(0)); hasBuiltIn = Project->hasBuiltinCompiler(objectMappedFile.at(0));
// qDebug("*** Extra compiler file has object mapped file '%s' => '%s'", qPrintable(inFile), qPrintable(objectMappedFile.join(" "))); // qDebug("*** Extra compiler file has object mapped file '%s' => '%s'", qPrintable(inFile), qPrintable(objectMappedFile.join(' ')));
} }
CustomBuildTool.AdditionalDependencies.clear(); CustomBuildTool.AdditionalDependencies.clear();
@ -2187,10 +2187,10 @@ bool VCFilter::addExtraCompiler(const VCFilterFile &info)
// All information about the extra compiler // All information about the extra compiler
QString tmp_out = Project->project->first(ProKey(extraCompilerName + ".output")).toQString(); QString tmp_out = Project->project->first(ProKey(extraCompilerName + ".output")).toQString();
QString tmp_cmd = Project->project->values(ProKey(extraCompilerName + ".commands")).join(" "); QString tmp_cmd = Project->project->values(ProKey(extraCompilerName + ".commands")).join(' ');
QString tmp_cmd_name = Project->project->values(ProKey(extraCompilerName + ".name")).join(" "); QString tmp_cmd_name = Project->project->values(ProKey(extraCompilerName + ".name")).join(' ');
QStringList tmp_dep = Project->project->values(ProKey(extraCompilerName + ".depends")).toQStringList(); QStringList tmp_dep = Project->project->values(ProKey(extraCompilerName + ".depends")).toQStringList();
QString tmp_dep_cmd = Project->project->values(ProKey(extraCompilerName + ".depend_command")).join(" "); QString tmp_dep_cmd = Project->project->values(ProKey(extraCompilerName + ".depend_command")).join(' ');
const ProStringList &configs = Project->project->values(ProKey(extraCompilerName + ".CONFIG")); const ProStringList &configs = Project->project->values(ProKey(extraCompilerName + ".CONFIG"));
bool combined = configs.indexOf("combine") != -1; bool combined = configs.indexOf("combine") != -1;
@ -2268,7 +2268,7 @@ bool VCFilter::addExtraCompiler(const VCFilterFile &info)
// Replace variables for command w/all input files // Replace variables for command w/all input files
// ### join gives path issues with directories containing spaces! // ### join gives path issues with directories containing spaces!
cmd = Project->replaceExtraCompilerVariables(tmp_cmd, cmd = Project->replaceExtraCompilerVariables(tmp_cmd,
inputs.join(" "), inputs.join(' '),
out); out);
} else { } else {
deps += inFile; // input file itself too.. deps += inFile; // input file itself too..

View File

@ -467,7 +467,7 @@ void VcprojGenerator::writeSubDirs(QTextStream &t)
// Check if all requirements are fulfilled // Check if all requirements are fulfilled
if (!tmp_proj.isEmpty("QMAKE_FAILED_REQUIREMENTS")) { if (!tmp_proj.isEmpty("QMAKE_FAILED_REQUIREMENTS")) {
fprintf(stderr, "Project file(%s) not added to Solution because all requirements not met:\n\t%s\n", fprintf(stderr, "Project file(%s) not added to Solution because all requirements not met:\n\t%s\n",
fn.toLatin1().constData(), tmp_proj.values("QMAKE_FAILED_REQUIREMENTS").join(" ").toLatin1().constData()); fn.toLatin1().constData(), tmp_proj.values("QMAKE_FAILED_REQUIREMENTS").join(' ').toLatin1().constData());
continue; continue;
} }
if(tmp_proj.first("TEMPLATE") == "vcsubdirs") { if(tmp_proj.first("TEMPLATE") == "vcsubdirs") {
@ -617,7 +617,7 @@ nextfile:
QString slnConf = _slnSolutionConf; QString slnConf = _slnSolutionConf;
if (!project->isEmpty("CE_SDK") && !project->isEmpty("CE_ARCH")) { if (!project->isEmpty("CE_SDK") && !project->isEmpty("CE_ARCH")) {
QString slnPlatform = QString("|") + project->values("CE_SDK").join(" ") + " (" + project->first("CE_ARCH") + ")"; QString slnPlatform = QString("|") + project->values("CE_SDK").join(' ') + " (" + project->first("CE_ARCH") + ")";
slnConf.replace(QString("|Win32"), slnPlatform); slnConf.replace(QString("|Win32"), slnPlatform);
} else if (is64Bit) { } else if (is64Bit) {
slnConf.replace(QString("|Win32"), "|x64"); slnConf.replace(QString("|Win32"), "|x64");
@ -643,7 +643,7 @@ nextfile:
QString platform = is64Bit ? "x64" : "Win32"; QString platform = is64Bit ? "x64" : "Win32";
QString xplatform = platform; QString xplatform = platform;
if (!project->isEmpty("CE_SDK") && !project->isEmpty("CE_ARCH")) if (!project->isEmpty("CE_SDK") && !project->isEmpty("CE_ARCH"))
xplatform = project->values("CE_SDK").join(" ") + " (" + project->first("CE_ARCH") + ")"; xplatform = project->values("CE_SDK").join(' ') + " (" + project->first("CE_ARCH") + ")";
if (!project->isHostBuild()) if (!project->isHostBuild())
platform = xplatform; platform = xplatform;
t << "\n\t\t" << (*it)->uuid << QString(_slnProjDbgConfTag1).arg(xplatform) << platform; t << "\n\t\t" << (*it)->uuid << QString(_slnProjDbgConfTag1).arg(xplatform) << platform;
@ -852,7 +852,7 @@ void VcprojGenerator::initProject()
if (project->isHostBuild() || project->isEmpty("CE_SDK") || project->isEmpty("CE_ARCH")) { if (project->isHostBuild() || project->isEmpty("CE_SDK") || project->isEmpty("CE_ARCH")) {
vcProject.PlatformName = (is64Bit ? "x64" : "Win32"); vcProject.PlatformName = (is64Bit ? "x64" : "Win32");
} else { } else {
vcProject.PlatformName = project->values("CE_SDK").join(" ") + " (" + project->first("CE_ARCH") + ")"; vcProject.PlatformName = project->values("CE_SDK").join(' ') + " (" + project->first("CE_ARCH") + ")";
} }
// These are not used by Qt, but may be used by customers // These are not used by Qt, but may be used by customers
vcProject.SccProjectName = project->first("SCCPROJECTNAME").toQString(); vcProject.SccProjectName = project->first("SCCPROJECTNAME").toQString();
@ -910,14 +910,14 @@ void VcprojGenerator::initConfiguration()
conf.PrimaryOutputExtension = project->first("TARGET_EXT").toQString(); conf.PrimaryOutputExtension = project->first("TARGET_EXT").toQString();
} }
conf.Name = project->values("BUILD_NAME").join(" "); conf.Name = project->values("BUILD_NAME").join(' ');
if (conf.Name.isEmpty()) if (conf.Name.isEmpty())
conf.Name = isDebug ? "Debug" : "Release"; conf.Name = isDebug ? "Debug" : "Release";
conf.ConfigurationName = conf.Name; conf.ConfigurationName = conf.Name;
if (project->isHostBuild() || project->isEmpty("CE_SDK") || project->isEmpty("CE_ARCH")) { if (project->isHostBuild() || project->isEmpty("CE_SDK") || project->isEmpty("CE_ARCH")) {
conf.Name += (is64Bit ? "|x64" : "|Win32"); conf.Name += (is64Bit ? "|x64" : "|Win32");
} else { } else {
conf.Name += "|" + project->values("CE_SDK").join(" ") + " (" + project->first("CE_ARCH") + ")"; conf.Name += "|" + project->values("CE_SDK").join(' ') + " (" + project->first("CE_ARCH") + ")";
} }
conf.ATLMinimizesCRunTimeLibraryUsage = (project->first("ATLMinimizesCRunTimeLibraryUsage").isEmpty() ? _False : _True); conf.ATLMinimizesCRunTimeLibraryUsage = (project->first("ATLMinimizesCRunTimeLibraryUsage").isEmpty() ? _False : _True);
conf.BuildBrowserInformation = triState(temp.isEmpty() ? (short)unset : temp.toShort()); conf.BuildBrowserInformation = triState(temp.isEmpty() ? (short)unset : temp.toShort());
@ -1085,7 +1085,7 @@ void VcprojGenerator::initPostBuildEventTools()
void VcprojGenerator::initDeploymentTool() void VcprojGenerator::initDeploymentTool()
{ {
VCConfiguration &conf = vcProject.Configuration; VCConfiguration &conf = vcProject.Configuration;
QString targetPath = project->values("deploy.path").join(" "); QString targetPath = project->values("deploy.path").join(' ');
if (targetPath.isEmpty()) if (targetPath.isEmpty())
targetPath = QString("%CSIDL_PROGRAM_FILES%\\") + project->first("TARGET"); targetPath = QString("%CSIDL_PROGRAM_FILES%\\") + project->first("TARGET");
if (targetPath.endsWith("/") || targetPath.endsWith("\\")) if (targetPath.endsWith("/") || targetPath.endsWith("\\"))
@ -1116,7 +1116,7 @@ void VcprojGenerator::initDeploymentTool()
} }
// C-runtime deployment // C-runtime deployment
QString runtime = project->values("QT_CE_C_RUNTIME").join(QLatin1String(" ")); QString runtime = project->values("QT_CE_C_RUNTIME").join(QLatin1Char(' '));
if (!runtime.isEmpty() && (runtime != QLatin1String("no"))) { if (!runtime.isEmpty() && (runtime != QLatin1String("no"))) {
QString runtimeVersion = QLatin1String("msvcr"); QString runtimeVersion = QLatin1String("msvcr");
ProString mkspec = project->first("QMAKESPEC"); ProString mkspec = project->first("QMAKESPEC");
@ -1135,7 +1135,7 @@ void VcprojGenerator::initDeploymentTool()
QString vcInstallDir = qgetenv("VCINSTALLDIR"); QString vcInstallDir = qgetenv("VCINSTALLDIR");
if (!vcInstallDir.isEmpty()) { if (!vcInstallDir.isEmpty()) {
vcInstallDir += "\\ce\\dll\\"; vcInstallDir += "\\ce\\dll\\";
vcInstallDir += project->values("CE_ARCH").join(QLatin1String(" ")); vcInstallDir += project->values("CE_ARCH").join(QLatin1Char(' '));
if (!QFileInfo(vcInstallDir + QDir::separator() + runtimeVersion).exists()) if (!QFileInfo(vcInstallDir + QDir::separator() + runtimeVersion).exists())
runtime.clear(); runtime.clear();
else else
@ -1323,7 +1323,7 @@ void VcprojGenerator::initResourceFiles()
vcProject.ResourceFiles.Guid = _GUIDResourceFiles; vcProject.ResourceFiles.Guid = _GUIDResourceFiles;
// Bad hack, please look away ------------------------------------- // Bad hack, please look away -------------------------------------
QString rcc_dep_cmd = project->values("rcc.depend_command").join(" "); QString rcc_dep_cmd = project->values("rcc.depend_command").join(' ');
if(!rcc_dep_cmd.isEmpty()) { if(!rcc_dep_cmd.isEmpty()) {
ProStringList qrc_files = project->values("RESOURCES"); ProStringList qrc_files = project->values("RESOURCES");
QStringList deps; QStringList deps;
@ -1509,7 +1509,7 @@ QString VcprojGenerator::replaceExtraCompilerVariables(const QString &var, const
ProStringList &incpath = project->values("VCPROJ_MAKEFILE_INCPATH"); ProStringList &incpath = project->values("VCPROJ_MAKEFILE_INCPATH");
if(incpath.isEmpty() && !this->var("MSVCPROJ_INCPATH").isEmpty()) if(incpath.isEmpty() && !this->var("MSVCPROJ_INCPATH").isEmpty())
incpath.append(this->var("MSVCPROJ_INCPATH")); incpath.append(this->var("MSVCPROJ_INCPATH"));
ret.replace("$(INCPATH)", incpath.join(" ")); ret.replace("$(INCPATH)", incpath.join(' '));
return ret; return ret;
} }

View File

@ -377,23 +377,23 @@ void Win32MakefileGenerator::processRcFileVar()
QStringList vers = project->first("VERSION").toQString().split("."); QStringList vers = project->first("VERSION").toQString().split(".");
for (int i = vers.size(); i < 4; i++) for (int i = vers.size(); i < 4; i++)
vers += "0"; vers += "0";
QString versionString = vers.join("."); QString versionString = vers.join('.');
QString companyName; QString companyName;
if (!project->values("QMAKE_TARGET_COMPANY").isEmpty()) if (!project->values("QMAKE_TARGET_COMPANY").isEmpty())
companyName = project->values("QMAKE_TARGET_COMPANY").join(" "); companyName = project->values("QMAKE_TARGET_COMPANY").join(' ');
QString description; QString description;
if (!project->values("QMAKE_TARGET_DESCRIPTION").isEmpty()) if (!project->values("QMAKE_TARGET_DESCRIPTION").isEmpty())
description = project->values("QMAKE_TARGET_DESCRIPTION").join(" "); description = project->values("QMAKE_TARGET_DESCRIPTION").join(' ');
QString copyright; QString copyright;
if (!project->values("QMAKE_TARGET_COPYRIGHT").isEmpty()) if (!project->values("QMAKE_TARGET_COPYRIGHT").isEmpty())
copyright = project->values("QMAKE_TARGET_COPYRIGHT").join(" "); copyright = project->values("QMAKE_TARGET_COPYRIGHT").join(' ');
QString productName; QString productName;
if (!project->values("QMAKE_TARGET_PRODUCT").isEmpty()) if (!project->values("QMAKE_TARGET_PRODUCT").isEmpty())
productName = project->values("QMAKE_TARGET_PRODUCT").join(" "); productName = project->values("QMAKE_TARGET_PRODUCT").join(' ');
else else
productName = project->first("TARGET").toQString(); productName = project->first("TARGET").toQString();
@ -703,7 +703,7 @@ void Win32MakefileGenerator::writeStandardParts(QTextStream &t)
} }
t << "dist:" << "\n\t" t << "dist:" << "\n\t"
<< "$(ZIP) " << var("QMAKE_ORIG_TARGET") << ".zip " << "$(SOURCES) $(DIST) " << "$(ZIP) " << var("QMAKE_ORIG_TARGET") << ".zip " << "$(SOURCES) $(DIST) "
<< dist_files.join(" ") << " " << var("TRANSLATIONS") << " "; << dist_files.join(' ') << " " << var("TRANSLATIONS") << " ";
if(!project->isEmpty("QMAKE_EXTRA_COMPILERS")) { if(!project->isEmpty("QMAKE_EXTRA_COMPILERS")) {
const ProStringList &quc = project->values("QMAKE_EXTRA_COMPILERS"); const ProStringList &quc = project->values("QMAKE_EXTRA_COMPILERS");
for (ProStringList::ConstIterator it = quc.begin(); it != quc.end(); ++it) { for (ProStringList::ConstIterator it = quc.begin(); it != quc.end(); ++it) {

View File

@ -1361,7 +1361,7 @@ QMakeEvaluator::VisitReturn QMakeEvaluator::visitProFile(
#ifdef QT_BUILD_QMAKE #ifdef QT_BUILD_QMAKE
// After user configs, to override them // After user configs, to override them
if (!m_extraConfigs.isEmpty()) if (!m_extraConfigs.isEmpty())
evaluateCommand("CONFIG += " + m_extraConfigs.join(" "), fL1S("(extra configs)")); evaluateCommand("CONFIG += " + m_extraConfigs.join(' '), fL1S("(extra configs)"));
#endif #endif
} }
@ -1378,7 +1378,7 @@ QMakeEvaluator::VisitReturn QMakeEvaluator::visitProFile(
// Specifically, do not allow a project to override debug/release within a // Specifically, do not allow a project to override debug/release within a
// debug_and_release build pass - it's too late for that at this point anyway. // debug_and_release build pass - it's too late for that at this point anyway.
if (!m_extraConfigs.isEmpty()) if (!m_extraConfigs.isEmpty())
evaluateCommand("CONFIG += " + m_extraConfigs.join(" "), fL1S("(extra configs)")); evaluateCommand("CONFIG += " + m_extraConfigs.join(' '), fL1S("(extra configs)"));
#endif #endif
if ((vr = evaluateFeatureFile(QLatin1String("default_post.prf"))) == ReturnError) if ((vr = evaluateFeatureFile(QLatin1String("default_post.prf"))) == ReturnError)

View File

@ -86,7 +86,7 @@ static ProStringList prepareBuiltinArgs(const QList<ProStringList> &args)
ProStringList ret; ProStringList ret;
ret.reserve(args.size()); ret.reserve(args.size());
foreach (const ProStringList &arg, args) foreach (const ProStringList &arg, args)
ret << arg.join(" "); ret << arg.join(' ');
return ret; return ret;
} }