# HG changeset patch # User wetmore # Date 1206734194 25200 # Node ID 3a38b68bc477a511f90e4f2ebe436bfc11ebbe9a # Parent ec0a200b3723ae844b4969cb7fd0eac2cee9ddcc# Parent 2a80925bf7ac3907f4dfa4a94714beb1377a6901 Merge diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/common/Defs-linux.gmk --- a/jdk/make/common/Defs-linux.gmk Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/common/Defs-linux.gmk Fri Mar 28 12:56:34 2008 -0700 @@ -50,13 +50,13 @@ CC_DEPEND_FILTER = $(SED) -e 's!$*\.$(OBJECT_SUFFIX)!$(dir $@)& $(dir $@)$*.$(DEPEND_SUFFIX)!g' ifndef PLATFORM_SRC - PLATFORM_SRC = $(JDK_TOPDIR)/src/solaris + PLATFORM_SRC = $(BUILDDIR)/../src/solaris endif # PLATFORM_SRC # Platform specific closed sources ifndef OPENJDK ifndef CLOSED_PLATFORM_SRC - CLOSED_PLATFORM_SRC = $(JDK_TOPDIR)/src/closed/solaris + CLOSED_PLATFORM_SRC = $(BUILDDIR)/../src/closed/solaris endif endif diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/common/Defs-solaris.gmk --- a/jdk/make/common/Defs-solaris.gmk Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/common/Defs-solaris.gmk Fri Mar 28 12:56:34 2008 -0700 @@ -45,13 +45,13 @@ include $(JDK_MAKE_SHARED_DIR)/Defs.gmk ifndef PLATFORM_SRC -PLATFORM_SRC = $(JDK_TOPDIR)/src/solaris +PLATFORM_SRC = $(BUILDDIR)/../src/solaris endif # PLATFORM_SRC # Platform specific closed sources ifndef OPENJDK ifndef CLOSED_PLATFORM_SRC - CLOSED_PLATFORM_SRC = $(JDK_TOPDIR)/src/closed/solaris + CLOSED_PLATFORM_SRC = $(BUILDDIR)/../src/closed/solaris endif endif diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/common/Defs-windows.gmk --- a/jdk/make/common/Defs-windows.gmk Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/common/Defs-windows.gmk Fri Mar 28 12:56:34 2008 -0700 @@ -51,13 +51,13 @@ endif # LIB_LOCATION ifndef PLATFORM_SRC - PLATFORM_SRC = $(JDK_TOPDIR)/src/windows + PLATFORM_SRC = $(BUILDDIR)/../src/windows endif # PLATFORM_SRC # Platform specific closed sources ifndef OPENJDK ifndef CLOSED_PLATFORM_SRC - CLOSED_PLATFORM_SRC = $(JDK_TOPDIR)/src/closed/windows + CLOSED_PLATFORM_SRC = $(BUILDDIR)/../src/closed/windows endif endif @@ -367,7 +367,7 @@ endif # Settings for the VERSIONINFO tap on windows. -VERSIONINFO_RESOURCE = $(JDK_TOPDIR)/src/windows/resource/version.rc +VERSIONINFO_RESOURCE = $(BUILDDIR)/../src/windows/resource/version.rc ifneq ($(JDK_BUILD_NUMBER),) COOKED_BUILD_NUMBER = $(shell $(ECHO) $(JDK_BUILD_NUMBER) | $(SED) -e 's/^b//' -e 's/^0//') diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/common/Defs.gmk --- a/jdk/make/common/Defs.gmk Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/common/Defs.gmk Fri Mar 28 12:56:34 2008 -0700 @@ -41,7 +41,15 @@ SUN_MAKE_TEST:sh = echo "ERROR: PLEASE USE GNU VERSION OF MAKE"; exit 33 ifndef JDK_TOPDIR - JDK_TOPDIR=$(BUILDDIR)/.. + ifdef BUILDDIR + JDK_TOPDIR=$(BUILDDIR)/.. + else + JDK_TOPDIR:=$(error "ERROR: Cannot define top of jdk repository") + endif +endif +ifndef BUILDDIR + # Hack, due to deploy repository using this file. + BUILDDIR=$(JDK_TOPDIR)/make endif ifndef JDK_MAKE_SHARED_DIR JDK_MAKE_SHARED_DIR=$(JDK_TOPDIR)/make/common/shared @@ -59,13 +67,13 @@ # there yet. # ifndef SHARE_SRC - SHARE_SRC = $(JDK_TOPDIR)/src/share + SHARE_SRC = $(BUILDDIR)/../src/share endif # Files that cannot be included in the OpenJDK distribution are # collected under a parent directory which contains just those files. ifndef CLOSED_SRC - CLOSED_SRC = $(JDK_TOPDIR)/src/closed + CLOSED_SRC = $(BUILDDIR)/../src/closed endif # If we have no closed directory, force it to an openjdk build @@ -170,14 +178,6 @@ endif endif # OPENJDK -# Default output directory -ifdef OPENJDK -_OUTPUTDIR=$(JDK_TOPDIR)/build/$(PLATFORM)-$(ARCH)$(OPENJDK_SUFFIX) -else -_OUTPUTDIR=$(JDK_TOPDIR)/build/$(PLATFORM)-$(ARCH) -endif - - # # Get platform definitions # diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/common/shared/Defs-control.gmk --- a/jdk/make/common/shared/Defs-control.gmk Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/common/shared/Defs-control.gmk Fri Mar 28 12:56:34 2008 -0700 @@ -36,7 +36,7 @@ endif ifndef CONTROL_TOPDIR - CONTROL_TOPDIR=$(TOPDIR)/control + CONTROL_TOPDIR=$(TOPDIR) endif ifndef HOTSPOT_TOPDIR HOTSPOT_TOPDIR=$(TOPDIR)/hotspot @@ -70,7 +70,8 @@ include $(JDK_MAKE_SHARED_DIR)/Platform.gmk # Default output directory -_OUTPUTDIR=$(CONTROL_TOPDIR)/build/$(PLATFORM)-$(ARCH) +BUILD_PARENT_DIRECTORY=$(TOPDIR) +_OUTPUTDIR=$(TOPDIR)/build/$(PLATFORM)-$(ARCH) # Get platform specific settings include $(JDK_MAKE_SHARED_DIR)/Defs.gmk diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/common/shared/Defs.gmk --- a/jdk/make/common/shared/Defs.gmk Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/common/shared/Defs.gmk Fri Mar 28 12:56:34 2008 -0700 @@ -55,7 +55,10 @@ # Simple pwd path define PwdPath -$(shell cd $1 2> $(DEV_NULL) && pwd) +$(shell $(CD) $1 2> $(DEV_NULL) && $(PWD)) +endef +define AbsPwdPathCheck +$(shell $(CD) .. 2> $(DEV_NULL) && $(CD) $1 2> $(DEV_NULL) && $(PWD)) endef # Checks an ALT value for spaces (should be one word), @@ -422,23 +425,54 @@ CACERTS_FILE:=$(call AltCheckValue,CACERTS_FILE) # OUTPUTDIR: Location of all output for the build -_BACKUP_OUTPUTDIR = $(TEMP_DISK)/$(USER)/jdk-outputdir ifdef ALT_OUTPUTDIR - _POSSIBLE_OUTPUTDIR =$(subst \,/,$(ALT_OUTPUTDIR)) + OUTPUTDIR:=$(subst \,/,$(ALT_OUTPUTDIR)) + # Assumes this is absolute (checks later) + ABS_OUTPUTDIR:=$(OUTPUTDIR) else ifndef _OUTPUTDIR - _OUTPUTDIR = $(_BACKUP_OUTPUTDIR) + # Default: Get "build" parent directory, which should always exist + ifndef BUILD_PARENT_DIRECTORY + BUILD_PARENT_DIRECTORY=$(BUILDDIR)/.. + endif + ABS_BUILD_PARENT_DIRECTORY:=$(call FullPath,$(BUILD_PARENT_DIRECTORY)) + ifdef OPENJDK + _OUTPUTDIRNAME=$(PLATFORM)-$(ARCH)$(OPENJDK_SUFFIX) + else + _OUTPUTDIRNAME=$(PLATFORM)-$(ARCH) + endif + _OUTPUTDIR=$(BUILD_PARENT_DIRECTORY)/build/$(_OUTPUTDIRNAME) + ABS_OUTPUTDIR:=$(ABS_BUILD_PARENT_DIRECTORY)/build/$(_OUTPUTDIRNAME) endif - _POSSIBLE_OUTPUTDIR =$(_OUTPUTDIR) + OUTPUTDIR:=$(_OUTPUTDIR) endif -_create_outputdir1:=$(shell mkdir -p $(_POSSIBLE_OUTPUTDIR) > $(DEV_NULL) 2>&1) -OUTPUTDIR:=$(call WriteDirExists,$(_POSSIBLE_OUTPUTDIR),$(_BACKUP_OUTPUTDIR)) -_create_outputdir2:=$(shell mkdir -p $(OUTPUTDIR) > $(DEV_NULL) 2>&1) -ifeq "$(OUTPUTDIR)" "$(_BACKUP_OUTPUTDIR)" - _outputdir_warning:=$(warning "WARNING: OUTPUTDIR '$(_POSSIBLE_OUTPUTDIR)' not writable, will use '$(_BACKUP_OUTPUTDIR)'") -endif +# Check for spaces and null value OUTPUTDIR:=$(call AltCheckSpaces,OUTPUTDIR) OUTPUTDIR:=$(call AltCheckValue,OUTPUTDIR) +# Create the output directory and make sure it exists and is writable +_create_outputdir:=$(shell $(MKDIR) -p "$(OUTPUTDIR)" > $(DEV_NULL) 2>&1) +ifeq ($(call WriteDirExists,$(OUTPUTDIR),/dev/null),/dev/null) + _outputdir_error:=$(error "ERROR: OUTPUTDIR '$(OUTPUTDIR)' not created or not writable") +endif +# Define absolute path if needed and check for spaces and null value +ifndef ABS_OUTPUTDIR + ABS_OUTPUTDIR:=$(call FullPath,$(OUTPUTDIR)) +endif +ABS_OUTPUTDIR:=$(call AltCheckSpaces,ABS_OUTPUTDIR) +ABS_OUTPUTDIR:=$(call AltCheckValue,ABS_OUTPUTDIR) +# Make doubly sure this is a full path +ifeq ($(call AbsPwdPathCheck,$(ABS_OUTPUTDIR)), ) + ifdef ALT_OUTPUTDIR + _outputdir_error:=$(error "ERROR: Trouble with the absolute path for OUTPUTDIR '$(OUTPUTDIR)', was ALT_OUTPUTDIR '$(ALT_OUTPUTDIR)' an absolute path?") + else + _outputdir_error:=$(error "ERROR: Trouble with the absolute path for OUTPUTDIR '$(OUTPUTDIR)'") + endif +endif +_dir1:=$(call FullPath,$(ABS_OUTPUTDIR)) +_dir2:=$(call FullPath,$(OUTPUTDIR)) +ifneq ($(_dir1),$(_dir2)) + _outputdir_error:=$(error "ERROR: ABS_OUTPUTDIR '$(ABS_OUTPUTDIR)' is not the same directory as OUTPUTDIR '$(OUTPUTDIR)', '$(_dir1)'!='$(_dir2)'") +endif # Bin directory # NOTE: ISA_DIR is usually empty, on Solaris it might be /sparcv9 or /amd64 @@ -475,9 +509,6 @@ COPYRIGHT_YEAR = $(shell $(DATE) '+%Y') endif -# Absolute path to output directory -ABS_OUTPUTDIR:=$(call FullPath,$(OUTPUTDIR)) - # Get shared compiler settings include $(JDK_MAKE_SHARED_DIR)/Compiler.gmk diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/common/shared/Platform.gmk --- a/jdk/make/common/shared/Platform.gmk Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/common/shared/Platform.gmk Fri Mar 28 12:56:34 2008 -0700 @@ -93,20 +93,18 @@ # Normal boot jdk is previous release, but a hard requirement is a 1.5 boot REQUIRED_BOOT_VER = 1.5 -#This is specific to OpenJDK build -ifdef OPENJDK - REQUIRED_FREETYPE_VERSION=2.3.0 -endif +# If we are using freetype, this is the required version +REQUIRED_FREETYPE_VERSION=2.3.0 # # Prune out all known SCM (Source Code Management) directories # so they will not be included when copying directory trees # or packaging up .jar files, etc. This applies to all workspaces. # -SCM_DIRs = .hg .svn CVS RCS SCCS Codemgr_wsdata deleted_files +SCM_DIRs = .hg .svn CVS RCS SCCS Codemgr_wsdata deleted_files .hgignore .hgtags # When changing SCM_DIRs also change SCM_DIRS_rexp and SCM_DIRS_prune: -SCM_DIRS_rexp = ".hg|.svn|CVS|RCS|SCCS|Codemgr_wsdata|deleted_files" -SCM_DIRS_prune = \( -name .hg -o -name .svn -o -name CVS -o -name RCS -o -name SCCS -o -name Codemgr_wsdata -o -name deleted_files \) -prune +SCM_DIRS_rexp = ".hg|.svn|CVS|RCS|SCCS|Codemgr_wsdata|deleted_files|.hgignore|.hgtags" +SCM_DIRS_prune = \( -name .hg -o -name .svn -o -name CVS -o -name RCS -o -name SCCS -o -name Codemgr_wsdata -o -name deleted_files -o -name .hgignore -o -name .hgtags \) -prune # Don't define this unless it's not defined ifndef VARIANT diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/java/nio/Makefile --- a/jdk/make/java/nio/Makefile Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/java/nio/Makefile Fri Mar 28 12:56:34 2008 -0700 @@ -191,7 +191,7 @@ GEN_BUFFER_SH = genBuffer.sh -GEN_BUFFER_CMD = SPP="$(SPP_CMD)" NAWK=$(NAWK) SED=$(SED) \ +GEN_BUFFER_CMD = SPP="$(SPP_CMD)" NAWK=$(NAWK) SED=$(SED) SH=$(SH) \ $(SH) $(GEN_BUFFER_SH) # Public abstract buffer classes @@ -582,7 +582,7 @@ GEN_CODER_SH = genCoder.sh -GEN_CODER_CMD = SPP="$(SPP_CMD)" SED=$(SED) NAWK=$(NAWK) $(SH) $(GEN_CODER_SH) +GEN_CODER_CMD = SPP="$(SPP_CMD)" SED=$(SED) NAWK=$(NAWK) SH=$(SH) $(SH) $(GEN_CODER_SH) $(CS_GEN)/CharsetDecoder.java: $(CS_SRC)/Charset-X-Coder.java $(GEN_CODER_SH) $(prep-target) @@ -602,7 +602,7 @@ GEN_EX_SH = genExceptions.sh -GEN_EX_CMD = NAWK=$(NAWK) $(SHELL) $(GEN_EX_SH) +GEN_EX_CMD = NAWK=$(NAWK) SH=$(SH) $(SH) $(GEN_EX_SH) $(CH_GEN)/%Exception.java: genExceptions.sh $(CH_SRC)/exceptions $(prep-target) @@ -635,8 +635,8 @@ $(HASHER_JARFILE) $(SCS_SRC)/standard-charsets $(prep-target) @$(RM) $@.temp - NAWK=$(NAWK) TEMPDIR=$(TEMPDIR) \ + NAWK=$(NAWK) TEMPDIR=$(TEMPDIR) SH=$(SH) \ HASHER="$(BOOT_JAVA_CMD) -jar $(HASHER_JARFILE)" \ - $(SHELL) -e genCharsetProvider.sh $(SCS_SRC)/standard-charsets $(SCS_GEN) + $(SH) -e genCharsetProvider.sh $(SCS_SRC)/standard-charsets $(SCS_GEN) .PHONY: sources diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/java/nio/genCharsetProvider.sh --- a/jdk/make/java/nio/genCharsetProvider.sh Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/java/nio/genCharsetProvider.sh Fri Mar 28 12:56:34 2008 -0700 @@ -48,7 +48,7 @@ # Header # -$SHELL addNotices.sh "$COPYRIGHT_YEARS" > $OUT +$SH ./addNotices.sh "$COPYRIGHT_YEARS" > $OUT cat <<__END__ >>$OUT diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/java/nio/genExceptions.sh --- a/jdk/make/java/nio/genExceptions.sh Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/java/nio/genExceptions.sh Fri Mar 28 12:56:34 2008 -0700 @@ -41,7 +41,7 @@ echo '-->' $DST/$ID.java out=$DST/${ID}.java - $SHELL addNotices.sh "$COPYRIGHT_YEARS" > $out + $SH ./addNotices.sh "$COPYRIGHT_YEARS" > $out cat >>$out <<__END__ diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/sun/splashscreen/Makefile --- a/jdk/make/sun/splashscreen/Makefile Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/sun/splashscreen/Makefile Fri Mar 28 12:56:34 2008 -0700 @@ -85,3 +85,13 @@ CPPFLAGS += -I$(PLATFORM_SRC)/native/$(PKGDIR)/splashscreen -I$(SHARE_SRC)/native/$(PKGDIR)/splashscreen CPPFLAGS += -I$(SHARE_SRC)/native/$(PKGDIR)/image/jpeg -I$(SHARE_SRC)/native/java/util/zip/zlib-1.1.3 +ifeq ($(PLATFORM), linux) + ifeq ($(ARCH_DATA_MODEL), 64) + # 64-bit gcc has problems compiling MMX instructions. + # Google it for more details. Possibly the newer versions of + # the PNG-library and/or the new compiler will not need this + # option in the future. + CPPFLAGS += -DPNG_NO_MMX_CODE + endif +endif + diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/sun/xawt/Makefile --- a/jdk/make/sun/xawt/Makefile Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/sun/xawt/Makefile Fri Mar 28 12:56:34 2008 -0700 @@ -1,5 +1,5 @@ # -# Copyright 2002-2007 Sun Microsystems, Inc. All Rights Reserved. +# Copyright 2002-2008 Sun Microsystems, Inc. All Rights Reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -246,7 +246,7 @@ @if [ "$(DOCOMPARE)$(suffix $@)" = "true.64" ]; then \ $(ECHO) COMPARING $@ and $(STORED_SIZES_TMPL_$(PLATFORM)_$(LIBARCH)); \ $(DIFF) $@ $(STORED_SIZES_TMPL_$(PLATFORM)_$(LIBARCH)); \ - fi + fi $(TEMPDIR)/.gen.wrappers: $(SIZES) $(WRAPPER_GENERATOR_CLASS) $(XLIBTYPES) $(BOOT_JAVA_CMD) -cp $(WRAPPER_GENERATOR_TEMPDIR) WrapperGenerator \ @@ -256,10 +256,11 @@ $(MKDIR) -p $(TEMPDIR) $(TOUCH) $(TEMPDIR)/.gen.wrappers -generated.clean: +generated.clean: $(RM) -r $(WRAPPER_GENERATOR_TEMPDIR) $(RM) -r $(WRAPPER_GENERATOR_DIR) $(RM) -r $(GEN_DIR)/*.java + $(RM) -r $(TEMPDIR)/.gen_icons ifdef OPENJDK ICONS_PATH_PREFIX=$(PLATFORM_SRC) diff -r ec0a200b3723 -r 3a38b68bc477 jdk/make/tools/freetypecheck/Makefile --- a/jdk/make/tools/freetypecheck/Makefile Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/make/tools/freetypecheck/Makefile Fri Mar 28 12:56:34 2008 -0700 @@ -38,7 +38,14 @@ all: $(FT_TEST_PATH) -FT_OPTIONS = -I$(FT_HEADERS) -I$(FT_HEADERS)/freetype2 +# Start with CFLAGS (which gets us the required -xarch setting on solaris) +ifeq ($(PLATFORM), windows) + FT_OPTIONS = +else + FT_OPTIONS = $(CFLAGS) +endif + +FT_OPTIONS += -I$(FT_HEADERS) -I$(FT_HEADERS)/freetype2 FT_OPTIONS += $(XARCH) #add runtime library search path diff -r ec0a200b3723 -r 3a38b68bc477 jdk/src/share/classes/com/sun/jmx/mbeanserver/OpenConverter.java --- a/jdk/src/share/classes/com/sun/jmx/mbeanserver/OpenConverter.java Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/src/share/classes/com/sun/jmx/mbeanserver/OpenConverter.java Fri Mar 28 12:56:34 2008 -0700 @@ -1118,11 +1118,11 @@ final Class propertyNamesClass = ConstructorProperties.class; Class targetClass = getTargetClass(); - Constructor[] constrs = targetClass.getConstructors(); + Constructor[] constrs = targetClass.getConstructors(); // Applicable if and only if there are any annotated constructors - List annotatedConstrList = newList(); - for (Constructor constr : constrs) { + List> annotatedConstrList = newList(); + for (Constructor constr : constrs) { if (Modifier.isPublic(constr.getModifiers()) && constr.getAnnotation(propertyNamesClass) != null) annotatedConstrList.add(constr); @@ -1152,7 +1152,7 @@ // Also remember the set of properties in that constructor // so we can test unambiguity. Set getterIndexSets = newSet(); - for (Constructor constr : annotatedConstrList) { + for (Constructor constr : annotatedConstrList) { String[] propertyNames = constr.getAnnotation(propertyNamesClass).value(); @@ -1309,10 +1309,10 @@ } private static class Constr { - final Constructor constructor; + final Constructor constructor; final int[] paramIndexes; final BitSet presentParams; - Constr(Constructor constructor, int[] paramIndexes, + Constr(Constructor constructor, int[] paramIndexes, BitSet presentParams) { this.constructor = constructor; this.paramIndexes = paramIndexes; diff -r ec0a200b3723 -r 3a38b68bc477 jdk/src/share/classes/com/sun/management/package.html --- a/jdk/src/share/classes/com/sun/management/package.html Fri Mar 21 14:45:20 2008 -0700 +++ b/jdk/src/share/classes/com/sun/management/package.html Fri Mar 28 12:56:34 2008 -0700 @@ -1,4 +1,4 @@ -CTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> +