summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPierre Joye <pajoye@php.net>2008-07-05 19:53:04 +0000
committerPierre Joye <pajoye@php.net>2008-07-05 19:53:04 +0000
commite78d5ac5c4f19ec851f9f9cf5c3c447f752ee628 (patch)
tree10ba7616b145e67eab8c33c2d9fccfa36e259773
parent5627ff52f0cd3036b8e791d0b4b145aea84f317e (diff)
downloadphp-git-e78d5ac5c4f19ec851f9f9cf5c3c447f752ee628.tar.gz
-MFH: improve detection of VC version and summary (2k2 and 2k3 are 1300 and resp. 1310) (Thx Marcus)
-rw-r--r--win32/build/config.w3212
-rw-r--r--win32/build/confutils.js15
2 files changed, 13 insertions, 14 deletions
diff --git a/win32/build/config.w32 b/win32/build/config.w32
index 14dbd2abf0..aefcabc2a3 100644
--- a/win32/build/config.w32
+++ b/win32/build/config.w32
@@ -31,13 +31,15 @@ function probe_binary(EXE, what)
}
// Which version of the compiler do we have?
-VCVERS = probe_binary(CL).substr(0, 2);
+VCVERS = probe_binary(CL);
+VCVERS = VCVERS.substr(0, 2) + VCVERS.substr(3, 2);
STDOUT.WriteLine("Detected MS compiler version " + VCVERS);
-// 12 is VC6
-// 13 is vs.net 2003
-// 14 is vs.net 2005
-// 15 is vs.net 2008
+// 1200 is VC6
+// 1300 is vs.net 2002
+// 1310 is vs.net 2003
+// 1400 is vs.net 2005
+// 1500 is vs.net 2008
// do we use x64 or 80x86 version of compiler?
X64 = probe_binary(CL, 64);
diff --git a/win32/build/confutils.js b/win32/build/confutils.js
index 8d45597a76..eaa2407939 100644
--- a/win32/build/confutils.js
+++ b/win32/build/confutils.js
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-// $Id: confutils.js,v 1.60.2.1.2.8.2.18 2008-07-02 20:50:18 pajoye Exp $
+// $Id: confutils.js,v 1.60.2.1.2.8.2.19 2008-07-05 19:53:04 pajoye Exp $
var STDOUT = WScript.StdOut;
var STDERR = WScript.StdErr;
@@ -30,15 +30,12 @@ var PROGRAM_FILES = WshShell.Environment("Process").Item("ProgramFiles");
var extensions_enabled = new Array();
var sapi_enabled = new Array();
-// 12 is VC6
-// 13 is vs.net 2003
-// 14 is vs.net 2005
-// 15 is vs.net 2008
var VC_VERSIONS = new Array();
-VC_VERSIONS[12] = 'VC6';
-VC_VERSIONS[13] = 'Visual C++ 2003';
-VC_VERSIONS[14] = 'Visual C++ 2005';
-VC_VERSIONS[15] = 'Visual C++ 2008';
+VC_VERSIONS[1200] = 'VC6';
+VC_VERSIONS[1300] = 'Visual C++ 2002';
+VC_VERSIONS[1310] = 'Visual C++ 2003';
+VC_VERSIONS[1400] = 'Visual C++ 2005';
+VC_VERSIONS[1500] = 'Visual C++ 2008';
if (PROGRAM_FILES == null) {
PROGRAM_FILES = "C:\\Program Files";