Merge jdk7-b93
authormikejwre
Wed, 12 May 2010 17:19:58 -0700
changeset 2358219b84b9533a
parent 2356 fa09af0e5b7c
parent 2357 7bbb5f3b6eed
child 2359 d352cd74ef71
child 2392 7a1873e045cb
Merge
     1.1 --- a/make/com/sun/java/pack/Makefile	Thu May 06 18:26:09 2010 -0700
     1.2 +++ b/make/com/sun/java/pack/Makefile	Wed May 12 17:19:58 2010 -0700
     1.3 @@ -152,7 +152,7 @@
     1.4  	$(prep-target)
     1.5  	$(LINKER)  $(LDDFLAGS) $(UNPACK_EXE_FILES_o) $(RES) $(LIBCXX) $(LDOUTPUT)$(TEMPDIR)/unpack200$(EXE_SUFFIX)
     1.6  ifdef MT
     1.7 -	$(MT) /manifest $(TEMPDIR)/unpack200$(EXE_SUFFIX).manifest /outputresource:$(TEMPDIR)/unpack200$(EXE_SUFFIX);#1
     1.8 +	$(MT) /manifest $(OBJDIR)/unpack200$(EXE_SUFFIX).manifest /outputresource:$(TEMPDIR)/unpack200$(EXE_SUFFIX);#1
     1.9  endif
    1.10  	$(CP) $(TEMPDIR)/unpack200$(EXE_SUFFIX) $(UNPACK_EXE)
    1.11  	$(install-module-file)
     2.1 --- a/make/common/Defs-windows.gmk	Thu May 06 18:26:09 2010 -0700
     2.2 +++ b/make/common/Defs-windows.gmk	Wed May 12 17:19:58 2010 -0700
     2.3 @@ -86,6 +86,11 @@
     2.4      MSVCPNN_DLL = msvcp90.dll
     2.5      MS_RUNTIME_LIBRARIES += $(MSVCRNN_DLL)
     2.6    endif
     2.7 +  ifeq ($(COMPILER_VERSION), VS2010)
     2.8 +    MSVCRNN_DLL = msvcr100.dll
     2.9 +    MSVCPNN_DLL = msvcp100.dll
    2.10 +    MS_RUNTIME_LIBRARIES += $(MSVCRNN_DLL)
    2.11 +  endif
    2.12  endif
    2.13  
    2.14  ifeq ($(ARCH_DATA_MODEL), 64)
    2.15 @@ -94,6 +99,11 @@
    2.16      MSVCPNN_DLL = msvcp90.dll
    2.17      MS_RUNTIME_LIBRARIES += $(MSVCRNN_DLL)
    2.18    endif
    2.19 +  ifeq ($(COMPILER_VERSION), VS2010)
    2.20 +    MSVCRNN_DLL = msvcr100.dll
    2.21 +    MSVCPNN_DLL = msvcp100.dll
    2.22 +    MS_RUNTIME_LIBRARIES += $(MSVCRNN_DLL)
    2.23 +  endif
    2.24  endif
    2.25  
    2.26  EXTRA_LFLAGS += /LIBPATH:$(DXSDK_LIB_PATH)
    2.27 @@ -155,6 +165,7 @@
    2.28      # Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
    2.29      AUTOMATIC_PCH_OPTION =
    2.30      GX_OPTION = -GX
    2.31 +    GZ_OPTION = -GZ
    2.32      ifeq ($(ARCH_DATA_MODEL), 32)
    2.33        CC_OPT/HIGHEST = -Ox -Gy -Os -GB
    2.34        CC_OPT/HIGHER  = -Ox -Gy -Os -GB
    2.35 @@ -171,6 +182,7 @@
    2.36      AUTOMATIC_PCH_OPTION = -YX
    2.37      # Also known as VC7 compiler
    2.38      GX_OPTION = -GX
    2.39 +    GZ_OPTION = -GZ
    2.40      ifeq ($(ARCH_DATA_MODEL), 32)
    2.41        # Lowered opt level to try and reduce footprint, dll size especially.
    2.42        #     Was: CC_OPT/HIGHEST = -O2 -G6
    2.43 @@ -190,6 +202,7 @@
    2.44      AUTOMATIC_PCH_OPTION =
    2.45      # VS2005 compiler, only with Platform SDK right now?
    2.46      GX_OPTION = -EHsc
    2.47 +    GZ_OPTION = -RTC1
    2.48      ifeq ($(ARCH_DATA_MODEL), 32)
    2.49        CC_OPT/HIGHEST = -O2
    2.50        CC_OPT/HIGHER  = -O1
    2.51 @@ -204,6 +217,23 @@
    2.52      # Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
    2.53      AUTOMATIC_PCH_OPTION =
    2.54      GX_OPTION = -EHsc
    2.55 +    GZ_OPTION = -RTC1
    2.56 +    ifeq ($(ARCH_DATA_MODEL), 32)
    2.57 +      CC_OPT/HIGHEST = -O2
    2.58 +      CC_OPT/HIGHER  = -O1
    2.59 +      CC_OPT/LOWER   = -O1
    2.60 +    else
    2.61 +      CC_OPT/HIGHEST = -O2
    2.62 +      CC_OPT/HIGHER  = -O1
    2.63 +      CC_OPT/LOWER   = -O1
    2.64 +    endif
    2.65 +  endif
    2.66 +
    2.67 +  ifeq ($(COMPILER_VERSION), VS2010)
    2.68 +    # Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
    2.69 +    AUTOMATIC_PCH_OPTION =
    2.70 +    GX_OPTION = -EHsc
    2.71 +    GZ_OPTION = -RTC1
    2.72      ifeq ($(ARCH_DATA_MODEL), 32)
    2.73        CC_OPT/HIGHEST = -O2
    2.74        CC_OPT/HIGHER  = -O1
    2.75 @@ -282,6 +312,13 @@
    2.76    CFLAGS_OPT      = $(CC_OPT)
    2.77    CFLAGS_DBG      = -Od $(MS_RUNTIME_DEBUG_OPTION)
    2.78  
    2.79 +  # REMIND: I don't see where CFLAGS_VS2005 is used. I suspect its
    2.80 +  # pulled in as a combined "CFLAGS_$(COMPILER_VERSION)" string
    2.81 +  # but the lack of this isn't causing any apparent build problems
    2.82 +  # with VS 2010 but it could be causing compiler warnings.
    2.83 +  # For now, I  will add it for all cases :
    2.84 +  CFLAGS_VS2010 += -Zc:wchar_t-
    2.85 +  #
    2.86    # Starting from VS2005 the wchar_t is handled as a built-in C/C++ data type
    2.87    # by default. However, we expect the wchar_t to be a typedef to the
    2.88    # unsigned short data type. The -Zc:wchar_t- option restores the old
    2.89 @@ -317,6 +354,7 @@
    2.90  
    2.91    # VS2008 has bufferoverflow baked in:
    2.92    LFLAGS_VS2008 = 
    2.93 +  LFLAGS_VS2010 = 
    2.94  
    2.95    # LFLAGS are the flags given to $(LINK) and used to build the actual DLL file
    2.96    BASELFLAGS = -nologo /opt:REF /incremental:no
     3.1 --- a/make/common/Modules.gmk	Thu May 06 18:26:09 2010 -0700
     3.2 +++ b/make/common/Modules.gmk	Wed May 12 17:19:58 2010 -0700
     3.3 @@ -357,6 +357,9 @@
     3.4  	$(MKDIR) -p $(JDK_MODULE_IMAGE_DIR)/bin
     3.5  	$(CP) $(BINDIR)/*$(EXE_SUFFIX) $(JDK_MODULE_IMAGE_DIR)/bin
     3.6  	$(CP) $(BINDIR)/jli.$(LIBRARY_SUFFIX) $(JDK_MODULE_IMAGE_DIR)/bin
     3.7 +    ifeq ($(COMPILER_VERSION), VS2010)
     3.8 +	$(CP) $(BINDIR)/msvc*100.$(LIBRARY_SUFFIX) $(JDK_MODULE_IMAGE_DIR)/bin
     3.9 +    endif
    3.10      ifeq ($(ARCH_DATA_MODEL), 32)
    3.11        ifeq ($(COMPILER_VERSION), VS2003)
    3.12  	$(CP) $(BINDIR)/msvc*71.$(LIBRARY_SUFFIX) $(JDK_MODULE_IMAGE_DIR)/bin
     4.1 --- a/make/common/Release.gmk	Thu May 06 18:26:09 2010 -0700
     4.2 +++ b/make/common/Release.gmk	Wed May 12 17:19:58 2010 -0700
     4.3 @@ -749,6 +749,8 @@
     4.4  	$(RM) `$(FIND) $(JRE_IMAGE_DIR)/lib -name 'ir.idl'`
     4.5  
     4.6  # Construct an initial jre image (initial jdk jre) no trimming or stripping
     4.7 +# See "initial-image-jdk-setup" for an explanation of the rm of
     4.8 +# drive names like C:
     4.9  initial-image-jre:: initial-image-jre-setup \
    4.10  		    $(JRE_LICENSES) $(JRE_DOCFILES) \
    4.11  		    $(RT_JAR) $(RESOURCES_JAR) $(JSSE_JAR) \
    4.12 @@ -759,6 +761,10 @@
    4.13  	$(MKDIR) -p $(JRE_IMAGE_DIR)/lib/applet
    4.14  	@# Copy in lib directory
    4.15  	$(CD) $(OUTPUTDIR) && $(FIND) lib -depth | $(CPIO) -pdum $(JRE_IMAGE_DIR)
    4.16 +  ifeq ($(USING_CYGWIN),true)
    4.17 +	  $(RM) -rf $(JRE_IMAGE_DIR)/[A-Za-z]:
    4.18 +	  $(RM) -rf $(OUTPUTDIR)/[A-Za-z]:
    4.19 +  endif
    4.20  	@# Make sure all directories are read/execute for everyone
    4.21  	$(CHMOD) a+rx `$(FIND) $(JRE_IMAGE_DIR) -type d`
    4.22  	@# Remove some files from the jre area
    4.23 @@ -858,11 +864,27 @@
    4.24  ######################################################
    4.25  # Note: cpio ($(CPIO)) sometimes leaves directories without rx access.
    4.26  
    4.27 +# REMIND: the $(RM) calls for patterns like c:, d: following $(CPIO)
    4.28 +# are because the 1.7.x versions of cygwin's cpio command drops these
    4.29 +# in the working directory if the output path begins with that pattern
    4.30 +# The one for the output jre subdirectory gets there because cpio sees its
    4.31 +# own dropping in the input jre subdirectory. Need to remove both of these.
    4.32 +# We can remove these RM's if someone figures out how to stop cpio from
    4.33 +# leaving these there.
    4.34 +# Note that its a real problem not because this directory can end up in the
    4.35 +# bundle (I think it won't since it not in bin or lib and those are the
    4.36 +# only places from which we copy everything), but because the presence
    4.37 +# of this file causes cygwin's find to bomb out, thus breaking the build
    4.38 +# in "install".
    4.39  initial-image-jdk-setup:
    4.40  	$(RM) -r $(JDK_IMAGE_DIR)
    4.41  	$(MKDIR) -p $(JDK_IMAGE_DIR)/jre
    4.42  	($(CD) $(JRE_IMAGE_DIR) && $(FIND) . -depth -print \
    4.43  	      | $(CPIO) -pdum $(JDK_IMAGE_DIR)/jre )
    4.44 +  ifeq ($(USING_CYGWIN),true)
    4.45 +	  $(RM) -rf $(JRE_IMAGE_DIR)/[A-Za-z]:
    4.46 +	  $(RM) -rf $(JDK_IMAGE_DIR)/jre/[A-Za-z]:
    4.47 +  endif
    4.48  	$(RM) -rf $(JDK_IMAGE_DIR)/jre/man
    4.49  	$(CHMOD) a+rx `$(FIND) $(JDK_IMAGE_DIR) -type d`
    4.50  
    4.51 @@ -923,6 +945,9 @@
    4.52  	$(MKDIR) -p $(JDK_IMAGE_DIR)/bin
    4.53  	$(CP) $(BINDIR)/*$(EXE_SUFFIX) $(JDK_IMAGE_DIR)/bin
    4.54  	$(CP) $(BINDIR)/jli.$(LIBRARY_SUFFIX) $(JDK_IMAGE_DIR)/bin
    4.55 +    ifeq ($(COMPILER_VERSION), VS2010)
    4.56 +	$(CP) $(BINDIR)/msvc*100.$(LIBRARY_SUFFIX) $(JDK_IMAGE_DIR)/bin
    4.57 +    endif
    4.58      ifeq ($(ARCH_DATA_MODEL), 32)
    4.59        ifeq ($(COMPILER_VERSION), VS2003)
    4.60  	$(CP) $(BINDIR)/msvc*71.$(LIBRARY_SUFFIX) $(JDK_IMAGE_DIR)/bin
     5.1 --- a/make/common/shared/Compiler-msvc.gmk	Thu May 06 18:26:09 2010 -0700
     5.2 +++ b/make/common/shared/Compiler-msvc.gmk	Wed May 12 17:19:58 2010 -0700
     5.3 @@ -67,7 +67,7 @@
     5.4        COMPILER_VERSION=VS2005
     5.5        REBASE     = $(COMPILER_PATH)../../Common8/Tools/Bin/rebase
     5.6        MTL        = $(COMPILER_PATH)../../Common8/Tools/Bin/midl
     5.7 -      MT         = $(MSDEVTOOLS_PATH)mt
     5.8 +      MT         = $(MSDEVTOOLS_PATH)/mt
     5.9        ifndef COMPILER_PATH
    5.10  	COMPILER_PATH := $(error COMPILER_PATH cannot be empty here)
    5.11        endif
    5.12 @@ -83,6 +83,17 @@
    5.13  	COMPILER_PATH := $(error COMPILER_PATH cannot be empty here)
    5.14        endif
    5.15      endif
    5.16 +    ifeq ($(CC_MAJORVER), 16)
    5.17 +      COMPILER_NAME=Visual Studio 10
    5.18 +      COMPILER_VERSION=VS2010
    5.19 +      #rebase and midl moved out of Visual Studio into the SDK:
    5.20 +      REBASE     = $(MSDEVTOOLS_PATH)/rebase
    5.21 +      MTL        = $(MSDEVTOOLS_PATH)/midl.exe
    5.22 +      MT         = $(MSDEVTOOLS_PATH)mt
    5.23 +      ifndef COMPILER_PATH
    5.24 +	COMPILER_PATH := $(error COMPILER_PATH cannot be empty here)
    5.25 +      endif
    5.26 +    endif
    5.27    else
    5.28      # else ARCH_DATA_MODEL is 64
    5.29      LINK_VER := $(shell $(LINK) | $(HEAD) -n 1 | $(NAWK) '{print $$6}')
    5.30 @@ -122,6 +133,15 @@
    5.31        COMPILER_VERSION=VS2008
    5.32        RC = $(MSSDK61)/Bin/X64/rc.exe
    5.33        MT = $(MSSDK61)/Bin/X64/mt.exe
    5.34 +      MTL = $(MSSDK61)/Bin/X64/midl.exe
    5.35 +    endif
    5.36 +    ifeq ($(CC_MAJORVER), 16)
    5.37 +      COMPILER_NAME=Microsoft Visual Studio 10 (16.00.30319.01)
    5.38 +      COMPILER_VERSION=VS2010
    5.39 +      RC = $(MSDEVTOOLS_PATH)/Bin/x64/rc.exe
    5.40 +      RSC = $(MSDEVTOOLS_PATH)/Bin/x64/rc.exe
    5.41 +      MT = $(MSDEVTOOLS_PATH)/Bin/x64/mt.exe
    5.42 +      MTL = $(MSDEVTOOLS_PATH)/Bin/X64/midl.exe
    5.43      endif
    5.44      # This will cause problems if ALT_COMPILER_PATH is defined to ""
    5.45      # which is a directive to use the PATH.
     6.1 --- a/make/common/shared/Defs-versions.gmk	Thu May 06 18:26:09 2010 -0700
     6.2 +++ b/make/common/shared/Defs-versions.gmk	Wed May 12 17:19:58 2010 -0700
     6.3 @@ -165,10 +165,10 @@
     6.4    REQUIRED_DXSDK_VER          = 0x0900
     6.5    ifeq ($(CC_VERSION),msvc)
     6.6      ifeq ($(ARCH_DATA_MODEL), 32)
     6.7 -      REQUIRED_COMPILER_NAME    = Visual Studio 9
     6.8 -      REQUIRED_COMPILER_VERSION = VS2008
     6.9 -      REQUIRED_CC_VER           = 15.00.21022.08
    6.10 -      REQUIRED_LINK_VER         = 9.00.21022.08
    6.11 +      REQUIRED_COMPILER_NAME    = Visual Studio 10
    6.12 +      REQUIRED_COMPILER_VERSION = VS2010
    6.13 +      REQUIRED_CC_VER           = 16.00.30319.01
    6.14 +      REQUIRED_LINK_VER         = 10.00.30319.01
    6.15      else
    6.16        ifeq ($(ARCH), ia64)
    6.17          REQUIRED_COMPILER_NAME    = Microsoft Platform SDK - November 2001 Edition
    6.18 @@ -177,10 +177,10 @@
    6.19          REQUIRED_LINK_VER         = 7.00.9337.7
    6.20        endif
    6.21        ifeq ($(ARCH), amd64)
    6.22 -        REQUIRED_COMPILER_NAME    = Microsoft Windows SDK with Visual Studio 9 (6001.18000.367)
    6.23 -        REQUIRED_COMPILER_VERSION = VS2008
    6.24 -        REQUIRED_CC_VER           = 15.00.21022.08
    6.25 -        REQUIRED_LINK_VER         = 9.00.21022.08
    6.26 +        REQUIRED_COMPILER_NAME    = Visual Studio 10
    6.27 +        REQUIRED_COMPILER_VERSION = VS2010
    6.28 +        REQUIRED_CC_VER           = 16.00.30319.01
    6.29 +        REQUIRED_LINK_VER         = 10.00.30319.01
    6.30        endif
    6.31      endif
    6.32    endif
     7.1 --- a/make/common/shared/Defs-windows.gmk	Thu May 06 18:26:09 2010 -0700
     7.2 +++ b/make/common/shared/Defs-windows.gmk	Wed May 12 17:19:58 2010 -0700
     7.3 @@ -248,26 +248,34 @@
     7.4    # If we still don't have it, look for VSnnCOMNTOOLS (newest first),
     7.5    # set by installer?
     7.6    ifeq ($(_msvc_dir),)
     7.7 -    ifdef VS90COMNTOOLS  # /Common/Tools directory, use ../../Vc
     7.8 -      xVS90COMNTOOLS :="$(subst \,/,$(VS90COMNTOOLS))"
     7.9 -      _vs90tools     :=$(call FullPath,$(xVS90COMNTOOLS))
    7.10 +    ifdef VS100COMNTOOLS  # /Common/Tools directory, use ../../Vc
    7.11 +      xVS100COMNTOOLS :="$(subst \,/,$(VS100COMNTOOLS))"
    7.12 +      _vs100tools     :=$(call FullPath,$(xVS100COMNTOOLS))
    7.13      endif
    7.14 -    ifneq ($(_vs90tools),)
    7.15 -      _msvc_dir   :=$(_vs90tools)/../../Vc
    7.16 +    ifneq ($(_vs100tools),)
    7.17 +      _msvc_dir   :=$(_vs100tools)/../../Vc
    7.18      else
    7.19 -      ifdef VS80COMNTOOLS  # /Common/Tools directory, use ../../Vc
    7.20 -        xVS80COMNTOOLS :="$(subst \,/,$(VS80COMNTOOLS))"
    7.21 -        _vs80tools     :=$(call FullPath,$(xVS80COMNTOOLS))
    7.22 +      ifdef VS90COMNTOOLS  # /Common/Tools directory, use ../../Vc
    7.23 +        xVS90COMNTOOLS :="$(subst \,/,$(VS90COMNTOOLS))"
    7.24 +        _vs90tools     :=$(call FullPath,$(xVS90COMNTOOLS))
    7.25        endif
    7.26 -      ifneq ($(_vs80tools),)
    7.27 -        _msvc_dir   :=$(_vs80tools)/../../Vc
    7.28 +      ifneq ($(_vs90tools),)
    7.29 +        _msvc_dir   :=$(_vs90tools)/../../Vc
    7.30        else
    7.31 -        ifdef VS71COMNTOOLS  # /Common/Tools directory, use ../../Vc7
    7.32 -          xVS71COMNTOOLS :="$(subst \,/,$(VS71COMNTOOLS))"
    7.33 -          _vs71tools     :=$(call FullPath,$(xVS71COMNTOOLS))
    7.34 +        ifdef VS80COMNTOOLS  # /Common/Tools directory, use ../../Vc
    7.35 +          xVS80COMNTOOLS :="$(subst \,/,$(VS80COMNTOOLS))"
    7.36 +          _vs80tools     :=$(call FullPath,$(xVS80COMNTOOLS))
    7.37          endif
    7.38 -        ifneq ($(_vs71tools),)
    7.39 -          _msvc_dir   :=$(_vs71tools)/../../Vc7
    7.40 +        ifneq ($(_vs80tools),)
    7.41 +          _msvc_dir   :=$(_vs80tools)/../../Vc
    7.42 +        else
    7.43 +          ifdef VS71COMNTOOLS  # /Common/Tools directory, use ../../Vc7
    7.44 +            xVS71COMNTOOLS :="$(subst \,/,$(VS71COMNTOOLS))"
    7.45 +            _vs71tools     :=$(call FullPath,$(xVS71COMNTOOLS))
    7.46 +          endif
    7.47 +          ifneq ($(_vs71tools),)
    7.48 +            _msvc_dir   :=$(_vs71tools)/../../Vc7
    7.49 +          endif
    7.50          endif
    7.51        endif
    7.52      endif
    7.53 @@ -276,12 +284,15 @@
    7.54      _compiler_bin :=$(_msvc_dir)/Bin
    7.55      # Assume PlatformSDK is in VS71 (will be empty if VS90)
    7.56      _ms_sdk       :=$(call FullPath,$(_msvc_dir)/PlatformSDK)
    7.57 -    # Assume VS90, then VS80, then VS71
    7.58 -    _redist_sdk   :=$(call FullPath,$(_msvc_dir)/redist/x86/Microsoft.VC90.CRT)
    7.59 +    # Assume VS100, then VS90, then VS80, then VS71
    7.60 +    _redist_sdk   :=$(call FullPath,$(_msvc_dir)/redist/x86/Microsoft.VC100.CRT)
    7.61      ifeq ($(_redist_sdk),)
    7.62 -      _redist_sdk   :=$(call FullPath,$(_msvc_dir)/redist/x86/Microsoft.VC80.CRT)
    7.63 +      _redist_sdk   :=$(call FullPath,$(_msvc_dir)/redist/x86/Microsoft.VC90.CRT)
    7.64        ifeq ($(_redist_sdk),)
    7.65 -        _redist_sdk   :=$(call FullPath,$(_msvc_dir)/../SDK/v1.1/Bin)
    7.66 +        _redist_sdk   :=$(call FullPath,$(_msvc_dir)/redist/x86/Microsoft.VC80.CRT)
    7.67 +        ifeq ($(_redist_sdk),)
    7.68 +          _redist_sdk   :=$(call FullPath,$(_msvc_dir)/../SDK/v1.1/Bin)
    7.69 +        endif
    7.70        endif
    7.71      endif
    7.72    endif
    7.73 @@ -316,23 +327,40 @@
    7.74    endif
    7.75  endif
    7.76  
    7.77 -# Compilers for 64bit are from SDK
    7.78 +# Compilers for 64bit may be from SDK. For VS 2010 we use those.
    7.79 +# The Express compilers don't contain 64 bit compilers, so in
    7.80 +# that case, you additionally need the SDK. At this time,
    7.81 +# there's no 64 bit SDK available that has VS 2010.
    7.82 +# Presumably SDK v7.1 will provide that and we may want to update
    7.83 +# the logic here to work with that.
    7.84 +# However official builds will use the Professional version.
    7.85  ifeq ($(ARCH_DATA_MODEL), 64)
    7.86 -  xVS2008 :="$(_program_files32)/Microsoft Visual Studio 9.0/"
    7.87 -  VS2008 :=$(call FullPath,$(xVS2008))
    7.88 -  ifneq ($(VS2008),)
    7.89 -    _compiler_bin :=$(VS2008)/VC/Bin/$(ARCH)
    7.90 -    xMSSDK61      :="$(_program_files)/Microsoft SDKs/Windows/v6.1/"
    7.91 -    MSSDK61       :=$(call FullPath,$(xMSSDK61))
    7.92 -    _redist_sdk   :=$(VS2008)/VC/redist/x86/Microsoft.VC90.CRT
    7.93 +  ifdef VS100COMNTOOLS  # /Common7/Tools directory, use ../../Vc
    7.94 +    xVS100COMNTOOLS :="$(subst \,/,$(VS100COMNTOOLS))"
    7.95 +    _vs100tools     :=$(call FullPath,$(xVS100COMNTOOLS))
    7.96 +  endif
    7.97 +  ifneq ($(_vs100tools),)
    7.98 +    _compiler_bin :=$(_vs100tools)/../../Vc/bin/amd64
    7.99 +    _redist_sdk   :=$(_vs100tools)/../../Vc/redist/x64/Microsoft.VC100.CRT
   7.100 +    xMSSDK70      :="$(_program_files32)/Microsoft SDKs/Windows/v7.0a/"
   7.101 +    MSSDK70       :=$(call FullPath,$(xMSSDK70))
   7.102    else
   7.103 -    ifneq ($(_ms_sdk),)
   7.104 -      ifeq ($(ARCH), ia64)
   7.105 -        _compiler_bin :=$(_ms_sdk)/Bin/Win64
   7.106 -      endif
   7.107 -      ifeq ($(ARCH), amd64)
   7.108 -        _compiler_bin :=$(_ms_sdk)/Bin/Win64/x86/$(ARCH)
   7.109 -        _redist_sdk   :=$(_ms_sdk)/redist/win64/AMD64
   7.110 +    xVS2008 :="$(_program_files32)/Microsoft Visual Studio 9.0/"
   7.111 +    VS2008 :=$(call FullPath,$(xVS2008))
   7.112 +    ifneq ($(VS2008),)
   7.113 +      _compiler_bin :=$(VS2008)/VC/Bin/$(ARCH)
   7.114 +      xMSSDK61      :="$(_program_files)/Microsoft SDKs/Windows/v6.1/"
   7.115 +      MSSDK61       :=$(call FullPath,$(xMSSDK61))
   7.116 +      _redist_sdk   :=$(VS2008)/VC/redist/x86/Microsoft.VC90.CRT
   7.117 +    else
   7.118 +      ifneq ($(_ms_sdk),)
   7.119 +        ifeq ($(ARCH), ia64)
   7.120 +          _compiler_bin :=$(_ms_sdk)/Bin/Win64
   7.121 +        endif
   7.122 +        ifeq ($(ARCH), amd64)
   7.123 +          _compiler_bin :=$(_ms_sdk)/Bin/Win64/x86/$(ARCH)
   7.124 +          _redist_sdk   :=$(_ms_sdk)/redist/win64/AMD64
   7.125 +        endif
   7.126        endif
   7.127      endif
   7.128    endif
   7.129 @@ -454,10 +482,14 @@
   7.130  ifeq ($(ARCH_DATA_MODEL), 32)
   7.131    _NEEDS_MSVCRNN = true
   7.132  else
   7.133 -  ifeq ($(VS2008),)
   7.134 -    _NEEDS_MSVCRNN = false
   7.135 -  else
   7.136 +  ifneq ($(VS2010),)
   7.137      _NEEDS_MSVCRNN = true
   7.138 +  else 
   7.139 +    ifneq ($(VS2008),)
   7.140 +      _NEEDS_MSVCRNN = true
   7.141 +    else
   7.142 +      _NEEDS_MSVCRNN = false
   7.143 +    endif
   7.144    endif
   7.145  endif
   7.146  
   7.147 @@ -557,6 +589,17 @@
   7.148  endif
   7.149  CSCRIPT:=$(call AltCheckSpaces,CSCRIPT)
   7.150  
   7.151 +# CABARC: path to cabarc.exe (used in creating install bundles)
   7.152 +ifdef ALT_CABARC
   7.153 +  xALT_CABARC :="$(subst \,/,$(ALT_CABARC))"
   7.154 +  CABARC  =$(xALT_CABARC)
   7.155 +else
   7.156 +  _CABARC1 :=$(_system_root)/system32/cabarc.exe
   7.157 +  _CABARC2 :=$(DEVTOOLS_PATH)cabarc.exe
   7.158 +  CABARC  :=$(call FileExists,$(_CABARC1),$(_CABARC2))
   7.159 +endif
   7.160 +CABARC:=$(call AltCheckSpaces,CABARC)
   7.161 +
   7.162  # MSIVAL2: path to msival2.exe (used in validating install msi files)
   7.163  ifdef ALT_MSIVAL2
   7.164    xALT_MSIVAL2 :="$(subst \,/,$(ALT_MSIVAL2))"
     8.1 --- a/make/common/shared/Platform.gmk	Thu May 06 18:26:09 2010 -0700
     8.2 +++ b/make/common/shared/Platform.gmk	Wed May 12 17:19:58 2010 -0700
     8.3 @@ -275,7 +275,12 @@
     8.4    endif
     8.5    ARCH_FAMILY = $(ARCH)
     8.6    # Where is unwanted output to be delivered?
     8.7 -  DEV_NULL = NUL
     8.8 +  # MKS uses the special file "NUL", cygwin uses the customary unix file.
     8.9 +  ifeq ($(USING_CYGWIN),true)
    8.10 +    DEV_NULL = /dev/null
    8.11 +  else
    8.12 +    DEV_NULL = NUL
    8.13 +  endif
    8.14    export DEV_NULL
    8.15    # Classpath separator
    8.16    CLASSPATH_SEPARATOR = ;
     9.1 --- a/src/share/bin/main.c	Thu May 06 18:26:09 2010 -0700
     9.2 +++ b/src/share/bin/main.c	Wed May 12 17:19:58 2010 -0700
     9.3 @@ -33,14 +33,16 @@
     9.4  #include "defines.h"
     9.5  
     9.6  #ifdef _MSC_VER
     9.7 -#if _MSC_VER > 1400
     9.8 +#if _MSC_VER > 1400 && _MSC_VER < 1600
     9.9  
    9.10  /*
    9.11   * When building for Microsoft Windows, main has a dependency on msvcr??.dll.
    9.12   *
    9.13 - * When using Visual Studio 2005 or later, that must be recorded in
    9.14 + * When using Visual Studio 2005 or 2008, that must be recorded in
    9.15   * the [java,javaw].exe.manifest file.
    9.16   *
    9.17 + * As of VS2010 (ver=1600), the runtimes again no longer need manifests.
    9.18 + *
    9.19   * Reference:
    9.20   *     C:/Program Files/Microsoft SDKs/Windows/v6.1/include/crtdefs.h
    9.21   */
    9.22 @@ -67,7 +69,7 @@
    9.23          "publicKeyToken='" _VC_ASSEMBLY_PUBLICKEYTOKEN "'\"")
    9.24  
    9.25  #endif  /* _M_AMD64 */
    9.26 -#endif  /* _MSC_VER > 1400 */
    9.27 +#endif  /* _MSC_VER > 1400 && _MSC_VER < 1600 */
    9.28  #endif  /* _MSC_VER */
    9.29  
    9.30  /*
    10.1 --- a/src/windows/bin/java_md.c	Thu May 06 18:26:09 2010 -0700
    10.2 +++ b/src/windows/bin/java_md.c	Wed May 12 17:19:58 2010 -0700
    10.3 @@ -148,11 +148,18 @@
    10.4           * assumed to be present in the "JRE path" directory.  If it is not found
    10.5           * there (or "JRE path" fails to resolve), skip the explicit load and let
    10.6           * nature take its course, which is likely to be a failure to execute.
    10.7 +         * This is clearly completely specific to the exact compiler version
    10.8 +         * which isn't very nice, but its hardly the only place.
    10.9 +         * No attempt to look for compiler versions in between 2003 and 2010
   10.10 +         * as we aren't supporting building with those.
   10.11           */
   10.12  #ifdef _MSC_VER
   10.13  #if _MSC_VER < 1400
   10.14  #define CRT_DLL "msvcr71.dll"
   10.15  #endif
   10.16 +#if _MSC_VER >= 1600
   10.17 +#define CRT_DLL "msvcr100.dll"
   10.18 +#endif
   10.19  #ifdef CRT_DLL
   10.20          if (GetJREPath(crtpath, MAXPATHLEN)) {
   10.21              (void)JLI_StrCat(crtpath, "\\bin\\" CRT_DLL);   /* Add crt dll */
    11.1 --- a/src/windows/native/sun/jkernel/DownloadDialog.cpp	Thu May 06 18:26:09 2010 -0700
    11.2 +++ b/src/windows/native/sun/jkernel/DownloadDialog.cpp	Wed May 12 17:19:58 2010 -0700
    11.3 @@ -29,7 +29,10 @@
    11.4  
    11.5  #define STRICT
    11.6  #ifndef _WIN32_WINNT
    11.7 -#define _WIN32_WINNT 0x0400
    11.8 +/* REMIND : 0x500 means Windows 2000 .. seems like we can update
    11.9 + * for Windows XP when we move the SDK and build platform
   11.10 + */
   11.11 +#define _WIN32_WINNT 0x0500
   11.12  #endif
   11.13  #define _ATL_APARTMENT_THREADED
   11.14  
    12.1 --- a/src/windows/native/sun/jkernel/DownloadHelper.cpp	Thu May 06 18:26:09 2010 -0700
    12.2 +++ b/src/windows/native/sun/jkernel/DownloadHelper.cpp	Wed May 12 17:19:58 2010 -0700
    12.3 @@ -29,7 +29,10 @@
    12.4  
    12.5  #define STRICT
    12.6  #ifndef _WIN32_WINNT
    12.7 -#define _WIN32_WINNT 0x0400
    12.8 +/* REMIND : 0x500 means Windows 2000 .. seems like we can update
    12.9 + * for Windows XP when we move the SDK and build platform
   12.10 + */
   12.11 +#define _WIN32_WINNT 0x0500
   12.12  #endif
   12.13  #define _ATL_APARTMENT_THREADED
   12.14  
    13.1 --- a/src/windows/native/sun/jkernel/stdafx.h	Thu May 06 18:26:09 2010 -0700
    13.2 +++ b/src/windows/native/sun/jkernel/stdafx.h	Wed May 12 17:19:58 2010 -0700
    13.3 @@ -36,7 +36,10 @@
    13.4  
    13.5  #define STRICT
    13.6  #ifndef _WIN32_WINNT
    13.7 -#define _WIN32_WINNT 0x0400
    13.8 +/* REMIND : 0x500 means Windows 2000 .. seems like we can update
    13.9 + * for Windows XP when we move the SDK and build platform
   13.10 + */
   13.11 +#define _WIN32_WINNT 0x0500
   13.12  #endif
   13.13  #define _ATL_APARTMENT_THREADED
   13.14  
    14.1 --- a/src/windows/native/sun/windows/awt_DesktopProperties.cpp	Thu May 06 18:26:09 2010 -0700
    14.2 +++ b/src/windows/native/sun/windows/awt_DesktopProperties.cpp	Wed May 12 17:19:58 2010 -0700
    14.3 @@ -233,7 +233,19 @@
    14.4      //
    14.5      NONCLIENTMETRICS    ncmetrics;
    14.6  
    14.7 -    ncmetrics.cbSize = sizeof(ncmetrics);
    14.8 +    // Fix for 6944516: specify correct size for ncmetrics on WIN2K/XP
    14.9 +    // Microsoft recommend to subtract the size of  'iPaddedBorderWidth' field
   14.10 +    // when running on XP. However this can't be referenced at compile time
   14.11 +    // with the older SDK, so there use 'lfMessageFont' plus its size.
   14.12 +    if (!IS_WINVISTA) {
   14.13 +#if defined(_MSC_VER) && (_MSC_VER >= 1600) {
   14.14 +        ncmetrics.cbSize = offsetof(NONCLIENTMETRICS, iPaddedBorderWidth);
   14.15 +#else
   14.16 +        ncmetrics.cbSize = offsetof(NONCLIENTMETRICS,lfMessageFont) + sizeof(LOGFONT);
   14.17 +#endif
   14.18 +    } else {
   14.19 +        ncmetrics.cbSize = sizeof(ncmetrics);
   14.20 +    }
   14.21      VERIFY( SystemParametersInfo(SPI_GETNONCLIENTMETRICS, ncmetrics.cbSize, &ncmetrics, FALSE) );
   14.22  
   14.23      SetFontProperty( TEXT("win.frame.captionFont"), ncmetrics.lfCaptionFont );
    15.1 --- a/src/windows/native/sun/windows/awt_DnDDS.cpp	Thu May 06 18:26:09 2010 -0700
    15.2 +++ b/src/windows/native/sun/windows/awt_DnDDS.cpp	Wed May 12 17:19:58 2010 -0700
    15.3 @@ -29,21 +29,16 @@
    15.4  //we need <new> inclusion for STL "new" oprators set.
    15.5  #define bad_alloc zbad_alloc
    15.6  #include <new>
    15.7 +
    15.8 +#if defined(_DEBUG) || defined(DEBUG)
    15.9 +extern void * operator new(size_t size, const char * filename, int linenumber);
   15.10 +void * operator new(size_t size) {return operator new(size, "stl", 1);}
   15.11 +#endif
   15.12 +#include <map>
   15.13 +
   15.14  #pragma pop_macro("bad_alloc")
   15.15  //"bad_alloc" is undefined from here
   15.16  
   15.17 -//we need to include any STL container before <awt.h> inclusion due to
   15.18 -//"new" re-redefinition that is in conflict with in-place new allocator
   15.19 -//applied in STL.
   15.20 -#if defined(_DEBUG) || defined(DEBUG)
   15.21 -    //forward declaration of "new" operator from <awt.h>
   15.22 -    extern void * operator new(size_t size, const char * filename, int linenumber);
   15.23 -    //"new" operator definition that is consistent with re-defined
   15.24 -    //in <awt.h> "delete" operator
   15.25 -    void * operator new(size_t size) {return operator new(size, "stl", 1);}
   15.26 -#endif
   15.27 -#include <map>
   15.28 -
   15.29  #include <awt.h>
   15.30  #include <shlobj.h>
   15.31  
    16.1 --- a/src/windows/native/sun/windows/awt_TextArea.cpp	Thu May 06 18:26:09 2010 -0700
    16.2 +++ b/src/windows/native/sun/windows/awt_TextArea.cpp	Wed May 12 17:19:58 2010 -0700
    16.3 @@ -758,7 +758,7 @@
    16.4                      si.cbSize = sizeof(SCROLLINFO);
    16.5                      si.fMask = SIF_POS | SIF_RANGE | SIF_PAGE;
    16.6                      int actualScrollLines =
    16.7 -                        abs(platfScrollLines * (*delta_accum / WHEEL_DELTA));
    16.8 +                        abs((int)(platfScrollLines * (*delta_accum / WHEEL_DELTA)));
    16.9                      for (int i = 0; i < actualScrollLines; i++) {
   16.10                          if (::GetScrollInfo(hWnd, sb_type, &si)) {
   16.11                              if ((wm_msg == WM_VSCROLL)