diff options
author | Joerg Bornemann <joerg.bornemann@digia.com> | 2014-03-03 17:02:11 +0100 |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@digia.com> | 2014-04-08 13:56:26 +0200 |
commit | 9c42cb3e891da2fdb915430ecad13120e01eb4ed (patch) | |
tree | 68770756a98dc056a30806e8cd557b3c05cf0444 /share | |
parent | d17ca97abe00313447a60252c5d403f821e75f72 (diff) |
detect Visual Studio build environment using vcvarsall.bat
To provide a consistent build environment for Visual Studio
setup-toolchains now executes the vsvarsall.bat that comes with the
Visual Studio installation. The environment is written to the profile
under the key "buildEnvironment".
The setupBuildEnvironment script in windows-msvc.qbs isn't needed
anymore.
Task-number: QBS-444
Task-number: QBS-508
Change-Id: I3191f5ff127bed6b96ce5ea5520b20fc9646364f
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
Diffstat (limited to 'share')
-rw-r--r-- | share/qbs/modules/cpp/windows-msvc.qbs | 41 |
1 files changed, 1 insertions, 40 deletions
diff --git a/share/qbs/modules/cpp/windows-msvc.qbs b/share/qbs/modules/cpp/windows-msvc.qbs index ac7f81571..1896eb14c 100644 --- a/share/qbs/modules/cpp/windows-msvc.qbs +++ b/share/qbs/modules/cpp/windows-msvc.qbs @@ -20,7 +20,7 @@ CppModule { property bool generateManifestFiles: true property path toolchainInstallPath - property path windowsSDKPath + property path windowsSDKPath // ### remove in 1.3 architecture: qbs.architecture staticLibraryPrefix: "" dynamicLibraryPrefix: "" @@ -30,45 +30,6 @@ CppModule { executableSuffix: ".exe" property string dynamicLibraryImportSuffix: ".lib" - setupBuildEnvironment: { - var vcDir = toolchainInstallPath.replace(/[\\/]bin$/i, ""); - var vcRootDir = vcDir.replace(/[\\/]VC$/i, ""); - - var v = new ModUtils.EnvironmentVariable("INCLUDE", ";", true) - v.prepend(vcDir + "/ATLMFC/INCLUDE") - v.prepend(vcDir + "/INCLUDE") - v.prepend(windowsSDKPath + "/include") - v.set() - - if (architecture == 'x86') { - v = new ModUtils.EnvironmentVariable("PATH", ";", true) - v.prepend(windowsSDKPath + "/bin") - v.prepend(vcRootDir + "/Common7/IDE") - v.prepend(vcDir + "/bin") - v.prepend(vcRootDir + "/Common7/Tools") - v.set() - - v = new ModUtils.EnvironmentVariable("LIB", ";", true) - v.prepend(vcDir + "/ATLMFC/LIB") - v.prepend(vcDir + "/LIB") - v.prepend(windowsSDKPath + "/lib") - v.set() - } else if (architecture == 'x86_64') { - v = new ModUtils.EnvironmentVariable("PATH", ";", true) - v.prepend(windowsSDKPath + "/bin/x64") - v.prepend(vcRootDir + "/Common7/IDE") - v.prepend(vcDir + "/bin/amd64") - v.prepend(vcRootDir + "/Common7/Tools") - v.set() - - v = new ModUtils.EnvironmentVariable("LIB", ";", true) - v.prepend(vcDir + "/ATLMFC/LIB/amd64") - v.prepend(vcDir + "/LIB/amd64") - v.prepend(windowsSDKPath + "/lib/x64") - v.set() - } - } - Transformer { condition: cPrecompiledHeader !== undefined inputs: cPrecompiledHeader |