1.1 --- a/make/windows/makefiles/compile.make Fri Nov 07 13:55:14 2008 -0800 1.2 +++ b/make/windows/makefiles/compile.make Tue Nov 11 22:01:08 2008 -0800 1.3 @@ -30,7 +30,7 @@ 1.4 # /W3 Warning level 3 1.5 # /Zi Include debugging information 1.6 # /WX Treat any warning error as a fatal error 1.7 -# /MD Use dynamic multi-threaded runtime (msvcrt.dll or msvc*71.dll) 1.8 +# /MD Use dynamic multi-threaded runtime (msvcrt.dll or msvc*NN.dll) 1.9 # /MTd Use static multi-threaded runtime debug versions 1.10 # /O1 Optimize for size (/Os), skips /Oi 1.11 # /O2 Optimize for speed (/Ot), adds /Oi to /O1 1.12 @@ -80,8 +80,10 @@ 1.13 CPP=ARCH_ERROR 1.14 !endif 1.15 1.16 -# MSC_VER is a 4 digit number that tells us what compiler is being used, it is 1.17 -# generated when the local.make file is created by the script gen_msc_ver.sh. 1.18 +# MSC_VER is a 4 digit number that tells us what compiler is being used 1.19 +# and is generated when the local.make file is created by build.make 1.20 +# via the script get_msc_ver.sh 1.21 +# 1.22 # If MSC_VER is set, it overrides the above default setting. 1.23 # But it should be set. 1.24 # Possible values: 1.25 @@ -89,13 +91,14 @@ 1.26 # 1300 and 1310 is VS2003 or VC7 1.27 # 1399 is our fake number for the VS2005 compiler that really isn't 1400 1.28 # 1400 is for VS2005 1.29 +# 1500 is for VS2008 1.30 # Do not confuse this MSC_VER with the predefined macro _MSC_VER that the 1.31 # compiler provides, when MSC_VER==1399, _MSC_VER will be 1400. 1.32 # Normally they are the same, but a pre-release of the VS2005 compilers 1.33 # in the Windows 64bit Platform SDK said it was 1400 when it was really 1.34 # closer to VS2003 in terms of option spellings, so we use 1399 for that 1.35 # 1400 version that really isn't 1400. 1.36 -# See the file gen_msc_ver.sh for more info. 1.37 +# See the file get_msc_ver.sh for more info. 1.38 !if "x$(MSC_VER)" == "x" 1.39 COMPILER_NAME=$(DEFAULT_COMPILER_NAME) 1.40 !else 1.41 @@ -115,6 +118,9 @@ 1.42 !if "$(MSC_VER)" == "1400" 1.43 COMPILER_NAME=VS2005 1.44 !endif 1.45 +!if "$(MSC_VER)" == "1500" 1.46 +COMPILER_NAME=VS2008 1.47 +!endif 1.48 !endif 1.49 1.50 # Add what version of the compiler we think this is to the compile line 1.51 @@ -160,7 +166,25 @@ 1.52 # externals at link time. Even with /GS-, you need bufferoverflowU.lib. 1.53 # NOTE: Currently we decided to not use /GS- 1.54 BUFFEROVERFLOWLIB = bufferoverflowU.lib 1.55 -LINK_FLAGS = $(LINK_FLAGS) $(BUFFEROVERFLOWLIB) 1.56 +LINK_FLAGS = /manifest $(LINK_FLAGS) $(BUFFEROVERFLOWLIB) 1.57 +# Manifest Tool - used in VS2005 and later to adjust manifests stored 1.58 +# as resources inside build artifacts. 1.59 +MT=mt.exe 1.60 +!if "$(BUILDARCH)" == "i486" 1.61 +# VS2005 on x86 restricts the use of certain libc functions without this 1.62 +CPP_FLAGS=$(CPP_FLAGS) /D _CRT_SECURE_NO_DEPRECATE 1.63 +!endif 1.64 +!endif 1.65 + 1.66 +!if "$(COMPILER_NAME)" == "VS2008" 1.67 +PRODUCT_OPT_OPTION = /O2 /Oy- 1.68 +FASTDEBUG_OPT_OPTION = /O2 /Oy- 1.69 +DEBUG_OPT_OPTION = /Od 1.70 +GX_OPTION = /EHsc 1.71 +LINK_FLAGS = /manifest $(LINK_FLAGS) 1.72 +# Manifest Tool - used in VS2005 and later to adjust manifests stored 1.73 +# as resources inside build artifacts. 1.74 +MT=mt.exe 1.75 !if "$(BUILDARCH)" == "i486" 1.76 # VS2005 on x86 restricts the use of certain libc functions without this 1.77 CPP_FLAGS=$(CPP_FLAGS) /D _CRT_SECURE_NO_DEPRECATE