diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2014-10-18 13:52:16 -0500 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2014-10-18 13:52:16 -0500 |
commit | 76397a8b53d2043dd7a6dc94e521bd7958148fae (patch) | |
tree | eb7a0128a0dcad05a04873c757fdfe7365b91e1f /configure.ac | |
parent | b77ea7496af7a4685c58e1487d7f49162184f290 (diff) |
windows: try to locate a good MSBuild.exe based on the version of VS
lcms2 for instance call MSBuild.exe, naked. it relies on what is found
in the PATH, but apparently MSBuild.exe can be found in many places
including for instance the .NET Framework.
This was causing failure with a VS2013
This patch inspect the registry to see if there is a MSBuild of the
same level than VS2013 and use that information to adjust the PATH
so that we invoke the right version.
Note: starting VS2013, Microsoft is numbering the version of MSBuild
with the same version number than VS itself.. so with VS2013 the version
of MSBuild is 12.0 (vs 4.0 before that)
Change-Id: I04c614116d1d365a10c9b9e0e8ce9571d770c065
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index aa9112f934b1..25ff959e231e 100644 --- a/configure.ac +++ b/configure.ac @@ -3430,6 +3430,7 @@ find_msvc() } SHOWINCLUDES_PREFIX= +MSBUILD_PATH= if test "$_os" = "WINNT"; then if test "$WITH_MINGW" != "yes"; then AC_MSG_CHECKING([Visual C++]) @@ -3468,6 +3469,12 @@ if test "$_os" = "WINNT"; then AC_MSG_RESULT([No]) fi + # Find the proper version of MSBuild.exe to use based on the VS version + reg_get_value_32 HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/MSBuild/$vcnumwithdot/MSBuildOverrideTasksPath + if test -n "$regvalue" ; then + MSBUILD_PATH="$regvalue" + fi + dnl =========================================================== dnl Check for the corresponding mspdb*.dll dnl =========================================================== @@ -12750,6 +12757,9 @@ else pathmunge "$MIDL_PATH" "before" pathmunge "$AL_PATH" "before" pathmunge "$MSPDB_PATH" "before" + if test -n "$MSBUILD_PATH" ; then + pathmunge "$MSBUILD_PATH" "before" + fi if test "$BITNESS_OVERRIDE" = 64; then pathmunge "$COMPATH/bin/amd64" "before" pathmunge "$WINDOWS_SDK_HOME/bin/x64" "before" |