This commit is contained in:
Jesper Wilhelmsson 2018-03-02 21:00:12 +01:00
commit 8f1e5bc574
193 changed files with 3831 additions and 1782 deletions

View File

@ -471,3 +471,6 @@ e569e83139fdfbecfeb3cd9014d560917787f158 jdk-10+38
107413b070b92c88bde6230ceb4a19b579781068 jdk-10+43 107413b070b92c88bde6230ceb4a19b579781068 jdk-10+43
dfa46cfe56346884a61efdc30dc50f7505d66761 jdk-11+1 dfa46cfe56346884a61efdc30dc50f7505d66761 jdk-11+1
03ae177c26b016353e5ea1cab6ffd051dfa086ca jdk-11+2 03ae177c26b016353e5ea1cab6ffd051dfa086ca jdk-11+2
663f20fc51091bd7f95d18448850ba091207b7bd jdk-10+44
4f96cf952e71cb8a127334494faf28880c26181b jdk-10+45
1fd4d6068f54561cfc67d54fc9ca84af7212c4f8 jdk-11+3

View File

@ -61,7 +61,7 @@ MODULES_SOURCE_PATH := $(call PathList, $(call GetModuleSrcPath) \
$(SUPPORT_OUTPUTDIR)/rmic/* $(TOPDIR)/src/*/share/doc/stub) $(SUPPORT_OUTPUTDIR)/rmic/* $(TOPDIR)/src/*/share/doc/stub)
# URLs # URLs
JAVADOC_BASE_URL := http://www.oracle.com/pls/topic/lookup?ctx=javase9&id=homepage JAVADOC_BASE_URL := http://www.oracle.com/pls/topic/lookup?ctx=javase10&id=homepage
BUG_SUBMIT_URL := http://bugreport.java.com/bugreport/ BUG_SUBMIT_URL := http://bugreport.java.com/bugreport/
COPYRIGHT_URL := {@docroot}/../legal/copyright.html COPYRIGHT_URL := {@docroot}/../legal/copyright.html
LICENSE_URL := http://www.oracle.com/technetwork/java/javase/terms/license/java10speclicense.html LICENSE_URL := http://www.oracle.com/technetwork/java/javase/terms/license/java10speclicense.html

View File

@ -1127,6 +1127,8 @@ AC_DEFUN_ONCE([BASIC_SETUP_COMPLEX_TOOLS],
fi fi
fi fi
BASIC_REQUIRE_PROGS(SETFILE, SetFile) BASIC_REQUIRE_PROGS(SETFILE, SetFile)
elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
BASIC_REQUIRE_PROGS(ELFEDIT, elfedit)
fi fi
]) ])

View File

