diff options
author | Oswald Buddenhagen <oswald.buddenhagen@nokia.com> | 2011-03-22 19:08:22 (GMT) |
---|---|---|
committer | Oswald Buddenhagen <oswald.buddenhagen@nokia.com> | 2011-04-12 09:58:34 (GMT) |
commit | 7f8773a209567fb9c962602b8b1f4ec70e38ea51 (patch) | |
tree | f6e648f6fda9ba20318a31fa8b5ba983033b4d5e /qmake/project.cpp | |
parent | e2ac68f3437ab6e9e865c7c9ad1c52b293f61910 (diff) | |
download | Qt-7f8773a209567fb9c962602b8b1f4ec70e38ea51.zip Qt-7f8773a209567fb9c962602b8b1f4ec70e38ea51.tar.gz Qt-7f8773a209567fb9c962602b8b1f4ec70e38ea51.tar.bz2 |
prefix TEMPLATE_PREFIX to TEMPLATE even if it is "default-constructed"
that way prf files don't have to check both the prefix and the actual
template to identify visual studio mode.
Reviewed-by: mariusSO
Diffstat (limited to 'qmake/project.cpp')
-rw-r--r-- | qmake/project.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/qmake/project.cpp b/qmake/project.cpp index e985401..16200f1 100644 --- a/qmake/project.cpp +++ b/qmake/project.cpp @@ -3028,17 +3028,17 @@ QStringList &QMakeProject::values(const QString &_var, QMap<QString, QStringList if(!Option::user_template.isEmpty()) { var = ".BUILTIN.USER." + var; place[var] = QStringList(Option::user_template); - } else if(!place[var].isEmpty()) { - QString orig_template = place["TEMPLATE"].first(), real_template; + } else { + QString orig_template, real_template; + if(!place[var].isEmpty()) + orig_template = place[var].first(); + real_template = orig_template.isEmpty() ? "app" : orig_template; if(!Option::user_template_prefix.isEmpty() && !orig_template.startsWith(Option::user_template_prefix)) - real_template = Option::user_template_prefix + orig_template; - if(!real_template.isEmpty()) { + real_template.prepend(Option::user_template_prefix); + if(real_template != orig_template) { var = ".BUILTIN." + var; place[var] = QStringList(real_template); } - } else { - var = ".BUILTIN." + var; - place[var] = QStringList("app"); } } else if(var.startsWith(QLatin1String("QMAKE_HOST."))) { QString ret, type = var.mid(11); |