summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@nokia.com>2012-08-07 17:16:56 +0200
committerQt by Nokia <qt-info@nokia.com>2012-08-07 18:55:43 +0200
commite81d7fd1e57fe2ce11cbe07636f890973116f7ab (patch)
treead84280c73f4541ae17f160d0084ad4b90641465
parentb4ae57c881455d791f4587978423c47b046a9a4e (diff)
qmake vcxproj generator: map TARGET_EXT to $(TargetExt)
Task-number: QTBUG-26782 Change-Id: Ib143fa6b8674c4d09d798a9301bb209b886e791d Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
-rw-r--r--qmake/generators/win32/msbuild_objectmodel.cpp12
-rw-r--r--qmake/generators/win32/msvc_objectmodel.h1
-rw-r--r--qmake/generators/win32/msvc_vcproj.cpp1
3 files changed, 12 insertions, 2 deletions
diff --git a/qmake/generators/win32/msbuild_objectmodel.cpp b/qmake/generators/win32/msbuild_objectmodel.cpp
index 7b004e57f9..52f50a0adb 100644
--- a/qmake/generators/win32/msbuild_objectmodel.cpp
+++ b/qmake/generators/win32/msbuild_objectmodel.cpp
@@ -455,7 +455,11 @@ void VCXProjectWriter::write(XmlOutput &xml, VCProjectSingleConfig &tool)
<< attrTag("Condition", condition)
<< valueTag(tool.Configuration.PrimaryOutput);
}
-
+ if (!tool.Configuration.PrimaryOutputExtension.isEmpty()) {
+ xml<< tag("TargetExt")
+ << attrTag("Condition", condition)
+ << valueTag(tool.Configuration.PrimaryOutputExtension);
+ }
if ( tool.Configuration.linker.IgnoreImportLibrary != unset) {
xml<< tag("IgnoreImportLibrary")
<< attrTag("Condition", condition)
@@ -652,7 +656,11 @@ void VCXProjectWriter::write(XmlOutput &xml, VCProject &tool)
<< attrTag("Condition", condition)
<< valueTag(config.PrimaryOutput);
}
-
+ if (!config.PrimaryOutputExtension.isEmpty()) {
+ xml << tag("TargetExt")
+ << attrTag("Condition", condition)
+ << valueTag(config.PrimaryOutputExtension);
+ }
if (config.linker.IgnoreImportLibrary != unset) {
xml << tag("IgnoreImportLibrary")
<< attrTag("Condition", condition)
diff --git a/qmake/generators/win32/msvc_objectmodel.h b/qmake/generators/win32/msvc_objectmodel.h
index 0d1e11b277..4c55408a52 100644
--- a/qmake/generators/win32/msvc_objectmodel.h
+++ b/qmake/generators/win32/msvc_objectmodel.h
@@ -856,6 +856,7 @@ public:
QString ConfigurationName;
QString OutputDirectory;
QString PrimaryOutput;
+ QString PrimaryOutputExtension;
QString ProgramDatabase;
triState RegisterOutput;
useOfATL UseOfATL;
diff --git a/qmake/generators/win32/msvc_vcproj.cpp b/qmake/generators/win32/msvc_vcproj.cpp
index 7291c42ed9..f823889ec9 100644
--- a/qmake/generators/win32/msvc_vcproj.cpp
+++ b/qmake/generators/win32/msvc_vcproj.cpp
@@ -908,6 +908,7 @@ void VcprojGenerator::initConfiguration()
conf.PrimaryOutput = project->first("TARGET");
if ( !conf.PrimaryOutput.isEmpty() && !project->first("TARGET_VERSION_EXT").isEmpty() && project->isActiveConfig("shared"))
conf.PrimaryOutput.append(project->first("TARGET_VERSION_EXT"));
+ conf.PrimaryOutputExtension = project->first("TARGET_EXT");
}
conf.Name = project->values("BUILD_NAME").join(" ");