@ -710,6 +710,7 @@ CYGPATH:=@CYGPATH@
LDD:=@LDD@ LDD:=@LDD@
OTOOL:=@OTOOL@ OTOOL:=@OTOOL@
READELF:=@READELF@ READELF:=@READELF@
ELFEDIT:=@ELFEDIT@
EXPR:=@EXPR@ EXPR:=@EXPR@
FILE:=@FILE@ FILE:=@FILE@
DOT:=@DOT@ DOT:=@DOT@

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -30,7 +30,7 @@
ifndef _NATIVE_COMPILATION_GMK ifndef _NATIVE_COMPILATION_GMK
_NATIVE_COMPILATION_GMK := 1 _NATIVE_COMPILATION_GMK := 1
ifeq (,$(_MAKEBASE_GMK)) ifeq ($(_MAKEBASE_GMK), )
$(error You must include MakeBase.gmk prior to including NativeCompilation.gmk) $(error You must include MakeBase.gmk prior to including NativeCompilation.gmk)
endif endif
@ -231,32 +231,32 @@ define add_native_source
endif endif
endif endif
ifneq (,$$(filter %.c,$2)) ifneq ($$(filter %.c, $2), )
# Compile as a C file # Compile as a C file
$1_$2_FLAGS=$(CFLAGS_CCACHE) $$($1_$2_USE_PCH_FLAGS) $4 \ $1_$2_FLAGS := $(CFLAGS_CCACHE) $$($1_$2_USE_PCH_FLAGS) $4 \
$$($1_$(notdir $2)_OPT_CFLAGS) \ $$($1_$(notdir $2)_OPT_CFLAGS) \
$$($1_$(notdir $2)_CFLAGS) $$($1_$2_THIS_FILE) -c $$($1_$(notdir $2)_CFLAGS) $$($1_$2_THIS_FILE) -c
$1_$2_COMP=$5 $1_$2_COMP := $5
$1_$2_DEP_FLAG:=$(C_FLAG_DEPS) $1_$2_DEP_FLAG := $(C_FLAG_DEPS)
else ifneq (,$$(filter %.m,$2)) else ifneq ($$(filter %.m, $2), )
# Compile as an Objective-C file # Compile as an Objective-C file
$1_$2_FLAGS=-x objective-c $(CFLAGS_CCACHE) $$($1_$2_USE_PCH_FLAGS) $4 \ $1_$2_FLAGS := -x objective-c $(CFLAGS_CCACHE) $$($1_$2_USE_PCH_FLAGS) $4 \
$$($1_$(notdir $2)_OPT_CFLAGS) \ $$($1_$(notdir $2)_OPT_CFLAGS) \
$$($1_$(notdir $2)_CFLAGS) $$($1_$2_THIS_FILE) -c $$($1_$(notdir $2)_CFLAGS) $$($1_$2_THIS_FILE) -c
$1_$2_COMP=$5 $1_$2_COMP := $5
$1_$2_DEP_FLAG:=$(C_FLAG_DEPS) $1_$2_DEP_FLAG := $(C_FLAG_DEPS)
else ifneq (,$$(filter %.s %.S,$2)) else ifneq ($$(filter %.s %.S, $2), )
# Compile as assembler file # Compile as assembler file
$1_$2_FLAGS=$8 $1_$2_FLAGS := $8
$1_$2_COMP=$(AS) $1_$2_COMP := $(AS)
$1_$2_DEP_FLAG:= $1_$2_DEP_FLAG :=
else ifneq (,$$(filter %.cpp,$2)$$(filter %.cc,$2)$$(filter %.mm,$2)) else ifneq ($$(filter %.cpp, $2)$$(filter %.cc, $2)$$(filter %.mm, $2), )
# Compile as a C++ or Objective-C++ file # Compile as a C++ or Objective-C++ file
$1_$2_FLAGS=$(CFLAGS_CCACHE) $$($1_$2_USE_PCH_FLAGS) $6 \ $1_$2_FLAGS := $(CFLAGS_CCACHE) $$($1_$2_USE_PCH_FLAGS) $6 \
$$($1_$(notdir $2)_OPT_CXXFLAGS) \ $$($1_$(notdir $2)_OPT_CXXFLAGS) \
$$($1_$(notdir $2)_CXXFLAGS) $$($1_$2_THIS_FILE) -c $$($1_$(notdir $2)_CXXFLAGS) $$($1_$2_THIS_FILE) -c
$1_$2_COMP=$7 $1_$2_COMP := $7
$1_$2_DEP_FLAG:=$(CXX_FLAG_DEPS) $1_$2_DEP_FLAG := $(CXX_FLAG_DEPS)
else else
$$(error Internal error in NativeCompilation.gmk: no compiler for file $2) $$(error Internal error in NativeCompilation.gmk: no compiler for file $2)
endif endif
@ -264,14 +264,14 @@ define add_native_source
$1_$2_OBJ := $3/$$(call replace_with_obj_extension, $$(notdir $2)) $1_$2_OBJ := $3/$$(call replace_with_obj_extension, $$(notdir $2))
# Only continue if this object file hasn't been processed already. This lets the first found # Only continue if this object file hasn't been processed already. This lets the first found
# source file override any other with the same name. # source file override any other with the same name.
ifeq (,$$(findstring $$($1_$2_OBJ),$$($1_OBJS_SO_FAR))) ifeq ($$(findstring $$($1_$2_OBJ), $$($1_OBJS_SO_FAR)), )
$1_OBJS_SO_FAR+=$$($1_$2_OBJ) $1_OBJS_SO_FAR += $$($1_$2_OBJ)
ifeq (,$$(filter %.s %.S,$2)) ifeq ($$(filter %.s %.S, $2), )
# And this is the dependency file for this obj file. # And this is the dependency file for this obj file.
$1_$2_DEP:=$$(patsubst %$(OBJ_SUFFIX),%.d,$$($1_$2_OBJ)) $1_$2_DEP := $$(patsubst %$(OBJ_SUFFIX),%.d,$$($1_$2_OBJ))
# The dependency target file lists all dependencies as empty targets # The dependency target file lists all dependencies as empty targets
# to avoid make error "No rule to make target" for removed files # to avoid make error "No rule to make target" for removed files
$1_$2_DEP_TARGETS:=$$(patsubst %$(OBJ_SUFFIX),%.d.targets,$$($1_$2_OBJ)) $1_$2_DEP_TARGETS := $$(patsubst %$(OBJ_SUFFIX),%.d.targets,$$($1_$2_OBJ))
# Include previously generated dependency information. (if it exists) # Include previously generated dependency information. (if it exists)
-include $$($1_$2_DEP) -include $$($1_$2_DEP)
@ -280,7 +280,7 @@ define add_native_source
ifeq ($(TOOLCHAIN_TYPE), microsoft) ifeq ($(TOOLCHAIN_TYPE), microsoft)
# To avoid name clashes between pdbs for objects and libs/execs, put # To avoid name clashes between pdbs for objects and libs/execs, put
# object pdbs in a separate subdir. # object pdbs in a separate subdir.
$1_$2_DEBUG_OUT_FLAGS:=-Fd$$(strip $$(patsubst $$($1_OBJECT_DIR)/%, \ $1_$2_DEBUG_OUT_FLAGS := -Fd$$(strip $$(patsubst $$($1_OBJECT_DIR)/%, \
$$($1_OBJECT_DIR)/pdb/%, $$(patsubst %$(OBJ_SUFFIX),%.pdb,$$($1_$2_OBJ)))) $$($1_OBJECT_DIR)/pdb/%, $$(patsubst %$(OBJ_SUFFIX),%.pdb,$$($1_$2_OBJ))))
endif endif
endif endif
@ -293,10 +293,10 @@ define add_native_source
endif endif
$$($1_$2_OBJ) : $2 $$($1_COMPILE_VARDEPS_FILE) $$($1_$2_VARDEPS_FILE) | $$($1_BUILD_INFO) $$($1_$2_OBJ) : $2 $$($1_COMPILE_VARDEPS_FILE) $$($1_$2_VARDEPS_FILE) | $$($1_BUILD_INFO)
$$(call LogInfo, Compiling $$(notdir $2) (for $$(notdir $$($1_TARGET)))) $$(call LogInfo, Compiling $$(notdir $2) (for $$($1_BASENAME)))
$$(call MakeDir, $$(@D) $$(@D)/pdb) $$(call MakeDir, $$(@D) $$(@D)/pdb)
ifneq ($(TOOLCHAIN_TYPE), microsoft) ifneq ($(TOOLCHAIN_TYPE), microsoft)
ifeq ($(TOOLCHAIN_TYPE)$$(filter %.s,$2), solstudio) ifeq ($(TOOLCHAIN_TYPE)$$(filter %.s, $2), solstudio)
# The Solaris studio compiler doesn't output the full path to the object file in the # The Solaris studio compiler doesn't output the full path to the object file in the
# generated deps files. Fixing it with sed. If compiling assembly, don't try this. # generated deps files. Fixing it with sed. If compiling assembly, don't try this.
$$(call ExecuteWithLog, $$@, \ $$(call ExecuteWithLog, $$@, \
@ -308,7 +308,7 @@ define add_native_source
endif endif
# Create a dependency target file from the dependency file. # Create a dependency target file from the dependency file.
# Solution suggested by http://make.mad-scientist.net/papers/advanced-auto-dependency-generation/ # Solution suggested by http://make.mad-scientist.net/papers/advanced-auto-dependency-generation/
ifneq ($$($1_$2_DEP),) ifneq ($$($1_$2_DEP), )
$(SED) $(DEPENDENCY_TARGET_SED_PATTERN) $$($1_$2_DEP) > $$($1_$2_DEP_TARGETS) $(SED) $(DEPENDENCY_TARGET_SED_PATTERN) $$($1_$2_DEP) > $$($1_$2_DEP_TARGETS)
endif endif
else else
@ -338,6 +338,9 @@ endef
# and the targets generated are listed in a variable by that name. # and the targets generated are listed in a variable by that name.
# #
# Remaining parameters are named arguments. These include: # Remaining parameters are named arguments. These include:
# NAME The base name for the resulting binary, excluding decorations (like *.exe)
# TYPE Type of binary (EXECUTABLE, LIBRARY or STATIC_LIBRARY). Default is LIBRARY.
# SUFFIX Override the default suffix for the output file
# TOOLCHAIN Name of toolchain setup to use. Defaults to TOOLCHAIN_DEFAULT. # TOOLCHAIN Name of toolchain setup to use. Defaults to TOOLCHAIN_DEFAULT.
# SRC one or more directory roots to scan for C/C++ files. # SRC one or more directory roots to scan for C/C++ files.
# CFLAGS the compiler flags to be used, used both for C and C++. # CFLAGS the compiler flags to be used, used both for C and C++.
@ -347,8 +350,6 @@ endef
# ARFLAGS the archiver flags to be used # ARFLAGS the archiver flags to be used
# OBJECT_DIR the directory where we store the object files # OBJECT_DIR the directory where we store the object files
# OUTPUT_DIR the directory where the resulting binary is put # OUTPUT_DIR the directory where the resulting binary is put
# LIBRARY the resulting library file
# PROGRAM the resulting exec file
# INCLUDES only pick source from these directories # INCLUDES only pick source from these directories
# EXCLUDES do not pick source from these directories # EXCLUDES do not pick source from these directories
# INCLUDE_FILES only compile exactly these files! # INCLUDE_FILES only compile exactly these files!
@ -385,106 +386,60 @@ endef
SetupNativeCompilation = $(NamedParamsMacroTemplate) SetupNativeCompilation = $(NamedParamsMacroTemplate)
define SetupNativeCompilationBody define SetupNativeCompilationBody
# If type is unspecified, default to LIBRARY
ifeq ($$($1_TYPE), )
$1_TYPE := LIBRARY
endif
# If we're doing a static build and producing a library # If we're doing a static build and producing a library
# force it to be a static library and remove the -l libraries # force it to be a static library and remove the -l libraries
ifeq ($(STATIC_BUILD), true) ifeq ($(STATIC_BUILD), true)
ifneq ($$($1_LIBRARY),) ifeq ($$($1_TYPE), LIBRARY)
$1_STATIC_LIBRARY := $$($1_LIBRARY) $1_TYPE := STATIC_LIBRARY
$1_LIBRARY :=
endif endif
endif endif
ifneq (,$$($1_BIN)) ifeq ($$($1_TYPE), EXECUTABLE)
$$(error BIN has been replaced with OBJECT_DIR) $1_PREFIX :=
endif
ifneq (,$$($1_LIB))
$$(error LIB has been replaced with LIBRARY)
endif
ifneq (,$$($1_EXE))
$$(error EXE has been replaced with PROGRAM)
endif
ifneq (,$$($1_LIBRARY))
ifeq (,$$($1_OUTPUT_DIR))
$$(error LIBRARY requires OUTPUT_DIR)
endif
ifneq ($$($1_LIBRARY),$(basename $$($1_LIBRARY)))
$$(error directory of LIBRARY should be specified using OUTPUT_DIR)
endif
ifneq (,$(findstring $(SHARED_LIBRARY_SUFFIX),$$($1_LIBRARY)))
$$(error LIBRARY should be specified without SHARED_LIBRARY_SUFFIX: $(SHARED_LIBRARY_SUFFIX))
endif
ifneq (,$(findstring $(LIBRARY_PREFIX),$$($1_LIBRARY)))
$$(error LIBRARY should be specified without LIBRARY_PREFIX: $(LIBRARY_PREFIX))
endif
ifeq ($$($1_SUFFIX), )
$1_SUFFIX := $(SHARED_LIBRARY_SUFFIX)
endif
$1_BASENAME:=$(LIBRARY_PREFIX)$$($1_LIBRARY)$$($1_SUFFIX)
$1_TARGET:=$$($1_OUTPUT_DIR)/$$($1_BASENAME)
$1_NOSUFFIX:=$(LIBRARY_PREFIX)$$($1_LIBRARY)
endif
ifneq (,$$($1_STATIC_LIBRARY))
ifeq (,$$($1_OUTPUT_DIR))
$$(error STATIC_LIBRARY requires OUTPUT_DIR)
endif
ifneq ($$($1_STATIC_LIBRARY),$(basename $$($1_STATIC_LIBRARY)))
$$(error directory of STATIC_LIBRARY should be specified using OUTPUT_DIR)
endif
ifneq (,$(findstring $(STATIC_LIBRARY_SUFFIX),$$($1_STATIC_LIBRARY)))
$$(error STATIC_LIBRARY should be specified without STATIC_LIBRARY_SUFFIX: $(STATIC_LIBRARY_SUFFIX))
endif
ifneq (,$(findstring $(LIBRARY_PREFIX),$$($1_STATIC_LIBRARY)))
$$(error STATIC_LIBRARY should be specified without LIBRARY_PREFIX: $(LIBRARY_PREFIX))
endif
ifeq ($$($1_SUFFIX), )
$1_SUFFIX := $(STATIC_LIBRARY_SUFFIX)
endif
$1_BASENAME:=$(LIBRARY_PREFIX)$$($1_STATIC_LIBRARY)$$($1_SUFFIX)
$1_TARGET:=$$($1_OUTPUT_DIR)/$$($1_BASENAME)
$1_NOSUFFIX:=$(LIBRARY_PREFIX)$$($1_STATIC_LIBRARY)
endif
ifneq (,$$($1_PROGRAM))
ifeq (,$$($1_OUTPUT_DIR))
$$(error PROGRAM requires OUTPUT_DIR)
endif
ifneq ($$($1_PROGRAM),$(basename $$($1_PROGRAM)))
$$(error directory of PROGRAM should be specified using OUTPUT_DIR)
endif
ifneq (,$(findstring $(EXE_SUFFIX),$$($1_PROGRAM)))
$$(error PROGRAM should be specified without EXE_SUFFIX: $(EXE_SUFFIX))
endif
ifeq ($$($1_SUFFIX), ) ifeq ($$($1_SUFFIX), )
$1_SUFFIX := $(EXE_SUFFIX) $1_SUFFIX := $(EXE_SUFFIX)
endif endif
else
$1_BASENAME:=$$($1_PROGRAM)$$($1_SUFFIX) $1_PREFIX := $(LIBRARY_PREFIX)
$1_TARGET:=$$($1_OUTPUT_DIR)/$$($1_BASENAME) ifeq ($$($1_TYPE), LIBRARY)
$1_NOSUFFIX:=$$($1_PROGRAM) ifeq ($$($1_SUFFIX), )
$1_SUFFIX := $(SHARED_LIBRARY_SUFFIX)
endif
else ifeq ($$($1_TYPE), STATIC_LIBRARY)
ifeq ($$($1_SUFFIX), )
$1_SUFFIX := $(STATIC_LIBRARY_SUFFIX)
endif
endif
endif endif
ifneq ($$($1_NAME), $(basename $$($1_NAME)))
$$(error NAME must not contain any directory path in $1)
endif
ifneq ($(findstring $$($1_SUFFIX), $$($1_NAME)), )
$$(error NAME should be specified without suffix: $$($1_SUFFIX) in $1)
endif
ifneq ($(findstring $$($1_PREFIX), $$($1_NAME)), )
$$(error NAME should be specified without prefix: $$($1_PREFIX) in $1)
endif
ifeq ($$($1_OUTPUT_DIR), )
$$(error OUTPUT_DIR is missing in $1)
endif
ifneq ($$($1_MANIFEST), )
ifeq ($$($1_MANIFEST_VERSION), )
$$(error If MANIFEST is provided, then MANIFEST_VERSION is required in $1)
endif
endif
$1_BASENAME := $$($1_PREFIX)$$($1_NAME)$$($1_SUFFIX)
$1_TARGET := $$($1_OUTPUT_DIR)/$$($1_BASENAME)
$1_NOSUFFIX := $$($1_PREFIX)$$($1_NAME)
$1_SAFE_NAME := $$(strip $$(subst /,_, $1)) $1_SAFE_NAME := $$(strip $$(subst /,_, $1))
ifeq (,$$($1_TARGET))
$$(error Neither PROGRAM, LIBRARY nor STATIC_LIBRARY has been specified for SetupNativeCompilation)
endif
# Setup the toolchain to be used # Setup the toolchain to be used
$$(call SetIfEmpty, $1_TOOLCHAIN, TOOLCHAIN_DEFAULT) $$(call SetIfEmpty, $1_TOOLCHAIN, TOOLCHAIN_DEFAULT)
$$(call SetIfEmpty, $1_CC, $$($$($1_TOOLCHAIN)_CC)) $$(call SetIfEmpty, $1_CC, $$($$($1_TOOLCHAIN)_CC))
@ -499,41 +454,35 @@ define SetupNativeCompilationBody
$$(call SetIfEmpty, $1_SYSROOT_CFLAGS, $$($$($1_TOOLCHAIN)_SYSROOT_CFLAGS)) $$(call SetIfEmpty, $1_SYSROOT_CFLAGS, $$($$($1_TOOLCHAIN)_SYSROOT_CFLAGS))
$$(call SetIfEmpty, $1_SYSROOT_LDFLAGS, $$($$($1_TOOLCHAIN)_SYSROOT_LDFLAGS)) $$(call SetIfEmpty, $1_SYSROOT_LDFLAGS, $$($$($1_TOOLCHAIN)_SYSROOT_LDFLAGS))
ifneq ($$($1_MANIFEST), )
ifeq ($$($1_MANIFEST_VERSION), )
$$(error If MANIFEST is provided, then MANIFEST_VERSION is required in $1)
endif
endif
# Make sure the dirs exist. # Make sure the dirs exist.
$$(call MakeDir,$$($1_OBJECT_DIR) $$($1_OUTPUT_DIR)) $$(call MakeDir, $$($1_OBJECT_DIR) $$($1_OUTPUT_DIR))
$$(foreach d,$$($1_SRC), $$(if $$(wildcard $$d),, \ $$(foreach d, $$($1_SRC), $$(if $$(wildcard $$d), , \
$$(error SRC specified to SetupNativeCompilation $1 contains missing directory $$d))) $$(error SRC specified to SetupNativeCompilation $1 contains missing directory $$d)))
# Find all files in the source trees. Preserve order. # Find all files in the source trees. Preserve order.
$1_SRCS := $$(foreach s, $$($1_SRC), $$(call CacheFind,$$(s))) $1_SRCS := $$(foreach s, $$($1_SRC), $$(call CacheFind, $$(s)))
$1_SRCS := $$(filter $$(NATIVE_SOURCE_EXTENSIONS), $$($1_SRCS)) $1_SRCS := $$(filter $$(NATIVE_SOURCE_EXTENSIONS), $$($1_SRCS))
# Extract the C/C++ files. # Extract the C/C++ files.
ifneq ($$($1_EXCLUDE_PATTERNS), ) ifneq ($$($1_EXCLUDE_PATTERNS), )
# We must not match the exclude pattern against the src root(s). # We must not match the exclude pattern against the src root(s).
$1_SRCS_WITHOUT_ROOTS := $$($1_SRCS) $1_SRCS_WITHOUT_ROOTS := $$($1_SRCS)
$$(foreach i,$$($1_SRC),$$(eval $1_SRCS_WITHOUT_ROOTS := $$(patsubst \ $$(foreach i, $$($1_SRC), $$(eval $1_SRCS_WITHOUT_ROOTS := $$(patsubst \
$$i/%,%, $$($1_SRCS_WITHOUT_ROOTS)))) $$i/%,%, $$($1_SRCS_WITHOUT_ROOTS))))
$1_ALL_EXCLUDE_FILES := $$(call containing, $$($1_EXCLUDE_PATTERNS), \ $1_ALL_EXCLUDE_FILES := $$(call containing, $$($1_EXCLUDE_PATTERNS), \
$$($1_SRCS_WITHOUT_ROOTS)) $$($1_SRCS_WITHOUT_ROOTS))
endif endif
ifneq ($$($1_EXCLUDE_FILES),) ifneq ($$($1_EXCLUDE_FILES), )
$1_ALL_EXCLUDE_FILES += $$($1_EXCLUDE_FILES) $1_ALL_EXCLUDE_FILES += $$($1_EXCLUDE_FILES)
endif endif
ifneq ($$($1_ALL_EXCLUDE_FILES),) ifneq ($$($1_ALL_EXCLUDE_FILES), )
$1_EXCLUDE_FILES_PAT := $$($1_ALL_EXCLUDE_FILES) \ $1_EXCLUDE_FILES_PAT := $$($1_ALL_EXCLUDE_FILES) \
$$(foreach i,$$($1_SRC),$$(addprefix $$i/,$$($1_ALL_EXCLUDE_FILES))) $$(foreach i, $$($1_SRC), $$(addprefix $$i/, $$($1_ALL_EXCLUDE_FILES)))
$1_EXCLUDE_FILES_PAT := $$(addprefix %,$$($1_EXCLUDE_FILES_PAT)) $1_EXCLUDE_FILES_PAT := $$(addprefix %, $$($1_EXCLUDE_FILES_PAT))
$1_SRCS := $$(filter-out $$($1_EXCLUDE_FILES_PAT),$$($1_SRCS)) $1_SRCS := $$(filter-out $$($1_EXCLUDE_FILES_PAT), $$($1_SRCS))
endif endif
ifneq ($$($1_INCLUDE_FILES), ) ifneq ($$($1_INCLUDE_FILES), )
$1_INCLUDE_FILES_PAT := $$(foreach i,$$($1_SRC),$$(addprefix $$i/,$$($1_INCLUDE_FILES))) $1_INCLUDE_FILES_PAT := $$(foreach i, $$($1_SRC), $$(addprefix $$i/, $$($1_INCLUDE_FILES)))
$1_SRCS := $$(filter $$($1_INCLUDE_FILES_PAT),$$($1_SRCS)) $1_SRCS := $$(filter $$($1_INCLUDE_FILES_PAT), $$($1_SRCS))
endif endif
# There can be only a single bin dir root, no need to foreach over the roots. # There can be only a single bin dir root, no need to foreach over the roots.
$1_BINS := $$(wildcard $$($1_OBJECT_DIR)/*$(OBJ_SUFFIX)) $1_BINS := $$(wildcard $$($1_OBJECT_DIR)/*$(OBJ_SUFFIX))
@ -541,29 +490,29 @@ define SetupNativeCompilationBody
# and we have a list of all existing object files: $$($1_BINS) # and we have a list of all existing object files: $$($1_BINS)
# Prepend the source/bin path to the filter expressions. Then do the filtering. # Prepend the source/bin path to the filter expressions. Then do the filtering.
ifneq ($$($1_INCLUDES),) ifneq ($$($1_INCLUDES), )
$1_SRC_INCLUDES := $$(foreach i,$$($1_SRC),$$(addprefix $$i/,$$(addsuffix /%,$$($1_INCLUDES)))) $1_SRC_INCLUDES := $$(foreach i, $$($1_SRC), $$(addprefix $$i/, $$(addsuffix /%, $$($1_INCLUDES))))
$1_SRCS := $$(filter $$($1_SRC_INCLUDES),$$($1_SRCS)) $1_SRCS := $$(filter $$($1_SRC_INCLUDES), $$($1_SRCS))
endif endif
ifneq ($$($1_EXCLUDES),) ifneq ($$($1_EXCLUDES), )
$1_SRC_EXCLUDES := $$(addsuffix /%,$$($1_EXCLUDES)) $1_SRC_EXCLUDES := $$(addsuffix /%, $$($1_EXCLUDES))
$1_SRC_EXCLUDES += $$(foreach i,$$($1_SRC),$$(addprefix $$i/,$$(addsuffix /%,$$($1_EXCLUDES)))) $1_SRC_EXCLUDES += $$(foreach i, $$($1_SRC), $$(addprefix $$i/, $$(addsuffix /%, $$($1_EXCLUDES))))
$1_SRCS := $$(filter-out $$($1_SRC_EXCLUDES),$$($1_SRCS)) $1_SRCS := $$(filter-out $$($1_SRC_EXCLUDES), $$($1_SRCS))
endif endif
$1_SRCS += $$($1_EXTRA_FILES) $1_SRCS += $$($1_EXTRA_FILES)
ifeq (,$$($1_SRCS)) ifeq ($$($1_SRCS), )
$$(error No sources found for $1 when looking inside the dirs $$($1_SRC)) $$(error No sources found for $1 when looking inside the dirs $$($1_SRC))
endif endif
# Calculate the expected output from compiling the sources # Calculate the expected output from compiling the sources
$1_EXPECTED_OBJS_FILENAMES := $$(call replace_with_obj_extension, $$(notdir $$($1_SRCS))) $1_EXPECTED_OBJS_FILENAMES := $$(call replace_with_obj_extension, $$(notdir $$($1_SRCS)))
$1_EXPECTED_OBJS := $$(addprefix $$($1_OBJECT_DIR)/,$$($1_EXPECTED_OBJS_FILENAMES)) $1_EXPECTED_OBJS := $$(addprefix $$($1_OBJECT_DIR)/, $$($1_EXPECTED_OBJS_FILENAMES))
# Are there too many object files on disk? Perhaps because some source file was removed? # Are there too many object files on disk? Perhaps because some source file was removed?
$1_SUPERFLOUS_OBJS:=$$(sort $$(filter-out $$($1_EXPECTED_OBJS),$$($1_BINS))) $1_SUPERFLOUS_OBJS := $$(sort $$(filter-out $$($1_EXPECTED_OBJS), $$($1_BINS)))
# Clean out the superfluous object files. # Clean out the superfluous object files.
ifneq ($$($1_SUPERFLUOUS_OBJS),) ifneq ($$($1_SUPERFLUOUS_OBJS), )
$$(shell $(RM) -f $$($1_SUPERFLUOUS_OBJS)) $$(shell $(RM) -f $$($1_SUPERFLUOUS_OBJS))
endif endif
# Sort to remove dupliates and provide a reproducable order on the input files to the linker. # Sort to remove dupliates and provide a reproducable order on the input files to the linker.
@ -571,42 +520,42 @@ define SetupNativeCompilationBody
# Pickup extra OPENJDK_TARGET_OS_TYPE, OPENJDK_TARGET_OS, and/or OPENJDK_TARGET_OS plus # Pickup extra OPENJDK_TARGET_OS_TYPE, OPENJDK_TARGET_OS, and/or OPENJDK_TARGET_OS plus
# OPENJDK_TARGET_CPU pair dependent variables for CFLAGS. # OPENJDK_TARGET_CPU pair dependent variables for CFLAGS.
$1_EXTRA_CFLAGS:=$$($1_CFLAGS_$(OPENJDK_TARGET_OS_TYPE)) $$($1_CFLAGS_$(OPENJDK_TARGET_OS)) \ $1_EXTRA_CFLAGS := $$($1_CFLAGS_$(OPENJDK_TARGET_OS_TYPE)) $$($1_CFLAGS_$(OPENJDK_TARGET_OS)) \
$$($1_CFLAGS_$(OPENJDK_TARGET_OS)_$(OPENJDK_TARGET_CPU)) $$($1_CFLAGS_$(OPENJDK_TARGET_OS)_$(OPENJDK_TARGET_CPU))
ifneq ($(DEBUG_LEVEL),release) ifneq ($(DEBUG_LEVEL), release)
# Pickup extra debug dependent variables for CFLAGS # Pickup extra debug dependent variables for CFLAGS
$1_EXTRA_CFLAGS+=$$($1_CFLAGS_debug) $1_EXTRA_CFLAGS += $$($1_CFLAGS_debug)
$1_EXTRA_CFLAGS+=$$($1_CFLAGS_$(OPENJDK_TARGET_OS_TYPE)_debug) $1_EXTRA_CFLAGS += $$($1_CFLAGS_$(OPENJDK_TARGET_OS_TYPE)_debug)
$1_EXTRA_CFLAGS+=$$($1_CFLAGS_$(OPENJDK_TARGET_OS)_debug) $1_EXTRA_CFLAGS += $$($1_CFLAGS_$(OPENJDK_TARGET_OS)_debug)
$1_EXTRA_CFLAGS+=$$($1_CFLAGS_$(OPENJDK_TARGET_OS)_$(OPENJDK_TARGET_CPU)_debug) $1_EXTRA_CFLAGS += $$($1_CFLAGS_$(OPENJDK_TARGET_OS)_$(OPENJDK_TARGET_CPU)_debug)
else else
$1_EXTRA_CFLAGS+=$$($1_CFLAGS_release) $1_EXTRA_CFLAGS += $$($1_CFLAGS_release)
$1_EXTRA_CFLAGS+=$$($1_CFLAGS_$(OPENJDK_TARGET_OS_TYPE)_release) $1_EXTRA_CFLAGS += $$($1_CFLAGS_$(OPENJDK_TARGET_OS_TYPE)_release)
$1_EXTRA_CFLAGS+=$$($1_CFLAGS_$(OPENJDK_TARGET_OS)_release) $1_EXTRA_CFLAGS += $$($1_CFLAGS_$(OPENJDK_TARGET_OS)_release)
$1_EXTRA_CFLAGS+=$$($1_CFLAGS_$(OPENJDK_TARGET_OS)_$(OPENJDK_TARGET_CPU)_release) $1_EXTRA_CFLAGS += $$($1_CFLAGS_$(OPENJDK_TARGET_OS)_$(OPENJDK_TARGET_CPU)_release)
endif endif
# Pickup extra OPENJDK_TARGET_OS_TYPE and/or OPENJDK_TARGET_OS dependent variables for CXXFLAGS. # Pickup extra OPENJDK_TARGET_OS_TYPE and/or OPENJDK_TARGET_OS dependent variables for CXXFLAGS.
$1_EXTRA_CXXFLAGS:=$$($1_CXXFLAGS_$(OPENJDK_TARGET_OS_TYPE)) $$($1_CXXFLAGS_$(OPENJDK_TARGET_OS)) $1_EXTRA_CXXFLAGS := $$($1_CXXFLAGS_$(OPENJDK_TARGET_OS_TYPE)) $$($1_CXXFLAGS_$(OPENJDK_TARGET_OS))
ifneq ($(DEBUG_LEVEL),release) ifneq ($(DEBUG_LEVEL), release)
# Pickup extra debug dependent variables for CXXFLAGS # Pickup extra debug dependent variables for CXXFLAGS
$1_EXTRA_CXXFLAGS+=$$($1_CXXFLAGS_debug) $1_EXTRA_CXXFLAGS += $$($1_CXXFLAGS_debug)
$1_EXTRA_CXXFLAGS+=$$($1_CXXFLAGS_$(OPENJDK_TARGET_OS_TYPE)_debug) $1_EXTRA_CXXFLAGS += $$($1_CXXFLAGS_$(OPENJDK_TARGET_OS_TYPE)_debug)
$1_EXTRA_CXXFLAGS+=$$($1_CXXFLAGS_$(OPENJDK_TARGET_OS)_debug) $1_EXTRA_CXXFLAGS += $$($1_CXXFLAGS_$(OPENJDK_TARGET_OS)_debug)
else else
$1_EXTRA_CXXFLAGS+=$$($1_CXXFLAGS_release) $1_EXTRA_CXXFLAGS += $$($1_CXXFLAGS_release)
$1_EXTRA_CXXFLAGS+=$$($1_CXXFLAGS_$(OPENJDK_TARGET_OS_TYPE)_release) $1_EXTRA_CXXFLAGS += $$($1_CXXFLAGS_$(OPENJDK_TARGET_OS_TYPE)_release)
$1_EXTRA_CXXFLAGS+=$$($1_CXXFLAGS_$(OPENJDK_TARGET_OS)_release) $1_EXTRA_CXXFLAGS += $$($1_CXXFLAGS_$(OPENJDK_TARGET_OS)_release)
endif endif
# If no C++ flags are explicitly set, default to using the C flags. # If no C++ flags are explicitly set, default to using the C flags.
# After that, we can set additional C++ flags that should not interfere # After that, we can set additional C++ flags that should not interfere
# with the mechanism for copying the C flags by default. # with the mechanism for copying the C flags by default.
ifeq ($$($1_CXXFLAGS),) ifeq ($$($1_CXXFLAGS), )
$1_CXXFLAGS:=$$($1_CFLAGS) $1_CXXFLAGS := $$($1_CFLAGS)
endif endif
ifeq ($$(strip $$($1_EXTRA_CXXFLAGS)),) ifeq ($$(strip $$($1_EXTRA_CXXFLAGS)), )
$1_EXTRA_CXXFLAGS:=$$($1_EXTRA_CFLAGS) $1_EXTRA_CXXFLAGS := $$($1_EXTRA_CFLAGS)
endif endif
ifeq ($(COMPILE_WITH_DEBUG_SYMBOLS), true) ifeq ($(COMPILE_WITH_DEBUG_SYMBOLS), true)
@ -616,19 +565,19 @@ define SetupNativeCompilationBody
$1_EXTRA_CXXFLAGS += $$($1_CXXFLAGS_DEBUG_SYMBOLS) $1_EXTRA_CXXFLAGS += $$($1_CXXFLAGS_DEBUG_SYMBOLS)
endif endif
ifneq (,$$($1_REORDER)) ifneq ($$($1_REORDER), )
$1_EXTRA_CFLAGS += $$(C_FLAG_REORDER) $1_EXTRA_CFLAGS += $$(C_FLAG_REORDER)
$1_EXTRA_CXXFLAGS += $$(CXX_FLAG_REORDER) $1_EXTRA_CXXFLAGS += $$(CXX_FLAG_REORDER)
endif endif
# Pass the library name for static JNI library naming # Pass the library name for static JNI library naming
ifneq ($$($1_STATIC_LIBRARY),) ifeq ($$($1_TYPE), STATIC_LIBRARY)
$1_EXTRA_CFLAGS += -DLIBRARY_NAME=$$($1_STATIC_LIBRARY) $1_EXTRA_CFLAGS += -DLIBRARY_NAME=$$($1_NAME)
$1_EXTRA_CXXFLAGS += -DLIBRARY_NAME=$$($1_STATIC_LIBRARY) $1_EXTRA_CXXFLAGS += -DLIBRARY_NAME=$$($1_NAME)
endif endif
# Pick up disabled warnings, if possible on this platform. # Pick up disabled warnings, if possible on this platform.
ifneq ($(DISABLE_WARNING_PREFIX),) ifneq ($(DISABLE_WARNING_PREFIX), )
$1_EXTRA_CFLAGS += $$(addprefix $(DISABLE_WARNING_PREFIX), \ $1_EXTRA_CFLAGS += $$(addprefix $(DISABLE_WARNING_PREFIX), \
$$($1_DISABLED_WARNINGS_$(TOOLCHAIN_TYPE)) \ $$($1_DISABLED_WARNINGS_$(TOOLCHAIN_TYPE)) \
$$($1_DISABLED_WARNINGS_C_$(TOOLCHAIN_TYPE))) $$($1_DISABLED_WARNINGS_C_$(TOOLCHAIN_TYPE)))
@ -639,8 +588,8 @@ define SetupNativeCompilationBody
# Check if warnings should be considered errors. # Check if warnings should be considered errors.
# Pick first binary and toolchain specific, then binary specific, then general setting. # Pick first binary and toolchain specific, then binary specific, then general setting.
ifeq ($$($1_WARNINGS_AS_ERRORS_$(TOOLCHAIN_TYPE)),) ifeq ($$($1_WARNINGS_AS_ERRORS_$(TOOLCHAIN_TYPE)), )
ifeq ($$($1_WARNINGS_AS_ERRORS),) ifeq ($$($1_WARNINGS_AS_ERRORS), )
$1_WARNINGS_AS_ERRORS_$(TOOLCHAIN_TYPE) := $$(WARNINGS_AS_ERRORS) $1_WARNINGS_AS_ERRORS_$(TOOLCHAIN_TYPE) := $$(WARNINGS_AS_ERRORS)
else else
$1_WARNINGS_AS_ERRORS_$(TOOLCHAIN_TYPE) := $$($1_WARNINGS_AS_ERRORS) $1_WARNINGS_AS_ERRORS_$(TOOLCHAIN_TYPE) := $$($1_WARNINGS_AS_ERRORS)
@ -740,7 +689,7 @@ define SetupNativeCompilationBody
endif endif
# Now call add_native_source for each source file we are going to compile. # Now call add_native_source for each source file we are going to compile.
$$(foreach p,$$($1_SRCS), \ $$(foreach p, $$($1_SRCS), \
$$(eval $$(call add_native_source,$1,$$p,$$($1_OBJECT_DIR), \ $$(eval $$(call add_native_source,$1,$$p,$$($1_OBJECT_DIR), \
$$($1_CFLAGS) $$($1_EXTRA_CFLAGS) $$($1_SYSROOT_CFLAGS), \ $$($1_CFLAGS) $$($1_EXTRA_CFLAGS) $$($1_SYSROOT_CFLAGS), \
$$($1_CC), \ $$($1_CC), \
@ -750,7 +699,7 @@ define SetupNativeCompilationBody
# Setup rule for printing progress info when compiling source files. # Setup rule for printing progress info when compiling source files.
# This is a rough heuristic and may not always print accurate information. # This is a rough heuristic and may not always print accurate information.
$$($1_BUILD_INFO): $$($1_SRCS) $$($1_COMPILE_VARDEPS_FILE) $$($1_BUILD_INFO): $$($1_SRCS) $$($1_COMPILE_VARDEPS_FILE)
ifeq ($$(wildcard $$($1_TARGET)),) ifeq ($$(wildcard $$($1_TARGET)), )
$(ECHO) 'Creating $$(subst $$(OUTPUTDIR)/,,$$($1_TARGET)) from $$(words \ $(ECHO) 'Creating $$(subst $$(OUTPUTDIR)/,,$$($1_TARGET)) from $$(words \
$$(filter-out %.vardeps, $$?)) file(s)' $$(filter-out %.vardeps, $$?)) file(s)'
else else
@ -763,10 +712,10 @@ define SetupNativeCompilationBody
# On windows we need to create a resource file # On windows we need to create a resource file
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
ifneq (,$$($1_VERSIONINFO_RESOURCE)) ifneq ($$($1_VERSIONINFO_RESOURCE), )
$1_RES:=$$($1_OBJECT_DIR)/$$($1_BASENAME).res $1_RES := $$($1_OBJECT_DIR)/$$($1_BASENAME).res
$1_RES_DEP:=$$($1_RES).d $1_RES_DEP := $$($1_RES).d
$1_RES_DEP_TARGETS:=$$($1_RES).d.targets $1_RES_DEP_TARGETS := $$($1_RES).d.targets
-include $$($1_RES_DEP) -include $$($1_RES_DEP)
-include $$($1_RES_DEP_TARGETS) -include $$($1_RES_DEP_TARGETS)
@ -775,7 +724,7 @@ define SetupNativeCompilationBody
$$($1_RES).vardeps) $$($1_RES).vardeps)
$$($1_RES): $$($1_VERSIONINFO_RESOURCE) $$($1_RES_VARDEPS_FILE) $$($1_RES): $$($1_VERSIONINFO_RESOURCE) $$($1_RES_VARDEPS_FILE)
$$(call LogInfo, Compiling resource $$(notdir $$($1_VERSIONINFO_RESOURCE)) (for $$(notdir $$($1_TARGET)))) $$(call LogInfo, Compiling resource $$(notdir $$($1_VERSIONINFO_RESOURCE)) (for $$($1_BASENAME)))
$$(call MakeDir, $$(@D) $$($1_OBJECT_DIR)) $$(call MakeDir, $$(@D) $$($1_OBJECT_DIR))
$$(call ExecuteWithLog, $$@, \ $$(call ExecuteWithLog, $$@, \
$$($1_RC) $$($1_RC_FLAGS) $$($1_SYSROOT_CFLAGS) $(CC_OUT_OPTION)$$@ \ $$($1_RC) $$($1_RC_FLAGS) $$($1_SYSROOT_CFLAGS) $(CC_OUT_OPTION)$$@ \
@ -798,10 +747,10 @@ define SetupNativeCompilationBody
endif endif
endif endif
ifneq ($(DISABLE_MAPFILES),true) ifneq ($(DISABLE_MAPFILES), true)
$1_REAL_MAPFILE := $$($1_MAPFILE) $1_REAL_MAPFILE := $$($1_MAPFILE)
ifneq ($(OPENJDK_TARGET_OS),windows) ifneq ($(OPENJDK_TARGET_OS), windows)
ifneq (,$$($1_REORDER)) ifneq ($$($1_REORDER), )
$1_REAL_MAPFILE := $$($1_OBJECT_DIR)/mapfile $1_REAL_MAPFILE := $$($1_OBJECT_DIR)/mapfile
$$($1_REAL_MAPFILE) : $$($1_MAPFILE) $$($1_REORDER) $$($1_REAL_MAPFILE) : $$($1_MAPFILE) $$($1_REORDER)
@ -815,9 +764,9 @@ define SetupNativeCompilationBody
# Pickup extra OPENJDK_TARGET_OS_TYPE and/or OPENJDK_TARGET_OS dependent variables # Pickup extra OPENJDK_TARGET_OS_TYPE and/or OPENJDK_TARGET_OS dependent variables
# for LDFLAGS and LIBS # for LDFLAGS and LIBS
$1_EXTRA_LDFLAGS:=$$($1_LDFLAGS_$(OPENJDK_TARGET_OS_TYPE)) $$($1_LDFLAGS_$(OPENJDK_TARGET_OS)) $1_EXTRA_LDFLAGS := $$($1_LDFLAGS_$(OPENJDK_TARGET_OS_TYPE)) $$($1_LDFLAGS_$(OPENJDK_TARGET_OS))
$1_EXTRA_LIBS:=$$($1_LIBS_$(OPENJDK_TARGET_OS_TYPE)) $$($1_LIBS_$(OPENJDK_TARGET_OS)) $1_EXTRA_LIBS := $$($1_LIBS_$(OPENJDK_TARGET_OS_TYPE)) $$($1_LIBS_$(OPENJDK_TARGET_OS))
ifneq (,$$($1_REAL_MAPFILE)) ifneq ($$($1_REAL_MAPFILE), )
$1_EXTRA_LDFLAGS += $(call SET_SHARED_LIBRARY_MAPFILE,$$($1_REAL_MAPFILE)) $1_EXTRA_LDFLAGS += $(call SET_SHARED_LIBRARY_MAPFILE,$$($1_REAL_MAPFILE))
endif endif
@ -835,7 +784,7 @@ define SetupNativeCompilationBody
ifeq ($$($1_COPY_DEBUG_SYMBOLS), true) ifeq ($$($1_COPY_DEBUG_SYMBOLS), true)
ifneq ($$($1_DEBUG_SYMBOLS), false) ifneq ($$($1_DEBUG_SYMBOLS), false)
# Only copy debug symbols for dynamic libraries and programs. # Only copy debug symbols for dynamic libraries and programs.
ifeq ($$($1_STATIC_LIBRARY), ) ifneq ($$($1_TYPE), STATIC_LIBRARY)
# Generate debuginfo files. # Generate debuginfo files.
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
$1_EXTRA_LDFLAGS += -debug "-pdb:$$($1_OUTPUT_DIR)/$$($1_NOSUFFIX).pdb" \ $1_EXTRA_LDFLAGS += -debug "-pdb:$$($1_OUTPUT_DIR)/$$($1_NOSUFFIX).pdb" \
@ -899,17 +848,17 @@ define SetupNativeCompilationBody
endif endif
endif endif
ifneq (,$$($1_LIBRARY)) ifeq ($$($1_TYPE), LIBRARY)
# Generating a dynamic library. # Generating a dynamic library.
$1_EXTRA_LDFLAGS += $$(call SET_SHARED_LIBRARY_NAME,$$($1_BASENAME)) $1_EXTRA_LDFLAGS += $$(call SET_SHARED_LIBRARY_NAME,$$($1_BASENAME))
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
$1_EXTRA_LDFLAGS += "-implib:$$($1_OBJECT_DIR)/$$($1_LIBRARY).lib" $1_EXTRA_LDFLAGS += "-implib:$$($1_OBJECT_DIR)/$$($1_NAME).lib"
# Create a rule for the import lib so that other rules may depend on it # Create a rule for the import lib so that other rules may depend on it
$$($1_OBJECT_DIR)/$$($1_LIBRARY).lib: $$($1_TARGET) $$($1_OBJECT_DIR)/$$($1_NAME).lib: $$($1_TARGET)
endif endif
# Create loadmap on AIX. Helps in diagnosing some problems. # Create loadmap on AIX. Helps in diagnosing some problems.
ifneq ($(COMPILER_BINDCMD_FILE_FLAG),) ifneq ($(COMPILER_BINDCMD_FILE_FLAG), )
$1_EXTRA_LDFLAGS += $(COMPILER_BINDCMD_FILE_FLAG)$$($1_OBJECT_DIR)/$$($1_NOSUFFIX).loadmap $1_EXTRA_LDFLAGS += $(COMPILER_BINDCMD_FILE_FLAG)$$($1_OBJECT_DIR)/$$($1_NOSUFFIX).loadmap
endif endif
@ -924,7 +873,7 @@ define SetupNativeCompilationBody
# If there are many object files, use an @-file... # If there are many object files, use an @-file...
ifneq ($$(word 17, $$($1_ALL_OBJS)), ) ifneq ($$(word 17, $$($1_ALL_OBJS)), )
$1_OBJ_FILE_LIST := $$($1_OBJECT_DIR)/_$1_objectfilenames.txt $1_OBJ_FILE_LIST := $$($1_OBJECT_DIR)/_$1_objectfilenames.txt
ifneq ($(COMPILER_COMMAND_FILE_FLAG),) ifneq ($(COMPILER_COMMAND_FILE_FLAG), )
$1_LD_OBJ_ARG := $(COMPILER_COMMAND_FILE_FLAG)$$($1_OBJ_FILE_LIST) $1_LD_OBJ_ARG := $(COMPILER_COMMAND_FILE_FLAG)$$($1_OBJ_FILE_LIST)
else else
# ...except for toolchains which don't support them. # ...except for toolchains which don't support them.
@ -986,7 +935,7 @@ define SetupNativeCompilationBody
endif endif
ifneq (,$$($1_STATIC_LIBRARY)) ifeq ($$($1_TYPE), STATIC_LIBRARY)
$1_VARDEPS := $$($1_AR) $$($1_ARFLAGS) $$($1_LIBS) \ $1_VARDEPS := $$($1_AR) $$($1_ARFLAGS) $$($1_LIBS) \
$$($1_EXTRA_LIBS) $$($1_EXTRA_LIBS)
$1_VARDEPS_FILE := $$(call DependOnVariable, $1_VARDEPS, \ $1_VARDEPS_FILE := $$(call DependOnVariable, $1_VARDEPS, \
@ -1000,7 +949,7 @@ define SetupNativeCompilationBody
endif endif
$$($1_TARGET): $$($1_ALL_OBJS) $$($1_RES) $$($1_VARDEPS_FILE) $$(STATIC_MAPFILE_DEP) $$($1_TARGET): $$($1_ALL_OBJS) $$($1_RES) $$($1_VARDEPS_FILE) $$(STATIC_MAPFILE_DEP)
$$(call LogInfo, Archiving $$($1_STATIC_LIBRARY)) $$(call LogInfo, Building static library $$($1_BASENAME))
$$(call ExecuteWithLog, $$($1_OBJECT_DIR)/$$($1_SAFE_NAME)_link, \ $$(call ExecuteWithLog, $$($1_OBJECT_DIR)/$$($1_SAFE_NAME)_link, \
$$($1_AR) $$($1_ARFLAGS) $(AR_OUT_OPTION)$$($1_TARGET) $$($1_ALL_OBJS) \ $$($1_AR) $$($1_ARFLAGS) $(AR_OUT_OPTION)$$($1_TARGET) $$($1_ALL_OBJS) \
$$($1_RES)) $$($1_RES))
@ -1013,7 +962,7 @@ define SetupNativeCompilationBody
endif endif
endif endif
ifneq (,$$($1_PROGRAM)) ifeq ($$($1_TYPE), EXECUTABLE)
# A executable binary has been specified, setup the target for it. # A executable binary has been specified, setup the target for it.
$1_VARDEPS := $$($1_LD) $$($1_SYSROOT_LDFLAGS) $$($1_LDFLAGS) $$($1_EXTRA_LDFLAGS) \ $1_VARDEPS := $$($1_LD) $$($1_SYSROOT_LDFLAGS) $$($1_LDFLAGS) $$($1_EXTRA_LDFLAGS) \
$$($1_LIBS) $$($1_EXTRA_LIBS) $$($1_MT) \ $$($1_LIBS) $$($1_EXTRA_LIBS) $$($1_MT) \
@ -1038,13 +987,13 @@ define SetupNativeCompilationBody
$$($1_LIBS) $$($1_EXTRA_LIBS)) $$($1_LIBS) $$($1_EXTRA_LIBS))
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
ifneq ($$($1_MANIFEST), ) ifneq ($$($1_MANIFEST), )
$$($1_MT) -nologo -manifest $$($1_MANIFEST) -identity:"$$($1_PROGRAM).exe, version=$$($1_MANIFEST_VERSION)" -outputresource:$$@;#1 $$($1_MT) -nologo -manifest $$($1_MANIFEST) -identity:"$$($1_NAME).exe, version=$$($1_MANIFEST_VERSION)" -outputresource:$$@;#1
endif endif
endif endif
# This only works if the openjdk_codesign identity is present on the system. Let # This only works if the openjdk_codesign identity is present on the system. Let
# silently fail otherwise. # silently fail otherwise.
ifneq (,$(CODESIGN)) ifneq ($(CODESIGN), )
ifneq (,$$($1_CODESIGN)) ifneq ($$($1_CODESIGN), )
$(CODESIGN) -s openjdk_codesign $$@ $(CODESIGN) -s openjdk_codesign $$@
endif endif
endif endif

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -61,11 +61,13 @@ define SetupTestFilesCompilationBody
$1_OUTPUT_SUBDIR := lib $1_OUTPUT_SUBDIR := lib
$1_CFLAGS := $(CFLAGS_TESTLIB) $(CFLAGS_WARNINGS_ARE_ERRORS) $1_CFLAGS := $(CFLAGS_TESTLIB) $(CFLAGS_WARNINGS_ARE_ERRORS)
$1_LDFLAGS := $(LDFLAGS_TESTLIB) $(call SET_SHARED_LIBRARY_ORIGIN) $1_LDFLAGS := $(LDFLAGS_TESTLIB) $(call SET_SHARED_LIBRARY_ORIGIN)
$1_COMPILATION_TYPE := LIBRARY
else ifeq ($$($1_TYPE), PROGRAM) else ifeq ($$($1_TYPE), PROGRAM)
$1_PREFIX = exe $1_PREFIX = exe
$1_OUTPUT_SUBDIR := bin $1_OUTPUT_SUBDIR := bin
$1_CFLAGS := $(CFLAGS_TESTEXE) $(CFLAGS_WARNINGS_ARE_ERRORS) $1_CFLAGS := $(CFLAGS_TESTEXE) $(CFLAGS_WARNINGS_ARE_ERRORS)
$1_LDFLAGS := $(LDFLAGS_TESTEXE) $1_LDFLAGS := $(LDFLAGS_TESTEXE)
$1_COMPILATION_TYPE := EXECUTABLE
else else
$$(error Unknown type: $$($1_TYPE)) $$(error Unknown type: $$($1_TYPE))
endif endif
@ -78,7 +80,8 @@ define SetupTestFilesCompilationBody
$$(foreach file, $$($1_FILE_LIST),\ $$(foreach file, $$($1_FILE_LIST),\
$$(eval name := $$(strip $$(patsubst $$($1_PREFIX)%, %, $$(basename $$(notdir $$(file)))))) \ $$(eval name := $$(strip $$(patsubst $$($1_PREFIX)%, %, $$(basename $$(notdir $$(file)))))) \
$$(eval $$(call SetupNativeCompilation, BUILD_TEST_$$(name), \ $$(eval $$(call SetupNativeCompilation, BUILD_TEST_$$(name), \
$$($1_TYPE) := $$(name), \ NAME := $$(name), \
TYPE := $$($1_COMPILATION_TYPE), \
SRC := $$(patsubst %/,%,$$(dir $$(file))), \ SRC := $$(patsubst %/,%,$$(dir $$(file))), \
INCLUDE_FILES := $$(notdir $$(file)), \ INCLUDE_FILES := $$(notdir $$(file)), \
OBJECT_DIR := $$($1_OUTPUT_DIR)/support/$$($1_PREFIX)$$(name), \ OBJECT_DIR := $$($1_OUTPUT_DIR)/support/$$($1_PREFIX)$$(name), \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -53,7 +53,7 @@ ifeq ($(call check-jvm-feature, compiler2), true)
# Set the C++ standard if supported # Set the C++ standard if supported
ADLC_CFLAGS += $(CXXSTD_CXXFLAG) ADLC_CFLAGS += $(CXXSTD_CXXFLAG)
# NOTE: The old build didn't set -DASSERT for windows but it doesn't seem to # NOTE: The old build didn't set -DASSERT for windows but it doesn't seem to
# hurt. # hurt.
ADLC_CFLAGS += -DASSERT ADLC_CFLAGS += -DASSERT
@ -63,6 +63,8 @@ ifeq ($(call check-jvm-feature, compiler2), true)
ADLC_CFLAGS += -I$(TOPDIR)/src/hotspot/share ADLC_CFLAGS += -I$(TOPDIR)/src/hotspot/share
$(eval $(call SetupNativeCompilation, BUILD_ADLC, \ $(eval $(call SetupNativeCompilation, BUILD_ADLC, \
NAME := adlc, \
TYPE := EXECUTABLE, \
TOOLCHAIN := TOOLCHAIN_BUILD_LINK_CXX, \ TOOLCHAIN := TOOLCHAIN_BUILD_LINK_CXX, \
SRC := $(TOPDIR)/src/hotspot/share/adlc, \ SRC := $(TOPDIR)/src/hotspot/share/adlc, \
EXTRA_FILES := $(TOPDIR)/src/hotspot/share/opto/opcodes.cpp, \ EXTRA_FILES := $(TOPDIR)/src/hotspot/share/opto/opcodes.cpp, \
@ -71,7 +73,6 @@ ifeq ($(call check-jvm-feature, compiler2), true)
LIBS := $(ADLC_LIBS), \ LIBS := $(ADLC_LIBS), \
OBJECT_DIR := $(JVM_VARIANT_OUTPUTDIR)/tools/adlc/objs, \ OBJECT_DIR := $(JVM_VARIANT_OUTPUTDIR)/tools/adlc/objs, \
OUTPUT_DIR := $(JVM_VARIANT_OUTPUTDIR)/tools/adlc, \ OUTPUT_DIR := $(JVM_VARIANT_OUTPUTDIR)/tools/adlc, \
PROGRAM := adlc, \
DEBUG_SYMBOLS := false, \ DEBUG_SYMBOLS := false, \
DISABLED_WARNINGS_clang := tautological-compare, \ DISABLED_WARNINGS_clang := tautological-compare, \
DISABLED_WARNINGS_solstudio := notemsource, \ DISABLED_WARNINGS_solstudio := notemsource, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -46,6 +46,8 @@ ifeq ($(call check-jvm-feature, dtrace), true)
# in the libjvm.so, using JVM_CFLAGS as setup in CompileJvm.gmk. Otherwise # in the libjvm.so, using JVM_CFLAGS as setup in CompileJvm.gmk. Otherwise
# this would preferrably have been done as a part of GensrcDtrace.gmk. # this would preferrably have been done as a part of GensrcDtrace.gmk.
$(eval $(call SetupNativeCompilation, BUILD_DTRACE_GEN_OFFSETS, \ $(eval $(call SetupNativeCompilation, BUILD_DTRACE_GEN_OFFSETS, \
NAME := dtraceGenOffsets, \
TYPE := EXECUTABLE, \
SRC := $(TOPDIR)/make/hotspot/src/native/dtrace, \ SRC := $(TOPDIR)/make/hotspot/src/native/dtrace, \
CC := $(BUILD_CXX), \ CC := $(BUILD_CXX), \
CXX := $(BUILD_CXX), \ CXX := $(BUILD_CXX), \
@ -56,7 +58,6 @@ ifeq ($(call check-jvm-feature, dtrace), true)
LIBS := -lc, \ LIBS := -lc, \
OBJECT_DIR := $(JVM_VARIANT_OUTPUTDIR)/tools/dtrace-gen-offsets/objs, \ OBJECT_DIR := $(JVM_VARIANT_OUTPUTDIR)/tools/dtrace-gen-offsets/objs, \
OUTPUT_DIR := $(JVM_VARIANT_OUTPUTDIR)/tools/dtrace-gen-offsets, \ OUTPUT_DIR := $(JVM_VARIANT_OUTPUTDIR)/tools/dtrace-gen-offsets, \
PROGRAM := dtraceGenOffsets, \
)) ))
DTRACE_GEN_OFFSETS_TOOL := $(BUILD_DTRACE_GEN_OFFSETS_TARGET) DTRACE_GEN_OFFSETS_TOOL := $(BUILD_DTRACE_GEN_OFFSETS_TARGET)
@ -156,21 +157,19 @@ ifeq ($(call check-jvm-feature, dtrace), true)
# Unfortunately dtrace generates incorrect types for some symbols in # Unfortunately dtrace generates incorrect types for some symbols in
# dtrace_jhelper.o, resulting in "warning: symbol X has differing types" # dtrace_jhelper.o, resulting in "warning: symbol X has differing types"
# This is tracked in JDK-6890703. # See JDK-6890703 for details.
$(DTRACE_JHELPER_OBJ): $(TOPDIR)/src/hotspot/os/solaris/dtrace/jhelper.d \ # We work around this by fixing the types for these symbols using elfedit,
$(JVM_OFFSETS_INDEX_H) # after dtrace has generated the .o file.
JHELPER_DTRACE_SRC := $(TOPDIR)/src/hotspot/os/solaris/dtrace/jhelper.d
DTRACE_EXTERNAL_SYMBOLS := $(shell $(GREP) ^extern $(JHELPER_DTRACE_SRC) | $(AWK) '{ gsub(";","") ; print $$3 }')
DTRACE_ELFEDIT_COMMANDS := $(foreach symbol, $(DTRACE_EXTERNAL_SYMBOLS), \
-e 'sym:st_type $(symbol) 1')
$(DTRACE_JHELPER_OBJ): $(JHELPER_DTRACE_SRC) $(JVM_OFFSETS_INDEX_H)
$(call LogInfo, Running dtrace for $(<F)) $(call LogInfo, Running dtrace for $(<F))
$(call ExecuteWithLog, $@, $(DTRACE) $(DTRACE_FLAGS) $(DTRACE_CPP_FLAGS) -C \ $(call ExecuteWithLog, $@, $(DTRACE) $(DTRACE_FLAGS) $(DTRACE_CPP_FLAGS) -C \
-I$(DTRACE_SUPPORT_DIR) -o $@ -s $<) -I$(DTRACE_SUPPORT_DIR) -o $@ -s $<)
$(call ExecuteWithLog, $@.elfedit, $(ELFEDIT) $(DTRACE_ELFEDIT_COMMANDS) $@)
# NOTE: We should really do something like this, but unfortunately this
# results in a compilation error. :-(
# $(call MakeDir, $(DTRACE_SUPPORT_DIR))
# $(call ExecuteWithLog, $(DTRACE_SUPPORT_DIR)/$(@F).d, $(CC) -E \
# $(DTRACE_CPP_FLAGS) -I$(DTRACE_SUPPORT_DIR) $^ \
# > $(DTRACE_SUPPORT_DIR)/$(@F).d)
# $(call ExecuteWithLog, $@, $(DTRACE) $(DTRACE_FLAGS) -o $@ \
# -s $(DTRACE_SUPPORT_DIR)/$(@F).d)
############################################################################ ############################################################################
# Build the stand-alone dtrace libraries # Build the stand-alone dtrace libraries
@ -178,7 +177,7 @@ ifeq ($(call check-jvm-feature, dtrace), true)
LIBJVM_DTRACE_OUTPUTDIR := $(JVM_VARIANT_OUTPUTDIR)/libjvm_dtrace LIBJVM_DTRACE_OUTPUTDIR := $(JVM_VARIANT_OUTPUTDIR)/libjvm_dtrace
$(eval $(call SetupNativeCompilation, BUILD_LIBJVM_DTRACE, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJVM_DTRACE, \
LIBRARY := jvm_dtrace, \ NAME := jvm_dtrace, \
OUTPUT_DIR := $(JVM_LIB_OUTPUTDIR), \ OUTPUT_DIR := $(JVM_LIB_OUTPUTDIR), \
SRC := $(TOPDIR)/src/java.base/solaris/native/libjvm_dtrace, \ SRC := $(TOPDIR)/src/java.base/solaris/native/libjvm_dtrace, \
CFLAGS := -m64 -G -mt -KPIC, \ CFLAGS := -m64 -G -mt -KPIC, \
@ -193,7 +192,7 @@ ifeq ($(call check-jvm-feature, dtrace), true)
# Note that libjvm_db.c has tests for COMPILER2, but this was never set by # Note that libjvm_db.c has tests for COMPILER2, but this was never set by
# the old build. # the old build.
$(eval $(call SetupNativeCompilation, BUILD_LIBJVM_DB, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJVM_DB, \
LIBRARY := jvm_db, \ NAME := jvm_db, \
OUTPUT_DIR := $(JVM_LIB_OUTPUTDIR), \ OUTPUT_DIR := $(JVM_LIB_OUTPUTDIR), \
SRC := $(TOPDIR)/src/java.base/solaris/native/libjvm_db, \ SRC := $(TOPDIR)/src/java.base/solaris/native/libjvm_db, \
CFLAGS := -I$(JVM_VARIANT_OUTPUTDIR)/gensrc -I$(DTRACE_SUPPORT_DIR) \ CFLAGS := -I$(JVM_VARIANT_OUTPUTDIR)/gensrc -I$(DTRACE_SUPPORT_DIR) \

View File

@ -63,8 +63,8 @@ endif
# exclusive to the gtest libjvm.so. # exclusive to the gtest libjvm.so.
$(eval $(call SetupNativeCompilation, BUILD_GTEST_LIBJVM, \ $(eval $(call SetupNativeCompilation, BUILD_GTEST_LIBJVM, \
NAME := jvm, \
TOOLCHAIN := TOOLCHAIN_LINK_CXX, \ TOOLCHAIN := TOOLCHAIN_LINK_CXX, \
LIBRARY := jvm, \
OUTPUT_DIR := $(JVM_OUTPUTDIR)/gtest, \ OUTPUT_DIR := $(JVM_OUTPUTDIR)/gtest, \
OBJECT_DIR := $(JVM_OUTPUTDIR)/gtest/objs, \ OBJECT_DIR := $(JVM_OUTPUTDIR)/gtest/objs, \
SRC := $(GTEST_TEST_SRC), \ SRC := $(GTEST_TEST_SRC), \
@ -108,7 +108,8 @@ TARGETS += $(BUILD_GTEST_LIBJVM)
$(eval $(call SetupNativeCompilation, BUILD_GTEST_LAUNCHER, \ $(eval $(call SetupNativeCompilation, BUILD_GTEST_LAUNCHER, \
TOOLCHAIN := TOOLCHAIN_LINK_CXX, \ TOOLCHAIN := TOOLCHAIN_LINK_CXX, \
PROGRAM := gtestLauncher, \ NAME := gtestLauncher, \
TYPE := EXECUTABLE, \
OUTPUT_DIR := $(JVM_OUTPUTDIR)/gtest, \ OUTPUT_DIR := $(JVM_OUTPUTDIR)/gtest, \
EXTRA_FILES := $(GTEST_LAUNCHER_SRC), \ EXTRA_FILES := $(GTEST_LAUNCHER_SRC), \
OBJECT_DIR := $(JVM_OUTPUTDIR)/gtest/launcher-objs, \ OBJECT_DIR := $(JVM_OUTPUTDIR)/gtest/launcher-objs, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -210,8 +210,8 @@ JVM_STRIPFLAGS ?= $(STRIPFLAGS)
# Now set up the actual compilation of the main hotspot native library # Now set up the actual compilation of the main hotspot native library
$(eval $(call SetupNativeCompilation, BUILD_LIBJVM, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJVM, \
NAME := jvm, \
TOOLCHAIN := TOOLCHAIN_LINK_CXX, \ TOOLCHAIN := TOOLCHAIN_LINK_CXX, \
LIBRARY := jvm, \
OUTPUT_DIR := $(JVM_LIB_OUTPUTDIR), \ OUTPUT_DIR := $(JVM_LIB_OUTPUTDIR), \
SRC := $(JVM_SRC_DIRS), \ SRC := $(JVM_SRC_DIRS), \
EXCLUDES := $(JVM_EXCLUDES), \ EXCLUDES := $(JVM_EXCLUDES), \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -90,7 +90,7 @@ ifneq ($(OPENJDK_TARGET_OS), windows)
LIB_OUTPUTDIR := $(call FindLibDirForModule, java.base) LIB_OUTPUTDIR := $(call FindLibDirForModule, java.base)
$(eval $(call SetupNativeCompilation, BUILD_LIBJSIG, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJSIG, \
LIBRARY := jsig, \ NAME := jsig, \
SRC := $(LIBJSIG_SRC_DIR), \ SRC := $(LIBJSIG_SRC_DIR), \
OUTPUT_DIR := $(LIB_OUTPUTDIR), \ OUTPUT_DIR := $(LIB_OUTPUTDIR), \
LANG := C, \ LANG := C, \

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -49,14 +49,14 @@ import static jdk.javadoc.doclet.Taglet.Location.*;
* will produce the following html * will produce the following html
* <p> * <p>
* {@code * {@code
* Please see <a href="https://www.oracle.com/pls/topic/lookup?ctx=javase9&id=Borealis">a spectacular</a> sight. * Please see <a href="https://www.oracle.com/pls/topic/lookup?ctx=javase10&id=Borealis">a spectacular</a> sight.
* } * }
*/ */
public class ExtLink implements Taglet { public class ExtLink implements Taglet {
static final String TAG_NAME = "extLink"; static final String TAG_NAME = "extLink";
static final String URL = "https://www.oracle.com/pls/topic/lookup?ctx=javase9&amp;id="; static final String URL = "https://www.oracle.com/pls/topic/lookup?ctx=javase10&amp;id=";
static final Pattern TAG_PATTERN = Pattern.compile("(?s)(\\s*)(?<name>\\w+)(\\s+)(?<desc>.*)$"); static final Pattern TAG_PATTERN = Pattern.compile("(?s)(\\s*)(?<name>\\w+)(\\s+)(?<desc>.*)$");

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -73,6 +73,8 @@ $(eval $(call SetupBuildLauncher, keytool, \
ifeq ($(OPENJDK_TARGET_OS), linux) ifeq ($(OPENJDK_TARGET_OS), linux)
$(eval $(call SetupNativeCompilation, BUILD_JEXEC, \ $(eval $(call SetupNativeCompilation, BUILD_JEXEC, \
NAME := jexec, \
TYPE := EXECUTABLE, \
SRC := $(TOPDIR)/src/$(MODULE)/unix/native/launcher, \ SRC := $(TOPDIR)/src/$(MODULE)/unix/native/launcher, \
INCLUDE_FILES := jexec.c, \ INCLUDE_FILES := jexec.c, \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
@ -83,7 +85,6 @@ ifeq ($(OPENJDK_TARGET_OS), linux)
LDFLAGS := $(LDFLAGS_JDKEXE), \ LDFLAGS := $(LDFLAGS_JDKEXE), \
OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/jexec_obj, \ OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/jexec_obj, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \
PROGRAM := jexec, \
)) ))
TARGETS += $(BUILD_JEXEC) TARGETS += $(BUILD_JEXEC)
@ -93,6 +94,8 @@ endif
ifneq ($(findstring $(OPENJDK_TARGET_OS), macosx solaris aix), ) ifneq ($(findstring $(OPENJDK_TARGET_OS), macosx solaris aix), )
$(eval $(call SetupNativeCompilation, BUILD_JSPAWNHELPER, \ $(eval $(call SetupNativeCompilation, BUILD_JSPAWNHELPER, \
NAME := jspawnhelper, \
TYPE := EXECUTABLE, \
SRC := $(TOPDIR)/src/$(MODULE)/unix/native/jspawnhelper, \ SRC := $(TOPDIR)/src/$(MODULE)/unix/native/jspawnhelper, \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
CFLAGS := $(CFLAGS_JDKEXE) -I$(TOPDIR)/src/$(MODULE)/unix/native/libjava, \ CFLAGS := $(CFLAGS_JDKEXE) -I$(TOPDIR)/src/$(MODULE)/unix/native/libjava, \
@ -100,7 +103,6 @@ ifneq ($(findstring $(OPENJDK_TARGET_OS), macosx solaris aix), )
LDFLAGS := $(LDFLAGS_JDKEXE), \ LDFLAGS := $(LDFLAGS_JDKEXE), \
OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/jspawnhelper, \ OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/jspawnhelper, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \
PROGRAM := jspawnhelper, \
)) ))
TARGETS += $(BUILD_JSPAWNHELPER) TARGETS += $(BUILD_JSPAWNHELPER)

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -33,7 +33,9 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
JABSWITCH_SRC := $(TOPDIR)/src/jdk.accessibility/windows/native/jabswitch JABSWITCH_SRC := $(TOPDIR)/src/jdk.accessibility/windows/native/jabswitch
ACCESSBRIDGE_SRC := $(TOPDIR)/src/jdk.accessibility/windows/native/common ACCESSBRIDGE_SRC := $(TOPDIR)/src/jdk.accessibility/windows/native/common
$(eval $(call SetupNativeCompilation,BUILD_JABSWITCH, \ $(eval $(call SetupNativeCompilation, BUILD_JABSWITCH, \
NAME := jabswitch, \
TYPE := EXECUTABLE, \
SRC := $(JABSWITCH_SRC), \ SRC := $(JABSWITCH_SRC), \
INCLUDE_FILES := jabswitch.cpp, \ INCLUDE_FILES := jabswitch.cpp, \
CFLAGS := $(filter-out -Zc:wchar_t-, $(CFLAGS_JDKEXE)) -Zc:wchar_t \ CFLAGS := $(filter-out -Zc:wchar_t-, $(CFLAGS_JDKEXE)) -Zc:wchar_t \
@ -44,7 +46,6 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
LIBS := advapi32.lib version.lib user32.lib, \ LIBS := advapi32.lib version.lib user32.lib, \
OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/jdk.accessibility/jabswitch, \ OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/jdk.accessibility/jabswitch, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_cmds/jdk.accessibility, \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_cmds/jdk.accessibility, \
PROGRAM := jabswitch, \
VERSIONINFO_RESOURCE := $(ACCESSBRIDGE_SRC)/AccessBridgeStatusWindow.RC, \ VERSIONINFO_RESOURCE := $(ACCESSBRIDGE_SRC)/AccessBridgeStatusWindow.RC, \
RC_FLAGS := $(RC_FLAGS) \ RC_FLAGS := $(RC_FLAGS) \
-D "JDK_FNAME=jabswitch.exe" \ -D "JDK_FNAME=jabswitch.exe" \
@ -70,6 +71,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
# Parameter 2 ACCESSBRIDGE_ARCH_ -D suffix # Parameter 2 ACCESSBRIDGE_ARCH_ -D suffix
$$(eval $$(call SetupNativeCompilation, BUILD_JACCESSINSPECTOR$1, \ $$(eval $$(call SetupNativeCompilation, BUILD_JACCESSINSPECTOR$1, \
NAME := jaccessinspector$1, \
TYPE := EXECUTABLE, \
SRC := $(TOPDIR)/jaccessinspector $(TOPDIR)/common \ SRC := $(TOPDIR)/jaccessinspector $(TOPDIR)/common \
$(TOPDIR)/toolscommon $(TOPDIR)/bridge, \ $(TOPDIR)/toolscommon $(TOPDIR)/bridge, \
CFLAGS := $$(CFLAGS_JDKEXE) $(TOOLS_CFLAGS) -DACCESSBRIDGE_ARCH_$2 -EHsc, \ CFLAGS := $$(CFLAGS_JDKEXE) $(TOOLS_CFLAGS) -DACCESSBRIDGE_ARCH_$2 -EHsc, \
@ -77,7 +80,6 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
LIBS := advapi32.lib user32.lib, \ LIBS := advapi32.lib user32.lib, \
OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/jdk.accessibility/jaccessinspector$1, \ OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/jdk.accessibility/jaccessinspector$1, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_cmds/jdk.accessibility, \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_cmds/jdk.accessibility, \
PROGRAM := jaccessinspector$1, \
VERSIONINFO_RESOURCE := $(TOPDIR)/jaccessinspector/jaccessinspectorWindow.rc, \ VERSIONINFO_RESOURCE := $(TOPDIR)/jaccessinspector/jaccessinspectorWindow.rc, \
RC_FLAGS := $$(RC_FLAGS) \ RC_FLAGS := $$(RC_FLAGS) \
-D "JDK_FNAME=jaccessinspector$1.exe" \ -D "JDK_FNAME=jaccessinspector$1.exe" \
@ -96,7 +98,9 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
# Parameter 1 File name suffix # Parameter 1 File name suffix
# Parameter 2 ACCESSBRIDGE_ARCH_ -D suffix # Parameter 2 ACCESSBRIDGE_ARCH_ -D suffix
$$(eval $$(call SetupNativeCompilation,BUILD_JACCESSWALKER$1, \ $$(eval $$(call SetupNativeCompilation, BUILD_JACCESSWALKER$1, \
NAME := jaccesswalker$1, \
TYPE := EXECUTABLE, \
SRC := $(TOPDIR)/jaccesswalker $(TOPDIR)/common \ SRC := $(TOPDIR)/jaccesswalker $(TOPDIR)/common \
$(TOPDIR)/toolscommon $(TOPDIR)/bridge, \ $(TOPDIR)/toolscommon $(TOPDIR)/bridge, \
CFLAGS := $$(CFLAGS_JDKEXE) $(TOOLS_CFLAGS) -DACCESSBRIDGE_ARCH_$2 -EHsc, \ CFLAGS := $$(CFLAGS_JDKEXE) $(TOOLS_CFLAGS) -DACCESSBRIDGE_ARCH_$2 -EHsc, \
@ -104,7 +108,6 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
LIBS := advapi32.lib comctl32.lib gdi32.lib user32.lib, \ LIBS := advapi32.lib comctl32.lib gdi32.lib user32.lib, \
OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/jdk.accessibility/jaccesswalker$1, \ OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/jdk.accessibility/jaccesswalker$1, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_cmds/jdk.accessibility, \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_cmds/jdk.accessibility, \
PROGRAM := jaccesswalker$1, \
VERSIONINFO_RESOURCE := $(TOPDIR)/jaccesswalker/jaccesswalkerWindow.rc, \ VERSIONINFO_RESOURCE := $(TOPDIR)/jaccesswalker/jaccesswalkerWindow.rc, \
RC_FLAGS := $$(RC_FLAGS) \ RC_FLAGS := $$(RC_FLAGS) \
-D "JDK_FNAME=jaccesswalker$1.exe" \ -D "JDK_FNAME=jaccesswalker$1.exe" \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -73,7 +73,9 @@ else
UNPACK_MAPFILE := $(UNPACK_MAPFILE_DIR)/mapfile-vers-unpack200 UNPACK_MAPFILE := $(UNPACK_MAPFILE_DIR)/mapfile-vers-unpack200
endif endif
$(eval $(call SetupNativeCompilation,BUILD_UNPACKEXE, \ $(eval $(call SetupNativeCompilation, BUILD_UNPACKEXE, \
NAME := unpack200, \
TYPE := EXECUTABLE, \
SRC := $(UNPACKEXE_SRC), \ SRC := $(UNPACKEXE_SRC), \
TOOLCHAIN := TOOLCHAIN_LINK_CXX, \ TOOLCHAIN := TOOLCHAIN_LINK_CXX, \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
@ -91,7 +93,6 @@ $(eval $(call SetupNativeCompilation,BUILD_UNPACKEXE, \
LIBS_solaris := -lc, \ LIBS_solaris := -lc, \
OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/unpackexe, \ OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/unpackexe, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_cmds/$(MODULE), \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_cmds/$(MODULE), \
PROGRAM := unpack200, \
VERSIONINFO_RESOURCE := $(GLOBAL_VERSION_INFO_RESOURCE), \ VERSIONINFO_RESOURCE := $(GLOBAL_VERSION_INFO_RESOURCE), \
RC_FLAGS := $(RC_FLAGS) \ RC_FLAGS := $(RC_FLAGS) \
-D "JDK_FNAME=unpack200.exe" \ -D "JDK_FNAME=unpack200.exe" \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -183,6 +183,8 @@ define SetupBuildLauncherBody
endif endif
$$(eval $$(call SetupNativeCompilation, BUILD_LAUNCHER_$1, \ $$(eval $$(call SetupNativeCompilation, BUILD_LAUNCHER_$1, \
NAME := $1, \
TYPE := EXECUTABLE, \
EXTRA_FILES := $(LAUNCHER_SRC)/main.c, \ EXTRA_FILES := $(LAUNCHER_SRC)/main.c, \
OPTIMIZATION := $$($1_OPTIMIZATION), \ OPTIMIZATION := $$($1_OPTIMIZATION), \
CFLAGS := $$($1_CFLAGS) \ CFLAGS := $$($1_CFLAGS) \
@ -211,7 +213,6 @@ define SetupBuildLauncherBody
$$($1_LIBS_windows), \ $$($1_LIBS_windows), \
OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/$1_objs, \ OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/$1_objs, \
OUTPUT_DIR := $$($1_OUTPUT_DIR), \ OUTPUT_DIR := $$($1_OUTPUT_DIR), \
PROGRAM := $1, \
VERSIONINFO_RESOURCE := $$($1_VERSION_INFO_RESOURCE), \ VERSIONINFO_RESOURCE := $$($1_VERSION_INFO_RESOURCE), \
RC_FLAGS := $$(RC_FLAGS) \ RC_FLAGS := $$(RC_FLAGS) \
-D "JDK_FNAME=$1$(EXE_SUFFIX)" \ -D "JDK_FNAME=$1$(EXE_SUFFIX)" \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -48,8 +48,8 @@ ifneq ($(OPENJDK_TARGET_OS), windows)
BUILD_LIBMLIB_LDLIBS += $(LIBM) $(LIBDL) BUILD_LIBMLIB_LDLIBS += $(LIBM) $(LIBDL)
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBMLIB_IMAGE, \ $(eval $(call SetupNativeCompilation, BUILD_LIBMLIB_IMAGE, \
LIBRARY := mlib_image, \ NAME := mlib_image, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(BUILD_LIBMLIB_SRC), \ SRC := $(BUILD_LIBMLIB_SRC), \
EXCLUDE_FILES := mlib_c_ImageBlendTable.c, \ EXCLUDE_FILES := mlib_c_ImageBlendTable.c, \
@ -107,8 +107,8 @@ ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH), solaris-sparc)
LIBMLIB_IMAGE_V_CFLAGS += $(filter-out -DMLIB_NO_LIBSUNMATH, $(BUILD_LIBMLIB_CFLAGS)) LIBMLIB_IMAGE_V_CFLAGS += $(filter-out -DMLIB_NO_LIBSUNMATH, $(BUILD_LIBMLIB_CFLAGS))
$(eval $(call SetupNativeCompilation,BUILD_LIBMLIB_IMAGE_V, \ $(eval $(call SetupNativeCompilation, BUILD_LIBMLIB_IMAGE_V, \
LIBRARY := mlib_image_v, \ NAME := mlib_image_v, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBMLIB_IMAGE_V_SRC), \ SRC := $(LIBMLIB_IMAGE_V_SRC), \
EXCLUDE_FILES := $(BUILD_LIBMLIB_IMAGE_V_EXFILES), \ EXCLUDE_FILES := $(BUILD_LIBMLIB_IMAGE_V_EXFILES), \
@ -226,8 +226,8 @@ ifeq ($(TOOLCHAIN_TYPE), gcc)
LIBAWT_CFLAGS += -fgcse-after-reload LIBAWT_CFLAGS += -fgcse-after-reload
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBAWT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBAWT, \
LIBRARY := awt, \ NAME := awt, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBAWT_DIRS), \ SRC := $(LIBAWT_DIRS), \
EXCLUDES := $(LIBAWT_EXCLUDES), \ EXCLUDES := $(LIBAWT_EXCLUDES), \
@ -347,8 +347,8 @@ ifeq ($(findstring $(OPENJDK_TARGET_OS),windows macosx),)
BUILD_LIBAWT_XAWT_debug_mem.c_CFLAGS := -w BUILD_LIBAWT_XAWT_debug_mem.c_CFLAGS := -w
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBAWT_XAWT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBAWT_XAWT, \
LIBRARY := awt_xawt, \ NAME := awt_xawt, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBAWT_XAWT_DIRS), \ SRC := $(LIBAWT_XAWT_DIRS), \
EXCLUDES := $(LIBAWT_XAWT_EXCLUDES), \ EXCLUDES := $(LIBAWT_XAWT_EXCLUDES), \
@ -406,8 +406,8 @@ else
LIBLCMS_CPPFLAGS += $(addprefix -I, $(LIBLCMS_SRC)) LIBLCMS_CPPFLAGS += $(addprefix -I, $(LIBLCMS_SRC))
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBLCMS, \ $(eval $(call SetupNativeCompilation, BUILD_LIBLCMS, \
LIBRARY := lcms, \ NAME := lcms, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBLCMS_SRC), \ SRC := $(LIBLCMS_SRC), \
INCLUDE_FILES := $(BUILD_LIBLCMS_INCLUDE_FILES), \ INCLUDE_FILES := $(BUILD_LIBLCMS_INCLUDE_FILES), \
@ -483,8 +483,8 @@ else
BUILD_LIBJAVAJPEG_HEADERS := $(addprefix -I, $(LIBJAVAJPEG_SRC)) BUILD_LIBJAVAJPEG_HEADERS := $(addprefix -I, $(LIBJAVAJPEG_SRC))
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBJAVAJPEG, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJAVAJPEG, \
LIBRARY := javajpeg, \ NAME := javajpeg, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJAVAJPEG_SRC), \ SRC := $(LIBJAVAJPEG_SRC), \
INCLUDE_FILES := $(BUILD_LIBJAVAJPEG_INCLUDE_FILES), \ INCLUDE_FILES := $(BUILD_LIBJAVAJPEG_INCLUDE_FILES), \
@ -547,8 +547,8 @@ ifeq ($(findstring $(OPENJDK_TARGET_OS), windows macosx),)
endif endif
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBAWT_HEADLESS, \ $(eval $(call SetupNativeCompilation, BUILD_LIBAWT_HEADLESS, \
LIBRARY := awt_headless, \ NAME := awt_headless, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBAWT_HEADLESS_DIRS), \ SRC := $(LIBAWT_HEADLESS_DIRS), \
EXCLUDES := $(LIBAWT_HEADLESS_EXCLUDES), \ EXCLUDES := $(LIBAWT_HEADLESS_EXCLUDES), \
@ -657,8 +657,8 @@ ifeq ($(TOOLCHAIN_TYPE), gcc)
BUILD_LIBFONTMANAGER_ExtensionSubtables.cpp_CXXFLAGS := -fno-strict-aliasing BUILD_LIBFONTMANAGER_ExtensionSubtables.cpp_CXXFLAGS := -fno-strict-aliasing
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBFONTMANAGER, \ $(eval $(call SetupNativeCompilation, BUILD_LIBFONTMANAGER, \
LIBRARY := fontmanager, \ NAME := fontmanager, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libfontmanager, \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libfontmanager, \
SRC := $(LIBFONTMANAGER_SRC), \ SRC := $(LIBFONTMANAGER_SRC), \
EXCLUDE_FILES := $(LIBFONTMANAGER_EXCLUDE_FILES) \ EXCLUDE_FILES := $(LIBFONTMANAGER_EXCLUDE_FILES) \
@ -691,7 +691,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFONTMANAGER, \
LIBS := $(BUILD_LIBFONTMANAGER_FONTLIB), \ LIBS := $(BUILD_LIBFONTMANAGER_FONTLIB), \
LIBS_unix := -lawt -ljava -ljvm $(LIBM) $(LIBCXX), \ LIBS_unix := -lawt -ljava -ljvm $(LIBM) $(LIBCXX), \
LIBS_linux := -lc, \ LIBS_linux := -lc, \
LIBS_solaris := -lawt_headless -lc, \ LIBS_solaris := -lc, \
LIBS_aix := -lawt_headless,\ LIBS_aix := -lawt_headless,\
LIBS_windows := $(WIN_JAVA_LIB) advapi32.lib user32.lib gdi32.lib \ LIBS_windows := $(WIN_JAVA_LIB) advapi32.lib user32.lib gdi32.lib \
$(WIN_AWT_LIB), \ $(WIN_AWT_LIB), \
@ -744,8 +744,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
ifeq ($(OPENJDK_TARGET_CPU), x86) ifeq ($(OPENJDK_TARGET_CPU), x86)
KERNEL32_LIB := kernel32.lib KERNEL32_LIB := kernel32.lib
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBJAWT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJAWT, \
LIBRARY := jawt, \ NAME := jawt, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJAWT_SRC), \ SRC := $(LIBJAWT_SRC), \
INCLUDE_FILES := $(LIBJAWT_INCLUDE_FILES), \ INCLUDE_FILES := $(LIBJAWT_INCLUDE_FILES), \
@ -804,8 +804,8 @@ else # OPENJDK_TARGET_OS not windows
endif endif
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBJAWT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJAWT, \
LIBRARY := jawt, \ NAME := jawt, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJAWT_SRC), \ SRC := $(LIBJAWT_SRC), \
INCLUDE_FILES := $(JAWT_FILES), \ INCLUDE_FILES := $(JAWT_FILES), \
@ -935,8 +935,8 @@ ifeq ($(ENABLE_HEADLESS_ONLY), false)
LIBSPLASHSCREEN_LIBS += $(X_LIBS) -lX11 -lXext $(LIBM) -lpthread -ldl LIBSPLASHSCREEN_LIBS += $(X_LIBS) -lX11 -lXext $(LIBM) -lpthread -ldl
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBSPLASHSCREEN, \ $(eval $(call SetupNativeCompilation, BUILD_LIBSPLASHSCREEN, \
LIBRARY := splashscreen, \ NAME := splashscreen, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBSPLASHSCREEN_DIRS), \ SRC := $(LIBSPLASHSCREEN_DIRS), \
EXCLUDE_FILES := imageioJPEG.c jpegdecoder.c pngtest.c, \ EXCLUDE_FILES := imageioJPEG.c jpegdecoder.c pngtest.c, \
@ -1008,8 +1008,8 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
LIBAWT_LWAWT_EXFILES := fontpath.c awt_Font.c X11Color.c LIBAWT_LWAWT_EXFILES := fontpath.c awt_Font.c X11Color.c
LIBAWT_LWAWT_EXCLUDES := $(TOPDIR)/src/java.desktop/unix/native/common/awt/medialib LIBAWT_LWAWT_EXCLUDES := $(TOPDIR)/src/java.desktop/unix/native/common/awt/medialib
$(eval $(call SetupNativeCompilation,BUILD_LIBAWT_LWAWT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBAWT_LWAWT, \
LIBRARY := awt_lwawt, \ NAME := awt_lwawt, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBAWT_LWAWT_DIRS), \ SRC := $(LIBAWT_LWAWT_DIRS), \
INCLUDE_FILES := $(LIBAWT_LWAWT_FILES), \ INCLUDE_FILES := $(LIBAWT_LWAWT_FILES), \
@ -1057,8 +1057,8 @@ endif
ifeq ($(OPENJDK_TARGET_OS), macosx) ifeq ($(OPENJDK_TARGET_OS), macosx)
$(eval $(call SetupNativeCompilation,BUILD_LIBOSXUI, \ $(eval $(call SetupNativeCompilation, BUILD_LIBOSXUI, \
LIBRARY := osxui, \ NAME := osxui, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(TOPDIR)/src/java.desktop/macosx/native/libosxui, \ SRC := $(TOPDIR)/src/java.desktop/macosx/native/libosxui, \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -55,8 +55,9 @@ LIBFDLIBM_SRC := $(TOPDIR)/src/java.base/share/native/libfdlibm
LIBFDLIBM_CFLAGS := -I$(LIBFDLIBM_SRC) LIBFDLIBM_CFLAGS := -I$(LIBFDLIBM_SRC)
ifneq ($(OPENJDK_TARGET_OS), macosx) ifneq ($(OPENJDK_TARGET_OS), macosx)
$(eval $(call SetupNativeCompilation,BUILD_LIBFDLIBM, \ $(eval $(call SetupNativeCompilation, BUILD_LIBFDLIBM, \
STATIC_LIBRARY := fdlibm, \ NAME := fdlibm, \
TYPE := STATIC_LIBRARY, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE), \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE), \
SRC := $(LIBFDLIBM_SRC), \ SRC := $(LIBFDLIBM_SRC), \
OPTIMIZATION := $(BUILD_LIBFDLIBM_OPTIMIZATION), \ OPTIMIZATION := $(BUILD_LIBFDLIBM_OPTIMIZATION), \
@ -77,8 +78,8 @@ else
# On macosx the old build does partial (incremental) linking of fdlibm instead of # On macosx the old build does partial (incremental) linking of fdlibm instead of
# a plain static library. # a plain static library.
$(eval $(call SetupNativeCompilation,BUILD_LIBFDLIBM_MAC, \ $(eval $(call SetupNativeCompilation, BUILD_LIBFDLIBM_MAC, \
LIBRARY := fdlibm, \ NAME := fdlibm, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libfdlibm, \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libfdlibm, \
SRC := $(LIBFDLIBM_SRC), \ SRC := $(LIBFDLIBM_SRC), \
CFLAGS := $(CFLAGS_JDKLIB) $(LIBFDLIBM_CFLAGS), \ CFLAGS := $(CFLAGS_JDKLIB) $(LIBFDLIBM_CFLAGS), \
@ -107,8 +108,8 @@ ifneq ($(findstring $(OPENJDK_TARGET_OS), solaris linux), )
endif endif
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBVERIFY, \ $(eval $(call SetupNativeCompilation, BUILD_LIBVERIFY, \
LIBRARY := verify, \ NAME := verify, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(TOPDIR)/src/java.base/share/native/libverify, \ SRC := $(TOPDIR)/src/java.base/share/native/libverify, \
OPTIMIZATION := $(LIBVERIFY_OPTIMIZATION), \ OPTIMIZATION := $(LIBVERIFY_OPTIMIZATION), \
@ -155,8 +156,8 @@ ifeq ($(OPENJDK_TARGET_OS), solaris)
endif endif
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBJAVA, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJAVA, \
LIBRARY := java, \ NAME := java, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJAVA_SRC_DIRS), \ SRC := $(LIBJAVA_SRC_DIRS), \
OPTIMIZATION := HIGH, \ OPTIMIZATION := HIGH, \
@ -218,8 +219,8 @@ ifeq ($(LIBZIP_CAN_USE_MMAP), true)
BUILD_LIBZIP_MMAP := -DUSE_MMAP BUILD_LIBZIP_MMAP := -DUSE_MMAP
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBZIP, \ $(eval $(call SetupNativeCompilation, BUILD_LIBZIP, \
LIBRARY := zip, \ NAME := zip, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
SRC := $(TOPDIR)/src/java.base/share/native/libzip, \ SRC := $(TOPDIR)/src/java.base/share/native/libzip, \
@ -262,8 +263,8 @@ JIMAGELIB_CPPFLAGS := \
-I$(SUPPORT_OUTPUTDIR)/headers/java.base \ -I$(SUPPORT_OUTPUTDIR)/headers/java.base \
# #
$(eval $(call SetupNativeCompilation,BUILD_LIBJIMAGE, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJIMAGE, \
LIBRARY := jimage, \ NAME := jimage, \
TOOLCHAIN := TOOLCHAIN_LINK_CXX, \ TOOLCHAIN := TOOLCHAIN_LINK_CXX, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
@ -358,8 +359,8 @@ ifneq ($(USE_EXTERNAL_LIBZ), true)
) )
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBJLI, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJLI, \
LIBRARY := jli, \ NAME := jli, \
OUTPUT_DIR := $(LIBJLI_OUTPUT_DIR), \ OUTPUT_DIR := $(LIBJLI_OUTPUT_DIR), \
SRC := $(LIBJLI_SRC_DIRS), \ SRC := $(LIBJLI_SRC_DIRS), \
EXCLUDE_FILES := $(LIBJLI_EXCLUDE_FILES), \ EXCLUDE_FILES := $(LIBJLI_EXCLUDE_FILES), \
@ -415,8 +416,9 @@ TARGETS += $(BUILD_LIBJLI)
# with the shared library, so the static library is given a different name. No harm # with the shared library, so the static library is given a different name. No harm
# in doing it for all platform to reduce complexity. # in doing it for all platform to reduce complexity.
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
$(eval $(call SetupNativeCompilation,BUILD_LIBJLI_STATIC, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJLI_STATIC, \
STATIC_LIBRARY := jli_static, \ NAME := jli_static, \
TYPE := STATIC_LIBRARY, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE), \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE), \
SRC := $(LIBJLI_SRC_DIRS), \ SRC := $(LIBJLI_SRC_DIRS), \
EXCLUDE_FILES := $(LIBJLI_EXCLUDE_FILES), \ EXCLUDE_FILES := $(LIBJLI_EXCLUDE_FILES), \
@ -434,8 +436,8 @@ else ifeq ($(OPENJDK_TARGET_OS), macosx)
# On macosx they do partial (incremental) linking of libjli_static.a # On macosx they do partial (incremental) linking of libjli_static.a
# code it here...rather than add support to NativeCompilation # code it here...rather than add support to NativeCompilation
# as this is first time I see it # as this is first time I see it
$(eval $(call SetupNativeCompilation,BUILD_LIBJLI_STATIC, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJLI_STATIC, \
LIBRARY := jli_static, \ NAME := jli_static, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE), \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE), \
SRC := $(LIBJLI_SRC_DIRS), \ SRC := $(LIBJLI_SRC_DIRS), \
EXCLUDE_FILES := $(LIBJLI_EXCLUDE_FILES), \ EXCLUDE_FILES := $(LIBJLI_EXCLUDE_FILES), \
@ -457,8 +459,9 @@ else ifeq ($(OPENJDK_TARGET_OS), macosx)
else ifeq ($(OPENJDK_TARGET_OS), aix) else ifeq ($(OPENJDK_TARGET_OS), aix)
# AIX also requires a static libjli because the compiler doesn't support '-rpath' # AIX also requires a static libjli because the compiler doesn't support '-rpath'
$(eval $(call SetupNativeCompilation,BUILD_LIBJLI_STATIC, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJLI_STATIC, \
STATIC_LIBRARY := jli_static, \ NAME := jli_static, \
TYPE := STATIC_LIBRARY, \
OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE), \ OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE), \
SRC := $(LIBJLI_SRC_DIRS), \ SRC := $(LIBJLI_SRC_DIRS), \
EXCLUDE_FILES := $(LIBJLI_EXCLUDE_FILES), \ EXCLUDE_FILES := $(LIBJLI_EXCLUDE_FILES), \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -49,8 +49,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
LIBINSTRUMENT_CFLAGS += -Dstrcasecmp=stricmp LIBINSTRUMENT_CFLAGS += -Dstrcasecmp=stricmp
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBINSTRUMENT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBINSTRUMENT, \
LIBRARY := instrument, \ NAME := instrument, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBINSTRUMENT_SRC), \ SRC := $(LIBINSTRUMENT_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -44,8 +44,8 @@ ifneq ($(findstring $(OPENJDK_TARGET_OS), solaris linux), )
endif endif
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBMANAGEMENT, \
LIBRARY := management, \ NAME := management, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBMANAGEMENT_SRC), \ SRC := $(LIBMANAGEMENT_SRC), \
OPTIMIZATION := $(LIBMANAGEMENT_OPTIMIZATION), \ OPTIMIZATION := $(LIBMANAGEMENT_OPTIMIZATION), \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -33,8 +33,8 @@ else
LIBPREF_SRC_DIRS := $(TOPDIR)/src/java.prefs/$(OPENJDK_TARGET_OS_TYPE)/native/libprefs LIBPREF_SRC_DIRS := $(TOPDIR)/src/java.prefs/$(OPENJDK_TARGET_OS_TYPE)/native/libprefs
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBPREFS, \ $(eval $(call SetupNativeCompilation, BUILD_LIBPREFS, \
LIBRARY := prefs, \ NAME := prefs, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBPREF_SRC_DIRS), \ SRC := $(LIBPREF_SRC_DIRS), \
OPTIMIZATION := HIGH, \ OPTIMIZATION := HIGH, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -27,8 +27,8 @@ include LibCommon.gmk
################################################################################ ################################################################################
$(eval $(call SetupNativeCompilation,BUILD_LIBRMI, \ $(eval $(call SetupNativeCompilation, BUILD_LIBRMI, \
LIBRARY := rmi, \ NAME := rmi, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(TOPDIR)/src/java.rmi/share/native/librmi, \ SRC := $(TOPDIR)/src/java.rmi/share/native/librmi, \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -32,8 +32,8 @@ ifneq ($(OPENJDK_TARGET_OS), windows)
$(TOPDIR)/src/java.security.jgss/$(OPENJDK_TARGET_OS_TYPE)/native/libj2gss \ $(TOPDIR)/src/java.security.jgss/$(OPENJDK_TARGET_OS_TYPE)/native/libj2gss \
# #
$(eval $(call SetupNativeCompilation,BUILD_LIBJ2GSS, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJ2GSS, \
LIBRARY := j2gss, \ NAME := j2gss, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJ2GSS_SRC), \ SRC := $(LIBJ2GSS_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
@ -74,8 +74,8 @@ ifneq ($(BUILD_CRYPTO), false)
ifneq ($(BUILD_LIBKRB5_NAME), ) ifneq ($(BUILD_LIBKRB5_NAME), )
# libosxkrb5 needs to call deprecated krb5 APIs so that java # libosxkrb5 needs to call deprecated krb5 APIs so that java
# can use the native credentials cache. # can use the native credentials cache.
$(eval $(call SetupNativeCompilation,BUILD_LIBKRB5, \ $(eval $(call SetupNativeCompilation, BUILD_LIBKRB5, \
LIBRARY := $(BUILD_LIBKRB5_NAME), \ NAME := $(BUILD_LIBKRB5_NAME), \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(BUILD_LIBKRB5_SRC), \ SRC := $(BUILD_LIBKRB5_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -33,8 +33,8 @@ LIBJ2PCSC_CPPFLAGS := $(addprefix -I,$(LIBJ2PCSC_SRC)) \
-I$(TOPDIR)/src/java.smartcardio/$(OPENJDK_TARGET_OS_TYPE)/native/libj2pcsc/MUSCLE \ -I$(TOPDIR)/src/java.smartcardio/$(OPENJDK_TARGET_OS_TYPE)/native/libj2pcsc/MUSCLE \
-I$(SUPPORT_OUTPUTDIR)/headers/java.smartcardio -I$(SUPPORT_OUTPUTDIR)/headers/java.smartcardio
$(eval $(call SetupNativeCompilation,BUILD_LIBJ2PCSC, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJ2PCSC, \
LIBRARY := j2pcsc, \ NAME := j2pcsc, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJ2PCSC_SRC), \ SRC := $(LIBJ2PCSC_SRC), \
CFLAGS_unix := -D__sun_jdk, \ CFLAGS_unix := -D__sun_jdk, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -41,8 +41,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
# Parameter 1 Suffix # Parameter 1 Suffix
# Parameter 2 ACCESSBRIDGE_ARCH_ suffix # Parameter 2 ACCESSBRIDGE_ARCH_ suffix
$(call SetupNativeCompilation,BUILD_JAVAACCESSBRIDGE$1, \ $(call SetupNativeCompilation, BUILD_JAVAACCESSBRIDGE$1, \
LIBRARY = javaaccessbridge$1, \ NAME := javaaccessbridge$1, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(JAVA_AB_SRCDIR), \ SRC := $(JAVA_AB_SRCDIR), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
@ -71,8 +71,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
define SetupWinDLL define SetupWinDLL
# Parameter 1 Suffix # Parameter 1 Suffix
# Parameter 2 ACCESSBRIDGE_ARCH_ suffix # Parameter 2 ACCESSBRIDGE_ARCH_ suffix
$(call SetupNativeCompilation,BUILD_WINDOWSACCESSBRIDGE$1, \ $(call SetupNativeCompilation, BUILD_WINDOWSACCESSBRIDGE$1, \
LIBRARY = windowsaccessbridge$1, \ NAME := windowsaccessbridge$1, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(WIN_AB_SRCDIR), \ SRC := $(WIN_AB_SRCDIR), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
@ -99,8 +99,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
define SetupAccessBridgeSysInfo define SetupAccessBridgeSysInfo
$(call SetupNativeCompilation,BUILD_ACCESSBRIDGESYSINFO, \ $(call SetupNativeCompilation, BUILD_ACCESSBRIDGESYSINFO, \
LIBRARY = jabsysinfo, \ NAME := jabsysinfo, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(SYSINFO_SRCDIR), \ SRC := $(SYSINFO_SRCDIR), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -34,8 +34,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
LIBATTACH_CFLAGS := -DPSAPI_VERSION=1 LIBATTACH_CFLAGS := -DPSAPI_VERSION=1
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBATTACH, \ $(eval $(call SetupNativeCompilation, BUILD_LIBATTACH, \
LIBRARY := attach, \ NAME := attach, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(call FindSrcDirsForLib, jdk.attach, attach), \ SRC := $(call FindSrcDirsForLib, jdk.attach, attach), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -30,8 +30,8 @@ include LibCommon.gmk
LIBJ2PKCS11_SRC := $(TOPDIR)/src/jdk.crypto.cryptoki/share/native/libj2pkcs11 \ LIBJ2PKCS11_SRC := $(TOPDIR)/src/jdk.crypto.cryptoki/share/native/libj2pkcs11 \
$(TOPDIR)/src/jdk.crypto.cryptoki/$(OPENJDK_TARGET_OS_TYPE)/native/libj2pkcs11 $(TOPDIR)/src/jdk.crypto.cryptoki/$(OPENJDK_TARGET_OS_TYPE)/native/libj2pkcs11
$(eval $(call SetupNativeCompilation,BUILD_LIBJ2PKCS11, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJ2PKCS11, \
LIBRARY := j2pkcs11, \ NAME := j2pkcs11, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJ2PKCS11_SRC), \ SRC := $(LIBJ2PKCS11_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -43,8 +43,8 @@ ifeq ($(ENABLE_INTREE_EC), true)
ECC_JNI_SOLSPARC_FILTER := -xregs=no%appl ECC_JNI_SOLSPARC_FILTER := -xregs=no%appl
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBSUNEC, \ $(eval $(call SetupNativeCompilation, BUILD_LIBSUNEC, \
LIBRARY := sunec, \ NAME := sunec, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBSUNEC_SRC), \ SRC := $(LIBSUNEC_SRC), \
TOOLCHAIN := TOOLCHAIN_LINK_CXX, \ TOOLCHAIN := TOOLCHAIN_LINK_CXX, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -31,8 +31,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
LIBSUNMSCAPI_SRC := $(TOPDIR)/src/jdk.crypto.mscapi/$(OPENJDK_TARGET_OS_TYPE)/native/libsunmscapi LIBSUNMSCAPI_SRC := $(TOPDIR)/src/jdk.crypto.mscapi/$(OPENJDK_TARGET_OS_TYPE)/native/libsunmscapi
$(eval $(call SetupNativeCompilation,BUILD_LIBSUNMSCAPI, \ $(eval $(call SetupNativeCompilation, BUILD_LIBSUNMSCAPI, \
LIBRARY := sunmscapi, \ NAME := sunmscapi, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBSUNMSCAPI_SRC), \ SRC := $(LIBSUNMSCAPI_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -31,8 +31,8 @@ ifeq ($(OPENJDK_TARGET_OS), solaris)
LIBJ2UCRYPTO_SRC := $(TOPDIR)/src/jdk.crypto.ucrypto/solaris/native/libj2ucrypto LIBJ2UCRYPTO_SRC := $(TOPDIR)/src/jdk.crypto.ucrypto/solaris/native/libj2ucrypto
$(eval $(call SetupNativeCompilation,BUILD_LIBJ2UCRYPTO, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJ2UCRYPTO, \
LIBRARY := j2ucrypto, \ NAME := j2ucrypto, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJ2UCRYPTO_SRC), \ SRC := $(LIBJ2UCRYPTO_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -98,12 +98,12 @@ endif
################################################################################ ################################################################################
$(eval $(call SetupNativeCompilation, BUILD_LIBSA, \ $(eval $(call SetupNativeCompilation, BUILD_LIBSA, \
NAME := $(SA_NAME), \
TOOLCHAIN := $(SA_TOOLCHAIN), \ TOOLCHAIN := $(SA_TOOLCHAIN), \
OPTIMIZATION := NONE, \ OPTIMIZATION := NONE, \
DISABLED_WARNINGS_microsoft := 4267, \ DISABLED_WARNINGS_microsoft := 4267, \
DISABLED_WARNINGS_gcc := sign-compare, \ DISABLED_WARNINGS_gcc := sign-compare, \
DISABLED_WARNINGS_CXX_solstudio := truncwarn unknownpragma, \ DISABLED_WARNINGS_CXX_solstudio := truncwarn unknownpragma, \
LIBRARY := $(SA_NAME), \
OUTPUT_DIR := $(call FindLibDirForModule, $(MODULE)), \ OUTPUT_DIR := $(call FindLibDirForModule, $(MODULE)), \
SRC := $(SA_SRC), \ SRC := $(SA_SRC), \
EXCLUDE_FILES := test.c saproc_audit.cpp $(SA_EXCLUDE_FILES), \ EXCLUDE_FILES := test.c saproc_audit.cpp $(SA_EXCLUDE_FILES), \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -36,8 +36,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
-I$(SUPPORT_OUTPUTDIR)/headers/jdk.internal.le \ -I$(SUPPORT_OUTPUTDIR)/headers/jdk.internal.le \
# #
$(eval $(call SetupNativeCompilation,BUILD_LIBLE, \ $(eval $(call SetupNativeCompilation, BUILD_LIBLE, \
LIBRARY := le, \ NAME := le, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBLE_SRC), \ SRC := $(LIBLE_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -39,8 +39,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
-I$(SUPPORT_OUTPUTDIR)/headers/jdk.jdi \ -I$(SUPPORT_OUTPUTDIR)/headers/jdk.jdi \
# #
$(eval $(call SetupNativeCompilation,BUILD_LIBDT_SHMEM, \ $(eval $(call SetupNativeCompilation, BUILD_LIBDT_SHMEM, \
LIBRARY := dt_shmem, \ NAME := dt_shmem, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBDT_SHMEM_SRC), \ SRC := $(LIBDT_SHMEM_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -36,8 +36,8 @@ LIBDT_SOCKET_CPPFLAGS := \
-I$(TOPDIR)/src/jdk.jdwp.agent/share/native/include \ -I$(TOPDIR)/src/jdk.jdwp.agent/share/native/include \
# #
$(eval $(call SetupNativeCompilation,BUILD_LIBDT_SOCKET, \ $(eval $(call SetupNativeCompilation, BUILD_LIBDT_SOCKET, \
LIBRARY := dt_socket, \ NAME := dt_socket, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBDT_SOCKET_SRC), \ SRC := $(LIBDT_SOCKET_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
@ -73,8 +73,8 @@ LIBJDWP_CPPFLAGS := \
$(addprefix -I, $(LIBJDWP_SRC)) $(addprefix -I, $(LIBJDWP_SRC))
# JDWP_LOGGING causes log messages to be compiled into the library. # JDWP_LOGGING causes log messages to be compiled into the library.
$(eval $(call SetupNativeCompilation,BUILD_LIBJDWP, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJDWP, \
LIBRARY := jdwp, \ NAME := jdwp, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJDWP_SRC), \ SRC := $(LIBJDWP_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -33,8 +33,8 @@ LIBMANAGEMENT_AGENT_CFLAGS := $(addprefix -I,$(LIBMANAGEMENT_AGENT_SRC)) \
$(LIBJAVA_HEADER_FLAGS) \ $(LIBJAVA_HEADER_FLAGS) \
# #
$(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT_AGENT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBMANAGEMENT_AGENT, \
LIBRARY := management_agent, \ NAME := management_agent, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBMANAGEMENT_AGENT_SRC), \ SRC := $(LIBMANAGEMENT_AGENT_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -53,8 +53,8 @@ ifneq ($(findstring $(OPENJDK_TARGET_OS), solaris linux), )
endif endif
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT_EXT, \ $(eval $(call SetupNativeCompilation, BUILD_LIBMANAGEMENT_EXT, \
LIBRARY := management_ext, \ NAME := management_ext, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBMANAGEMENT_EXT_SRC), \ SRC := $(LIBMANAGEMENT_EXT_SRC), \
LANG := C, \ LANG := C, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -30,7 +30,7 @@ include LibCommon.gmk
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
$(eval $(call SetupNativeCompilation, BUILD_LIBEXTNET, \ $(eval $(call SetupNativeCompilation, BUILD_LIBEXTNET, \
LIBRARY := extnet, \ NAME := extnet, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(TOPDIR)/src/jdk.net/solaris/native/libextnet, \ SRC := $(TOPDIR)/src/jdk.net/solaris/native/libextnet, \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \
@ -51,7 +51,7 @@ endif
ifeq ($(OPENJDK_TARGET_OS), linux) ifeq ($(OPENJDK_TARGET_OS), linux)
$(eval $(call SetupNativeCompilation, BUILD_LIBEXTNET, \ $(eval $(call SetupNativeCompilation, BUILD_LIBEXTNET, \
LIBRARY := extnet, \ NAME := extnet, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(TOPDIR)/src/jdk.net/linux/native/libextnet, \ SRC := $(TOPDIR)/src/jdk.net/linux/native/libextnet, \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -27,8 +27,8 @@ include LibCommon.gmk
################################################################################ ################################################################################
$(eval $(call SetupNativeCompilation,BUILD_LIBUNPACK, \ $(eval $(call SetupNativeCompilation, BUILD_LIBUNPACK, \
LIBRARY := unpack, \ NAME := unpack, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(TOPDIR)/src/jdk.pack/share/native/libunpack \ SRC := $(TOPDIR)/src/jdk.pack/share/native/libunpack \
$(TOPDIR)/src/jdk.pack/share/native/common-unpack, \ $(TOPDIR)/src/jdk.pack/share/native/common-unpack, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -30,8 +30,8 @@ include LibCommon.gmk
ifeq ($(OPENJDK_TARGET_OS_TYPE), unix) ifeq ($(OPENJDK_TARGET_OS_TYPE), unix)
ifeq (, $(filter $(OPENJDK_TARGET_OS), macosx aix)) ifeq (, $(filter $(OPENJDK_TARGET_OS), macosx aix))
$(eval $(call SetupNativeCompilation,BUILD_LIBSCTP, \ $(eval $(call SetupNativeCompilation, BUILD_LIBSCTP, \
LIBRARY := sctp, \ NAME := sctp, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(TOPDIR)/src/jdk.sctp/$(OPENJDK_TARGET_OS_TYPE)/native/libsctp, \ SRC := $(TOPDIR)/src/jdk.sctp/$(OPENJDK_TARGET_OS_TYPE)/native/libsctp, \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -38,8 +38,8 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
LIBJAAS_NAME := jaas_nt LIBJAAS_NAME := jaas_nt
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBJAAS, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJAAS, \
LIBRARY := $(LIBJAAS_NAME), \ NAME := $(LIBJAAS_NAME), \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(call FindSrcDirsForLib, jdk.security.auth, jaas), \ SRC := $(call FindSrcDirsForLib, jdk.security.auth, jaas), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -34,8 +34,8 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
-I$(SUPPORT_OUTPUTDIR)/headers/java.desktop \ -I$(SUPPORT_OUTPUTDIR)/headers/java.desktop \
# #
$(eval $(call SetupNativeCompilation,BUILD_LIBOSX, \ $(eval $(call SetupNativeCompilation, BUILD_LIBOSX, \
LIBRARY := osx, \ NAME := osx, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBOSX_DIRS), \ SRC := $(LIBOSX_DIRS), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -25,8 +25,8 @@
LIBNET_SRC_DIRS := $(call FindSrcDirsForLib, java.base, net) LIBNET_SRC_DIRS := $(call FindSrcDirsForLib, java.base, net)
$(eval $(call SetupNativeCompilation,BUILD_LIBNET, \ $(eval $(call SetupNativeCompilation, BUILD_LIBNET, \
LIBRARY := net, \ NAME := net, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBNET_SRC_DIRS), \ SRC := $(LIBNET_SRC_DIRS), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -56,8 +56,8 @@ ifeq ($(OPENJDK_TARGET_OS), aix)
BUILD_LIBNIO_MAPFILE := $(TOPDIR)/make/mapfiles/libnio/mapfile-$(OPENJDK_TARGET_OS) BUILD_LIBNIO_MAPFILE := $(TOPDIR)/make/mapfiles/libnio/mapfile-$(OPENJDK_TARGET_OS)
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBNIO, \ $(eval $(call SetupNativeCompilation, BUILD_LIBNIO, \
LIBRARY := nio, \ NAME := nio, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(BUILD_LIBNIO_SRC), \ SRC := $(BUILD_LIBNIO_SRC), \
EXCLUDE_FILES := $(BUILD_LIBNIO_EXFILES), \ EXCLUDE_FILES := $(BUILD_LIBNIO_EXFILES), \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -29,8 +29,8 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
LIBOSXAPP_SRC := $(TOPDIR)/src/java.desktop/macosx/native/libosxapp LIBOSXAPP_SRC := $(TOPDIR)/src/java.desktop/macosx/native/libosxapp
$(eval $(call SetupNativeCompilation,BUILD_LIBOSXAPP, \ $(eval $(call SetupNativeCompilation, BUILD_LIBOSXAPP, \
LIBRARY := osxapp, \ NAME := osxapp, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBOSXAPP_SRC), \ SRC := $(LIBOSXAPP_SRC), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -26,7 +26,7 @@
include LibCommon.gmk include LibCommon.gmk
ifeq ($(OPENJDK_TARGET_OS), macosx) ifeq ($(OPENJDK_TARGET_OS), macosx)
# JavaNativeFoundation framework not supported in static builds # JavaNativeFoundation framework not supported in static builds
ifneq ($(STATIC_BUILD), true) ifneq ($(STATIC_BUILD), true)
################################################################################ ################################################################################
@ -36,8 +36,8 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
$(LIBJAVA_HEADER_FLAGS) \ $(LIBJAVA_HEADER_FLAGS) \
-I$(SUPPORT_OUTPUTDIR)/headers/java.base \ -I$(SUPPORT_OUTPUTDIR)/headers/java.base \
$(eval $(call SetupNativeCompilation,BUILD_LIBOSXSECURITY, \ $(eval $(call SetupNativeCompilation, BUILD_LIBOSXSECURITY, \
LIBRARY := osxsecurity, \ NAME := osxsecurity, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBOSXSECURITY_DIRS), \ SRC := $(LIBOSXSECURITY_DIRS), \
OPTIMIZATION := LOW, \ OPTIMIZATION := LOW, \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -114,8 +114,8 @@ endif # OPENJDK_TARGET_OS solaris
LIBJSOUND_CFLAGS += -DEXTRA_SOUND_JNI_LIBS='"$(EXTRA_SOUND_JNI_LIBS)"' LIBJSOUND_CFLAGS += -DEXTRA_SOUND_JNI_LIBS='"$(EXTRA_SOUND_JNI_LIBS)"'
$(eval $(call SetupNativeCompilation,BUILD_LIBJSOUND, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJSOUND, \
LIBRARY := jsound, \ NAME := jsound, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJSOUND_SRC_DIRS), \ SRC := $(LIBJSOUND_SRC_DIRS), \
INCLUDE_FILES := $(LIBJSOUND_SRC_FILES), \ INCLUDE_FILES := $(LIBJSOUND_SRC_FILES), \
@ -149,8 +149,8 @@ TARGETS += $(BUILD_LIBJSOUND)
ifneq ($(filter jsoundalsa, $(EXTRA_SOUND_JNI_LIBS)), ) ifneq ($(filter jsoundalsa, $(EXTRA_SOUND_JNI_LIBS)), )
$(eval $(call SetupNativeCompilation,BUILD_LIBJSOUNDALSA, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJSOUNDALSA, \
LIBRARY := jsoundalsa, \ NAME := jsoundalsa, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJSOUND_SRC_DIRS), \ SRC := $(LIBJSOUND_SRC_DIRS), \
INCLUDE_FILES := Utilities.c $(LIBJSOUND_MIDIFILES) $(LIBJSOUND_PORTFILES) \ INCLUDE_FILES := Utilities.c $(LIBJSOUND_MIDIFILES) $(LIBJSOUND_PORTFILES) \
@ -186,8 +186,8 @@ endif
ifneq ($(filter jsoundds, $(EXTRA_SOUND_JNI_LIBS)), ) ifneq ($(filter jsoundds, $(EXTRA_SOUND_JNI_LIBS)), )
$(eval $(call SetupNativeCompilation,BUILD_LIBJSOUNDDS, \ $(eval $(call SetupNativeCompilation, BUILD_LIBJSOUNDDS, \
LIBRARY := jsoundds, \ NAME := jsoundds, \
OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \ OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
SRC := $(LIBJSOUND_SRC_DIRS), \ SRC := $(LIBJSOUND_SRC_DIRS), \
INCLUDE_FILES := Utilities.c $(LIBJSOUND_DAUDIOFILES) \ INCLUDE_FILES := Utilities.c $(LIBJSOUND_DAUDIOFILES) \

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -64,7 +64,7 @@ TARGETS += $(BUILD_FAILURE_HANDLER)
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
$(eval $(call SetupNativeCompilation, BUILD_LIBTIMEOUT_HANDLER, \ $(eval $(call SetupNativeCompilation, BUILD_LIBTIMEOUT_HANDLER, \
LIBRARY := timeoutHandler, \ NAME := timeoutHandler, \
SRC := $(FH_BASEDIR)/src/windows/native/libtimeoutHandler, \ SRC := $(FH_BASEDIR)/src/windows/native/libtimeoutHandler, \
OBJECT_DIR := $(FH_SUPPORT)/libtimeoutHandler, \ OBJECT_DIR := $(FH_SUPPORT)/libtimeoutHandler, \
OUTPUT_DIR := $(FH_SUPPORT), \ OUTPUT_DIR := $(FH_SUPPORT), \

View File

@ -587,6 +587,20 @@ void G1RemSet::refine_card_concurrently(jbyte* card_ptr,
return; return;
} }
// While we are processing RSet buffers during the collection, we
// actually don't want to scan any cards on the collection set,
// since we don't want to update remembered sets with entries that
// point into the collection set, given that live objects from the
// collection set are about to move and such entries will be stale
// very soon. This change also deals with a reliability issue which
// involves scanning a card in the collection set and coming across
// an array that was being chunked and looking malformed. Note,
// however, that if evacuation fails, we have to scan any objects
// that were not moved and create any missing entries.
if (r->in_collection_set()) {
return;
}
// The result from the hot card cache insert call is either: // The result from the hot card cache insert call is either:
// * pointer to the current card // * pointer to the current card
// (implying that the current card is not 'hot'), // (implying that the current card is not 'hot'),
@ -611,7 +625,8 @@ void G1RemSet::refine_card_concurrently(jbyte* card_ptr,
// Check whether the region formerly in the cache should be // Check whether the region formerly in the cache should be
// ignored, as discussed earlier for the original card. The // ignored, as discussed earlier for the original card. The
// region could have been freed while in the cache. // region could have been freed while in the cache. The cset is
// not relevant here, since we're in concurrent phase.
if (!r->is_old_or_humongous()) { if (!r->is_old_or_humongous()) {
return; return;
} }

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -88,6 +88,29 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
} }
} }
/**
* Compares the objects of two AbstractStringBuilder implementations lexicographically.
*
* @since 11
*/
int compareTo(AbstractStringBuilder another) {
if (this == another) {
return 0;
}
byte val1[] = value;
byte val2[] = another.value;
int count1 = this.count;
int count2 = another.count;
if (coder == another.coder) {
return isLatin1() ? StringLatin1.compareTo(val1, val2, count1, count2)
: StringUTF16.compareTo(val1, val2, count1, count2);
}
return isLatin1() ? StringLatin1.compareToUTF16(val1, val2, count1, count2)
: StringUTF16.compareToLatin1(val1, val2, count1, count2);
}
/** /**
* Returns the length (character count). * Returns the length (character count).
* *

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -26,6 +26,7 @@
package java.lang; package java.lang;
import java.util.NoSuchElementException; import java.util.NoSuchElementException;
import java.util.Objects;
import java.util.PrimitiveIterator; import java.util.PrimitiveIterator;
import java.util.Spliterator; import java.util.Spliterator;
import java.util.Spliterators; import java.util.Spliterators;
@ -43,9 +44,9 @@ import java.util.stream.StreamSupport;
* *
* <p> This interface does not refine the general contracts of the {@link * <p> This interface does not refine the general contracts of the {@link
* java.lang.Object#equals(java.lang.Object) equals} and {@link * java.lang.Object#equals(java.lang.Object) equals} and {@link
* java.lang.Object#hashCode() hashCode} methods. The result of comparing two * java.lang.Object#hashCode() hashCode} methods. The result of testing two objects
* objects that implement {@code CharSequence} is therefore, in general, * that implement {@code CharSequence} for equality is therefore, in general, undefined.
* undefined. Each object may be implemented by a different class, and there * Each object may be implemented by a different class, and there
* is no guarantee that each class will be capable of testing its instances * is no guarantee that each class will be capable of testing its instances
* for equality with those of the other. It is therefore inappropriate to use * for equality with those of the other. It is therefore inappropriate to use
* arbitrary {@code CharSequence} instances as elements in a set or as keys in * arbitrary {@code CharSequence} instances as elements in a set or as keys in
@ -237,4 +238,54 @@ public interface CharSequence {
Spliterator.ORDERED, Spliterator.ORDERED,
false); false);
} }
/**
* Compares two {@code CharSequence} instances lexicographically. Returns a
* negative value, zero, or a positive value if the first sequence is lexicographically
* less than, equal to, or greater than the second, respectively.
*
* <p>
* The lexicographical ordering of {@code CharSequence} is defined as follows.
* Consider a {@code CharSequence} <i>cs</i> of length <i>len</i> to be a
* sequence of char values, <i>cs[0]</i> to <i>cs[len-1]</i>. Suppose <i>k</i>
* is the lowest index at which the corresponding char values from each sequence
* differ. The lexicographic ordering of the sequences is determined by a numeric
* comparison of the char values <i>cs1[k]</i> with <i>cs2[k]</i>. If there is
* no such index <i>k</i>, the shorter sequence is considered lexicographically
* less than the other. If the sequences have the same length, the sequences are
* considered lexicographically equal.
*
*
* @param cs1 the first {@code CharSequence}
* @param cs2 the second {@code CharSequence}
*
* @return the value {@code 0} if the two {@code CharSequence} are equal;
* a negative integer if the first {@code CharSequence}
* is lexicographically less than the second; or a
* positive integer if the first {@code CharSequence} is
* lexicographically greater than the second.
*
* @since 11
*/
@SuppressWarnings("unchecked")
public static int compare(CharSequence cs1, CharSequence cs2) {
if (Objects.requireNonNull(cs1) == Objects.requireNonNull(cs2)) {
return 0;
}
if (cs1.getClass() == cs2.getClass() && cs1 instanceof Comparable) {
return ((Comparable<Object>) cs1).compareTo(cs2);
}
for (int i = 0, len = Math.min(cs1.length(), cs2.length()); i < len; i++) {
char a = cs1.charAt(i);
char b = cs2.charAt(i);
if (a != b) {
return a - b;
}
}
return cs1.length() - cs2.length();
}
} }

View File

@ -2963,6 +2963,56 @@ public final class String
*/ */
public native String intern(); public native String intern();
/**
* Returns a string whose value is the concatenation of this
* string repeated {@code count} times.
* <p>
* If this string is empty or count is zero then the empty
* string is returned.
*
* @param count number of times to repeat
*
* @return A string composed of this string repeated
* {@code count} times or the empty string if this
* string is empty or count is zero
*
* @throws IllegalArgumentException if the {@code count} is
* negative.
*
* @since 11
*/
public String repeat(int count) {
if (count < 0) {
throw new IllegalArgumentException("count is negative: " + count);
}
if (count == 1) {
return this;
}
final int len = value.length;
if (len == 0 || count == 0) {
return "";
}
if (len == 1) {
final byte[] single = new byte[count];
Arrays.fill(single, value[0]);
return new String(single, coder);
}
if (Integer.MAX_VALUE / count < len) {
throw new OutOfMemoryError("Repeating " + len + " bytes String " + count +
" times will produce a String exceeding maximum size.");
}
final int limit = len * count;
final byte[] multiple = new byte[limit];
System.arraycopy(value, 0, multiple, 0, len);
int copied = len;
for (int next = copied << 1; next < limit && 0 < next; next = next << 1) {
System.arraycopy(multiple, 0, multiple, copied, copied);
copied = next;
}
System.arraycopy(multiple, 0, multiple, copied, limit - copied);
return new String(multiple, coder);
}
//////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////
/** /**

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 1994, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1994, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -90,6 +90,14 @@ import jdk.internal.HotSpotIntrinsicCandidate;
* this one, as it supports all of the same operations but it is faster, as * this one, as it supports all of the same operations but it is faster, as
* it performs no synchronization. * it performs no synchronization.
* *
* @apiNote
* {@code StringBuffer} implements {@code Comparable} but does not override
* {@link Object#equals equals}. Thus, the natural ordering of {@code StringBuffer}
* is inconsistent with equals. Care should be exercised if {@code StringBuffer}
* objects are used as keys in a {@code SortedMap} or elements in a {@code SortedSet}.
* See {@link Comparable}, {@link java.util.SortedMap SortedMap}, or
* {@link java.util.SortedSet SortedSet} for more information.
*
* @author Arthur van Hoff * @author Arthur van Hoff
* @see java.lang.StringBuilder * @see java.lang.StringBuilder
* @see java.lang.String * @see java.lang.String
@ -97,7 +105,7 @@ import jdk.internal.HotSpotIntrinsicCandidate;
*/ */
public final class StringBuffer public final class StringBuffer
extends AbstractStringBuilder extends AbstractStringBuilder
implements java.io.Serializable, CharSequence implements java.io.Serializable, Comparable<StringBuffer>, CharSequence
{ {
/** /**
@ -162,6 +170,35 @@ import jdk.internal.HotSpotIntrinsicCandidate;
append(seq); append(seq);
} }
/**
* Compares two {@code StringBuffer} instances lexicographically. This method
* follows the same rules for lexicographical comparison as defined in the
* {@linkplain java.lang.CharSequence#compare(java.lang.CharSequence,
* java.lang.CharSequence) CharSequence.compare(this, another)} method.
*
* <p>
* For finer-grained, locale-sensitive String comparison, refer to
* {@link java.text.Collator}.
*
* @implNote
* This method synchronizes on {@code this}, the current object, but not
* {@code StringBuffer another} with which {@code this StringBuffer} is compared.
*
* @param another the {@code StringBuffer} to be compared with
*
* @return the value {@code 0} if this {@code StringBuffer} contains the same
* character sequence as that of the argument {@code StringBuffer}; a negative integer
* if this {@code StringBuffer} is lexicographically less than the
* {@code StringBuffer} argument; or a positive integer if this {@code StringBuffer}
* is lexicographically greater than the {@code StringBuffer} argument.
*
* @since 11
*/
@Override
public synchronized int compareTo(StringBuffer another) {
return super.compareTo(another);
}
@Override @Override
public synchronized int length() { public synchronized int length() {
return count; return count;

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -69,6 +69,14 @@ import jdk.internal.HotSpotIntrinsicCandidate;
* or method in this class will cause a {@link NullPointerException} to be * or method in this class will cause a {@link NullPointerException} to be
* thrown. * thrown.
* *
* @apiNote
* {@code StringBuilder} implements {@code Comparable} but does not override
* {@link Object#equals equals}. Thus, the natural ordering of {@code StringBuilder}
* is inconsistent with equals. Care should be exercised if {@code StringBuilder}
* objects are used as keys in a {@code SortedMap} or elements in a {@code SortedSet}.
* See {@link Comparable}, {@link java.util.SortedMap SortedMap}, or
* {@link java.util.SortedSet SortedSet} for more information.
*
* @author Michael McCloskey * @author Michael McCloskey
* @see java.lang.StringBuffer * @see java.lang.StringBuffer
* @see java.lang.String * @see java.lang.String
@ -76,7 +84,7 @@ import jdk.internal.HotSpotIntrinsicCandidate;
*/ */
public final class StringBuilder public final class StringBuilder
extends AbstractStringBuilder extends AbstractStringBuilder
implements java.io.Serializable, CharSequence implements java.io.Serializable, Comparable<StringBuilder>, CharSequence
{ {
/** use serialVersionUID for interoperability */ /** use serialVersionUID for interoperability */
@ -130,6 +138,31 @@ public final class StringBuilder
append(seq); append(seq);
} }
/**
* Compares two {@code StringBuilder} instances lexicographically. This method
* follows the same rules for lexicographical comparison as defined in the
* {@linkplain java.lang.CharSequence#compare(java.lang.CharSequence,
* java.lang.CharSequence) CharSequence.compare(this, another)} method.
*
* <p>
* For finer-grained, locale-sensitive String comparison, refer to
* {@link java.text.Collator}.
*
* @param another the {@code StringBuilder} to be compared with
*
* @return the value {@code 0} if this {@code StringBuilder} contains the same
* character sequence as that of the argument {@code StringBuilder}; a negative integer
* if this {@code StringBuilder} is lexicographically less than the
* {@code StringBuilder} argument; or a positive integer if this {@code StringBuilder}
* is lexicographically greater than the {@code StringBuilder} argument.
*
* @since 11
*/
@Override
public int compareTo(StringBuilder another) {
return super.compareTo(another);
}
@Override @Override
public StringBuilder append(Object obj) { public StringBuilder append(Object obj) {
return append(String.valueOf(obj)); return append(String.valueOf(obj));

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -103,6 +103,10 @@ final class StringLatin1 {
public static int compareTo(byte[] value, byte[] other) { public static int compareTo(byte[] value, byte[] other) {
int len1 = value.length; int len1 = value.length;
int len2 = other.length; int len2 = other.length;
return compareTo(value, other, len1, len2);
}
public static int compareTo(byte[] value, byte[] other, int len1, int len2) {
int lim = Math.min(len1, len2); int lim = Math.min(len1, len2);
for (int k = 0; k < lim; k++) { for (int k = 0; k < lim; k++) {
if (value[k] != other[k]) { if (value[k] != other[k]) {
@ -116,6 +120,20 @@ final class StringLatin1 {
public static int compareToUTF16(byte[] value, byte[] other) { public static int compareToUTF16(byte[] value, byte[] other) {
int len1 = length(value); int len1 = length(value);
int len2 = StringUTF16.length(other); int len2 = StringUTF16.length(other);
return compareToUTF16Values(value, other, len1, len2);
}
/*
* Checks the boundary and then compares the byte arrays.
*/
public static int compareToUTF16(byte[] value, byte[] other, int len1, int len2) {
checkOffset(len1, length(value));
checkOffset(len2, StringUTF16.length(other));
return compareToUTF16Values(value, other, len1, len2);
}
private static int compareToUTF16Values(byte[] value, byte[] other, int len1, int len2) {
int lim = Math.min(len1, len2); int lim = Math.min(len1, len2);
for (int k = 0; k < lim; k++) { for (int k = 0; k < lim; k++) {
char c1 = getChar(value, k); char c1 = getChar(value, k);

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -273,6 +273,20 @@ final class StringUTF16 {
public static int compareTo(byte[] value, byte[] other) { public static int compareTo(byte[] value, byte[] other) {
int len1 = length(value); int len1 = length(value);
int len2 = length(other); int len2 = length(other);
return compareValues(value, other, len1, len2);
}
/*
* Checks the boundary and then compares the byte arrays.
*/
public static int compareTo(byte[] value, byte[] other, int len1, int len2) {
checkOffset(len1, value);
checkOffset(len2, other);
return compareValues(value, other, len1, len2);
}
private static int compareValues(byte[] value, byte[] other, int len1, int len2) {
int lim = Math.min(len1, len2); int lim = Math.min(len1, len2);
for (int k = 0; k < lim; k++) { for (int k = 0; k < lim; k++) {
char c1 = getChar(value, k); char c1 = getChar(value, k);
@ -289,6 +303,10 @@ final class StringUTF16 {
return -StringLatin1.compareToUTF16(other, value); return -StringLatin1.compareToUTF16(other, value);
} }
public static int compareToLatin1(byte[] value, byte[] other, int len1, int len2) {
return -StringLatin1.compareToUTF16(other, value, len2, len1);
}
public static int compareToCI(byte[] value, byte[] other) { public static int compareToCI(byte[] value, byte[] other) {
int len1 = length(value); int len1 = length(value);
int len2 = length(other); int len2 = length(other);

View File

@ -1007,22 +1007,22 @@ class Thread implements Runnable {
* @spec JSR-51 * @spec JSR-51
*/ */
public void interrupt() { public void interrupt() {
Thread me = Thread.currentThread(); if (this != Thread.currentThread()) {
if (this != me)
checkAccess(); checkAccess();
// set interrupt status // thread may be blocked in an I/O operation
interrupt0();
// thread may be blocked in an I/O operation
if (this != me && blocker != null) {
synchronized (blockerLock) { synchronized (blockerLock) {
Interruptible b = blocker; Interruptible b = blocker;
if (b != null) { if (b != null) {
interrupt0(); // set interrupt status
b.interrupt(this); b.interrupt(this);
return;
} }
} }
} }
// set interrupt status
interrupt0();
} }
/** /**

View File

@ -93,6 +93,10 @@ class InvokerBytecodeGenerator {
private ClassWriter cw; private ClassWriter cw;
private MethodVisitor mv; private MethodVisitor mv;
/** Single element internal class name lookup cache. */
private Class<?> lastClass;
private String lastInternalName;
private static final MemberName.Factory MEMBERNAME_FACTORY = MemberName.getFactory(); private static final MemberName.Factory MEMBERNAME_FACTORY = MemberName.getFactory();
private static final Class<?> HOST_CLASS = LambdaForm.class; private static final Class<?> HOST_CLASS = LambdaForm.class;
@ -602,13 +606,18 @@ class InvokerBytecodeGenerator {
mv.visitInsn(opcode); mv.visitInsn(opcode);
} }
private static String getInternalName(Class<?> c) { private String getInternalName(Class<?> c) {
if (c == Object.class) return OBJ; if (c == Object.class) return OBJ;
else if (c == Object[].class) return OBJARY; else if (c == Object[].class) return OBJARY;
else if (c == Class.class) return CLS; else if (c == Class.class) return CLS;
else if (c == MethodHandle.class) return MH; else if (c == MethodHandle.class) return MH;
assert(VerifyAccess.isTypeVisible(c, Object.class)) : c.getName(); assert(VerifyAccess.isTypeVisible(c, Object.class)) : c.getName();
return c.getName().replace('.', '/');
if (c == lastClass) {
return lastInternalName;
}
lastClass = c;
return lastInternalName = c.getName().replace('.', '/');
} }
private static MemberName resolveFrom(String name, MethodType type, Class<?> holder) { private static MemberName resolveFrom(String name, MethodType type, Class<?> holder) {

View File

@ -105,7 +105,8 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* {@code checkCreateClassLoader} method doesn't allow * {@code checkCreateClassLoader} method doesn't allow
* creation of a class loader. * creation of a class loader.
* @exception NullPointerException if {@code urls} is {@code null}. * @exception NullPointerException if {@code urls} or any of its
* elements is {@code null}.
* @see SecurityManager#checkCreateClassLoader * @see SecurityManager#checkCreateClassLoader
*/ */
public URLClassLoader(URL[] urls, ClassLoader parent) { public URLClassLoader(URL[] urls, ClassLoader parent) {
@ -149,7 +150,8 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* {@code checkCreateClassLoader} method doesn't allow * {@code checkCreateClassLoader} method doesn't allow
* creation of a class loader. * creation of a class loader.
* @exception NullPointerException if {@code urls} is {@code null}. * @exception NullPointerException if {@code urls} or any of its
* elements is {@code null}.
* @see SecurityManager#checkCreateClassLoader * @see SecurityManager#checkCreateClassLoader
*/ */
public URLClassLoader(URL[] urls) { public URLClassLoader(URL[] urls) {
@ -192,7 +194,8 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* {@code checkCreateClassLoader} method doesn't allow * {@code checkCreateClassLoader} method doesn't allow
* creation of a class loader. * creation of a class loader.
* @exception NullPointerException if {@code urls} is {@code null}. * @exception NullPointerException if {@code urls} or any of its
* elements is {@code null}.
* @see SecurityManager#checkCreateClassLoader * @see SecurityManager#checkCreateClassLoader
*/ */
public URLClassLoader(URL[] urls, ClassLoader parent, public URLClassLoader(URL[] urls, ClassLoader parent,
@ -221,7 +224,8 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* @param parent the parent class loader for delegation * @param parent the parent class loader for delegation
* *
* @throws IllegalArgumentException if the given name is empty. * @throws IllegalArgumentException if the given name is empty.
* @throws NullPointerException if {@code urls} is {@code null}. * @throws NullPointerException if {@code urls} or any of its
* elements is {@code null}.
* *
* @throws SecurityException if a security manager exists and its * @throws SecurityException if a security manager exists and its
* {@link SecurityManager#checkCreateClassLoader()} method doesn't * {@link SecurityManager#checkCreateClassLoader()} method doesn't
@ -256,7 +260,8 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* @param factory the URLStreamHandlerFactory to use when creating URLs * @param factory the URLStreamHandlerFactory to use when creating URLs
* *
* @throws IllegalArgumentException if the given name is empty. * @throws IllegalArgumentException if the given name is empty.
* @throws NullPointerException if {@code urls} is {@code null}. * @throws NullPointerException if {@code urls} or any of its
* elements is {@code null}.
* *
* @throws SecurityException if a security manager exists and its * @throws SecurityException if a security manager exists and its
* {@code checkCreateClassLoader} method doesn't allow * {@code checkCreateClassLoader} method doesn't allow
@ -805,7 +810,8 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* *
* @param urls the URLs to search for classes and resources * @param urls the URLs to search for classes and resources
* @param parent the parent class loader for delegation * @param parent the parent class loader for delegation
* @exception NullPointerException if {@code urls} is {@code null}. * @exception NullPointerException if {@code urls} or any of its
* elements is {@code null}.
* @return the resulting class loader * @return the resulting class loader
*/ */
public static URLClassLoader newInstance(final URL[] urls, public static URLClassLoader newInstance(final URL[] urls,
@ -831,7 +837,8 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* loading the class. * loading the class.
* *
* @param urls the URLs to search for classes and resources * @param urls the URLs to search for classes and resources
* @exception NullPointerException if {@code urls} is {@code null}. * @exception NullPointerException if {@code urls} or any of its
* elements is {@code null}.
* @return the resulting class loader * @return the resulting class loader
*/ */
public static URLClassLoader newInstance(final URL[] urls) { public static URLClassLoader newInstance(final URL[] urls) {

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2001, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -27,9 +27,8 @@ package java.nio.charset;
import java.lang.ref.WeakReference; import java.lang.ref.WeakReference;
import java.nio.*; import java.nio.*;
import java.util.concurrent.ConcurrentHashMap;
import java.util.Map; import java.util.Map;
import java.util.HashMap;
/** /**
* A description of the result state of a coder. * A description of the result state of a coder.
@ -197,14 +196,12 @@ public class CoderResult {
protected abstract CoderResult create(int len); protected abstract CoderResult create(int len);
private synchronized CoderResult get(int len) { private CoderResult get(int len) {
if (len <= 0)
throw new IllegalArgumentException("Non-positive length");
Integer k = len; Integer k = len;
WeakReference<CoderResult> w; WeakReference<CoderResult> w;
CoderResult e = null; CoderResult e = null;
if (cache == null) { if (cache == null) {
cache = new HashMap<>(); cache = new ConcurrentHashMap<>();
} else if ((w = cache.get(k)) != null) { } else if ((w = cache.get(k)) != null) {
e = w.get(); e = w.get();
} }
@ -214,15 +211,21 @@ public class CoderResult {
} }
return e; return e;
} }
} }
private static Cache malformedCache private static final Cache malformedCache
= new Cache() { = new Cache() {
public CoderResult create(int len) { public CoderResult create(int len) {
return new CoderResult(CR_MALFORMED, len); return new CoderResult(CR_MALFORMED, len);
}}; }};
private static final CoderResult[] malformed4 = new CoderResult[] {
new CoderResult(CR_MALFORMED, 1),
new CoderResult(CR_MALFORMED, 2),
new CoderResult(CR_MALFORMED, 3),
new CoderResult(CR_MALFORMED, 4),
};
/** /**
* Static factory method that returns the unique object describing a * Static factory method that returns the unique object describing a
* malformed-input error of the given length. * malformed-input error of the given length.
@ -233,15 +236,26 @@ public class CoderResult {
* @return The requested coder-result object * @return The requested coder-result object
*/ */
public static CoderResult malformedForLength(int length) { public static CoderResult malformedForLength(int length) {
if (length <= 0)
throw new IllegalArgumentException("Non-positive length");
if (length <= 4)
return malformed4[length - 1];
return malformedCache.get(length); return malformedCache.get(length);
} }
private static Cache unmappableCache private static final Cache unmappableCache
= new Cache() { = new Cache() {
public CoderResult create(int len) { public CoderResult create(int len) {
return new CoderResult(CR_UNMAPPABLE, len); return new CoderResult(CR_UNMAPPABLE, len);
}}; }};
private static final CoderResult[] unmappable4 = new CoderResult[] {
new CoderResult(CR_UNMAPPABLE, 1),
new CoderResult(CR_UNMAPPABLE, 2),
new CoderResult(CR_UNMAPPABLE, 3),
new CoderResult(CR_UNMAPPABLE, 4),
};
/** /**
* Static factory method that returns the unique result object describing * Static factory method that returns the unique result object describing
* an unmappable-character error of the given length. * an unmappable-character error of the given length.
@ -252,6 +266,10 @@ public class CoderResult {
* @return The requested coder-result object * @return The requested coder-result object
*/ */
public static CoderResult unmappableForLength(int length) { public static CoderResult unmappableForLength(int length) {
if (length <= 0)
throw new IllegalArgumentException("Non-positive length");
if (length <= 4)
return unmappable4[length - 1];
return unmappableCache.get(length); return unmappableCache.get(length);
} }

View File

@ -40,7 +40,9 @@ import sun.util.logging.PlatformLogger;
* The Attributes class maps Manifest attribute names to associated string * The Attributes class maps Manifest attribute names to associated string
* values. Valid attribute names are case-insensitive, are restricted to * values. Valid attribute names are case-insensitive, are restricted to
* the ASCII characters in the set [0-9a-zA-Z_-], and cannot exceed 70 * the ASCII characters in the set [0-9a-zA-Z_-], and cannot exceed 70
* characters in length. Attribute values can contain any characters and * characters in length. There must be a colon and a SPACE after the name;
* the combined length will not exceed 72 characters.
* Attribute values can contain any characters and
* will be UTF8-encoded when written to the output stream. See the * will be UTF8-encoded when written to the output stream. See the
* <a href="{@docRoot}/../specs/jar/jar.html">JAR File Specification</a> * <a href="{@docRoot}/../specs/jar/jar.html">JAR File Specification</a>
* for more information about valid attribute names and values. * for more information about valid attribute names and values.
@ -310,8 +312,8 @@ public class Attributes implements Map<Object,Object>, Cloneable {
} }
buffer.append(value); buffer.append(value);
buffer.append("\r\n");
Manifest.make72Safe(buffer); Manifest.make72Safe(buffer);
buffer.append("\r\n");
os.writeBytes(buffer.toString()); os.writeBytes(buffer.toString());
} }
os.writeBytes("\r\n"); os.writeBytes("\r\n");
@ -355,8 +357,8 @@ public class Attributes implements Map<Object,Object>, Cloneable {
} }
buffer.append(value); buffer.append(value);
buffer.append("\r\n");
Manifest.make72Safe(buffer); Manifest.make72Safe(buffer);
buffer.append("\r\n");
out.writeBytes(buffer.toString()); out.writeBytes(buffer.toString());
} }
} }

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -157,8 +157,8 @@ public class Manifest implements Cloneable {
value = new String(vb, 0, 0, vb.length); value = new String(vb, 0, 0, vb.length);
} }
buffer.append(value); buffer.append(value);
buffer.append("\r\n");
make72Safe(buffer); make72Safe(buffer);
buffer.append("\r\n");
dos.writeBytes(buffer.toString()); dos.writeBytes(buffer.toString());
e.getValue().write(dos); e.getValue().write(dos);
} }
@ -170,13 +170,11 @@ public class Manifest implements Cloneable {
*/ */
static void make72Safe(StringBuffer line) { static void make72Safe(StringBuffer line) {
int length = line.length(); int length = line.length();
if (length > 72) { int index = 72;
int index = 70; while (index < length) {
while (index < length - 2) { line.insert(index, "\r\n ");
line.insert(index, "\r\n "); index += 74; // + line width + line break ("\r\n")
index += 72; length += 3; // + line break ("\r\n") and space
length += 3;
}
} }
return; return;
} }

View File

@ -107,6 +107,11 @@ public class BytecodeDescriptor {
} }
public static String unparse(Class<?> type) { public static String unparse(Class<?> type) {
if (type == Object.class) {
return "Ljava/lang/Object;";
} else if (type == int.class) {
return "I";
}
StringBuilder sb = new StringBuilder(); StringBuilder sb = new StringBuilder();
unparseSig(type, sb); unparseSig(type, sb);
return sb.toString(); return sb.toString();
@ -148,6 +153,8 @@ public class BytecodeDescriptor {
char c = Wrapper.forBasicType(t).basicTypeChar(); char c = Wrapper.forBasicType(t).basicTypeChar();
if (c != 'L') { if (c != 'L') {
sb.append(c); sb.append(c);
} else if (t == Object.class) {
sb.append("Ljava/lang/Object;");
} else { } else {
boolean lsemi = (!t.isArray()); boolean lsemi = (!t.isArray());
if (lsemi) sb.append('L'); if (lsemi) sb.append('L');

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -52,6 +52,8 @@ class _AppMenuBarHandler {
return instance; return instance;
} }
private static ScreenMenuBar defaultMenuBar;
// callback from the native delegate -init function // callback from the native delegate -init function
private static void initMenuStates(final boolean aboutMenuItemVisible, private static void initMenuStates(final boolean aboutMenuItemVisible,
final boolean aboutMenuItemEnabled, final boolean aboutMenuItemEnabled,
@ -76,6 +78,9 @@ class _AppMenuBarHandler {
void setDefaultMenuBar(final JMenuBar menuBar) { void setDefaultMenuBar(final JMenuBar menuBar) {
installDefaultMenuBar(menuBar); installDefaultMenuBar(menuBar);
if (menuBar == null) {
return;
}
// scan the current frames, and see if any are foreground // scan the current frames, and see if any are foreground
final Frame[] frames = Frame.getFrames(); final Frame[] frames = Frame.getFrames();
@ -100,8 +105,13 @@ class _AppMenuBarHandler {
} }
static void installDefaultMenuBar(final JMenuBar menuBar) { static void installDefaultMenuBar(final JMenuBar menuBar) {
if (menuBar == null) { if (menuBar == null) {
// intentionally clearing the default menu // intentionally clearing the default menu
if (defaultMenuBar != null) {
defaultMenuBar.removeNotify();
defaultMenuBar = null;
}
nativeSetDefaultMenuBar(0); nativeSetDefaultMenuBar(0);
return; return;
} }
@ -124,7 +134,14 @@ class _AppMenuBarHandler {
throw new IllegalStateException("Application.setDefaultMenuBar() only works if apple.laf.useScreenMenuBar=true"); throw new IllegalStateException("Application.setDefaultMenuBar() only works if apple.laf.useScreenMenuBar=true");
} }
screenMenuBar.addNotify(); if (screenMenuBar != defaultMenuBar) {
if (defaultMenuBar != null) {
defaultMenuBar.removeNotify();
}
defaultMenuBar = screenMenuBar;
screenMenuBar.addNotify();
}
final Object peer = AWTAccessor.getMenuComponentAccessor().getPeer(screenMenuBar); final Object peer = AWTAccessor.getMenuComponentAccessor().getPeer(screenMenuBar);
if (!(peer instanceof CMenuBar)) { if (!(peer instanceof CMenuBar)) {
// such a thing should not be possible // such a thing should not be possible

View File

@ -2359,6 +2359,7 @@ public class JList<E> extends JComponent implements Scrollable, Accessible
/** /**
* Selects the specified object from the list. * Selects the specified object from the list.
* If the object passed is {@code null}, the selection is cleared.
* *
* @param anObject the object to select * @param anObject the object to select
* @param shouldScroll {@code true} if the list should scroll to display * @param shouldScroll {@code true} if the list should scroll to display
@ -2366,7 +2367,7 @@ public class JList<E> extends JComponent implements Scrollable, Accessible
*/ */
public void setSelectedValue(Object anObject,boolean shouldScroll) { public void setSelectedValue(Object anObject,boolean shouldScroll) {
if(anObject == null) if(anObject == null)
setSelectedIndex(-1); clearSelection();
else if(!anObject.equals(getSelectedValue())) { else if(!anObject.equals(getSelectedValue())) {
int i,c; int i,c;
ListModel<E> dm = getModel(); ListModel<E> dm = getModel();

View File

@ -110,6 +110,8 @@ public class RepaintManager
private Dimension doubleBufferMaxSize; private Dimension doubleBufferMaxSize;
private boolean isCustomMaxBufferSizeSet = false;
// Support for both the standard and volatile offscreen buffers exists to // Support for both the standard and volatile offscreen buffers exists to
// provide backwards compatibility for the [rare] programs which may be // provide backwards compatibility for the [rare] programs which may be
// calling getOffScreenBuffer() and not expecting to get a VolatileImage. // calling getOffScreenBuffer() and not expecting to get a VolatileImage.
@ -335,7 +337,13 @@ public class RepaintManager
} }
private void displayChanged() { private void displayChanged() {
clearImages(); if (isCustomMaxBufferSizeSet) {
clearImages();
} else {
// Reset buffer maximum size to get valid size from updated graphics
// environment in getDoubleBufferMaximumSize()
setDoubleBufferMaximumSize(null);
}
} }
/** /**
@ -1156,8 +1164,10 @@ public class RepaintManager
public void setDoubleBufferMaximumSize(Dimension d) { public void setDoubleBufferMaximumSize(Dimension d) {
doubleBufferMaxSize = d; doubleBufferMaxSize = d;
if (doubleBufferMaxSize == null) { if (doubleBufferMaxSize == null) {
isCustomMaxBufferSizeSet = false;
clearImages(); clearImages();
} else { } else {
isCustomMaxBufferSizeSet = true;
clearImages(d.width, d.height); clearImages(d.width, d.height);
} }
} }

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -149,7 +149,7 @@ public class XRBackendNative implements XRBackend {
XRColor c = new XRColor(); XRColor c = new XRColor();
for (int i = 0; i < pixels.length; i++) { for (int i = 0; i < pixels.length; i++) {
c.setColorValues(pixels[i], true); c.setColorValues(pixels[i]);
renderColors[i * 4 + 0] = (short) c.alpha; renderColors[i * 4 + 0] = (short) c.alpha;
renderColors[i * 4 + 1] = (short) c.red; renderColors[i * 4 + 1] = (short) c.red;
renderColors[i * 4 + 2] = (short) c.green; renderColors[i * 4 + 2] = (short) c.green;

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -73,7 +73,7 @@ public class XRColor {
XRColor c = new XRColor(); XRColor c = new XRColor();
for (int i = 0; i < pixels.length; i++) { for (int i = 0; i < pixels.length; i++) {
c.setColorValues(pixels[i], true); c.setColorValues(pixels[i]);
colorValues[i * 4 + 0] = c.alpha; colorValues[i * 4 + 0] = c.alpha;
colorValues[i * 4 + 1] = c.red; colorValues[i * 4 + 1] = c.red;
colorValues[i * 4 + 2] = c.green; colorValues[i * 4 + 2] = c.green;
@ -83,7 +83,7 @@ public class XRColor {
return colorValues; return colorValues;
} }
public void setColorValues(int pixel, boolean pre) { public void setColorValues(int pixel) {
long pix = XRUtils.intToULong(pixel); long pix = XRUtils.intToULong(pixel);
alpha = (int) (((pix & 0xFF000000) >> 16) + 255); alpha = (int) (((pix & 0xFF000000) >> 16) + 255);
red = (int) (((pix & 0x00FF0000) >> 8) + 255); red = (int) (((pix & 0x00FF0000) >> 8) + 255);
@ -93,13 +93,6 @@ public class XRColor {
if (alpha == 255) { if (alpha == 255) {
alpha = 0; alpha = 0;
} }
if (!pre) {
double alphaMult = XRUtils.XFixedToDouble(alpha);
this.red = (int) (red * alphaMult);
this.green = (int) (green * alphaMult);
this.blue = (int) (blue * alphaMult);
}
} }
public static int byteToXRColorValue(int byteValue) { public static int byteToXRColorValue(int byteValue) {

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -131,7 +131,7 @@ public class XRCompositeManager {
} }
public void setForeground(int pixel) { public void setForeground(int pixel) {
solidColor.setColorValues(pixel, true); solidColor.setColorValues(pixel);
} }
public void setGradientPaint(XRSurfaceData gradient) { public void setGradientPaint(XRSurfaceData gradient) {

View File

@ -47,7 +47,7 @@ public class XRSolidSrcPict {
public XRSurfaceData prepareSrcPict(int pixelVal) { public XRSurfaceData prepareSrcPict(int pixelVal) {
if(pixelVal != curPixVal) { if(pixelVal != curPixVal) {
xrCol.setColorValues(pixelVal, true); xrCol.setColorValues(pixelVal);
con.renderRectangle(srcPict.picture, XRUtils.PictOpSrc, xrCol, 0, 0, 1, 1); con.renderRectangle(srcPict.picture, XRUtils.PictOpSrc, xrCol, 0, 0, 1, 1);
this.curPixVal = pixelVal; this.curPixVal = pixelVal;
} }

View File

@ -394,77 +394,50 @@ int32_t format ;
XRectangle bbox; /* bounding box of grabbed area */ XRectangle bbox; /* bounding box of grabbed area */
list_ptr regions;/* list of regions to read from */ list_ptr regions;/* list of regions to read from */
{ {
image_region_type *reg; XImage *ximage ;
int32_t dst_x, dst_y; /* where in pixmap to write (UL) */ image_region_type* reg;
int32_t diff; int32_t rect;
XImage *reg_image,*ximage ;
int32_t srcRect_x,srcRect_y,srcRect_width,srcRect_height ;
int32_t rem ;
int32_t bytes_per_line;
int32_t bitmap_unit;
bitmap_unit = sizeof (long);
if (format == ZPixmap)
bytes_per_line = width*depth/8;
else
bytes_per_line = width/8;
/* Find out how many more bytes are required for padding so that
** bytes per scan line will be multiples of bitmap_unit bits */
if (format == ZPixmap) {
rem = (bytes_per_line*8)%bitmap_unit;
if (rem)
bytes_per_line += (rem/8 + 1);
}
ximage = XCreateImage(disp,fakeVis,(uint32_t) depth,format,0,NULL, ximage = XCreateImage(disp,fakeVis,(uint32_t) depth,format,0,NULL,
(uint32_t)width,(uint32_t)height,8,0); (uint32_t)width,(uint32_t)height,8,0);
bytes_per_line = ximage->bytes_per_line; ximage->data = calloc(ximage->bytes_per_line*height*((format==ZPixmap)? 1 : depth), sizeof(char));
if (format == ZPixmap)
ximage->data = malloc(height*bytes_per_line);
else
ximage->data = malloc(height*bytes_per_line*depth);
ximage->bits_per_pixel = depth; /** Valid only if format is ZPixmap ***/ ximage->bits_per_pixel = depth; /** Valid only if format is ZPixmap ***/
for (reg = (image_region_type *) first_in_list( regions); reg; for (reg = (image_region_type *) first_in_list( regions); reg;
reg = (image_region_type *) next_in_list( regions)) reg = (image_region_type *) next_in_list( regions))
{ {
int32_t rect; struct my_XRegion *vis_reg = (struct my_XRegion *)(reg->visible_region);
struct my_XRegion *vis_reg; for (rect = 0; rect < vis_reg->numRects; rect++)
vis_reg = (struct my_XRegion *)(reg->visible_region);
for (rect = 0;
rect < vis_reg->numRects;
rect++)
{ {
/** ------------------------------------------------------------------------ /** ------------------------------------------------------------------------
Intersect bbox with visible part of region giving src rect & output Intersect bbox with visible part of region giving src rect & output
location. Width is the min right side minus the max left side. location. Width is the min right side minus the max left side.
Similar for height. Offset src rect so x,y are relative to Similar for height. Offset src rect so x,y are relative to
origin of win, not the root-relative visible rect of win. origin of win, not the root-relative visible rect of win.
------------------------------------------------------------------------ **/ ------------------------------------------------------------------------ **/
srcRect_width = MIN( vis_reg->rects[rect].x2, bbox.width + bbox.x) int32_t srcRect_width = MIN( vis_reg->rects[rect].x2, bbox.width + bbox.x)
- MAX( vis_reg->rects[rect].x1, bbox.x); - MAX( vis_reg->rects[rect].x1, bbox.x);
srcRect_height = MIN( vis_reg->rects[rect].y2, bbox.height + bbox.y) int32_t srcRect_height = MIN( vis_reg->rects[rect].y2, bbox.height + bbox.y)
- MAX( vis_reg->rects[rect].y1, bbox.y); - MAX( vis_reg->rects[rect].y1, bbox.y);
diff = bbox.x - vis_reg->rects[rect].x1; int32_t diff = bbox.x - vis_reg->rects[rect].x1;
srcRect_x = MAX( 0, diff) + (vis_reg->rects[rect].x1 - reg->x_rootrel - reg->border); int32_t srcRect_x = MAX( 0, diff) + (vis_reg->rects[rect].x1 - reg->x_rootrel - reg->border);
dst_x = MAX( 0, -diff) ; int32_t dst_x = MAX( 0, -diff) ;
diff = bbox.y - vis_reg->rects[rect].y1;
srcRect_y = MAX( 0, diff) + (vis_reg->rects[rect].y1 - reg->y_rootrel - reg->border); diff = bbox.y - vis_reg->rects[rect].y1;
dst_y = MAX( 0, -diff) ; int32_t srcRect_y = MAX( 0, diff) + (vis_reg->rects[rect].y1 - reg->y_rootrel - reg->border);
reg_image = XGetImage(disp,reg->win,srcRect_x,srcRect_y, int32_t dst_y = MAX( 0, -diff) ;
(uint32_t) srcRect_width, (uint32_t) srcRect_height,AllPlanes,format) ; XImage* reg_image = XGetImage(disp,reg->win,srcRect_x,srcRect_y,
TransferImage(disp,reg_image,srcRect_width, (uint32_t) srcRect_width, (uint32_t) srcRect_height,AllPlanes,format) ;
srcRect_height,reg,ximage,dst_x,dst_y) ;
XDestroyImage(reg_image); if (reg_image) {
} TransferImage(disp,reg_image,srcRect_width,
srcRect_height,reg,ximage,dst_x,dst_y) ;
XDestroyImage(reg_image);
}
}
} }
return ximage ; return ximage ;
} }

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -116,11 +116,10 @@ public class MonitorInfo extends LockInfo {
* <tbody style="text-align:left"> * <tbody style="text-align:left">
* <tr> * <tr>
* <th scope="row">lockedStackFrame</th> * <th scope="row">lockedStackFrame</th>
* <td><code>CompositeData as specified in the * <td><a href="ThreadInfo.html#stackTraceElement">
* <a href="ThreadInfo.html#StackTrace">stackTrace</a> * {@code CompositeData} for {@code StackTraceElement}</a> as specified
* attribute defined in the {@link ThreadInfo#from * in {@link ThreadInfo#from(CompositeData)} method.
* ThreadInfo.from} method. * </td>
* </code></td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">lockedStackDepth</th> * <th scope="row">lockedStackDepth</th>
@ -134,7 +133,7 @@ public class MonitorInfo extends LockInfo {
* @throws IllegalArgumentException if {@code cd} does not * @throws IllegalArgumentException if {@code cd} does not
* represent a {@code MonitorInfo} with the attributes described * represent a {@code MonitorInfo} with the attributes described
* above. * above.
*
* @return a {@code MonitorInfo} object represented * @return a {@code MonitorInfo} object represented
* by {@code cd} if {@code cd} is not {@code null}; * by {@code cd} if {@code cd} is not {@code null};
* {@code null} otherwise. * {@code null} otherwise.

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -25,6 +25,7 @@
package java.lang.management; package java.lang.management;
import javax.management.openmbean.ArrayType;
import javax.management.openmbean.CompositeData; import javax.management.openmbean.CompositeData;
import sun.management.ManagementFactoryHelper; import sun.management.ManagementFactoryHelper;
import sun.management.ThreadInfoCompositeData; import sun.management.ThreadInfoCompositeData;
@ -110,7 +111,6 @@ public class ThreadInfo {
private StackTraceElement[] stackTrace; private StackTraceElement[] stackTrace;
private MonitorInfo[] lockedMonitors; private MonitorInfo[] lockedMonitors;
private LockInfo[] lockedSynchronizers; private LockInfo[] lockedSynchronizers;
private static MonitorInfo[] EMPTY_MONITORS = new MonitorInfo[0]; private static MonitorInfo[] EMPTY_MONITORS = new MonitorInfo[0];
private static LockInfo[] EMPTY_SYNCS = new LockInfo[0]; private static LockInfo[] EMPTY_SYNCS = new LockInfo[0];
@ -264,6 +264,11 @@ public class ThreadInfo {
/* /*
* Constructs a {@code ThreadInfo} object from a * Constructs a {@code ThreadInfo} object from a
* {@link CompositeData CompositeData}. * {@link CompositeData CompositeData}.
*
* @throws IllegalArgumentException if the given CompositeData does not
* contain all of the attributes defined for ThreadInfo of version <= N.
*
* @see ThreadInfo#from
*/ */
private ThreadInfo(CompositeData cd) { private ThreadInfo(CompositeData cd) {
ThreadInfoCompositeData ticd = ThreadInfoCompositeData.getInstance(cd); ThreadInfoCompositeData ticd = ThreadInfoCompositeData.getInstance(cd);
@ -281,41 +286,11 @@ public class ThreadInfo {
suspended = ticd.suspended(); suspended = ticd.suspended();
inNative = ticd.inNative(); inNative = ticd.inNative();
stackTrace = ticd.stackTrace(); stackTrace = ticd.stackTrace();
lock = ticd.lockInfo();
// 6.0 attributes lockedMonitors = ticd.lockedMonitors();
if (ticd.hasV6()) { lockedSynchronizers = ticd.lockedSynchronizers();
lock = ticd.lockInfo(); daemon = ticd.isDaemon();
lockedMonitors = ticd.lockedMonitors(); priority = ticd.getPriority();
lockedSynchronizers = ticd.lockedSynchronizers();
} else {
// lockInfo is a new attribute added in 1.6 ThreadInfo
// If cd is a 5.0 version, construct the LockInfo object
// from the lockName value.
if (lockName != null) {
String result[] = lockName.split("@");
if (result.length == 2) {
int identityHashCode = Integer.parseInt(result[1], 16);
lock = new LockInfo(result[0], identityHashCode);
} else {
assert result.length == 2;
lock = null;
}
} else {
lock = null;
}
lockedMonitors = EMPTY_MONITORS;
lockedSynchronizers = EMPTY_SYNCS;
}
// 9.0 attributes
if (ticd.isCurrentVersion()) {
daemon = ticd.isDaemon();
priority = ticd.getPriority();
} else {
// Not ideal, but unclear what else we can do.
daemon = false;
priority = Thread.NORM_PRIORITY;
}
} }
/** /**
@ -692,52 +667,105 @@ public class ThreadInfo {
/** /**
* Returns a {@code ThreadInfo} object represented by the * Returns a {@code ThreadInfo} object represented by the
* given {@code CompositeData}. * given {@code CompositeData}.
* The given {@code CompositeData} must contain the following attributes *
* unless otherwise specified below: * <a id="attributes"></a>
* A {@code CompositeData} representing a {@code ThreadInfo} of
* version <em>N</em> must contain all of the attributes defined
* in version &le; <em>N</em> unless specified otherwise.
* The same rule applies the composite type of the given
* {@code CompositeData} and transitively to attributes whose
* {@linkplain CompositeData#getCompositeType() type} or
* {@linkplain ArrayType#getElementOpenType() component type} is
* {@code CompositeType}.
* <p>
* A {@code CompositeData} representing {@code ThreadInfo} of
* version <em>N</em> contains {@code "stackTrace"} attribute and
* {@code "lockedMonitors"} attribute representing
* an array of {@code StackTraceElement} and
* an array of {@link MonitorInfo} respectively
* and their types are of version <em>N</em>.
* The {@code "lockedStackFrame"} attribute in
* {@link MonitorInfo#from(CompositeData) MonitorInfo}'s composite type
* must represent {@code StackTraceElement} of the same version <em>N</em>.
* Otherwise, this method will throw {@code IllegalArgumentException}.
*
* <table class="striped" style="margin-left:2em"> * <table class="striped" style="margin-left:2em">
* <caption style="display:none">The attributes and their types the given CompositeData contains</caption> * <caption style="display:none">The attributes and their types for ThreadInfo's composite data</caption>
* <thead> * <thead>
* <tr> * <tr>
* <th scope="col">Attribute Name</th> * <th scope="col">Attribute Name</th>
* <th scope="col">Type</th> * <th scope="col">Type</th>
* <th scope="col">Since</th>
* </tr> * </tr>
* </thead> * </thead>
* <tbody style="text-align:left"> * <tbody style="text-align:left">
* <tr> * <tr>
* <th scope="row">threadId</th> * <th scope="row">threadId</th>
* <td>{@code java.lang.Long}</td> * <td>{@code java.lang.Long}</td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">threadName</th> * <th scope="row">threadName</th>
* <td>{@code java.lang.String}</td> * <td>{@code java.lang.String}</td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">threadState</th> * <th scope="row">threadState</th>
* <td>{@code java.lang.String}</td> * <td>{@code java.lang.String}</td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">suspended</th> * <th scope="row">suspended</th>
* <td>{@code java.lang.Boolean}</td> * <td>{@code java.lang.Boolean}</td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">inNative</th> * <th scope="row">inNative</th>
* <td>{@code java.lang.Boolean}</td> * <td>{@code java.lang.Boolean}</td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">blockedCount</th> * <th scope="row">blockedCount</th>
* <td>{@code java.lang.Long}</td> * <td>{@code java.lang.Long}</td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">blockedTime</th> * <th scope="row">blockedTime</th>
* <td>{@code java.lang.Long}</td> * <td>{@code java.lang.Long}</td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">waitedCount</th> * <th scope="row">waitedCount</th>
* <td>{@code java.lang.Long}</td> * <td>{@code java.lang.Long}</td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">waitedTime</th> * <th scope="row">waitedTime</th>
* <td>{@code java.lang.Long}</td> * <td>{@code java.lang.Long}</td>
* <td>5</td>
* </tr>
* <tr>
* <th scope="row">lockName</th>
* <td>{@code java.lang.String}</td>
* <td>5</td>
* </tr>
* <tr>
* <th scope="row">lockOwnerId</th>
* <td>{@code java.lang.Long}</td>
* <td>5</td>
* </tr>
* <tr>
* <th scope="row">lockOwnerName</th>
* <td>{@code java.lang.String}</td>
* <td>5</td>
* </tr>
* <tr>
* <th scope="row"><a id="StackTrace">stackTrace</a></th>
* <td>{@code javax.management.openmbean.CompositeData[]}, each element
* is a {@code CompositeData} representing {@code StackTraceElement}
* as specified <a href="#stackTraceElement">below</a>.
* </td>
* <td>5</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">lockInfo</th> * <th scope="row">lockInfo</th>
@ -745,78 +773,21 @@ public class ThreadInfo {
* - the mapped type for {@link LockInfo} as specified in the * - the mapped type for {@link LockInfo} as specified in the
* {@link LockInfo#from} method. * {@link LockInfo#from} method.
* <p> * <p>
* If {@code cd} does not contain this attribute, * If the given {@code CompositeData} does not contain this attribute,
* the {@code LockInfo} object will be constructed from * the {@code LockInfo} object will be constructed from
* the value of the {@code lockName} attribute. </td> * the value of the {@code lockName} attribute.</td>
* </tr> * <td>6</td>
* <tr>
* <th scope="row">lockName</th>
* <td>{@code java.lang.String}</td>
* </tr>
* <tr>
* <th scope="row">lockOwnerId</th>
* <td>{@code java.lang.Long}</td>
* </tr>
* <tr>
* <th scope="row">lockOwnerName</th>
* <td>{@code java.lang.String}</td>
* </tr>
* <tr>
* <th scope="row"><a id="StackTrace">stackTrace</a></th>
* <td>{@code javax.management.openmbean.CompositeData[]}
* <p>
* Each element is a {@code CompositeData} representing
* StackTraceElement containing the following attributes:
* <table class="striped" style="margin-left:2em">
* <caption style="display:none">The attributes and their types the given CompositeData contains</caption>
* <thead style="text-align:center">
* <tr>
* <th scope="col">Attribute Name</th>
* <th scope="col">Type</th>
* </tr>
* </thead>
* <tbody style="text-align:left">
* <tr>
* <th scope="row">moduleName</th>
* <td>{@code java.lang.String}</td>
* </tr>
* <tr>
* <th scope="row">moduleVersion</th>
* <td>{@code java.lang.String}</td>
* </tr>
* <tr>
* <th scope="row">className</th>
* <td>{@code java.lang.String}</td>
* </tr>
* <tr>
* <th scope="row">methodName</th>
* <td>{@code java.lang.String}</td>
* </tr>
* <tr>
* <th scope="row">fileName</th>
* <td>{@code java.lang.String}</td>
* </tr>
* <tr>
* <th scope="row">lineNumber</th>
* <td>{@code java.lang.Integer}</td>
* </tr>
* <tr>
* <th scope="row">nativeMethod</th>
* <td>{@code java.lang.Boolean}</td>
* </tr>
* </tbody>
* </table>
* </td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">lockedMonitors</th> * <th scope="row">lockedMonitors</th>
* <td>{@code javax.management.openmbean.CompositeData[]} * <td>{@code javax.management.openmbean.CompositeData[]}
* whose element type is the mapped type for * whose element type is the mapped type for
* {@link MonitorInfo} as specified in the * {@link MonitorInfo} as specified in the
* {@link MonitorInfo#from Monitor.from} method. * {@link MonitorInfo#from MonitorInfo.from} method.
* <p> * <p>
* If {@code cd} does not contain this attribute, * If the given {@code CompositeData} does not contain this attribute,
* this attribute will be set to an empty array. </td> * this attribute will be set to an empty array.</td>
* <td>6</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">lockedSynchronizers</th> * <th scope="row">lockedSynchronizers</th>
@ -824,25 +795,93 @@ public class ThreadInfo {
* whose element type is the mapped type for * whose element type is the mapped type for
* {@link LockInfo} as specified in the {@link LockInfo#from} method. * {@link LockInfo} as specified in the {@link LockInfo#from} method.
* <p> * <p>
* If {@code cd} does not contain this attribute, * If the given {@code CompositeData} does not contain this attribute,
* this attribute will be set to an empty array. </td> * this attribute will be set to an empty array.</td>
* <td>6</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">daemon</th> * <th scope="row">daemon</th>
* <td>{@code java.lang.Boolean}</td> * <td>{@code java.lang.Boolean}
* <p>
* If the given {@code CompositeData} does not contain this attribute,
* this attribute will be set to {@code false}.</td>
* <td>9</td>
* </tr> * </tr>
* <tr> * <tr>
* <th scope="row">priority</th> * <th scope="row">priority</th>
* <td>{@code java.lang.Integer}
* <p>
* If the given {@code CompositeData} does not contain this attribute,
* This attribute will be set to {@link Thread#NORM_PRIORITY}.</td>
* <td>9</td>
* </tr>
* </tbody>
* </table>
*
* <a id="stackTraceElement">A {@code CompositeData} representing
* {@code StackTraceElement}</a> of version <em>N</em> must contain
* all of the attributes defined in version &le; <em>N</em>
* unless specified otherwise.
*
* <table class="striped" style="margin-left:2em">
* <caption style="display:none">The attributes and their types for StackTraceElement's composite data</caption>
* <thead style="text-align:center">
* <tr>
* <th scope="col">Attribute Name</th>
* <th scope="col">Type</th>
* <th scope="col">Since</th>
* </tr>
* </thead>
* <tbody style="text-align:left">
* <tr>
* <th scope="row">classLoaderName</th>
* <td>{@code java.lang.String}</td>
* <td>9</td>
* </tr>
* <tr>
* <th scope="row">moduleName</th>
* <td>{@code java.lang.String}</td>
* <td>9</td>
* </tr>
* <tr>
* <th scope="row">moduleVersion</th>
* <td>{@code java.lang.String}</td>
* <td>9</td>
* </tr>
* <tr>
* <th scope="row">className</th>
* <td>{@code java.lang.String}</td>
* <td>5</td>
* </tr>
* <tr>
* <th scope="row">methodName</th>
* <td>{@code java.lang.String}</td>
* <td>5</td>
* </tr>
* <tr>
* <th scope="row">fileName</th>
* <td>{@code java.lang.String}</td>
* <td>5</td>
* </tr>
* <tr>
* <th scope="row">lineNumber</th>
* <td>{@code java.lang.Integer}</td> * <td>{@code java.lang.Integer}</td>
* <td>5</td>
* </tr>
* <tr>
* <th scope="row">nativeMethod</th>
* <td>{@code java.lang.Boolean}</td>
* <td>5</td>
* </tr> * </tr>
* </tbody> * </tbody>
* </table> * </table>
* *
* @param cd {@code CompositeData} representing a {@code ThreadInfo} * @param cd {@code CompositeData} representing a {@code ThreadInfo}
* *
* @throws IllegalArgumentException if {@code cd} does not * @throws IllegalArgumentException if the given {@code cd} and
* represent a {@code ThreadInfo} with the attributes described * its composite type does not contain all of
* above. * <a href="#attributes">the attributes</a> defined for a
* {@code ThreadInfo} of a specific runtime version.
* *
* @return a {@code ThreadInfo} object represented * @return a {@code ThreadInfo} object represented
* by {@code cd} if {@code cd} is not {@code null}; * by {@code cd} if {@code cd} is not {@code null};

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -58,15 +58,15 @@ public class LockInfoCompositeData extends LazyCompositeData {
protected CompositeData getCompositeData() { protected CompositeData getCompositeData() {
// CONTENTS OF THIS ARRAY MUST BE SYNCHRONIZED WITH // CONTENTS OF THIS ARRAY MUST BE SYNCHRONIZED WITH
// lockInfoItemNames! // LOCK_INFO_ATTRIBUTES!
final Object[] lockInfoItemValues = { final Object[] lockInfoItemValues = {
new String(lock.getClassName()), new String(lock.getClassName()),
lock.getIdentityHashCode(), lock.getIdentityHashCode(),
}; };
try { try {
return new CompositeDataSupport(lockInfoCompositeType, return new CompositeDataSupport(LOCK_INFO_COMPOSITE_TYPE,
lockInfoItemNames, LOCK_INFO_ATTRIBUTES,
lockInfoItemValues); lockInfoItemValues);
} catch (OpenDataException e) { } catch (OpenDataException e) {
// Should never reach here // Should never reach here
@ -74,10 +74,10 @@ public class LockInfoCompositeData extends LazyCompositeData {
} }
} }
private static final CompositeType lockInfoCompositeType; private static final CompositeType LOCK_INFO_COMPOSITE_TYPE;
static { static {
try { try {
lockInfoCompositeType = (CompositeType) LOCK_INFO_COMPOSITE_TYPE = (CompositeType)
MappedMXBeanType.toOpenType(LockInfo.class); MappedMXBeanType.toOpenType(LockInfo.class);
} catch (OpenDataException e) { } catch (OpenDataException e) {
// Should never reach here // Should never reach here
@ -85,13 +85,13 @@ public class LockInfoCompositeData extends LazyCompositeData {
} }
} }
static CompositeType getLockInfoCompositeType() { static CompositeType compositeType() {
return lockInfoCompositeType; return LOCK_INFO_COMPOSITE_TYPE;
} }
private static final String CLASS_NAME = "className"; private static final String CLASS_NAME = "className";
private static final String IDENTITY_HASH_CODE = "identityHashCode"; private static final String IDENTITY_HASH_CODE = "identityHashCode";
private static final String[] lockInfoItemNames = { private static final String[] LOCK_INFO_ATTRIBUTES = {
CLASS_NAME, CLASS_NAME,
IDENTITY_HASH_CODE, IDENTITY_HASH_CODE,
}; };
@ -104,7 +104,7 @@ public class LockInfoCompositeData extends LazyCompositeData {
throw new NullPointerException("Null CompositeData"); throw new NullPointerException("Null CompositeData");
} }
if (!isTypeMatched(lockInfoCompositeType, cd.getCompositeType())) { if (!isTypeMatched(LOCK_INFO_COMPOSITE_TYPE, cd.getCompositeType())) {
throw new IllegalArgumentException( throw new IllegalArgumentException(
"Unexpected composite type for LockInfo"); "Unexpected composite type for LockInfo");
} }

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -30,7 +30,7 @@ import javax.management.openmbean.CompositeType;
import javax.management.openmbean.CompositeData; import javax.management.openmbean.CompositeData;
import javax.management.openmbean.CompositeDataSupport; import javax.management.openmbean.CompositeDataSupport;
import javax.management.openmbean.OpenDataException; import javax.management.openmbean.OpenDataException;
import java.util.Set; import javax.management.openmbean.OpenType;
/** /**
* A CompositeData for MonitorInfo for the local management support. * A CompositeData for MonitorInfo for the local management support.
@ -55,14 +55,14 @@ public class MonitorInfoCompositeData extends LazyCompositeData {
protected CompositeData getCompositeData() { protected CompositeData getCompositeData() {
// CONTENTS OF THIS ARRAY MUST BE SYNCHRONIZED WITH // CONTENTS OF THIS ARRAY MUST BE SYNCHRONIZED WITH
// monitorInfoItemNames! // MONITOR_INFO_ATTRIBUTES!
int len = monitorInfoItemNames.length; int len = MONITOR_INFO_ATTRIBUTES.length;
Object[] values = new Object[len]; Object[] values = new Object[len];
CompositeData li = LockInfoCompositeData.toCompositeData(lock); CompositeData li = LockInfoCompositeData.toCompositeData(lock);
for (int i = 0; i < len; i++) { for (int i = 0; i < len; i++) {
String item = monitorInfoItemNames[i]; String item = MONITOR_INFO_ATTRIBUTES[i];
if (item.equals(LOCKED_STACK_FRAME)) { if (item.equals(LOCKED_STACK_FRAME)) {
StackTraceElement ste = lock.getLockedStackFrame(); StackTraceElement ste = lock.getLockedStackFrame();
values[i] = (ste != null ? StackTraceElementCompositeData. values[i] = (ste != null ? StackTraceElementCompositeData.
@ -76,8 +76,8 @@ public class MonitorInfoCompositeData extends LazyCompositeData {
} }
try { try {
return new CompositeDataSupport(monitorInfoCompositeType, return new CompositeDataSupport(MONITOR_INFO_COMPOSITE_TYPE,
monitorInfoItemNames, MONITOR_INFO_ATTRIBUTES,
values); values);
} catch (OpenDataException e) { } catch (OpenDataException e) {
// Should never reach here // Should never reach here
@ -85,28 +85,50 @@ public class MonitorInfoCompositeData extends LazyCompositeData {
} }
} }
private static final CompositeType monitorInfoCompositeType; private static final String CLASS_NAME = "className";
private static final String[] monitorInfoItemNames; private static final String IDENTITY_HASH_CODE = "identityHashCode";
private static final String LOCKED_STACK_FRAME = "lockedStackFrame";
private static final String LOCKED_STACK_DEPTH = "lockedStackDepth";
private static final String[] MONITOR_INFO_ATTRIBUTES = {
CLASS_NAME,
IDENTITY_HASH_CODE,
LOCKED_STACK_FRAME,
LOCKED_STACK_DEPTH
};
private static final CompositeType MONITOR_INFO_COMPOSITE_TYPE;
private static final CompositeType V6_COMPOSITE_TYPE;
static { static {
try { try {
monitorInfoCompositeType = (CompositeType) MONITOR_INFO_COMPOSITE_TYPE = (CompositeType)
MappedMXBeanType.toOpenType(MonitorInfo.class); MappedMXBeanType.toOpenType(MonitorInfo.class);
Set<String> s = monitorInfoCompositeType.keySet();
monitorInfoItemNames = s.toArray(new String[0]); OpenType<?>[] types = new OpenType<?>[MONITOR_INFO_ATTRIBUTES.length];
for (int i = 0; i < MONITOR_INFO_ATTRIBUTES.length; i++) {
String name = MONITOR_INFO_ATTRIBUTES[i];
types[i] = name.equals(LOCKED_STACK_FRAME)
? StackTraceElementCompositeData.v5CompositeType()
: MONITOR_INFO_COMPOSITE_TYPE.getType(name);
}
V6_COMPOSITE_TYPE = new CompositeType("MonitorInfo",
"JDK 6 MonitorInfo",
MONITOR_INFO_ATTRIBUTES,
MONITOR_INFO_ATTRIBUTES,
types);
} catch (OpenDataException e) { } catch (OpenDataException e) {
// Should never reach here // Should never reach here
throw new AssertionError(e); throw new AssertionError(e);
} }
} }
static CompositeType getMonitorInfoCompositeType() { static CompositeType v6CompositeType() {
return monitorInfoCompositeType; return V6_COMPOSITE_TYPE;
} }
private static final String CLASS_NAME = "className"; static CompositeType compositeType() {
private static final String IDENTITY_HASH_CODE = "identityHashCode"; return MONITOR_INFO_COMPOSITE_TYPE;
private static final String LOCKED_STACK_FRAME = "lockedStackFrame"; }
private static final String LOCKED_STACK_DEPTH = "lockedStackDepth";
public static String getClassName(CompositeData cd) { public static String getClassName(CompositeData cd) {
return getString(cd, CLASS_NAME); return getString(cd, CLASS_NAME);
@ -138,7 +160,8 @@ public class MonitorInfoCompositeData extends LazyCompositeData {
throw new NullPointerException("Null CompositeData"); throw new NullPointerException("Null CompositeData");
} }
if (!isTypeMatched(monitorInfoCompositeType, cd.getCompositeType())) { if (!isTypeMatched(MONITOR_INFO_COMPOSITE_TYPE, cd.getCompositeType()) &&
!isTypeMatched(V6_COMPOSITE_TYPE, cd.getCompositeType())) {
throw new IllegalArgumentException( throw new IllegalArgumentException(
"Unexpected composite type for MonitorInfo"); "Unexpected composite type for MonitorInfo");
} }

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -25,13 +25,13 @@
package sun.management; package sun.management;
import java.util.HashMap;
import java.util.Map;
import java.util.function.Predicate;
import javax.management.openmbean.CompositeType; import javax.management.openmbean.CompositeType;
import javax.management.openmbean.CompositeData; import javax.management.openmbean.CompositeData;
import javax.management.openmbean.CompositeDataSupport; import javax.management.openmbean.CompositeDataSupport;
import javax.management.openmbean.OpenDataException; import javax.management.openmbean.OpenDataException;
import javax.management.openmbean.OpenType;
import java.util.Arrays;
import java.util.stream.Stream;
/** /**
* A CompositeData for StackTraceElement for the local management support. * A CompositeData for StackTraceElement for the local management support.
@ -52,12 +52,7 @@ public class StackTraceElementCompositeData extends LazyCompositeData {
public static StackTraceElement from(CompositeData cd) { public static StackTraceElement from(CompositeData cd) {
validateCompositeData(cd); validateCompositeData(cd);
if (stackTraceElementV6CompositeType.equals(cd.getCompositeType())) { if (STACK_TRACE_ELEMENT_COMPOSITE_TYPE.equals(cd.getCompositeType())) {
return new StackTraceElement(getString(cd, CLASS_NAME),
getString(cd, METHOD_NAME),
getString(cd, FILE_NAME),
getInt(cd, LINE_NUMBER));
} else {
return new StackTraceElement(getString(cd, CLASS_LOADER_NAME), return new StackTraceElement(getString(cd, CLASS_LOADER_NAME),
getString(cd, MODULE_NAME), getString(cd, MODULE_NAME),
getString(cd, MODULE_VERSION), getString(cd, MODULE_VERSION),
@ -65,6 +60,12 @@ public class StackTraceElementCompositeData extends LazyCompositeData {
getString(cd, METHOD_NAME), getString(cd, METHOD_NAME),
getString(cd, FILE_NAME), getString(cd, FILE_NAME),
getInt(cd, LINE_NUMBER)); getInt(cd, LINE_NUMBER));
} else {
return new StackTraceElement(getString(cd, CLASS_NAME),
getString(cd, METHOD_NAME),
getString(cd, FILE_NAME),
getInt(cd, LINE_NUMBER));
} }
} }
@ -75,7 +76,7 @@ public class StackTraceElementCompositeData extends LazyCompositeData {
protected CompositeData getCompositeData() { protected CompositeData getCompositeData() {
// CONTENTS OF THIS ARRAY MUST BE SYNCHRONIZED WITH // CONTENTS OF THIS ARRAY MUST BE SYNCHRONIZED WITH
// stackTraceElementItemNames! // STACK_TRACE_ELEMENT_ATTRIBUTES!
final Object[] stackTraceElementItemValues = { final Object[] stackTraceElementItemValues = {
ste.getClassLoaderName(), ste.getClassLoaderName(),
ste.getModuleName(), ste.getModuleName(),
@ -87,8 +88,8 @@ public class StackTraceElementCompositeData extends LazyCompositeData {
ste.isNativeMethod(), ste.isNativeMethod(),
}; };
try { try {
return new CompositeDataSupport(stackTraceElementCompositeType, return new CompositeDataSupport(STACK_TRACE_ELEMENT_COMPOSITE_TYPE,
stackTraceElementItemNames, STACK_TRACE_ELEMENT_ATTRIBUTES,
stackTraceElementItemValues); stackTraceElementItemValues);
} catch (OpenDataException e) { } catch (OpenDataException e) {
// Should never reach here // Should never reach here
@ -106,11 +107,7 @@ public class StackTraceElementCompositeData extends LazyCompositeData {
private static final String LINE_NUMBER = "lineNumber"; private static final String LINE_NUMBER = "lineNumber";
private static final String NATIVE_METHOD = "nativeMethod"; private static final String NATIVE_METHOD = "nativeMethod";
private static final String[] V5_ATTRIBUTES = {
private static final String[] stackTraceElementItemNames = {
CLASS_LOADER_NAME,
MODULE_NAME,
MODULE_VERSION,
CLASS_NAME, CLASS_NAME,
METHOD_NAME, METHOD_NAME,
FILE_NAME, FILE_NAME,
@ -118,30 +115,48 @@ public class StackTraceElementCompositeData extends LazyCompositeData {
NATIVE_METHOD, NATIVE_METHOD,
}; };
private static final String[] stackTraceElementV9ItemNames = { private static final String[] V9_ATTRIBUTES = {
CLASS_LOADER_NAME, CLASS_LOADER_NAME,
MODULE_NAME, MODULE_NAME,
MODULE_VERSION, MODULE_VERSION,
}; };
private static final CompositeType stackTraceElementCompositeType; private static final String[] STACK_TRACE_ELEMENT_ATTRIBUTES =
private static final CompositeType stackTraceElementV6CompositeType; Stream.of(V5_ATTRIBUTES, V9_ATTRIBUTES).flatMap(Arrays::stream)
.toArray(String[]::new);
private static final CompositeType STACK_TRACE_ELEMENT_COMPOSITE_TYPE;
private static final CompositeType V5_COMPOSITE_TYPE;
static { static {
try { try {
stackTraceElementCompositeType = (CompositeType) STACK_TRACE_ELEMENT_COMPOSITE_TYPE = (CompositeType)
MappedMXBeanType.toOpenType(StackTraceElement.class); MappedMXBeanType.toOpenType(StackTraceElement.class);
stackTraceElementV6CompositeType =
TypeVersionMapper.getInstance().getVersionedCompositeType( OpenType<?>[] types = new OpenType<?>[V5_ATTRIBUTES.length];
stackTraceElementCompositeType, for (int i=0; i < V5_ATTRIBUTES.length; i++) {
TypeVersionMapper.V6 String name = V5_ATTRIBUTES[i];
); types[i] = STACK_TRACE_ELEMENT_COMPOSITE_TYPE.getType(name);
}
V5_COMPOSITE_TYPE = new CompositeType("StackTraceElement",
"JDK 5 StackTraceElement",
V5_ATTRIBUTES,
V5_ATTRIBUTES,
types);
} catch (OpenDataException e) { } catch (OpenDataException e) {
// Should never reach here // Should never reach here
throw new AssertionError(e); throw new AssertionError(e);
} }
} }
/** Validate if the input CompositeData has the expected static CompositeType v5CompositeType() {
return V5_COMPOSITE_TYPE;
}
static CompositeType compositeType() {
return STACK_TRACE_ELEMENT_COMPOSITE_TYPE;
}
/**
* Validate if the input CompositeData has the expected
* CompositeType (i.e. contain all attributes with expected * CompositeType (i.e. contain all attributes with expected
* names and types). * names and types).
*/ */
@ -151,22 +166,11 @@ public class StackTraceElementCompositeData extends LazyCompositeData {
} }
CompositeType ct = cd.getCompositeType(); CompositeType ct = cd.getCompositeType();
if (!isTypeMatched(stackTraceElementCompositeType, ct)) { if (!isTypeMatched(STACK_TRACE_ELEMENT_COMPOSITE_TYPE, ct) &&
if (!isTypeMatched(stackTraceElementV6CompositeType, ct)) { !isTypeMatched(V5_COMPOSITE_TYPE, ct)) {
throw new IllegalArgumentException( throw new IllegalArgumentException(
"Unexpected composite type for StackTraceElement"); "Unexpected composite type for StackTraceElement");
}
} }
} }
static boolean isV6Attribute(String name) {
for(String attrName : stackTraceElementV9ItemNames) {
if (name.equals(attrName)) {
return false;
}
}
return true;
}
private static final long serialVersionUID = -2704607706598396827L; private static final long serialVersionUID = -2704607706598396827L;
} }

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -28,10 +28,16 @@ package sun.management;
import java.lang.management.ThreadInfo; import java.lang.management.ThreadInfo;
import java.lang.management.MonitorInfo; import java.lang.management.MonitorInfo;
import java.lang.management.LockInfo; import java.lang.management.LockInfo;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
import java.util.stream.Stream;
import javax.management.openmbean.ArrayType;
import javax.management.openmbean.CompositeType; import javax.management.openmbean.CompositeType;
import javax.management.openmbean.CompositeData; import javax.management.openmbean.CompositeData;
import javax.management.openmbean.CompositeDataSupport; import javax.management.openmbean.CompositeDataSupport;
import javax.management.openmbean.OpenDataException; import javax.management.openmbean.OpenDataException;
import javax.management.openmbean.OpenType;
/** /**
* A CompositeData for ThreadInfo for the local management support. * A CompositeData for ThreadInfo for the local management support.
@ -41,35 +47,21 @@ import javax.management.openmbean.OpenDataException;
public class ThreadInfoCompositeData extends LazyCompositeData { public class ThreadInfoCompositeData extends LazyCompositeData {
private final ThreadInfo threadInfo; private final ThreadInfo threadInfo;
private final CompositeData cdata; private final CompositeData cdata;
private final boolean currentVersion;
private final boolean hasV6;
private ThreadInfoCompositeData(ThreadInfo ti) { private ThreadInfoCompositeData(ThreadInfo ti) {
this.threadInfo = ti; this.threadInfo = ti;
this.currentVersion = true;
this.cdata = null; this.cdata = null;
this.hasV6 = true;
} }
private ThreadInfoCompositeData(CompositeData cd) { private ThreadInfoCompositeData(CompositeData cd) {
this.threadInfo = null; this.threadInfo = null;
this.currentVersion = ThreadInfoCompositeData.isCurrentVersion(cd);
this.cdata = cd; this.cdata = cd;
this.hasV6 = ThreadInfoCompositeData.hasV6(cd);
} }
public ThreadInfo getThreadInfo() { public ThreadInfo getThreadInfo() {
return threadInfo; return threadInfo;
} }
public boolean hasV6() {
return hasV6;
}
public boolean isCurrentVersion() {
return currentVersion;
}
public static ThreadInfoCompositeData getInstance(CompositeData cd) { public static ThreadInfoCompositeData getInstance(CompositeData cd) {
validateCompositeData(cd); validateCompositeData(cd);
return new ThreadInfoCompositeData(cd); return new ThreadInfoCompositeData(cd);
@ -112,7 +104,7 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
} }
// CONTENTS OF THIS ARRAY MUST BE SYNCHRONIZED WITH // CONTENTS OF THIS ARRAY MUST BE SYNCHRONIZED WITH
// threadInfoItemNames! // THREAD_INFO_ATTRIBUTES!
final Object[] threadInfoItemValues = { final Object[] threadInfoItemValues = {
threadInfo.getThreadId(), threadInfo.getThreadId(),
threadInfo.getThreadName(), threadInfo.getThreadName(),
@ -126,8 +118,8 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
threadInfo.getLockOwnerId(), threadInfo.getLockOwnerId(),
threadInfo.getLockOwnerName(), threadInfo.getLockOwnerName(),
stackTraceData, stackTraceData,
threadInfo.isSuspended(), threadInfo.isSuspended(),
threadInfo.isInNative(), threadInfo.isInNative(),
lockedMonitorsData, lockedMonitorsData,
lockedSyncsData, lockedSyncsData,
threadInfo.isDaemon(), threadInfo.isDaemon(),
@ -135,8 +127,8 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
}; };
try { try {
return new CompositeDataSupport(threadInfoCompositeType, return new CompositeDataSupport(compositeType(),
threadInfoItemNames, THREAD_INFO_ATTRIBTUES,
threadInfoItemValues); threadInfoItemValues);
} catch (OpenDataException e) { } catch (OpenDataException e) {
// Should never reach here // Should never reach here
@ -164,7 +156,7 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
private static final String LOCKED_MONITORS = "lockedMonitors"; private static final String LOCKED_MONITORS = "lockedMonitors";
private static final String LOCKED_SYNCS = "lockedSynchronizers"; private static final String LOCKED_SYNCS = "lockedSynchronizers";
private static final String[] threadInfoItemNames = { private static final String[] V5_ATTRIBUTES = {
THREAD_ID, THREAD_ID,
THREAD_NAME, THREAD_NAME,
THREAD_STATE, THREAD_STATE,
@ -172,109 +164,28 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
BLOCKED_COUNT, BLOCKED_COUNT,
WAITED_TIME, WAITED_TIME,
WAITED_COUNT, WAITED_COUNT,
LOCK_INFO,
LOCK_NAME, LOCK_NAME,
LOCK_OWNER_ID, LOCK_OWNER_ID,
LOCK_OWNER_NAME, LOCK_OWNER_NAME,
STACK_TRACE, STACK_TRACE,
SUSPENDED, SUSPENDED,
IN_NATIVE, IN_NATIVE
LOCKED_MONITORS,
LOCKED_SYNCS,
DAEMON,
PRIORITY,
}; };
// New attributes added in 6.0 ThreadInfo private static final String[] V6_ATTRIBUTES = {
private static final String[] threadInfoV6Attributes = {
LOCK_INFO, LOCK_INFO,
LOCKED_MONITORS, LOCKED_MONITORS,
LOCKED_SYNCS, LOCKED_SYNCS,
}; };
private static final String[] threadInfoV9Attributes = { private static final String[] V9_ATTRIBUTES = {
DAEMON, DAEMON,
PRIORITY, PRIORITY,
}; };
// Current version of ThreadInfo private static final String[] THREAD_INFO_ATTRIBTUES =
private static final CompositeType threadInfoCompositeType; Stream.of(V5_ATTRIBUTES, V6_ATTRIBUTES, V9_ATTRIBUTES)
// Previous version of ThreadInfo .flatMap(Arrays::stream).toArray(String[]::new);
private static final CompositeType threadInfoV6CompositeType;
// Previous-previous version of ThreadInfo
private static final CompositeType threadInfoV5CompositeType;
private static final CompositeType lockInfoCompositeType;
static {
try {
threadInfoCompositeType = (CompositeType)
MappedMXBeanType.toOpenType(ThreadInfo.class);
// Form a CompositeType for JDK 5.0 ThreadInfo version
threadInfoV5CompositeType =
TypeVersionMapper.getInstance().getVersionedCompositeType(
threadInfoCompositeType, TypeVersionMapper.V5
);
threadInfoV6CompositeType =
TypeVersionMapper.getInstance().getVersionedCompositeType(
threadInfoCompositeType, TypeVersionMapper.V6
);
} catch (OpenDataException e) {
// Should never reach here
throw new AssertionError(e);
}
// Each CompositeData object has its CompositeType associated
// with it. So we can get the CompositeType representing LockInfo
// from a mapped CompositeData for any LockInfo object.
// Thus we construct a random LockInfo object and pass it
// to LockInfoCompositeData to do the conversion.
Object o = new Object();
LockInfo li = new LockInfo(o.getClass().getName(),
System.identityHashCode(o));
CompositeData cd = LockInfoCompositeData.toCompositeData(li);
lockInfoCompositeType = cd.getCompositeType();
}
static boolean isV5Attribute(String itemName) {
for (String n : threadInfoV6Attributes) {
if (itemName.equals(n)) {
return false;
}
}
for (String n : threadInfoV9Attributes) {
if (itemName.equals(n)) {
return false;
}
}
return true;
}
static boolean isV6Attribute(String itemName) {
for (String n : threadInfoV9Attributes) {
if (itemName.equals(n)) {
return false;
}
}
return true;
}
public static boolean isCurrentVersion(CompositeData cd) {
if (cd == null) {
throw new NullPointerException("Null CompositeData");
}
return isTypeMatched(threadInfoCompositeType, cd.getCompositeType());
}
private static boolean hasV6(CompositeData cd) {
if (cd == null) {
throw new NullPointerException("Null CompositeData");
}
return isTypeMatched(threadInfoCompositeType, cd.getCompositeType()) ||
isTypeMatched(threadInfoV6CompositeType, cd.getCompositeType());
}
public long threadId() { public long threadId() {
return getLong(cdata, THREAD_ID); return getLong(cdata, THREAD_ID);
@ -333,12 +244,18 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
return getBoolean(cdata, IN_NATIVE); return getBoolean(cdata, IN_NATIVE);
} }
/*
* if daemon attribute is not present, default to false.
*/
public boolean isDaemon() { public boolean isDaemon() {
return getBoolean(cdata, DAEMON); return cdata.containsKey(DAEMON) ? getBoolean(cdata, DAEMON) : false;
} }
/*
* if priority attribute is not present, default to norm priority.
*/
public int getPriority(){ public int getPriority(){
return getInt(cdata, PRIORITY); return cdata.containsKey(PRIORITY) ? getInt(cdata, PRIORITY) : Thread.NORM_PRIORITY;
} }
public StackTraceElement[] stackTrace() { public StackTraceElement[] stackTrace() {
@ -356,13 +273,37 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
return stackTrace; return stackTrace;
} }
// 6.0 new attributes /*
* lockInfo is a new attribute added in JDK 6 ThreadInfo
* If cd is a 5.0 version, construct the LockInfo object
* from the lockName value.
*/
public LockInfo lockInfo() { public LockInfo lockInfo() {
CompositeData lockInfoData = (CompositeData) cdata.get(LOCK_INFO); if (cdata.containsKey(LOCK_INFO)) {
return LockInfo.from(lockInfoData); CompositeData lockInfoData = (CompositeData) cdata.get(LOCK_INFO);
return LockInfo.from(lockInfoData);
} else {
String lockName = lockName();
LockInfo lock = null;
if (lockName != null) {
String result[] = lockName.split("@");
if (result.length == 2) {
int identityHashCode = Integer.parseInt(result[1], 16);
lock = new LockInfo(result[0], identityHashCode);
}
}
return lock;
}
} }
/**
* Returns an empty array if locked_monitors attribute is not present.
*/
public MonitorInfo[] lockedMonitors() { public MonitorInfo[] lockedMonitors() {
if (!cdata.containsKey(LOCKED_MONITORS)) {
return new MonitorInfo[0];
}
CompositeData[] lockedMonitorsData = CompositeData[] lockedMonitorsData =
(CompositeData[]) cdata.get(LOCKED_MONITORS); (CompositeData[]) cdata.get(LOCKED_MONITORS);
@ -377,7 +318,14 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
return monitors; return monitors;
} }
/**
* Returns an empty array if locked_monitors attribute is not present.
*/
public LockInfo[] lockedSynchronizers() { public LockInfo[] lockedSynchronizers() {
if (!cdata.containsKey(LOCKED_SYNCS)) {
return new LockInfo[0];
}
CompositeData[] lockedSyncsData = CompositeData[] lockedSyncsData =
(CompositeData[]) cdata.get(LOCKED_SYNCS); (CompositeData[]) cdata.get(LOCKED_SYNCS);
@ -391,7 +339,8 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
return locks; return locks;
} }
/** Validate if the input CompositeData has the expected /**
* Validate if the input CompositeData has the expected
* CompositeType (i.e. contain all attributes with expected * CompositeType (i.e. contain all attributes with expected
* names and types). * names and types).
*/ */
@ -401,62 +350,98 @@ public class ThreadInfoCompositeData extends LazyCompositeData {
} }
CompositeType type = cd.getCompositeType(); CompositeType type = cd.getCompositeType();
boolean currentVersion = true; int version;
if (!isTypeMatched(threadInfoCompositeType, type)) { if (Arrays.stream(V9_ATTRIBUTES).anyMatch(type::containsKey)) {
currentVersion = false; version = Runtime.version().feature();
// check if cd is an older version } else if (Arrays.stream(V6_ATTRIBUTES).anyMatch(type::containsKey)) {
if (!isTypeMatched(threadInfoV5CompositeType, type) && version = 6;
!isTypeMatched(threadInfoV6CompositeType, type)) { } else {
throw new IllegalArgumentException( version = 5;
"Unexpected composite type for ThreadInfo");
}
} }
CompositeData[] stackTraceData = if (!isTypeMatched(ThreadInfoCompositeTypes.ofVersion(version), type)) {
(CompositeData[]) cd.get(STACK_TRACE);
if (stackTraceData == null) {
throw new IllegalArgumentException( throw new IllegalArgumentException(
"StackTraceElement[] is missing"); "Unexpected composite type for ThreadInfo of version " + version);
}
if (stackTraceData.length > 0) {
StackTraceElementCompositeData.validateCompositeData(stackTraceData[0]);
}
// validate v6 attributes
if (currentVersion) {
CompositeData li = (CompositeData) cd.get(LOCK_INFO);
if (li != null) {
if (!isTypeMatched(lockInfoCompositeType,
li.getCompositeType())) {
throw new IllegalArgumentException(
"Unexpected composite type for \"" +
LOCK_INFO + "\" attribute.");
}
}
CompositeData[] lms = (CompositeData[]) cd.get(LOCKED_MONITORS);
if (lms == null) {
throw new IllegalArgumentException("MonitorInfo[] is null");
}
if (lms.length > 0) {
MonitorInfoCompositeData.validateCompositeData(lms[0]);
}
CompositeData[] lsyncs = (CompositeData[]) cd.get(LOCKED_SYNCS);
if (lsyncs == null) {
throw new IllegalArgumentException("LockInfo[] is null");
}
if (lsyncs.length > 0) {
if (!isTypeMatched(lockInfoCompositeType,
lsyncs[0].getCompositeType())) {
throw new IllegalArgumentException(
"Unexpected composite type for \"" +
LOCKED_SYNCS + "\" attribute.");
}
}
} }
} }
public static CompositeType compositeType() {
return ThreadInfoCompositeTypes.compositeTypes.get(0);
}
static class ThreadInfoCompositeTypes {
static final int CURRENT = Runtime.version().feature();
static final Map<Integer, CompositeType> compositeTypes = initCompositeTypes();
/*
* Returns CompositeType of the given runtime version
*/
static CompositeType ofVersion(int version) {
return compositeTypes.get(version);
}
static Map<Integer, CompositeType> initCompositeTypes() {
Map<Integer, CompositeType> types = new HashMap<>();
CompositeType ctype = initCompositeType();
types.put(CURRENT, ctype);
types.put(5, initV5CompositeType(ctype));
types.put(6, initV6CompositeType(ctype));
return types;
}
static CompositeType initCompositeType() {
try {
return (CompositeType)MappedMXBeanType.toOpenType(ThreadInfo.class);
} catch (OpenDataException e) {
// Should never reach here
throw new AssertionError(e);
}
}
static CompositeType initV5CompositeType(CompositeType threadInfoCompositeType) {
try {
OpenType<?>[] v5Types = new OpenType<?>[V5_ATTRIBUTES.length];
for (int i = 0; i < v5Types.length; i++) {
String name = V5_ATTRIBUTES[i];
v5Types[i] = name.equals(STACK_TRACE)
? new ArrayType<>(1, StackTraceElementCompositeData.v5CompositeType())
: threadInfoCompositeType.getType(name);
}
return new CompositeType("ThreadInfo",
"JDK 5 ThreadInfo",
V5_ATTRIBUTES,
V5_ATTRIBUTES,
v5Types);
} catch (OpenDataException e) {
// Should never reach here
throw new AssertionError(e);
}
}
static CompositeType initV6CompositeType(CompositeType threadInfoCompositeType) {
try {
String[] v6Names = Stream.of(V5_ATTRIBUTES, V6_ATTRIBUTES)
.flatMap(Arrays::stream).toArray(String[]::new);
OpenType<?>[] v6Types = new OpenType<?>[v6Names.length];
for (int i = 0; i < v6Names.length; i++) {
String name = v6Names[i];
OpenType<?> ot = threadInfoCompositeType.getType(name);
if (name.equals(STACK_TRACE)) {
ot = new ArrayType<>(1, StackTraceElementCompositeData.v5CompositeType());
} else if (name.equals(LOCKED_MONITORS)) {
ot = new ArrayType<>(1, MonitorInfoCompositeData.v6CompositeType());
}
v6Types[i] = ot;
}
return new CompositeType("ThreadInfo",
"JDK 6 ThreadInfo",
v6Names,
v6Names,
v6Types);
} catch (OpenDataException e) {
// Should never reach here
throw new AssertionError(e);
}
}
}
private static final long serialVersionUID = 2464378539119753175L; private static final long serialVersionUID = 2464378539119753175L;
} }

View File

@ -1,174 +0,0 @@
/*
* Copyright (c) 2015, Oracle and/or its affiliates. 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
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package sun.management;
import java.lang.management.ThreadInfo;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.function.Predicate;
import javax.management.openmbean.ArrayType;
import javax.management.openmbean.CompositeType;
import javax.management.openmbean.OpenDataException;
import javax.management.openmbean.OpenType;
import javax.management.openmbean.SimpleType;
import javax.management.openmbean.TabularType;
import static sun.management.Util.toStringArray;
/**
* Provides simplistic support for versioning of {@linkplain CompositeType} instances
* based on the latest version and filtering out certain items.
*/
final class TypeVersionMapper {
private static final class Singleton {
private final static TypeVersionMapper INSTANCE = new TypeVersionMapper();
}
final static String V5 = "J2SE 5.0";
final static String V6 = "Java SE 6";
private final Map<String, Map<String, Predicate<String>>> filterMap;
private TypeVersionMapper() {
filterMap = new HashMap<>();
setupStackTraceElement();
setupThreadInfo();
}
public static TypeVersionMapper getInstance() {
return Singleton.INSTANCE;
}
private void setupStackTraceElement() {
Map<String, Predicate<String>> filter = new HashMap<>();
filterMap.put(StackTraceElement.class.getName(), filter);
filter.put(V5, StackTraceElementCompositeData::isV6Attribute);
filter.put(V6, StackTraceElementCompositeData::isV6Attribute);
}
private void setupThreadInfo() {
Map<String, Predicate<String>> filter = new HashMap<>();
filterMap.put(ThreadInfo.class.getName(), filter);
filter.put(V5, ThreadInfoCompositeData::isV5Attribute);
filter.put(V6, ThreadInfoCompositeData::isV6Attribute);
}
/**
* Retrieves the specified version of a {@linkplain CompositeType} instance.
* @param type The current (latest) version of {@linkplain CompositeType}
* @param version The version identifier (eg. {@linkplain TypeVersionMapper#V5})
* @return Returns the {@linkplain CompositeType} corresponding to the requested
* version.
* @throws OpenDataException
*/
CompositeType getVersionedCompositeType(CompositeType type, String version)
throws OpenDataException
{
Predicate<String> filter = getFilter(type.getTypeName(), version);
if (filter == null) {
return type;
}
List<String> itemNames = new ArrayList<>();
List<String> itemDesc = new ArrayList<>();
List<OpenType<?>> itemTypes = new ArrayList<>();
for(String item : type.keySet()) {
if (filter.test(item)) {
itemNames.add(item);
itemDesc.add(type.getDescription(item));
itemTypes.add(getVersionedType(
type.getType(item),
version
));
}
}
return new CompositeType(
type.getTypeName(),
version != null ? version + " " + type.getDescription() : type.getDescription(),
itemNames.toArray(new String[itemNames.size()]),
itemDesc.toArray(new String[itemDesc.size()]),
itemTypes.toArray(new OpenType<?>[itemTypes.size()])
);
}
private OpenType<?> getVersionedType(OpenType<?> type, String version)
throws OpenDataException
{
if (type instanceof ArrayType) {
return getVersionedArrayType((ArrayType)type, version);
}
if (type instanceof CompositeType) {
return getVersionedCompositeType((CompositeType)type, version);
}
if (type instanceof TabularType) {
return getVersionedTabularType((TabularType)type, version);
}
return type;
}
private ArrayType<?> getVersionedArrayType(ArrayType<?> type, String version)
throws OpenDataException
{
if (type.isPrimitiveArray()) {
return type;
}
OpenType<?> ot = getVersionedType(
type.getElementOpenType(),
version
);
if (ot instanceof SimpleType) {
return new ArrayType<>((SimpleType<?>)ot, type.isPrimitiveArray());
} else {
return new ArrayType<>(type.getDimension(), ot);
}
}
private TabularType getVersionedTabularType(TabularType type, String version)
throws OpenDataException
{
CompositeType ct = getVersionedCompositeType(
type.getRowType(),
version
);
if (ct != null) {
return new TabularType(
type.getTypeName(), type.getDescription(), ct,
toStringArray(type.getIndexNames()));
}
return null;
}
private Predicate<String> getFilter(String type, String version) {
Map<String, Predicate<String>> versionMap = filterMap.get(type);
if (versionMap == null) {
return null;
}
return versionMap.get(version);
}
}

View File

@ -35,7 +35,6 @@ import com.sun.tools.javac.code.*;
import com.sun.tools.javac.code.Source.Feature; import com.sun.tools.javac.code.Source.Feature;
import com.sun.tools.javac.parser.Tokens.*; import com.sun.tools.javac.parser.Tokens.*;
import com.sun.tools.javac.parser.Tokens.Comment.CommentStyle; import com.sun.tools.javac.parser.Tokens.Comment.CommentStyle;
import com.sun.tools.javac.resources.CompilerProperties;
import com.sun.tools.javac.resources.CompilerProperties.Errors; import com.sun.tools.javac.resources.CompilerProperties.Errors;
import com.sun.tools.javac.resources.CompilerProperties.Fragments; import com.sun.tools.javac.resources.CompilerProperties.Fragments;
import com.sun.tools.javac.resources.CompilerProperties.Warnings; import com.sun.tools.javac.resources.CompilerProperties.Warnings;
@ -43,9 +42,7 @@ import com.sun.tools.javac.tree.*;
import com.sun.tools.javac.tree.JCTree.*; import com.sun.tools.javac.tree.JCTree.*;
import com.sun.tools.javac.util.*; import com.sun.tools.javac.util.*;
import com.sun.tools.javac.util.JCDiagnostic.DiagnosticFlag; import com.sun.tools.javac.util.JCDiagnostic.DiagnosticFlag;
import com.sun.tools.javac.util.JCDiagnostic.DiagnosticPosition;
import com.sun.tools.javac.util.JCDiagnostic.Error; import com.sun.tools.javac.util.JCDiagnostic.Error;
import com.sun.tools.javac.util.JCDiagnostic.Warning;
import com.sun.tools.javac.util.JCDiagnostic.Fragment; import com.sun.tools.javac.util.JCDiagnostic.Fragment;
import com.sun.tools.javac.util.List; import com.sun.tools.javac.util.List;
@ -58,6 +55,9 @@ import static com.sun.tools.javac.parser.Tokens.TokenKind.GT;
import static com.sun.tools.javac.parser.Tokens.TokenKind.IMPORT; import static com.sun.tools.javac.parser.Tokens.TokenKind.IMPORT;
import static com.sun.tools.javac.parser.Tokens.TokenKind.LT; import static com.sun.tools.javac.parser.Tokens.TokenKind.LT;
import static com.sun.tools.javac.tree.JCTree.Tag.*; import static com.sun.tools.javac.tree.JCTree.Tag.*;
import static com.sun.tools.javac.resources.CompilerProperties.Fragments.ImplicitAndExplicitNotAllowed;
import static com.sun.tools.javac.resources.CompilerProperties.Fragments.VarAndExplicitNotAllowed;
import static com.sun.tools.javac.resources.CompilerProperties.Fragments.VarAndImplicitNotAllowed;
/** The parser maps a token sequence into an abstract syntax /** The parser maps a token sequence into an abstract syntax
* tree. It operates by recursive descent, with code derived * tree. It operates by recursive descent, with code derived
@ -1673,8 +1673,6 @@ public class JavacParser implements Parser {
CAST, CAST,
EXPLICIT_LAMBDA, EXPLICIT_LAMBDA,
IMPLICIT_LAMBDA, IMPLICIT_LAMBDA,
IMPLICIT_LAMBDA_ALL_VAR,
BAD_LAMBDA,
PARENS PARENS
} }
@ -1682,89 +1680,77 @@ public class JavacParser implements Parser {
List<JCVariableDecl> params = explicitParams ? List<JCVariableDecl> params = explicitParams ?
formalParameters(true) : formalParameters(true) :
implicitParameters(hasParens); implicitParameters(hasParens);
if (explicitParams) { if (explicitParams) {
LambdaClassfier lambdaClassfier = new LambdaClassfier(); LambdaClassifier lambdaClassifier = new LambdaClassifier();
for (JCVariableDecl param: params) { for (JCVariableDecl param: params) {
if (param.vartype != null && if (param.vartype != null &&
isRestrictedLocalVarTypeName(param.vartype) && isRestrictedLocalVarTypeName(param.vartype) &&
param.vartype.hasTag(TYPEARRAY)) { param.vartype.hasTag(TYPEARRAY)) {
log.error(DiagnosticFlag.SYNTAX, param.pos, Errors.VarNotAllowedArray); log.error(DiagnosticFlag.SYNTAX, param.pos, Errors.VarNotAllowedArray);
} }
if (param.vartype != null && param.name != names.empty) { lambdaClassifier.addParameter(param);
if (isRestrictedLocalVarTypeName(param.vartype)) { if (lambdaClassifier.result() == LambdaParameterKind.ERROR) {
lambdaClassfier.addImplicitVarParameter();
} else {
lambdaClassfier.addExplicitParameter();
}
}
if (param.vartype == null && param.name != names.empty ||
param.vartype != null && param.name == names.empty) {
lambdaClassfier.addImplicitParameter();
}
if (lambdaClassfier.result() == ParensResult.BAD_LAMBDA) {
break; break;
} }
} }
if (lambdaClassfier.diagFragment != null) { if (lambdaClassifier.diagFragment != null) {
log.error(DiagnosticFlag.SYNTAX, pos, Errors.InvalidLambdaParameterDeclaration(lambdaClassfier.diagFragment)); log.error(DiagnosticFlag.SYNTAX, pos, Errors.InvalidLambdaParameterDeclaration(lambdaClassifier.diagFragment));
} }
} }
return lambdaExpressionOrStatementRest(params, pos); return lambdaExpressionOrStatementRest(params, pos);
} }
class LambdaClassfier { enum LambdaParameterKind {
ParensResult kind; //ParensResult.EXPLICIT_LAMBDA; EXPLICIT(0),
IMPLICIT(1),
VAR(2),
ERROR(-1);
private final int index;
LambdaParameterKind(int index) {
this.index = index;
}
}
private final static Fragment[][] decisionTable = new Fragment[][]{
/* EXPLICIT IMPLICIT VAR */
/* EXPLICIT */ {null, ImplicitAndExplicitNotAllowed, VarAndExplicitNotAllowed},
/* IMPLICIT */ {ImplicitAndExplicitNotAllowed, null, VarAndImplicitNotAllowed},
/* VAR */ {VarAndExplicitNotAllowed, VarAndImplicitNotAllowed, null}
};
class LambdaClassifier {
LambdaParameterKind kind;
Fragment diagFragment; Fragment diagFragment;
List<JCVariableDecl> params; List<JCVariableDecl> params;
void addExplicitParameter() { void addParameter(JCVariableDecl param) {
reduce(ParensResult.EXPLICIT_LAMBDA); if (param.vartype != null && param.name != names.empty) {
} if (isRestrictedLocalVarTypeName(param.vartype)) {
reduce(LambdaParameterKind.VAR);
void addImplicitVarParameter() { } else {
reduce(ParensResult.IMPLICIT_LAMBDA_ALL_VAR); reduce(LambdaParameterKind.EXPLICIT);
}
void addImplicitParameter() {
reduce(ParensResult.IMPLICIT_LAMBDA);
}
private void reduce(ParensResult newKind) {
if (kind == null) {
kind = newKind;
} else if (kind != newKind && kind != ParensResult.BAD_LAMBDA) {
ParensResult currentKind = kind;
kind = ParensResult.BAD_LAMBDA;
switch (currentKind) {
case EXPLICIT_LAMBDA:
if (newKind == ParensResult.IMPLICIT_LAMBDA) {
diagFragment = Fragments.ImplicitAndExplicitNotAllowed;
} else if (newKind == ParensResult.IMPLICIT_LAMBDA_ALL_VAR) {
diagFragment = Fragments.VarAndExplicitNotAllowed;
}
break;
case IMPLICIT_LAMBDA:
if (newKind == ParensResult.EXPLICIT_LAMBDA) {
diagFragment = Fragments.ImplicitAndExplicitNotAllowed;
} else if (newKind == ParensResult.IMPLICIT_LAMBDA_ALL_VAR) {
diagFragment = Fragments.VarAndImplicitNotAllowed;
}
break;
case IMPLICIT_LAMBDA_ALL_VAR:
if (newKind == ParensResult.EXPLICIT_LAMBDA) {
diagFragment = Fragments.VarAndExplicitNotAllowed;
} else if (newKind == ParensResult.IMPLICIT_LAMBDA) {
diagFragment = Fragments.VarAndImplicitNotAllowed;
}
break;
default:
throw new AssertionError("unexpected option for field kind");
} }
} }
if (param.vartype == null && param.name != names.empty ||
param.vartype != null && param.name == names.empty) {
reduce(LambdaParameterKind.IMPLICIT);
}
} }
ParensResult result() { private void reduce(LambdaParameterKind newKind) {
if (kind == null) {
kind = newKind;
} else if (kind != newKind && kind != LambdaParameterKind.ERROR) {
LambdaParameterKind currentKind = kind;
kind = LambdaParameterKind.ERROR;
diagFragment = decisionTable[currentKind.index][newKind.index];
}
}
LambdaParameterKind result() {
return kind; return kind;
} }
} }

View File

@ -311,15 +311,18 @@ class TaskFactory {
return fm.createSourceFileObject(w, w.classFullName(), w.wrapped()); return fm.createSourceFileObject(w, w.classFullName(), w.wrapped());
} }
/**
* Get the source information from the wrap. If this is external, or
* otherwise does not have wrap info, just use source code.
* @param d the Diagnostic from the compiler
* @return the corresponding Diag
*/
@Override @Override
public Diag diag(Diagnostic<? extends JavaFileObject> d) { public Diag diag(Diagnostic<? extends JavaFileObject> d) {
SourceMemoryJavaFileObject smjfo = (SourceMemoryJavaFileObject) d.getSource(); JavaFileObject jfo = d.getSource();
if (smjfo == null) { return jfo instanceof SourceMemoryJavaFileObject
// Handle failure that doesn't preserve mapping ? ((OuterWrap) ((SourceMemoryJavaFileObject) jfo).getOrigin()).wrapDiag(d)
return new StringSourceHandler().diag(d); : new StringSourceHandler().diag(d);
}
OuterWrap w = (OuterWrap) smjfo.getOrigin();
return w.wrapDiag(d);
} }
} }

View File

@ -111,8 +111,10 @@
# jdk_awt # jdk_awt
java/awt/BasicStroke/DashScaleMinWidth.java 8198411 windows-all
java/awt/BasicStroke/DashZeroWidth.java 8198411 windows-all
java/awt/event/MouseEvent/MouseClickTest/MouseClickTest.html 8168389 windows-all,macosx-all java/awt/event/MouseEvent/MouseClickTest/MouseClickTest.html 8168389 windows-all,macosx-all
java/awt/Focus/ActualFocusedWindowTest/ActualFocusedWindowBlockingTest.java 8168408 windows-all java/awt/Focus/ActualFocusedWindowTest/ActualFocusedWindowBlockingTest.java 8168408 windows-all,macosx-all
java/awt/Focus/FocusOwnerFrameOnClick/FocusOwnerFrameOnClick.java 8081489 generic-all java/awt/Focus/FocusOwnerFrameOnClick/FocusOwnerFrameOnClick.java 8081489 generic-all
java/awt/Focus/IconifiedFrameFocusChangeTest/IconifiedFrameFocusChangeTest.java 6849364 generic-all java/awt/Focus/IconifiedFrameFocusChangeTest/IconifiedFrameFocusChangeTest.java 6849364 generic-all
java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusToFrontTest.java 6848406 generic-all java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusToFrontTest.java 6848406 generic-all
@ -120,28 +122,62 @@ java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusSetVisibleTest.java 6848407
java/awt/Frame/MaximizedUndecorated/MaximizedUndecorated.java 8022302 generic-all java/awt/Frame/MaximizedUndecorated/MaximizedUndecorated.java 8022302 generic-all
java/awt/FileDialog/FileDialogIconTest/FileDialogIconTest.java 8160558 windows-all java/awt/FileDialog/FileDialogIconTest/FileDialogIconTest.java 8160558 windows-all
java/awt/FileDialog/8003399/bug8003399.java 8198334 windows-all
java/awt/event/MouseWheelEvent/InfiniteRecursion/InfiniteRecursion.java 8060176 windows-all,macosx-all java/awt/event/MouseWheelEvent/InfiniteRecursion/InfiniteRecursion.java 8060176 windows-all,macosx-all
java/awt/event/MouseWheelEvent/InfiniteRecursion/InfiniteRecursion_1.java 8060176 windows-all,macosx-all java/awt/event/MouseWheelEvent/InfiniteRecursion/InfiniteRecursion_1.java 8060176 windows-all,macosx-all
java/awt/dnd/BadSerializaionTest/BadSerializationTest.java 8039082 generic-all java/awt/dnd/BadSerializaionTest/BadSerializationTest.java 8039082 generic-all
java/awt/Focus/ChoiceFocus/ChoiceFocus.java 8169103 windows-all java/awt/dnd/MissingEventsOnModalDialog/MissingEventsOnModalDialogTest.java 8164464 linux-all,macosx-all
java/awt/dnd/URIListBetweenJVMsTest/URIListBetweenJVMsTest.html 8171510 macosx-all
java/awt/dnd/7171812/bug7171812.java 8041447 macosx-all
java/awt/Focus/ChoiceFocus/ChoiceFocus.java 8169103 windows-all,macosx-all
java/awt/Focus/ClearLwQueueBreakTest/ClearLwQueueBreakTest.java 8198618 macosx-all
java/awt/Focus/ConsumeNextKeyTypedOnModalShowTest/ConsumeNextKeyTypedOnModalShowTest.java 6986252 macosx-all
java/awt/Focus/FocusTraversalPolicy/ButtonGroupLayoutTraversal/ButtonGroupLayoutTraversalTest.java 8198619 macosx-all
java/awt/Focus/KeyEventForBadFocusOwnerTest/KeyEventForBadFocusOwnerTest.java 8198621 macosx-all
java/awt/Focus/MouseClickRequestFocusRaceTest/MouseClickRequestFocusRaceTest.java 8194753 linux-all,macosx-all
java/awt/Focus/NoAutotransferToDisabledCompTest/NoAutotransferToDisabledCompTest.java 7152980 macosx-all
java/awt/Focus/ShowFrameCheckForegroundTest/ShowFrameCheckForegroundTest.java 8028701 macosx-all
java/awt/Focus/SimpleWindowActivationTest/SimpleWindowActivationTest.java 8159599 macosx-all
java/awt/Focus/TypeAhead/TestFocusFreeze.java 8198622 macosx-all
java/awt/Focus/WrongKeyTypedConsumedTest/WrongKeyTypedConsumedTest.java 8169096 macosx-all
java/awt/event/KeyEvent/CorrectTime/CorrectTime.java 6626492 generic-all java/awt/event/KeyEvent/CorrectTime/CorrectTime.java 6626492 generic-all
java/awt/EventQueue/6980209/bug6980209.java 8198615 macosx-all
java/awt/Frame/MaximizedToUnmaximized/MaximizedToUnmaximized.java 8129569 generic-all java/awt/Frame/MaximizedToUnmaximized/MaximizedToUnmaximized.java 8129569 generic-all
java/awt/Frame/ExceptionOnSetExtendedStateTest/ExceptionOnSetExtendedStateTest.java 8198237 macosx-all
java/awt/Frame/ShapeNotSetSometimes/ShapeNotSetSometimes.java 8144030 macosx-all
java/awt/Frame/UnfocusableMaximizedFrameResizablity/UnfocusableMaximizedFrameResizablity.java 7158623 macosx-all
java/awt/grab/EmbeddedFrameTest1/EmbeddedFrameTest1.java 7080150 macosx-all
java/awt/event/InputEvent/EventWhenTest/EventWhenTest.java 8168646 generic-all java/awt/event/InputEvent/EventWhenTest/EventWhenTest.java 8168646 generic-all
java/awt/KeyboardFocusmanager/TypeAhead/EnqueueWithDialogButtonTest/EnqueueWithDialogButtonTest.java 8198623 macosx-all
java/awt/KeyboardFocusmanager/TypeAhead/FreezeTest/FreezeTest.java 8198623 macosx-all
java/awt/KeyboardFocusmanager/TypeAhead/SubMenuShowTest/SubMenuShowTest.html 8198624 macosx-all
java/awt/KeyboardFocusmanager/TypeAhead/TestDialogTypeAhead.html 8198626 macosx-all
java/awt/Mixing/AWT_Mixing/HierarchyBoundsListenerMixingTest.java 8049405 macosx-all
java/awt/Mixing/AWT_Mixing/OpaqueOverlappingChoice.java 8048171 generic-all java/awt/Mixing/AWT_Mixing/OpaqueOverlappingChoice.java 8048171 generic-all
java/awt/Mixing/AWT_Mixing/JMenuBarOverlapping.java 8159451 linux-all,windows-all java/awt/Mixing/AWT_Mixing/JMenuBarOverlapping.java 8159451 linux-all,windows-all,macosx-all
java/awt/Mixing/AWT_Mixing/JSplitPaneOverlapping.java 6986109 windows-all java/awt/Mixing/AWT_Mixing/JSplitPaneOverlapping.java 6986109 windows-all
java/awt/Mixing/AWT_Mixing/JInternalFrameMoveOverlapping.java 6986109 windows-all java/awt/Mixing/AWT_Mixing/JInternalFrameMoveOverlapping.java 6986109 windows-all
java/awt/Mixing/AWT_Mixing/JSplitPaneOverlapping.java 8194765 windows-all java/awt/Mixing/AWT_Mixing/JSplitPaneOverlapping.java 8194765 windows-all,macosx-all
java/awt/Mixing/AWT_Mixing/MixingPanelsResizing.java 8049405 generic-all java/awt/Mixing/AWT_Mixing/MixingPanelsResizing.java 8049405 generic-all
java/awt/Mixing/AWT_Mixing/JComboBoxOverlapping.java 8049405 macosx-all
java/awt/Mixing/AWT_Mixing/JPopupMenuOverlapping.java 8049405 macosx-all
java/awt/Mixing/NonOpaqueInternalFrame.java 7124549 macosx-all
java/awt/Focus/ActualFocusedWindowTest/ActualFocusedWindowRetaining.java 6829264 generic-all java/awt/Focus/ActualFocusedWindowTest/ActualFocusedWindowRetaining.java 6829264 generic-all
java/awt/datatransfer/DragImage/MultiResolutionDragImageTest.java 8080982 generic-all java/awt/datatransfer/DragImage/MultiResolutionDragImageTest.java 8080982 generic-all
java/awt/datatransfer/SystemFlavorMap/AddFlavorTest.java 8079268 linux-all
java/awt/Toolkit/ScreenInsetsTest/ScreenInsetsTest.java 6829250 windows-all java/awt/Toolkit/ScreenInsetsTest/ScreenInsetsTest.java 6829250 windows-all
java/awt/Toolkit/RealSync/Test.java 6849383 macosx-all
java/awt/LightweightComponent/LightweightEventTest/LightweightEventTest.java 8159252 windows-all java/awt/LightweightComponent/LightweightEventTest/LightweightEventTest.java 8159252 windows-all
java/awt/EventDispatchThread/HandleExceptionOnEDT/HandleExceptionOnEDT.java 6990210 generic-all java/awt/EventDispatchThread/HandleExceptionOnEDT/HandleExceptionOnEDT.java 6990210 generic-all
java/awt/EventDispatchThread/LoopRobustness/LoopRobustness.html 4931413 windows-all java/awt/EventDispatchThread/LoopRobustness/LoopRobustness.html 4931413 windows-all
java/awt/FullScreen/FullScreenInsets/FullScreenInsets.java 7019055 windows-all java/awt/FullScreen/FullScreenInsets/FullScreenInsets.java 7019055 windows-all
java/awt/Focus/8013611/JDK8013611.java 8175366 windows-all java/awt/FullScreen/UninitializedDisplayModeChangeTest/UninitializedDisplayModeChangeTest.java 8198335 windows-all
java/awt/Focus/6981400/Test1.java 8029675 windows-all java/awt/Focus/8013611/JDK8013611.java 8175366 windows-all,macosx-all
java/awt/Focus/6378278/InputVerifierTest.java 8198616 macosx-all
java/awt/Focus/6382144/EndlessLoopTest.java 8198617 macosx-all
java/awt/Focus/6981400/Test1.java 8029675 windows-all,macosx-all
java/awt/Focus/8073453/AWTFocusTransitionTest.java 8136517 macosx-all
java/awt/Focus/8073453/SwingFocusTransitionTest.java 8136517 macosx-all
java/awt/Focus/6981400/Test3.java 8173264 generic-all java/awt/Focus/6981400/Test3.java 8173264 generic-all
java/awt/event/KeyEvent/ExtendedKeyCode/ExtendedKeyCodeTest.java 8169476 windows-all java/awt/event/KeyEvent/ExtendedKeyCode/ExtendedKeyCodeTest.java 8169476 windows-all
java/awt/event/KeyEvent/KeyChar/KeyCharTest.java 8169474 windows-all java/awt/event/KeyEvent/KeyChar/KeyCharTest.java 8169474 windows-all
@ -152,8 +188,8 @@ java/awt/event/MouseEvent/MouseButtonsAndKeyMasksTest/MouseButtonsAndKeyMasksTes
java/awt/dnd/URIListToFileListBetweenJVMsTest/URIListToFileListBetweenJVMsTest.html 8194947 generic-all java/awt/dnd/URIListToFileListBetweenJVMsTest/URIListToFileListBetweenJVMsTest.html 8194947 generic-all
java/awt/dnd/ImageTransferTest/ImageTransferTest.java 8176556 generic-all java/awt/dnd/ImageTransferTest/ImageTransferTest.java 8176556 generic-all
java/awt/Dialog/MakeWindowAlwaysOnTop/MakeWindowAlwaysOnTop.java 7054585 generic-all
java/awt/Frame/SetMaximizedBounds/SetMaximizedBounds.java 8196006 windows-all java/awt/Frame/SetMaximizedBounds/SetMaximizedBounds.java 8196006 windows-all
java/awt/Frame/FramesGC/FramesGC.java 8079069 macosx-all
java/awt/FullScreen/AltTabCrashTest/AltTabCrashTest.java 8047218 generic-all java/awt/FullScreen/AltTabCrashTest/AltTabCrashTest.java 8047218 generic-all
java/awt/GridLayout/LayoutExtraGaps/LayoutExtraGaps.java 8000171 windows-all java/awt/GridLayout/LayoutExtraGaps/LayoutExtraGaps.java 8000171 windows-all
java/awt/Mouse/GetMousePositionTest/GetMousePositionWithPopup.java 8196017 windows-all java/awt/Mouse/GetMousePositionTest/GetMousePositionWithPopup.java 8196017 windows-all
@ -161,7 +197,7 @@ java/awt/Scrollbar/ScrollbarMouseWheelTest/ScrollbarMouseWheelTest.java 8196018
java/awt/TrayIcon/ActionCommand/ActionCommand.java 8150540 windows-all java/awt/TrayIcon/ActionCommand/ActionCommand.java 8150540 windows-all
java/awt/TrayIcon/ActionEventMask/ActionEventMask.java 8150540 windows-all java/awt/TrayIcon/ActionEventMask/ActionEventMask.java 8150540 windows-all
java/awt/TrayIcon/ActionEventTest/ActionEventTest.java 8150540 windows-all java/awt/TrayIcon/ActionEventTest/ActionEventTest.java 8150540 windows-all
java/awt/TrayIcon/ModalityTest/ModalityTest.java 8150540 windows-all java/awt/TrayIcon/ModalityTest/ModalityTest.java 8150540 windows-all,macosx-all
java/awt/TrayIcon/MouseEventMask/MouseEventMaskTest.java 8150540 windows-all java/awt/TrayIcon/MouseEventMask/MouseEventMaskTest.java 8150540 windows-all
java/awt/TrayIcon/MouseEventMask/MouseEventMovedTest.java 8150540 windows-all java/awt/TrayIcon/MouseEventMask/MouseEventMovedTest.java 8150540 windows-all
java/awt/TrayIcon/MouseMovedTest/MouseMovedTest.java 8150540 windows-all java/awt/TrayIcon/MouseMovedTest/MouseMovedTest.java 8150540 windows-all
@ -169,102 +205,275 @@ java/awt/TrayIcon/SecurityCheck/FunctionalityCheck/FunctionalityCheck.java 81505
java/awt/TrayIcon/TrayIconEventModifiers/TrayIconEventModifiersTest.java 8150540 windows-all java/awt/TrayIcon/TrayIconEventModifiers/TrayIconEventModifiersTest.java 8150540 windows-all
java/awt/TrayIcon/TrayIconEvents/TrayIconEventsTest.java 8150540 windows-all java/awt/TrayIcon/TrayIconEvents/TrayIconEventsTest.java 8150540 windows-all
java/awt/TrayIcon/TrayIconMouseTest/TrayIconMouseTest.java 8150540 windows-all java/awt/TrayIcon/TrayIconMouseTest/TrayIconMouseTest.java 8150540 windows-all
java/awt/TrayIcon/TrayIconPopup/TrayIconPopupClickTest.java 8150540 windows-all java/awt/TrayIcon/TrayIconPopup/TrayIconPopupClickTest.java 8150540 windows-all,macosx-all
java/awt/TrayIcon/TrayIconPopup/TrayIconPopupTest.java 8150540 windows-all java/awt/TrayIcon/TrayIconPopup/TrayIconPopupTest.java 8150540 windows-all
java/awt/TrayIcon/PopupMenuLeakTest/PopupMenuLeakTest.java 8196440 linux-all java/awt/TrayIcon/PopupMenuLeakTest/PopupMenuLeakTest.java 8196440 linux-all
java/awt/Window/Grab/GrabTest.java 8196019 windows-all java/awt/Window/Grab/GrabTest.java 8196019 windows-all
java/awt/Window/ShapedAndTranslucentWindows/ShapedTranslucentWindowClick.java 8196020 windows-all java/awt/Window/ShapedAndTranslucentWindows/ShapedTranslucentWindowClick.java 8196020 windows-all
java/awt/Window/ShapedAndTranslucentWindows/FocusAWTTest.java 8061236 macosx-all
java/awt/Window/ShapedAndTranslucentWindows/SetShapeAndClick.java 8197936 macosx-all
java/awt/Window/ShapedAndTranslucentWindows/SetShapeDynamicallyAndClick.java 8013450 macosx-all
java/awt/Window/ShapedAndTranslucentWindows/Shaped.java 8078999 macosx-all
java/awt/Window/ShapedAndTranslucentWindows/ShapedByAPI.java 8078999 macosx-all
java/awt/Window/ShapedAndTranslucentWindows/ShapedTranslucent.java 8078999 macosx-all
java/awt/Window/ShapedAndTranslucentWindows/ShapedTranslucentWindowClick.java 8196020 macosx-all
java/awt/Window/ShapedAndTranslucentWindows/StaticallyShaped.java 8165218 macosx-all
java/awt/Window/AlwaysOnTop/AutoTestOnTop.java 6847593 macosx-all
java/awt/Window/GrabSequence/GrabSequence.java 6848409 macosx-all
java/awt/font/TextLayout/CombiningPerf.java 8192931 generic-all java/awt/font/TextLayout/CombiningPerf.java 8192931 generic-all
java/awt/font/TextLayout/TextLayoutBounds.java 8169188 macosx-all
java/awt/font/MonospacedGlyphWidth/MonospacedGlyphWidthTest.java 8198412 linux-all,solaris-all
java/awt/font/StyledMetrics/BoldSpace.java 8198422 linux-all
java/awt/FontMetrics/FontCrash.java 8198336 windows-all
java/awt/image/DrawImage/IncorrectAlphaSurface2SW.java 8056077 generic-all java/awt/image/DrawImage/IncorrectAlphaSurface2SW.java 8056077 generic-all
java/awt/image/DrawImage/IncorrectClipXorModeSW2Surface.java 8196025 windows-all java/awt/image/DrawImage/IncorrectClipXorModeSW2Surface.java 8196025 windows-all
java/awt/image/DrawImage/IncorrectClipXorModeSurface2Surface.java 8196025 windows-all java/awt/image/DrawImage/IncorrectClipXorModeSurface2Surface.java 8196025 windows-all
java/awt/image/DrawImage/IncorrectSourceOffset.java 8196086 windows-all java/awt/image/DrawImage/IncorrectSourceOffset.java 8196086 windows-all
java/awt/image/DrawImage/IncorrectUnmanagedImageRotatedClip.java 8196087 windows-all java/awt/image/DrawImage/IncorrectUnmanagedImageRotatedClip.java 8196087 windows-all
java/awt/image/MultiResolutionImage/MultiResolutionDrawImageWithTransformTest.java 8198390 generic-all
java/awt/image/multiresolution/MultiresolutionIconTest.java 8169187 macosx-all
java/awt/print/Headless/HeadlessPrinterJob.java 8196088 windows-all java/awt/print/Headless/HeadlessPrinterJob.java 8196088 windows-all
java/awt/print/PrinterJob/TestPgfmtSetMPA.java 8198343 generic-all
sun/awt/datatransfer/SuplementaryCharactersTransferTest.java 8011371 generic-all
sun/awt/shell/ShellFolderMemoryLeak.java 8197794 windows-all
sun/java2d/DirectX/OnScreenRenderingResizeTest/OnScreenRenderingResizeTest.java 8022403 generic-all sun/java2d/DirectX/OnScreenRenderingResizeTest/OnScreenRenderingResizeTest.java 8022403 generic-all
sun/java2d/DirectX/OverriddenInsetsTest/OverriddenInsetsTest.java 8196102 generic-all sun/java2d/DirectX/OverriddenInsetsTest/OverriddenInsetsTest.java 8196102 generic-all
sun/java2d/DirectX/RenderingToCachedGraphicsTest/RenderingToCachedGraphicsTest.java 8196180 windows-all sun/java2d/DirectX/RenderingToCachedGraphicsTest/RenderingToCachedGraphicsTest.java 8196180 windows-all
sun/java2d/GdiRendering/InsetClipping.java 8196181 windows-all sun/java2d/GdiRendering/InsetClipping.java 8196181 windows-all
sun/java2d/OpenGL/CopyAreaOOB.java 7001973 windows-all sun/java2d/OpenGL/CopyAreaOOB.java 7001973 windows-all,macosx-all
sun/java2d/SunGraphics2D/EmptyClipRenderingTest.java 8144029 macosx-all
sun/java2d/SunGraphics2D/DrawImageBilinear.java 8191506 generic-all sun/java2d/SunGraphics2D/DrawImageBilinear.java 8191506 generic-all
sun/java2d/SunGraphics2D/PolyVertTest.java 6986565 generic-all sun/java2d/SunGraphics2D/PolyVertTest.java 6986565 generic-all
sun/java2d/SunGraphics2D/SimplePrimQuality.java 7992007 generic-all sun/java2d/SunGraphics2D/SimplePrimQuality.java 7992007 generic-all
sun/java2d/SunGraphics2D/SourceClippingBlitTest/SourceClippingBlitTest.java 8196191 windows-all sun/java2d/SunGraphics2D/SourceClippingBlitTest/SourceClippingBlitTest.java 8196191 windows-all,macosx-all
sun/java2d/pipe/InterpolationQualityTest.java 8171303 windows-all,linux-all sun/java2d/pipe/InterpolationQualityTest.java 8171303 windows-all,linux-all,macosx-all
java/awt/FullScreen/BufferStrategyExceptionTest/BufferStrategyExceptionTest.java 8196186 windows-all java/awt/FullScreen/BufferStrategyExceptionTest/BufferStrategyExceptionTest.java 8196186 windows-all
java/awt/FullScreen/DisplayChangeVITest/DisplayChangeVITest.java 8169469 windows-all java/awt/FullScreen/DisplayChangeVITest/DisplayChangeVITest.java 8169469 windows-all
java/awt/FullScreen/NonExistentDisplayModeTest/NonExistentDisplayModeTest.java 8196187 windows-all java/awt/FullScreen/NonExistentDisplayModeTest/NonExistentDisplayModeTest.java 8196187 windows-all
java/awt/Graphics/ClippedCopyAreaTest/ClippedCopyAreaTest.java 8196436 linux-all java/awt/Graphics/ClippedCopyAreaTest/ClippedCopyAreaTest.java 8196436 linux-all
java/awt/Graphics/CopyScaledArea/CopyScaledAreaTest.java 8196189 windows-all java/awt/Graphics/CopyScaledArea/CopyScaledAreaTest.java 8196189 windows-all
java/awt/Graphics2D/DrawString/DrawRotatedStringUsingRotatedFont.java 8197796 generic-all
java/awt/GraphicsDevice/CloneConfigsTest.java 8196190 windows-all java/awt/GraphicsDevice/CloneConfigsTest.java 8196190 windows-all
java/awt/TextArea/TextAreaScrolling/TextAreaScrolling.java 8196300 windows-all java/awt/TextArea/TextAreaScrolling/TextAreaScrolling.java 8196300 windows-all
java/awt/print/PrinterJob/Margins.java 8196301 windows-all java/awt/print/PrinterJob/Margins.java 8196301 windows-all
java/awt/print/PrinterJob/PSQuestionMark.java 7003378 windows-all
java/awt/print/PrinterJob/GlyphPositions.java 7003378 windows-all
java/awt/Choice/PopupPosTest/PopupPosTest.html 8192930 windows-all java/awt/Choice/PopupPosTest/PopupPosTest.html 8192930 windows-all
java/awt/Choice/ChoiceKeyEventReaction/ChoiceKeyEventReaction.html 6849922 macosx-all
java/awt/Choice/ChoiceMouseWheelTest/ChoiceMouseWheelTest.java 7100044 macosx-all
java/awt/Component/CreateImage/CreateImage.java 8198334 windows-all
java/awt/Component/GetScreenLocTest.java 4753654 windows-all java/awt/Component/GetScreenLocTest.java 4753654 windows-all
java/awt/Choice/SelectCurrentItemTest/SelectCurrentItemTest.html 8192929 windows-all java/awt/Choice/SelectCurrentItemTest/SelectCurrentItemTest.html 8192929 windows-all
java/awt/Dialog/MakeWindowAlwaysOnTop/MakeWindowAlwaysOnTop.java 7054586 windows-all java/awt/Clipboard/HTMLTransferTest/HTMLTransferTest.html 8017454 macosx-all
java/awt/Dialog/SiblingChildOrder/SiblingChildOrderTest.java 8193940 windows-all java/awt/Dialog/SiblingChildOrder/SiblingChildOrderTest.java 8193940 windows-all
java/awt/Focus/NonFocusableWindowTest/NoEventsTest.java 8000171 windows-all java/awt/Focus/NonFocusableWindowTest/NoEventsTest.java 8000171 windows-all
java/awt/Frame/MiscUndecorated/RepaintTest.java 8079267 windows-all java/awt/Frame/MiscUndecorated/RepaintTest.java 8079267 windows-all
java/awt/Robot/ModifierRobotKey/ModifierRobotKeyTest.java 8157173 windows-all java/awt/Robot/ModifierRobotKey/ModifierRobotKeyTest.java 8157173 windows-all
java/awt/Modal/FileDialog/FileDialogAppModal1Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogAppModal2Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogAppModal3Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogAppModal4Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogAppModal5Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogAppModal6Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogDocModal1Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogDocModal2Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogDocModal3Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogDocModal4Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogDocModal5Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogDocModal6Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogDocModal7Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogModal1Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogModal2Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogModal3Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogModal4Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogModal5Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogModal6Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogNonModal1Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogNonModal2Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogNonModal3Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogNonModal4Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogNonModal5Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogNonModal6Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogNonModal7Test.java 8198664 macosx-all
java/awt/Modal/FileDialog/FileDialogTKModal1Test.java 8196430 generic-all java/awt/Modal/FileDialog/FileDialogTKModal1Test.java 8196430 generic-all
java/awt/Modal/FileDialog/FileDialogTKModal2Test.java 8196430 generic-all java/awt/Modal/FileDialog/FileDialogTKModal2Test.java 8196430 generic-all
java/awt/Modal/FileDialog/FileDialogTKModal3Test.java 8196430 generic-all java/awt/Modal/FileDialog/FileDialogTKModal3Test.java 8196430 generic-all
java/awt/Modal/FileDialog/FileDialogTKModal4Test.java 8196430 generic-all java/awt/Modal/FileDialog/FileDialogTKModal4Test.java 8196430 generic-all
java/awt/Modal/FileDialog/FileDialogTKModal5Test.java 8196430 generic-all java/awt/Modal/FileDialog/FileDialogTKModal5Test.java 8196430 generic-all
java/awt/Modal/FileDialog/FileDialogTKModal6Test.java 8196430 generic-all java/awt/Modal/FileDialog/FileDialogTKModal6Test.java 8196430 generic-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeDialogPageSetupTest.java 8196431 linux-all java/awt/Modal/FileDialog/FileDialogTKModal7Test.java 8196430 macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeDialogPrintSetupTest.java 8196431 linux-all java/awt/Modal/ModalBlockingTests/BlockingDDAppModalTest.java 8198665 macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeFramePageSetupTest.java 8196431 linux-all java/awt/Modal/ModalBlockingTests/BlockingDDDocModalTest.java 8198665 macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeFramePrintSetupTest.java 8196431 linux-all java/awt/Modal/ModalBlockingTests/BlockingDDModelessTest.java 8198665 macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeDialogPageSetupTest.java 8196431 linux-all java/awt/Modal/ModalBlockingTests/BlockingDDNonModalTest.java 8198665 macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeDialogPrintSetupTest.java 8196431 linux-all java/awt/Modal/ModalBlockingTests/BlockingDDSetModalTest.java 8198665 macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeFramePageSetupTest.java 8196431 linux-all java/awt/Modal/ModalBlockingTests/BlockingDDToolkitModalTest.java 8198665 macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeFramePrintSetupTest.java 8196431 linux-all java/awt/Modal/ModalBlockingTests/BlockingDFAppModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingDFSetModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingDFToolkitModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingDFWModeless1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingDFWModeless2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingDFWNonModal1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingDFWNonModal2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingDocModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDModelessTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDNonModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWDocModal1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWDocModal2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWDocModal3Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWDocModal4Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWModeless1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWModeless2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWModeless3Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWModeless4Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWNonModal1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWNonModal2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWNonModal3Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingFDWNonModal4Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsAppModal1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsAppModal2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsAppModal3Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsAppModal4Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsAppModal5Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsAppModal6Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsDocModal1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsDocModal2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsSetModal1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsSetModal2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsSetModal3Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsSetModal4Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsSetModal5Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsSetModal6Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsToolkitModal1Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsToolkitModal2Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsToolkitModal3Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsToolkitModal4Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsToolkitModal5Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/BlockingWindowsToolkitModal6Test.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/UnblockedDialogAppModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/UnblockedDialogDocModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/UnblockedDialogModelessTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/UnblockedDialogNonModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/UnblockedDialogSetModalTest.java 8198665 macosx-all
java/awt/Modal/ModalBlockingTests/UnblockedDialogToolkitModalTest.java 8198665 macosx-all
java/awt/Modal/ModalDialogOrderingTest/ModalDialogOrderingTest.java 8066259 macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeFrameFileTest.java 8047179 macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeDialogFileTest.java 8047179 macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeDialogPageSetupTest.java 8196431 linux-all,macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeDialogPrintSetupTest.java 8196431 linux-all,macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeFramePageSetupTest.java 8196431 linux-all,macosx-all
java/awt/Modal/ModalExclusionTests/ApplicationExcludeFramePrintSetupTest.java 8196431 linux-all,macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeFrameFileTest.java 8047179 macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeDialogFileTest.java 8196431 macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeDialogPageSetupTest.java 8196431 linux-all,macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeDialogPrintSetupTest.java 8196431 linux-all,macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeFramePageSetupTest.java 8196431 linux-all,macosx-all
java/awt/Modal/ModalExclusionTests/ToolkitExcludeFramePrintSetupTest.java 8196431 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferWDFAppModal2Test.java 8058813 windows-all java/awt/Modal/ModalFocusTransferTests/FocusTransferWDFAppModal2Test.java 8058813 windows-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferWDFModeless2Test.java 8196191 windows-all java/awt/Modal/ModalFocusTransferTests/FocusTransferWDFModeless2Test.java 8196191 windows-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferDWFDocModalTest.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferDWFDocModalTest.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferDWFModelessTest.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferDWFModelessTest.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferDWFNonModalTest.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferDWFNonModalTest.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferDialogsModelessTest.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferDialogsModelessTest.java 8196432 linux-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferDialogsNonModalTest.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferDialogsNonModalTest.java 8196432 linux-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFDWDocModalTest.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFDWDocModalTest.java 8196432 linux-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFDWModelessTest.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFDWModelessTest.java 8196432 linux-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFDWNonModalTest.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFDWNonModalTest.java 8196432 linux-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDAppModal1Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDAppModal1Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDAppModal2Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDAppModal2Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDAppModal3Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDAppModal3Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDAppModal4Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDAppModal4Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDDocModal1Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDDocModal1Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDDocModal2Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDDocModal2Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDDocModal3Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDDocModal3Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDDocModal4Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDDocModal4Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDModeless1Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDModeless1Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDModeless2Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDModeless2Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDModeless3Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDModeless3Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDModeless4Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDModeless4Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDNonModal1Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDNonModal1Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDNonModal2Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDNonModal2Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDNonModal3Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDNonModal3Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDNonModal4Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferFWDNonModal4Test.java 8196432 linux-all,macosx-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferWDFDocModal2Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferWDFDocModal2Test.java 8196432 linux-all
java/awt/Modal/ModalFocusTransferTests/FocusTransferWDFNonModal2Test.java 8196432 linux-all java/awt/Modal/ModalFocusTransferTests/FocusTransferWDFNonModal2Test.java 8196432 linux-all
java/awt/Modal/MultipleDialogs/MultipleDialogs1Test.java 8198665 macosx-all
java/awt/Modal/MultipleDialogs/MultipleDialogs2Test.java 8198665 macosx-all
java/awt/Modal/MultipleDialogs/MultipleDialogs3Test.java 8198665 macosx-all
java/awt/Modal/MultipleDialogs/MultipleDialogs4Test.java 8198665 macosx-all
java/awt/Modal/MultipleDialogs/MultipleDialogs5Test.java 8198665 macosx-all
java/awt/Mouse/GetMousePositionTest/GetMousePositionWithOverlay.java 8196435 linux-all java/awt/Mouse/GetMousePositionTest/GetMousePositionWithOverlay.java 8196435 linux-all
java/awt/Mouse/EnterExitEvents/DragWindowOutOfFrameTest.java 8177326 macosx-all
java/awt/Mouse/EnterExitEvents/DragWindowTest.java 8023562 macosx-all
java/awt/Mouse/EnterExitEvents/ResizingFrameTest.java 8005021 macosx-all
java/awt/Mouse/EnterExitEvents/FullscreenEnterEventTest.java 8051455 macosx-all
java/awt/Mouse/MouseModifiersUnitTest/MouseModifiersUnitTest_Standard.java 7124407 macosx-all
java/awt/Mouse/RemovedComponentMouseListener/RemovedComponentMouseListener.java 8157170 macosx-all
java/awt/Focus/ForwardingFocusToProxyMotifTest/ForwardingFocusToProxyMotifTest.java 8196436 linux-all java/awt/Focus/ForwardingFocusToProxyMotifTest/ForwardingFocusToProxyMotifTest.java 8196436 linux-all
java/awt/Window/OverrideRedirectRemoved/ChildWindowProblem.java 8196438 linux-all java/awt/Window/OverrideRedirectRemoved/ChildWindowProblem.java 8196438 linux-all
java/awt/Modal/ToBack/ToBackAppModal1Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackAppModal1Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackAppModal2Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackAppModal2Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackAppModal3Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackAppModal3Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackAppModal4Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackAppModal4Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackModal1Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackAppModal5Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackModal2Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackModal1Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackModal3Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackModal2Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackModal4Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackModal3Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackTKModal1Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackModal4Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackTKModal2Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackTKModal1Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackTKModal3Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackTKModal2Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackTKModal4Test.java 8196441 linux-all java/awt/Modal/ToBack/ToBackTKModal3Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackTKModal4Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackTKModal5Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackDocModal1Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackDocModal2Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackDocModal3Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackDocModal4Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackDocModal5Test.java 8196441 linux-all,macosx-all
java/awt/Modal/ToBack/ToBackModeless1Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackModeless2Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackModeless3Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackModeless4Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackModeless5Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackNonModal1Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackNonModal2Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackNonModal3Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackNonModal4Test.java 8196441 macosx-all
java/awt/Modal/ToBack/ToBackNonModal5Test.java 8196441 macosx-all
java/awt/Modal/OnTop/OnTopAppModal1Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopAppModal2Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopAppModal3Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopAppModal4Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopAppModal5Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopAppModal6Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopDocModal1Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopDocModal2Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopDocModal3Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopDocModal4Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopDocModal5Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopDocModal6Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModal1Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModal2Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModal3Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModal4Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModal5Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModal6Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModal6Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModeless1Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModeless2Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModeless3Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModeless4Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModeless5Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopModeless6Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopTKModal1Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopTKModal2Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopTKModal3Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopTKModal4Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopTKModal5Test.java 8198666 macosx-all
java/awt/Modal/OnTop/OnTopTKModal6Test.java 8198666 macosx-all
java/awt/List/SingleModeDeselect/SingleModeDeselect.java 8196301 windows-all java/awt/List/SingleModeDeselect/SingleModeDeselect.java 8196301 windows-all
java/awt/SplashScreen/MultiResolutionSplash/MultiResolutionSplashTest.java 8061235 macosx-all
javax/print/PrintSEUmlauts/PrintSEUmlauts.java 8135174 generic-all
############################################################################ ############################################################################
@ -274,6 +483,8 @@ java/awt/List/SingleModeDeselect/SingleModeDeselect.java 8196301 windows-all
java/beans/Introspector/8132566/OverridePropertyInfoTest.java 8132565 generic-all java/beans/Introspector/8132566/OverridePropertyInfoTest.java 8132565 generic-all
java/beans/Introspector/8132566/OverrideUserDefPropertyInfoTest.java 8132565 generic-all java/beans/Introspector/8132566/OverrideUserDefPropertyInfoTest.java 8132565 generic-all
java/beans/XMLEncoder/Test6570354.java 8015593 macosx-all
############################################################################ ############################################################################
# jdk_lang # jdk_lang
@ -403,52 +614,91 @@ javax/sound/sampled/Mixers/DisabledAssertionCrash.java 7067310 generic-all
# jdk_swing # jdk_swing
com/sun/java/swing/plaf/windows/Test8173145.java 8198334 windows-all
javax/swing/border/Test6981576.java 8198339 generic-all
javax/swing/JComponent/7154030/bug7154030.java 7190978 generic-all javax/swing/JComponent/7154030/bug7154030.java 7190978 generic-all
javax/swing/JInternalFrame/8160248/JInternalFrameDraggingTest.java 8186513 generic-all
javax/swing/JComboBox/ConsumedKeyTest/ConsumedKeyTest.java 8067986 generic-all javax/swing/JComboBox/ConsumedKeyTest/ConsumedKeyTest.java 8067986 generic-all
javax/swing/JComponent/6683775/bug6683775.java 8172337 generic-all javax/swing/JComponent/6683775/bug6683775.java 8172337 generic-all
javax/swing/JComboBox/6236162/bug6236162.java 8028707 windows-all javax/swing/JComboBox/6236162/bug6236162.java 8028707 windows-all,macosx-all
javax/swing/text/html/parser/Test8017492.java 8022535 generic-all javax/swing/text/html/parser/Test8017492.java 8022535 generic-all
javax/swing/JWindow/ShapedAndTranslucentWindows/PerPixelTranslucentCanvas.java 8081476 windows-all javax/swing/JButton/8151303/PressedIconTest.java 8198689 macosx-all
javax/swing/JWindow/ShapedAndTranslucentWindows/PerPixelTranslucentCanvas.java 8081476 windows-all,macosx-all
javax/swing/JWindow/ShapedAndTranslucentWindows/PerPixelTranslucentSwing.java 8194128 macosx-all
javax/swing/JWindow/ShapedAndTranslucentWindows/ShapedPerPixelTranslucentGradient.java 8198667 macosx-all
javax/swing/JWindow/ShapedAndTranslucentWindows/SetShapeAndClickSwing.java 8013450 macosx-all
javax/swing/JWindow/ShapedAndTranslucentWindows/TranslucentJComboBox.java 8190347 macosx-all
# The next test below is an intermittent failure # The next test below is an intermittent failure
javax/swing/JComboBox/8033069/bug8033069ScrollBar.java 8163367 generic-all javax/swing/JComboBox/8033069/bug8033069ScrollBar.java 8163367 generic-all
javax/swing/JColorChooser/Test6541987.java 8143021 windows-all,linux-all javax/swing/JColorChooser/Test6541987.java 8143021 windows-all,linux-all,macosx-all
javax/swing/JColorChooser/Test7194184.java 8194126 linux-all,macosx-all
javax/swing/JTable/7124218/SelectEditTableCell.java 8148958 linux-all javax/swing/JTable/7124218/SelectEditTableCell.java 8148958 linux-all
javax/swing/JTable/4235420/bug4235420.java 8079127 linux-all,macosx-all
javax/swing/JTree/DnD/LastNodeLowerHalfDrop.java 8159131 linux-all javax/swing/JTree/DnD/LastNodeLowerHalfDrop.java 8159131 linux-all
javax/swing/JTree/4633594/JTreeFocusTest.java 8173125 macosx-all
javax/swing/JTree/8003400/Test8003400.java 8011259 macosx-all
javax/swing/JFileChooser/8041694/bug8041694.java 8196302 windows-all javax/swing/JFileChooser/8041694/bug8041694.java 8196302 windows-all
javax/swing/JInternalFrame/8069348/bug8069348.java 8196303 windows-all javax/swing/JInternalFrame/8069348/bug8069348.java 8196303 windows-all
javax/swing/AbstractButton/6711682/bug6711682.java 8060765 windows-all javax/swing/AbstractButton/6711682/bug6711682.java 8060765 windows-all,macosx-all
javax/swing/Action/8133039/bug8133039.java 8196089 windows-all javax/swing/Action/8133039/bug8133039.java 8196089 windows-all,macosx-all
javax/swing/JComboBox/6559152/bug6559152.java 8196090 windows-all javax/swing/JComboBox/6559152/bug6559152.java 8196090 windows-all,macosx-all
javax/swing/JComboBox/6607130/bug6607130.java 8196091 windows-all javax/swing/JComboBox/6607130/bug6607130.java 8196091 windows-all
javax/swing/JComboBox/8032878/bug8032878.java 8196092 windows-all javax/swing/JComboBox/8032878/bug8032878.java 8196092 windows-all,macosx-all
javax/swing/JComboBox/8057893/bug8057893.java 8169953 windows-all javax/swing/JComboBox/8057893/bug8057893.java 8169953 windows-all,macosx-all
javax/swing/JComboBox/8072767/bug8072767.java 8196093 windows-all javax/swing/JComboBox/8072767/bug8072767.java 8196093 windows-all,macosx-all
javax/swing/JComponent/4337267/bug4337267.java 8146451 windows-all javax/swing/JComponent/4337267/bug4337267.java 8146451 windows-all
javax/swing/JEditorPane/5076514/bug5076514.java 8198321 generic-all
javax/swing/JEditorPane/6917744/bug6917744.java 8194767 generic-all javax/swing/JEditorPane/6917744/bug6917744.java 8194767 generic-all
javax/swing/JFileChooser/4524490/bug4524490.java 8042380 generic-all javax/swing/JFileChooser/4524490/bug4524490.java 8042380 generic-all
javax/swing/JFileChooser/8002077/bug8002077.java 8196094 windows-all javax/swing/JFileChooser/8002077/bug8002077.java 8196094 windows-all
javax/swing/JFileChooser/DeserializedJFileChooser/DeserializedJFileChooserTest.java 8196095 generic-all javax/swing/JFileChooser/DeserializedJFileChooser/DeserializedJFileChooserTest.java 8196095 generic-all
javax/swing/JFileChooser/6396844/TwentyThousandTest.java 8058231 macosx-all
javax/swing/JFrame/8175301/ScaledFrameBackgroundTest.java 8193942 generic-all javax/swing/JFrame/8175301/ScaledFrameBackgroundTest.java 8193942 generic-all
javax/swing/JInternalFrame/8020708/bug8020708.java 8194943 windows-all javax/swing/JInternalFrame/8020708/bug8020708.java 8194943 windows-all
javax/swing/JList/6462008/bug6462008.java 7156347 generic-all javax/swing/JList/6462008/bug6462008.java 7156347 generic-all
javax/swing/JPopupMenu/6580930/bug6580930.java 8196096 windows-all javax/swing/JPopupMenu/6580930/bug6580930.java 8196096 windows-all,macosx-all
javax/swing/JPopupMenu/6800513/bug6800513.java 7184956 macosx-all
javax/swing/JPopupMenu/6675802/bug6675802.java 8196097 windows-all javax/swing/JPopupMenu/6675802/bug6675802.java 8196097 windows-all
javax/swing/JTabbedPane/8007563/Test8007563.java 8051591 generic-all javax/swing/JTabbedPane/8007563/Test8007563.java 8051591 generic-all
javax/swing/JTabbedPane/4624207/bug4624207.java 8064922 macosx-all
javax/swing/JTabbedPane/7024235/Test7024235.java 8028281 macosx-all
javax/swing/SwingUtilities/TestBadBreak/TestBadBreak.java 8160720 generic-all javax/swing/SwingUtilities/TestBadBreak/TestBadBreak.java 8160720 generic-all
javax/swing/plaf/basic/BasicTextUI/8001470/bug8001470.java 8196098 windows-all javax/swing/plaf/basic/BasicTextUI/8001470/bug8001470.java 8196098 windows-all
javax/swing/plaf/basic/Test6984643.java 8198340 windows-all
javax/swing/text/CSSBorder/6796710/bug6796710.java 8196099 windows-all javax/swing/text/CSSBorder/6796710/bug6796710.java 8196099 windows-all
javax/swing/text/DefaultCaret/HidingSelection/HidingSelectionTest.java 8194048 windows-all javax/swing/text/DefaultCaret/HidingSelection/HidingSelectionTest.java 8194048 windows-all
javax/swing/text/JTextComponent/5074573/bug5074573.java 8196100 windows-all javax/swing/text/JTextComponent/5074573/bug5074573.java 8196100 windows-all
javax/swing/JFileChooser/6798062/bug6798062.java 8146446 windows-all javax/swing/JFileChooser/6798062/bug6798062.java 8146446 windows-all
javax/swing/plaf/basic/BasicGraphicsUtils/8132119/bug8132119.java 8196434 linux-all javax/swing/plaf/basic/BasicGraphicsUtils/8132119/bug8132119.java 8196434 linux-all,solaris-all
javax/swing/JComboBox/8032878/bug8032878.java 8196439 linux-all javax/swing/JComboBox/8032878/bug8032878.java 8196439 linux-all
javax/swing/JComboBox/8182031/ComboPopupTest.java 8196465 linux-all javax/swing/JComboBox/8182031/ComboPopupTest.java 8196465 linux-all,macosx-all
javax/swing/JFileChooser/6738668/bug6738668.java 8194946 linux-all,macosx-all javax/swing/JFileChooser/6738668/bug6738668.java 8194946 generic-all
javax/swing/JFileChooser/8021253/bug8021253.java 8169954 windows-all,linux-all javax/swing/JFileChooser/8021253/bug8021253.java 8169954 windows-all,linux-all,macosx-all
javax/swing/JFileChooser/8062561/bug8062561.java 8196466 linux-all javax/swing/JFileChooser/8062561/bug8062561.java 8196466 linux-all,macosx-all
javax/swing/JInternalFrame/Test6325652.java 8196467 linux-all javax/swing/JFileChooser/FileSystemView/FileSystemViewListenerLeak.java 8198342 generic-all
javax/swing/JInternalFrame/Test6325652.java 8196467 linux-all,macosx-all
javax/swing/JInternalFrame/8145896/TestJInternalFrameMaximize.java 8194944 macosx-all
javax/swing/JLabel/6596966/bug6596966.java 8040914 macosx-all
javax/swing/JPopupMenu/4870644/bug4870644.java 8194130 macosx-all
javax/swing/JPopupMenu/4966112/bug4966112.java 8064915 macosx-all
javax/swing/MultiUIDefaults/Test6860438.java 8198391 generic-all
javax/swing/MultiUIDefaults/4300666/bug4300666.java 7105119 macosx-all
javax/swing/UITest/UITest.java 8198392 generic-all
javax/swing/plaf/basic/BasicComboBoxEditor/Test8015336.java 8198394 linux-all,macosx-all
javax/swing/plaf/metal/MetalLookAndFeel/Test8039750.java 8198395 generic-all
javax/swing/text/DevanagariEditor.java 8198397 linux-all
javax/swing/JColorChooser/Test6199676.java 8198398 linux-all,macosx-all
javax/swing/JTable/6735286/bug6735286.java 8198398 linux-all,macosx-all
javax/swing/SpringLayout/4726194/bug4726194.java 8198399 generic-all
javax/swing/SwingUtilities/6797139/bug6797139.java 8198400 generic-all
javax/swing/text/html/parser/Parser/6836089/bug6836089.java 8198401 linux-all,macosx-all
javax/swing/JTable/8133919/DrawGridLinesTest.java 8198407 generic-all
javax/swing/text/html/StyleSheet/BackgroundImage/BackgroundImagePosition.java 8198409 generic-all
javax/swing/text/AbstractDocument/DocumentInsert/DocumentInsertAtWrongPositionTest.java 8198396 generic-all
javax/swing/JFileChooser/6868611/bug6868611.java 7059834 windows-all
javax/swing/SwingWorker/6493680/bug6493680.java 8198410 windows-all
javax/swing/plaf/basic/BasicMenuUI/4983388/bug4983388.java 8042383 macosx-all
javax/swing/PopupFactory/6276087/NonOpaquePopupMenuTest.java 8065099 macosx-all
############################################################################ ############################################################################
@ -486,10 +736,6 @@ com/sun/jdi/sde/SourceDebugExtensionTest.java 8158066 windows-
com/sun/jdi/NashornPopFrameTest.java 8187143 generic-all com/sun/jdi/NashornPopFrameTest.java 8187143 generic-all
com/sun/jdi/EarlyReturnTest.java 8198803 generic-all
com/sun/jdi/EarlyReturnNegativeTest.java 8198803 generic-all
com/sun/jdi/MethodExitReturnValuesTest.java 8198803 generic-all
############################################################################ ############################################################################
# jdk_time # jdk_time

View File

@ -77,8 +77,9 @@ class EarlyReturnNegativeTarg {
public static ClassLoader classLoaderValue; public static ClassLoader classLoaderValue;
{ {
try { try {
urls[0] = new URL("hi there"); urls[0] = new URL("file:/foo");
} catch (java.net.MalformedURLException ee) { } catch (java.net.MalformedURLException ex) {
throw new AssertionError(ex);
} }
classLoaderValue = new URLClassLoader(urls); classLoaderValue = new URLClassLoader(urls);
} }

View File

@ -82,8 +82,9 @@ class EarlyReturnTarg {
public static ClassLoader classLoaderValue; public static ClassLoader classLoaderValue;
{ {
try { try {
urls[0] = new URL("hi there"); urls[0] = new URL("file:/foo");
} catch (java.net.MalformedURLException ee) { } catch (java.net.MalformedURLException ex) {
throw new AssertionError(ex);
} }
classLoaderValue = new URLClassLoader(urls); classLoaderValue = new URLClassLoader(urls);
} }
@ -116,8 +117,9 @@ class EarlyReturnTarg {
public static ClassLoader eclassLoaderValue; public static ClassLoader eclassLoaderValue;
{ {
try { try {
urls[0] = new URL("been there, done that"); urls[0] = new URL("file:/bar");
} catch (java.net.MalformedURLException ee) { } catch (java.net.MalformedURLException ex) {
throw new AssertionError(ex);
} }
classLoaderValue = new URLClassLoader(urls); classLoaderValue = new URLClassLoader(urls);
} }

View File

@ -66,8 +66,9 @@ class MethodExitReturnValuesTarg {
public static ClassLoader classLoaderValue; public static ClassLoader classLoaderValue;
{ {
try { try {
urls[0] = new URL("hi there"); urls[0] = new URL("file:/foo");
} catch (java.net.MalformedURLException ee) { } catch (java.net.MalformedURLException ex) {
throw new AssertionError(ex);
} }
classLoaderValue = new URLClassLoader(urls); classLoaderValue = new URLClassLoader(urls);
} }

View File

@ -23,6 +23,7 @@
/* /*
* @test * @test
* @key headful
* @bug 8176795 * @bug 8176795
* @summary Test verifies that we get proper color when we draw translucent * @summary Test verifies that we get proper color when we draw translucent
* color over an opaque color using X Render extension in Linux. * color over an opaque color using X Render extension in Linux.

View File

@ -23,6 +23,8 @@
/* @test /* @test
* @bug 8064934 * @bug 8064934
* @key headful
* @requires (os.family == "windows")
* @summary Incorrect Exception message from java.awt.Desktop.open() * @summary Incorrect Exception message from java.awt.Desktop.open()
* @author Dmitry Markov * @author Dmitry Markov
* @library ../../../../lib/testlibrary * @library ../../../../lib/testlibrary

View File

@ -23,6 +23,8 @@
/* @test /* @test
@bug 6550588 @bug 6550588
@key headful
@requires (os.family == "windows")
@summary java.awt.Desktop cannot open file with Windows UNC filename @summary java.awt.Desktop cannot open file with Windows UNC filename
@author Anton Litvinov @author Anton Litvinov
*/ */

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2010, 2018 Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -24,7 +24,7 @@
/* /*
@test @test
@key headful @key headful
@bug 6829546 @bug 6829546, 8197808
@summary tests that an always-on-top modal dialog doesn't make any windows always-on-top @summary tests that an always-on-top modal dialog doesn't make any windows always-on-top
@author artem.ananiev: area=awt.modal @author artem.ananiev: area=awt.modal
@library ../../regtesthelpers @library ../../regtesthelpers
@ -32,9 +32,13 @@
@run main MakeWindowAlwaysOnTop @run main MakeWindowAlwaysOnTop
*/ */
import java.awt.*; import java.awt.Frame;
import java.awt.event.*; import java.awt.Dialog;
import java.awt.EventQueue;
import java.awt.Color;
import java.awt.Robot;
import java.awt.Point;
import java.awt.event.InputEvent;
import test.java.awt.regtesthelpers.Util; import test.java.awt.regtesthelpers.Util;
public class MakeWindowAlwaysOnTop public class MakeWindowAlwaysOnTop
@ -59,21 +63,9 @@ public class MakeWindowAlwaysOnTop
d = new Dialog(null, "Modal dialog", Dialog.ModalityType.APPLICATION_MODAL); d = new Dialog(null, "Modal dialog", Dialog.ModalityType.APPLICATION_MODAL);
d.setBounds(500, 500, 160, 160); d.setBounds(500, 500, 160, 160);
d.setAlwaysOnTop(true); d.setAlwaysOnTop(true);
EventQueue.invokeLater(new Runnable() EventQueue.invokeLater(() -> d.setVisible(true) );
{
public void run()
{
d.setVisible(true);
}
});
// Wait until the dialog is shown // Wait until the dialog is shown
EventQueue.invokeAndWait(new Runnable() EventQueue.invokeAndWait(() -> { /* Empty */ });
{
public void run()
{
// Empty
}
});
r.delay(100); r.delay(100);
Util.waitForIdle(r); Util.waitForIdle(r);
@ -104,29 +96,30 @@ public class MakeWindowAlwaysOnTop
// Bring it above the first frame // Bring it above the first frame
t.toFront(); t.toFront();
r.delay(100);
r.delay(200);
Util.waitForIdle(r); Util.waitForIdle(r);
Color c = r.getPixelColor(p.x + f.getWidth() / 2, p.y + f.getHeight() / 2); Color c = r.getPixelColor(p.x + f.getWidth() / 2, p.y + f.getHeight() / 2);
System.out.println("Color = " + c); System.out.println("Color = " + c);
System.out.flush();
String exceptionMessage = null;
// If the color is RED, then the first frame is now always-on-top // If the color is RED, then the first frame is now always-on-top
if (Color.RED.equals(c)) if (Color.RED.equals(c)) {
{ exceptionMessage = "Test FAILED: the frame is always-on-top";
throw new RuntimeException("Test FAILED: the frame is always-on-top"); } else if (!Color.BLUE.equals(c)) {
} exceptionMessage = "Test FAILED: unknown window is on top of the frame";
else if (!Color.BLUE.equals(c))
{
throw new RuntimeException("Test FAILED: unknown window is on top of the frame");
}
else
{
System.out.println("Test PASSED");
System.out.flush();
} }
// Dispose all the windows // Dispose all the windows
t.dispose(); t.dispose();
f.dispose(); f.dispose();
if (exceptionMessage != null) {
throw new RuntimeException(exceptionMessage);
} else {
System.out.println("Test PASSED");
}
} }
} }

View File

@ -24,6 +24,7 @@
/* /*
* @test * @test
* @bug 6356322 * @bug 6356322
* @key headful
* @summary Tests that embedded frame's graphics configuration is updated * @summary Tests that embedded frame's graphics configuration is updated
* correctly when it is moved to another screen in multiscreen system, * correctly when it is moved to another screen in multiscreen system,
* XToolkit * XToolkit

View File

@ -27,6 +27,7 @@ import java.util.concurrent.TimeUnit;
/** /**
* @test * @test
* @key headful
* @bug 8177758 * @bug 8177758
* @requires os.family == "windows" * @requires os.family == "windows"
* @summary Regression in java.awt.FileDialog * @summary Regression in java.awt.FileDialog

View File

@ -24,6 +24,7 @@
/* /*
@test @test
@bug 6304979 @bug 6304979
@key headful
@summary REG: File Dialog throws ArrayIndexOutOfBounds Exception on XToolkit with b45 @summary REG: File Dialog throws ArrayIndexOutOfBounds Exception on XToolkit with b45
@author Dmitry Cherepanov: area=awt.filedialog @author Dmitry Cherepanov: area=awt.filedialog
@run main/othervm -Dsun.awt.disableGtkFileDialogs=true ISCthrownByFileListTest @run main/othervm -Dsun.awt.disableGtkFileDialogs=true ISCthrownByFileListTest

View File

@ -23,6 +23,7 @@
/* /*
@test @test
@key headful
@bug 8190515 8193468 @bug 8190515 8193468
@summary java.awt.Desktop.moveToTrash(File) prompts on Windows 7 but not on Mac. @summary java.awt.Desktop.moveToTrash(File) prompts on Windows 7 but not on Mac.
@run main MoveToTrashTest @run main MoveToTrashTest

View File

@ -23,6 +23,7 @@
/* /*
@test @test
@key headful
@bug 8048887 8164937 @bug 8048887 8164937
@summary Tests SortingFTP for an exception caused by the tim-sort algo. @summary Tests SortingFTP for an exception caused by the tim-sort algo.
@author anton.tarasov: area=awt.focus @author anton.tarasov: area=awt.focus

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -31,9 +31,11 @@ import java.awt.Toolkit;
/** /**
* @test * @test
* @key headful * @key headful
* @bug 8065739 * @bug 8065739 8129569
* @requires (os.family == "mac")
* @summary [macosx] Frame warps to lower left of screen when displayed * @summary [macosx] Frame warps to lower left of screen when displayed
* @author Alexandr Scherbatiy * @author Alexandr Scherbatiy
* @run main MaximizedToUnmaximized
*/ */
public class MaximizedToUnmaximized { public class MaximizedToUnmaximized {

View File

@ -23,8 +23,8 @@
/** /**
* @test * @test
* @bug 6358034 * @bug 6358034 6568560
* @bug 6568560 * @key headful
* @summary Tests that no exception is thrown when display mode is changed * @summary Tests that no exception is thrown when display mode is changed
* externally * externally
* @compile UninitializedDisplayModeChangeTest.java DisplayModeChanger.java * @compile UninitializedDisplayModeChangeTest.java DisplayModeChanger.java

View File

@ -33,6 +33,7 @@ import java.awt.geom.AffineTransform;
/* /*
* @test * @test
* @bug 8069361 * @bug 8069361
* @key headful
* @summary SunGraphics2D.getDefaultTransform() does not include scale factor * @summary SunGraphics2D.getDefaultTransform() does not include scale factor
* @author Alexander Scherbatiy * @author Alexander Scherbatiy
* @run main ScaledTransform * @run main ScaledTransform

View File

@ -22,6 +22,7 @@
*/ */
/* @test /* @test
* @key headful
* @bug 8156121 * @bug 8156121
* @summary "Fail forward" fails for GTK3 if no GTK2 available * @summary "Fail forward" fails for GTK3 if no GTK2 available
* @modules java.desktop/sun.awt * @modules java.desktop/sun.awt

View File

@ -22,6 +22,7 @@
# questions. # questions.
# @test JAWT.sh # @test JAWT.sh
# @key headful
# @bug 7190587 # @bug 7190587
# @summary Tests Java AWT native interface library # @summary Tests Java AWT native interface library
# @author kshefov # @author kshefov
@ -111,7 +112,7 @@ case "$OS" in
else else
ARCH="i386" ARCH="i386"
fi fi
SYST="cygwin" SYST="cygwin"
MAKE="make" MAKE="make"
;; ;;
Darwin ) Darwin )

View File

@ -24,6 +24,8 @@
/* /*
@test @test
@bug 6246467 @bug 6246467
@key headful
@requires (os.family == "linux") | (os.family == "solaris")
@summary List does not honor user specified background, foreground colors on XToolkit @summary List does not honor user specified background, foreground colors on XToolkit
@author Dmitry Cherepanov area=awt.list @author Dmitry Cherepanov area=awt.list
@library ../../../../lib/testlibrary @library ../../../../lib/testlibrary

View File

@ -0,0 +1,87 @@
/*
* Copyright (c) 2018, Oracle and/or its affiliates. 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
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/**
* @test
* @key headful
* @bug 8196322
* @summary [macosx] When the screen menu bar is used, clearing the default menu bar should permit AWT shutdown
* @author Alan Snyder
* @run main/othervm DefaultMenuBarDispose
* @requires (os.family == "mac")
*/
import java.awt.Desktop;
import java.lang.reflect.InvocationTargetException;
import javax.swing.JMenuBar;
import javax.swing.SwingUtilities;
public class DefaultMenuBarDispose
{
public DefaultMenuBarDispose()
{
Thread watcher = new Thread(() -> {
try {
synchronized (this) {
wait(5000);
}
throw new RuntimeException("Test failed: failed to exit");
} catch (InterruptedException ex) {
}
});
watcher.setDaemon(true);
watcher.start();
runSwing(() ->
{
JMenuBar mb = new JMenuBar();
Desktop.getDesktop().setDefaultMenuBar(mb);
Desktop.getDesktop().setDefaultMenuBar(null);
}
);
}
private static void runSwing(Runnable r)
{
try {
SwingUtilities.invokeAndWait(r);
} catch (InterruptedException e) {
} catch (InvocationTargetException e) {
throw new RuntimeException(e);
}
}
public static void main(String[] args)
{
if (!System.getProperty("os.name").contains("OS X")) {
System.out.println("This test is for MacOS only. Automatically passed on other platforms.");
return;
}
System.setProperty("apple.laf.useScreenMenuBar", "true");
new DefaultMenuBarDispose();
}
}

View File

@ -22,7 +22,7 @@
*/ */
/* /*
@test %I% %E% @test
@key headful @key headful
@bug 6315717 @bug 6315717
@summary verifies that drag events are coming for every button if the property is set to true @summary verifies that drag events are coming for every button if the property is set to true

Some files were not shown because too many files have changed in this diff Show More