Merge
This commit is contained in:
commit
08a84fcd75
@ -361,3 +361,4 @@ f900d5afd9c83a0df8f36161c27c5e4c86a66f4c jdk-9+111
|
||||
6743a8e0cab7b5f6f4a0575f6664892f0ab740af jdk-9+116
|
||||
e882bcdbdac436523f3d5681611d3118a3804ea7 jdk-9+117
|
||||
047f95de8f918d8ff5e8cd2636a2abb5c3c8adb8 jdk-9+118
|
||||
3463a3f14f0f0e8a68f29ac6405454f2fa2f598a jdk-9+119
|
||||
|
@ -484,6 +484,8 @@ AC_DEFUN_ONCE([BASIC_SETUP_FUNDAMENTAL_TOOLS],
|
||||
BASIC_REQUIRE_PROGS(FILE, file)
|
||||
BASIC_REQUIRE_PROGS(FIND, find)
|
||||
BASIC_REQUIRE_PROGS(HEAD, head)
|
||||
BASIC_REQUIRE_PROGS(GUNZIP, gunzip)
|
||||
BASIC_REQUIRE_PROGS(GZIP, pigz gzip)
|
||||
BASIC_REQUIRE_PROGS(LN, ln)
|
||||
BASIC_REQUIRE_PROGS(LS, ls)
|
||||
BASIC_REQUIRE_PROGS(MKDIR, mkdir)
|
||||
@ -496,7 +498,7 @@ AC_DEFUN_ONCE([BASIC_SETUP_FUNDAMENTAL_TOOLS],
|
||||
BASIC_REQUIRE_PROGS(SH, sh)
|
||||
BASIC_REQUIRE_PROGS(SORT, sort)
|
||||
BASIC_REQUIRE_PROGS(TAIL, tail)
|
||||
BASIC_REQUIRE_PROGS(TAR, tar)
|
||||
BASIC_REQUIRE_PROGS(TAR, gtar tar)
|
||||
BASIC_REQUIRE_PROGS(TEE, tee)
|
||||
BASIC_REQUIRE_PROGS(TOUCH, touch)
|
||||
BASIC_REQUIRE_PROGS(TR, tr)
|
||||
@ -839,8 +841,6 @@ AC_DEFUN_ONCE([BASIC_SETUP_OUTPUT_DIR],
|
||||
|
||||
# The spec.gmk file contains all variables for the make system.
|
||||
AC_CONFIG_FILES([$OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in])
|
||||
# The hotspot-spec.gmk file contains legacy variables for the hotspot make system.
|
||||
AC_CONFIG_FILES([$OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in])
|
||||
# The bootcycle-spec.gmk file contains support for boot cycle builds.
|
||||
AC_CONFIG_FILES([$OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in])
|
||||
# The buildjdk-spec.gmk file contains support for building a buildjdk when cross compiling.
|
||||
@ -1009,11 +1009,36 @@ AC_DEFUN([BASIC_CHECK_FIND_DELETE],
|
||||
AC_SUBST(FIND_DELETE)
|
||||
])
|
||||
|
||||
AC_DEFUN([BASIC_CHECK_TAR],
|
||||
[
|
||||
# Test which kind of tar was found
|
||||
if test "x$($TAR --version | $GREP "GNU tar")" != "x"; then
|
||||
TAR_TYPE="gnu"
|
||||
elif test "x$($TAR -v | $GREP "bsdtar")" != "x"; then
|
||||
TAR_TYPE="bsd"
|
||||
elif test "x$OPENJDK_BUILD_OS" = "xsolaris"; then
|
||||
TAR_TYPE="solaris"
|
||||
fi
|
||||
AC_MSG_CHECKING([what type of tar was found])
|
||||
AC_MSG_RESULT([$TAR_TYPE])
|
||||
|
||||
if test "x$TAR_TYPE" = "xgnu"; then
|
||||
TAR_INCLUDE_PARAM="T"
|
||||
TAR_SUPPORTS_TRANSFORM="true"
|
||||
else
|
||||
TAR_INCLUDE_PARAM="I"
|
||||
TAR_SUPPORTS_TRANSFORM="false"
|
||||
fi
|
||||
AC_SUBST(TAR_INCLUDE_PARAM)
|
||||
AC_SUBST(TAR_SUPPORTS_TRANSFORM)
|
||||
])
|
||||
|
||||
AC_DEFUN_ONCE([BASIC_SETUP_COMPLEX_TOOLS],
|
||||
[
|
||||
BASIC_CHECK_GNU_MAKE
|
||||
|
||||
BASIC_CHECK_FIND_DELETE
|
||||
BASIC_CHECK_TAR
|
||||
|
||||
# These tools might not be installed by default,
|
||||
# need hint on how to install them.
|
||||
|
@ -134,8 +134,9 @@ ifeq ($(JVM_INTERPRETER), cpp)
|
||||
endif
|
||||
|
||||
HOTSPOT_MAKE_ARGS := product docs export_product
|
||||
# Control wether Hotspot runs Queens test after building
|
||||
TEST_IN_BUILD := false
|
||||
|
||||
# Control wether Hotspot builds gtest tests
|
||||
BUILD_GTEST := false
|
||||
|
||||
USE_PRECOMPILED_HEADER := @USE_PRECOMPILED_HEADER@
|
||||
|
||||
|
@ -48,6 +48,7 @@ export EXPR="@EXPR@"
|
||||
export FILE="@FILE@"
|
||||
export FIND="@FIND@"
|
||||
export GREP="@GREP@"
|
||||
export GUNZIP="@GUNZIP@"
|
||||
export LDD="@LDD@"
|
||||
export LN="@LN@"
|
||||
export MKDIR="@MKDIR@"
|
||||
@ -63,10 +64,11 @@ export SED="@SED@"
|
||||
export SORT="@SORT@"
|
||||
export STAT="@STAT@"
|
||||
export STRIP="@STRIP@ @STRIPFLAGS@"
|
||||
export TAR="@TAR@"
|
||||
export TEE="@TEE@"
|
||||
export UNIQ="@UNIQ@"
|
||||
export UNPACK200="@FIXPATH@ @BOOT_JDK@/bin/unpack200"
|
||||
export UNARCHIVE="@UNZIP@ -q"
|
||||
export UNARCHIVE="@UNZIP@ -q -o"
|
||||
|
||||
export SRC_ROOT="@TOPDIR@"
|
||||
export OUTPUT_ROOT="@OUTPUT_ROOT@"
|
||||
|
@ -207,6 +207,7 @@ JDKOPT_SETUP_CODE_COVERAGE
|
||||
# Need toolchain to setup dtrace
|
||||
HOTSPOT_SETUP_DTRACE
|
||||
HOTSPOT_SETUP_JVM_FEATURES
|
||||
HOTSPOT_ENABLE_DISABLE_GTEST
|
||||
|
||||
###############################################################################
|
||||
#
|
||||
@ -226,7 +227,6 @@ LIB_SETUP_LIBRARIES
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
HOTSPOT_SETUP_LEGACY_BUILD
|
||||
JDKOPT_DETECT_INTREE_EC
|
||||
JDKOPT_ENABLE_DISABLE_FAILURE_HANDLER
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,158 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2011, 2016, 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.
|
||||
#
|
||||
|
||||
|
||||
# Chaining of spec files
|
||||
HOTSPOT_SPEC:=$(dir $(SPEC))hotspot-spec.gmk
|
||||
override SPEC=$(HOTSPOT_SPEC)
|
||||
# Now include the base spec.gmk file
|
||||
include $(BASE_SPEC)
|
||||
|
||||
# Additional legacy variables defined for Hotspot
|
||||
|
||||
@SET_OPENJDK@
|
||||
@HOTSPOT_SET_WARNINGS_AS_ERRORS@
|
||||
|
||||
# Legacy defines controlled by the SUPPORT_HEADLESS and SUPPORT_HEADFUL options.
|
||||
@BUILD_HEADLESS@
|
||||
|
||||
JVM_VARIANTS:=@JVM_VARIANTS_COMMA@
|
||||
|
||||
JVM_VARIANT_SERVER:=@JVM_VARIANT_SERVER@
|
||||
JVM_VARIANT_CLIENT:=@JVM_VARIANT_CLIENT@
|
||||
JVM_VARIANT_MINIMAL1:=@JVM_VARIANT_MINIMAL1@
|
||||
JVM_VARIANT_CORE:=@JVM_VARIANT_CORE@
|
||||
JVM_VARIANT_ZERO:=@JVM_VARIANT_ZERO@
|
||||
JVM_VARIANT_ZEROSHARK:=@JVM_VARIANT_ZEROSHARK@
|
||||
JVM_VARIANT_CUSTOM:=@JVM_VARIANT_HOTSPOT@
|
||||
|
||||
# Legacy setting: OPT or DBG
|
||||
VARIANT:=@VARIANT@
|
||||
# Legacy setting: true or false
|
||||
FASTDEBUG:=@FASTDEBUG@
|
||||
# Legacy setting: debugging the class files?
|
||||
DEBUG_CLASSFILES:=@DEBUG_CLASSFILES@
|
||||
|
||||
ALT_CUPS_HEADERS_PATH:=$(patsubst -I%,%,$(filter -I%,@CUPS_CFLAGS@))
|
||||
|
||||
# The HOSTCC/HOSTCXX is Hotspot terminology for the BUILD_CC/BUILD_CXX, i.e. the
|
||||
# compiler that produces code that can be run on the build platform.
|
||||
HOSTCC:=@FIXPATH@ @BUILD_ICECC@ @BUILD_CC@ $(BUILD_SYSROOT_CFLAGS)
|
||||
HOSTCXX:=@FIXPATH@ @BUILD_ICECC@ @BUILD_CXX@ $(BUILD_SYSROOT_CFLAGS)
|
||||
|
||||
####################################################
|
||||
#
|
||||
# Legacy Hotspot support
|
||||
|
||||
# If cross compiling, then define CROSS_COMPILE_ARCH:=cpu_name here.
|
||||
@DEFINE_CROSS_COMPILE_ARCH@
|
||||
|
||||
# Old name for OPENJDK_TARGET_OS (aix,bsd,hpux,linux,macosx,solaris,windows etc)
|
||||
PLATFORM=$(OPENJDK_TARGET_OS)
|
||||
# 32 or 64 bit
|
||||
ARCH_DATA_MODEL=$(OPENJDK_TARGET_CPU_BITS)
|
||||
|
||||
ALT_BOOTDIR=$(BOOT_JDK)
|
||||
# Can be /sparcv9 or /amd64 on Solaris
|
||||
ISA_DIR=$(OPENJDK_TARGET_CPU_ISADIR)
|
||||
# Yet another name for arch used for an extra subdir below the jvm lib.
|
||||
# Uses i386 and amd64, instead of x86 and x86_64.
|
||||
LIBARCH=$(OPENJDK_TARGET_CPU_LEGACY_LIB)
|
||||
# Set the cpu architecture
|
||||
ARCH=$(OPENJDK_TARGET_CPU_ARCH)
|
||||
# Legacy setting for building for a 64 bit machine.
|
||||
# If yes then this expands to _LP64:=1
|
||||
@LP64@
|
||||
|
||||
# Legacy settings for zero
|
||||
ZERO_ENDIANNESS=$(OPENJDK_TARGET_CPU_ENDIAN)
|
||||
ZERO_LIBARCH=$(OPENJDK_TARGET_CPU_LEGACY_LIB)
|
||||
ZERO_ARCHDEF=@ZERO_ARCHDEF@
|
||||
ZERO_ARCHFLAG=@ZERO_ARCHFLAG@
|
||||
LIBFFI_CFLAGS=@LIBFFI_CFLAGS@
|
||||
LIBFFI_LIBS=@LIBFFI_LIBS@
|
||||
|
||||
# Legacy settings for zeroshark
|
||||
LLVM_CFLAGS=@LLVM_CFLAGS@
|
||||
LLVM_LIBS=@LLVM_LIBS@
|
||||
LLVM_LDFLAGS=@LLVM_LDFLAGS@
|
||||
|
||||
ALT_OUTPUTDIR=$(HOTSPOT_OUTPUTDIR)
|
||||
ALT_EXPORT_PATH=$(HOTSPOT_DIST)
|
||||
|
||||
ifeq ($(HOTSPOT_TARGET_CPU), zero)
|
||||
CC_INTERP=true
|
||||
endif
|
||||
|
||||
HOTSPOT_MAKE_ARGS:=@HOTSPOT_MAKE_ARGS@ @STATIC_CXX_SETTING@
|
||||
# Control wether Hotspot runs Queens test after building
|
||||
TEST_IN_BUILD=@TEST_IN_BUILD@
|
||||
|
||||
USE_CLANG := @USE_CLANG@
|
||||
|
||||
# For hotspot, override compiler/tools definition to not include FIXPATH prefix.
|
||||
# Hotspot has its own handling on the Windows path situation.
|
||||
CXX:=@CCACHE@ @ICECC@ @HOTSPOT_CXX@
|
||||
LD:=@HOTSPOT_LD@
|
||||
MT:=@HOTSPOT_MT@
|
||||
RC:=@HOTSPOT_RC@
|
||||
|
||||
EXTRA_CFLAGS=@LEGACY_EXTRA_CFLAGS@ $(CFLAGS_CCACHE) $(NO_NULL_POINTER_CHECK_FLAG) \
|
||||
$(NO_LIFETIME_DSE_CFLAG) $(CXXSTD_CXXFLAG)
|
||||
EXTRA_CXXFLAGS=@LEGACY_EXTRA_CXXFLAGS@ $(CFLAGS_CCACHE)
|
||||
EXTRA_LDFLAGS=@LEGACY_EXTRA_LDFLAGS@
|
||||
|
||||
USE_PRECOMPILED_HEADER=@USE_PRECOMPILED_HEADER@
|
||||
|
||||
# Hotspot expects the variable FULL_DEBUG_SYMBOLS=1/0 to control debug symbols
|
||||
# creation.
|
||||
ifeq ($(COPY_DEBUG_SYMBOLS), true)
|
||||
FULL_DEBUG_SYMBOLS=1
|
||||
# Ensure hotspot uses the objcopy that configure located
|
||||
ALT_OBJCOPY:=$(OBJCOPY)
|
||||
else
|
||||
FULL_DEBUG_SYMBOLS=0
|
||||
endif
|
||||
|
||||
# Hotspot expects the variable ZIP_DEBUGINFO_FILES=1/0 and not true/false.
|
||||
ifeq ($(ZIP_EXTERNAL_DEBUG_SYMBOLS), true)
|
||||
ZIP_DEBUGINFO_FILES:=1
|
||||
else
|
||||
ZIP_DEBUGINFO_FILES:=0
|
||||
endif
|
||||
|
||||
DEBUG_BINARIES := @DEBUG_BINARIES@
|
||||
STRIP_POLICY := @STRIP_POLICY@
|
||||
|
||||
ifeq ($(OPENJDK_TARGET_OS), windows)
|
||||
# On Windows, the Visual Studio toolchain needs the LIB and INCLUDE
|
||||
# environment variables (in Windows path style).
|
||||
export INCLUDE:=@VS_INCLUDE@
|
||||
export LIB:=@VS_LIB@
|
||||
endif
|
||||
|
||||
# Sneak this in via the spec.gmk file, since we don't want to mess around too much with the Hotspot make files.
|
||||
# This is needed to get the LOG setting to work properly.
|
||||
include $(SRC_ROOT)/make/common/MakeBase.gmk
|
@ -93,7 +93,10 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_JVM_VARIANTS],
|
||||
# Check that the selected variants are valid
|
||||
|
||||
# grep filter function inspired by a comment to http://stackoverflow.com/a/1617326
|
||||
INVALID_VARIANTS=`$GREP -Fvx "${VALID_JVM_VARIANTS// /$'\n'}" <<< "${JVM_VARIANTS// /$'\n'}"`
|
||||
# Notice that the original variant failes on SLES 10 and 11
|
||||
NEEDLE=${VALID_JVM_VARIANTS// /$'\n'}
|
||||
STACK=${JVM_VARIANTS// /$'\n'}
|
||||
INVALID_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"`
|
||||
if test "x$INVALID_VARIANTS" != x; then
|
||||
AC_MSG_NOTICE([Unknown variant(s) specified: $INVALID_VARIANTS])
|
||||
AC_MSG_ERROR([The available JVM variants are: $VALID_JVM_VARIANTS])
|
||||
@ -101,7 +104,9 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_JVM_VARIANTS],
|
||||
|
||||
# All "special" variants share the same output directory ("server")
|
||||
VALID_MULTIPLE_JVM_VARIANTS="server client minimal"
|
||||
INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'}" <<< "${JVM_VARIANTS// /$'\n'}"`
|
||||
NEEDLE=${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'}
|
||||
STACK=${JVM_VARIANTS// /$'\n'}
|
||||
INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"`
|
||||
if test "x$INVALID_MULTIPLE_VARIANTS" != x && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xtrue; then
|
||||
AC_MSG_ERROR([You cannot build multiple variants with anything else than $VALID_MULTIPLE_JVM_VARIANTS.])
|
||||
fi
|
||||
@ -293,146 +298,51 @@ AC_DEFUN_ONCE([HOTSPOT_VALIDATE_JVM_FEATURES],
|
||||
features_var_name=JVM_FEATURES_$variant
|
||||
JVM_FEATURES_TO_TEST=${!features_var_name}
|
||||
AC_MSG_RESULT([$JVM_FEATURES_TO_TEST])
|
||||
INVALID_FEATURES=`$GREP -Fvx "${VALID_JVM_FEATURES// /$'\n'}" <<< "${JVM_FEATURES_TO_TEST// /$'\n'}"`
|
||||
NEEDLE=${VALID_JVM_FEATURES// /$'\n'}
|
||||
STACK=${JVM_FEATURES_TO_TEST// /$'\n'}
|
||||
INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"`
|
||||
if test "x$INVALID_FEATURES" != x; then
|
||||
AC_MSG_ERROR([Invalid JVM feature(s): $INVALID_FEATURES])
|
||||
fi
|
||||
done
|
||||
])
|
||||
|
||||
###############################################################################
|
||||
# Support for old hotspot build. Remove once new hotspot build has proven
|
||||
# to work satisfactory.
|
||||
################################################################################
|
||||
# Check if gtest should be built
|
||||
#
|
||||
AC_DEFUN_ONCE([HOTSPOT_SETUP_LEGACY_BUILD],
|
||||
AC_DEFUN_ONCE([HOTSPOT_ENABLE_DISABLE_GTEST],
|
||||
[
|
||||
AC_ARG_ENABLE(new-hotspot-build, [AS_HELP_STRING([--disable-new-hotspot-build],
|
||||
[disable the new hotspot build system (use the old) @<:@enabled@:>@])])
|
||||
AC_ARG_ENABLE([hotspot-gtest], [AS_HELP_STRING([--disable-hotspot-gtest],
|
||||
[Disables building of the Hotspot unit tests])])
|
||||
|
||||
if test "x$enable_new_hotspot_build" = "x" || test "x$enable_new_hotspot_build" = "xyes"; then
|
||||
USE_NEW_HOTSPOT_BUILD=true
|
||||
else
|
||||
USE_NEW_HOTSPOT_BUILD=false
|
||||
fi
|
||||
AC_SUBST(USE_NEW_HOTSPOT_BUILD)
|
||||
|
||||
case $HOTSPOT_DEBUG_LEVEL in
|
||||
product )
|
||||
VARIANT="OPT"
|
||||
FASTDEBUG="false"
|
||||
DEBUG_CLASSFILES="false"
|
||||
;;
|
||||
fastdebug )
|
||||
VARIANT="DBG"
|
||||
FASTDEBUG="true"
|
||||
DEBUG_CLASSFILES="true"
|
||||
;;
|
||||
debug )
|
||||
VARIANT="DBG"
|
||||
FASTDEBUG="false"
|
||||
DEBUG_CLASSFILES="true"
|
||||
;;
|
||||
optimized )
|
||||
VARIANT="OPT"
|
||||
FASTDEBUG="false"
|
||||
DEBUG_CLASSFILES="false"
|
||||
;;
|
||||
esac
|
||||
AC_SUBST(VARIANT)
|
||||
AC_SUBST(FASTDEBUG)
|
||||
AC_SUBST(DEBUG_CLASSFILES)
|
||||
|
||||
if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
|
||||
MACOSX_UNIVERSAL="true"
|
||||
fi
|
||||
|
||||
AC_SUBST(MACOSX_UNIVERSAL)
|
||||
|
||||
# Make sure JVM_VARIANTS_COMMA use minimal1 for backwards compatibility
|
||||
JVM_VARIANTS_COMMA=`$ECHO ,$JVM_VARIANTS_OPT, | $SED -e 's/,minimal,/,minimal1,/'`
|
||||
|
||||
JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS_COMMA" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'`
|
||||
JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS_COMMA" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'`
|
||||
JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS_COMMA" | $SED -e '/,minimal1\?,/!s/.*/false/g' -e '/,minimal1\?,/s/.*/true/g'`
|
||||
JVM_VARIANT_CORE=`$ECHO "$JVM_VARIANTS_COMMA" | $SED -e '/,core,/!s/.*/false/g' -e '/,core,/s/.*/true/g'`
|
||||
JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS_COMMA" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'`
|
||||
JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS_COMMA" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'`
|
||||
JVM_VARIANT_CUSTOM=`$ECHO "$JVM_VARIANTS_COMMA" | $SED -e '/,custom,/!s/.*/false/g' -e '/,custom,/s/.*/true/g'`
|
||||
|
||||
#####
|
||||
# Generate the legacy makefile targets for hotspot.
|
||||
HOTSPOT_TARGET=""
|
||||
|
||||
if test "x$JVM_VARIANT_SERVER" = xtrue; then
|
||||
HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} "
|
||||
fi
|
||||
|
||||
if test "x$JVM_VARIANT_CLIENT" = xtrue; then
|
||||
HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 "
|
||||
fi
|
||||
|
||||
if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
|
||||
HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 "
|
||||
fi
|
||||
|
||||
if test "x$JVM_VARIANT_ZERO" = xtrue; then
|
||||
HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero "
|
||||
fi
|
||||
|
||||
if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
|
||||
HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark "
|
||||
fi
|
||||
|
||||
if test "x$JVM_VARIANT_CORE" = xtrue; then
|
||||
HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}core "
|
||||
fi
|
||||
|
||||
HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_DEBUG_LEVEL"
|
||||
|
||||
# On Macosx universal binaries are produced, but they only contain
|
||||
# 64 bit intel. This invalidates control of which jvms are built
|
||||
# from configure, but only server is valid anyway. Fix this
|
||||
# when hotspot makefiles are rewritten.
|
||||
if test "x$MACOSX_UNIVERSAL" = xtrue; then
|
||||
HOTSPOT_TARGET=universal_${HOTSPOT_DEBUG_LEVEL}
|
||||
fi
|
||||
|
||||
HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET"
|
||||
AC_SUBST(HOTSPOT_MAKE_ARGS)
|
||||
|
||||
# Control wether Hotspot runs Queens test after build.
|
||||
AC_ARG_ENABLE([hotspot-test-in-build], [AS_HELP_STRING([--enable-hotspot-test-in-build],
|
||||
[run the Queens test after Hotspot build @<:@disabled@:>@])],,
|
||||
[enable_hotspot_test_in_build=no])
|
||||
if test "x$enable_hotspot_test_in_build" = "xyes"; then
|
||||
TEST_IN_BUILD=true
|
||||
if test -e "$HOTSPOT_TOPDIR/test/native"; then
|
||||
GTEST_DIR_EXISTS="true"
|
||||
else
|
||||
TEST_IN_BUILD=false
|
||||
fi
|
||||
AC_SUBST(TEST_IN_BUILD)
|
||||
|
||||
if test "x$USE_NEW_HOTSPOT_BUILD" = xfalse; then
|
||||
if test "x$JVM_VARIANT_CLIENT" = xtrue; then
|
||||
if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
|
||||
AC_MSG_ERROR([You cannot build a client JVM for a 64-bit machine.])
|
||||
fi
|
||||
fi
|
||||
if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
|
||||
if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
|
||||
AC_MSG_ERROR([You cannot build a minimal JVM for a 64-bit machine.])
|
||||
fi
|
||||
fi
|
||||
if test "x$JVM_VARIANT_CUSTOM" = xtrue; then
|
||||
AC_MSG_ERROR([You cannot build a custom JVM using the old hotspot build system.])
|
||||
fi
|
||||
GTEST_DIR_EXISTS="false"
|
||||
fi
|
||||
|
||||
AC_SUBST(JVM_VARIANTS_COMMA)
|
||||
AC_SUBST(JVM_VARIANT_SERVER)
|
||||
AC_SUBST(JVM_VARIANT_CLIENT)
|
||||
AC_SUBST(JVM_VARIANT_MINIMAL1)
|
||||
AC_SUBST(JVM_VARIANT_HOTSPOT)
|
||||
AC_SUBST(JVM_VARIANT_ZERO)
|
||||
AC_SUBST(JVM_VARIANT_ZEROSHARK)
|
||||
AC_SUBST(JVM_VARIANT_CORE)
|
||||
AC_MSG_CHECKING([if Hotspot gtest unit tests should be built])
|
||||
if test "x$enable_hotspot_gtest" = "xyes"; then
|
||||
if test "x$GTEST_DIR_EXISTS" = "xtrue"; then
|
||||
AC_MSG_RESULT([yes, forced])
|
||||
BUILD_GTEST="true"
|
||||
else
|
||||
AC_MSG_ERROR([Cannot build gtest without the test source])
|
||||
fi
|
||||
elif test "x$enable_hotspot_gtest" = "xno"; then
|
||||
AC_MSG_RESULT([no, forced])
|
||||
BUILD_GTEST="false"
|
||||
elif test "x$enable_hotspot_gtest" = "x"; then
|
||||
if test "x$GTEST_DIR_EXISTS" = "xtrue"; then
|
||||
AC_MSG_RESULT([yes])
|
||||
BUILD_GTEST="true"
|
||||
else
|
||||
AC_MSG_RESULT([no])
|
||||
BUILD_GTEST="false"
|
||||
fi
|
||||
else
|
||||
AC_MSG_ERROR([--enable-gtest must be either yes or no])
|
||||
fi
|
||||
|
||||
AC_SUBST(BUILD_GTEST)
|
||||
])
|
||||
|
@ -209,9 +209,6 @@ AC_DEFUN_ONCE([JDKOPT_SETUP_JDK_OPTIONS],
|
||||
if test "x$OPENJDK_TARGET_OS" = xaix ; then
|
||||
INCLUDE_SA=false
|
||||
fi
|
||||
if test "x$OPENJDK_TARGET_CPU" = xaarch64; then
|
||||
INCLUDE_SA=false
|
||||
fi
|
||||
AC_SUBST(INCLUDE_SA)
|
||||
|
||||
# Compress jars
|
||||
|
@ -95,6 +95,7 @@ AC_DEFUN_ONCE([LIB_SETUP_LIBRARIES],
|
||||
LIB_SETUP_LLVM
|
||||
LIB_SETUP_BUNDLED_LIBS
|
||||
LIB_SETUP_MISC_LIBS
|
||||
LIB_SETUP_SOLARIS_STLPORT
|
||||
])
|
||||
|
||||
################################################################################
|
||||
@ -189,3 +190,26 @@ AC_DEFUN_ONCE([LIB_SETUP_MISC_LIBS],
|
||||
LIBZIP_CAN_USE_MMAP=true
|
||||
AC_SUBST(LIBZIP_CAN_USE_MMAP)
|
||||
])
|
||||
|
||||
################################################################################
|
||||
# libstlport.so.1 is needed for running gtest on Solaris. Find it to
|
||||
# redistribute it in the test image.
|
||||
################################################################################
|
||||
AC_DEFUN_ONCE([LIB_SETUP_SOLARIS_STLPORT],
|
||||
[
|
||||
if test "$OPENJDK_TARGET_OS" = "solaris"; then
|
||||
# Find the root of the Solaris Studio installation from the compiler path
|
||||
SOLARIS_STUDIO_DIR="$(dirname $CC)/.."
|
||||
STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1"
|
||||
AC_MSG_CHECKING([for libstlport.so.1])
|
||||
if test -f "$STLPORT_LIB"; then
|
||||
AC_MSG_RESULT([yes, $STLPORT_LIB])
|
||||
BASIC_FIXUP_PATH([STLPORT_LIB])
|
||||
else
|
||||
AC_MSG_RESULT([no, not found at $STLPORT_LIB])
|
||||
AC_MSG_ERROR([Failed to find libstlport.so.1, cannot build Hotspot gtests])
|
||||
fi
|
||||
AC_SUBST(STLPORT_LIB)
|
||||
fi
|
||||
])
|
||||
|
||||
|
@ -366,6 +366,23 @@ AC_DEFUN([PLATFORM_SETUP_LEGACY_VARS_HELPER],
|
||||
fi
|
||||
AC_SUBST(OPENJDK_$1_OS_EXPORT_DIR)
|
||||
|
||||
# The new version string in JDK 9 also defined new naming of OS and ARCH for bundles
|
||||
# Macosx is osx and x86_64 is x64
|
||||
if test "x$OPENJDK_$1_OS" = xmacosx; then
|
||||
OPENJDK_$1_OS_BUNDLE="osx"
|
||||
else
|
||||
OPENJDK_$1_OS_BUNDLE="$OPENJDK_TARGET_OS"
|
||||
fi
|
||||
if test "x$OPENJDK_$1_CPU" = xx86_64; then
|
||||
OPENJDK_$1_CPU_BUNDLE="x64"
|
||||
else
|
||||
OPENJDK_$1_CPU_BUNDLE="$OPENJDK_$1_CPU"
|
||||
fi
|
||||
OPENJDK_$1_BUNDLE_PLATFORM="${OPENJDK_$1_OS_BUNDLE}-${OPENJDK_$1_CPU_BUNDLE}"
|
||||
AC_SUBST(OPENJDK_$1_OS_BUNDLE)
|
||||
AC_SUBST(OPENJDK_$1_CPU_BUNDLE)
|
||||
AC_SUBST(OPENJDK_$1_BUNDLE_PLATFORM)
|
||||
|
||||
if test "x$OPENJDK_$1_CPU_BITS" = x64; then
|
||||
A_LP64="LP64:="
|
||||
# -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in
|
||||
|
@ -89,6 +89,10 @@ HOTSPOT_TARGET_CPU := @HOTSPOT_TARGET_CPU@
|
||||
HOTSPOT_TARGET_CPU_ARCH := @HOTSPOT_TARGET_CPU_ARCH@
|
||||
HOTSPOT_TARGET_CPU_DEFINE := @HOTSPOT_TARGET_CPU_DEFINE@
|
||||
|
||||
OPENJDK_TARGET_CPU_BUNDLE:=@OPENJDK_TARGET_CPU_BUNDLE@
|
||||
OPENJDK_TARGET_OS_BUNDLE:=@OPENJDK_TARGET_OS_BUNDLE@
|
||||
OPENJDK_TARGET_BUNDLE_PLATFORM:=@OPENJDK_TARGET_BUNDLE_PLATFORM@
|
||||
|
||||
# We are building on this build system.
|
||||
# When not cross-compiling, it is the same as the target.
|
||||
OPENJDK_BUILD_OS:=@OPENJDK_BUILD_OS@
|
||||
@ -232,6 +236,9 @@ JVM_FEATURES_custom := @JVM_FEATURES_custom@
|
||||
VALID_JVM_FEATURES := @VALID_JVM_FEATURES@
|
||||
VALID_JVM_VARIANTS := @VALID_JVM_VARIANTS@
|
||||
|
||||
# Control wether Hotspot builds gtest tests
|
||||
BUILD_GTEST := @BUILD_GTEST@
|
||||
|
||||
# Control use of precompiled header in hotspot libjvm build
|
||||
USE_PRECOMPILED_HEADER := @USE_PRECOMPILED_HEADER@
|
||||
|
||||
@ -265,6 +272,7 @@ BUILDTOOLS_OUTPUTDIR=$(BUILD_OUTPUT)/buildtools
|
||||
HOTSPOT_OUTPUTDIR=$(BUILD_OUTPUT)/hotspot
|
||||
JDK_OUTPUTDIR=$(BUILD_OUTPUT)/jdk
|
||||
IMAGES_OUTPUTDIR=$(BUILD_OUTPUT)/images
|
||||
BUNDLES_OUTPUTDIR=$(BUILD_OUTPUT)/bundles
|
||||
TESTMAKE_OUTPUTDIR=$(BUILD_OUTPUT)/test-make
|
||||
MAKESUPPORT_OUTPUTDIR=$(BUILD_OUTPUT)/make-support
|
||||
# This does not get overridden in a bootcycle build
|
||||
@ -629,6 +637,7 @@ ECHO:=@ECHO@
|
||||
EGREP:=@EGREP@
|
||||
FGREP:=@FGREP@
|
||||
GREP:=@GREP@
|
||||
GZIP:=@GZIP@
|
||||
HEAD:=@HEAD@
|
||||
LS:=@LS@
|
||||
LN:=@LN@
|
||||
@ -676,6 +685,9 @@ XCODEBUILD=@XCODEBUILD@
|
||||
DTRACE := @DTRACE@
|
||||
FIXPATH:=@FIXPATH@
|
||||
|
||||
TAR_INCLUDE_PARAM:=@TAR_INCLUDE_PARAM@
|
||||
TAR_SUPPORTS_TRANSFORM:=@TAR_SUPPORTS_TRANSFORM@
|
||||
|
||||
# Build setup
|
||||
ENABLE_JFR=@ENABLE_JFR@
|
||||
ENABLE_INTREE_EC=@ENABLE_INTREE_EC@
|
||||
@ -685,6 +697,7 @@ USE_EXTERNAL_LIBZ:=@USE_EXTERNAL_LIBZ@
|
||||
LIBZIP_CAN_USE_MMAP:=@LIBZIP_CAN_USE_MMAP@
|
||||
MSVCR_DLL:=@MSVCR_DLL@
|
||||
MSVCP_DLL:=@MSVCP_DLL@
|
||||
STLPORT_LIB:=@STLPORT_LIB@
|
||||
|
||||
####################################################
|
||||
#
|
||||
@ -781,11 +794,46 @@ SYMBOLS_IMAGE_DIR=$(IMAGES_OUTPUTDIR)/$(SYMBOLS_IMAGE_SUBDIR)
|
||||
# Interim image
|
||||
INTERIM_IMAGE_DIR := $(SUPPORT_OUTPUTDIR)/interim-image
|
||||
|
||||
# Docs image
|
||||
DOCS_IMAGE_SUBDIR := docs
|
||||
DOCS_IMAGE_DIR := $(IMAGES_OUTPUTDIR)/$(DOCS_IMAGE_SUBDIR)
|
||||
|
||||
# Macosx bundles directory definitions
|
||||
JDK_MACOSX_BUNDLE_SUBDIR=jdk-bundle/jdk-$(VERSION_NUMBER).jdk/Contents
|
||||
JRE_MACOSX_BUNDLE_SUBDIR=jre-bundle/jre-$(VERSION_NUMBER).jre/Contents
|
||||
JDK_MACOSX_BUNDLE_SUBDIR=jdk-bundle
|
||||
JRE_MACOSX_BUNDLE_SUBDIR=jre-bundle
|
||||
JDK_MACOSX_BUNDLE_DIR=$(IMAGES_OUTPUTDIR)/$(JDK_MACOSX_BUNDLE_SUBDIR)
|
||||
JRE_MACOSX_BUNDLE_DIR=$(IMAGES_OUTPUTDIR)/$(JRE_MACOSX_BUNDLE_SUBDIR)
|
||||
JDK_MACOSX_CONTENTS_SUBDIR=jdk-$(VERSION_NUMBER).jdk/Contents
|
||||
JRE_MACOSX_CONTENTS_SUBDIR=jre-$(VERSION_NUMBER).jre/Contents
|
||||
JDK_MACOSX_CONTENTS_DIR=$(JDK_MACOSX_BUNDLE_DIR)/$(JDK_MACOSX_CONTENTS_SUBDIR)
|
||||
JRE_MACOSX_CONTENTS_DIR=$(JRE_MACOSX_BUNDLE_DIR)/$(JRE_MACOSX_CONTENTS_SUBDIR)
|
||||
|
||||
# Bundle names
|
||||
BASE_NAME := $(VERSION_SHORT)+$(VERSION_BUILD)_$(OPENJDK_TARGET_BUNDLE_PLATFORM)
|
||||
ifeq ($(DEBUG_LEVEL), fastdebug)
|
||||
DEBUG_PART := -debug
|
||||
else ifneq ($(DEBUG_LEVEL), release)
|
||||
DEBUG_PART := -$(DEBUG_LEVEL)
|
||||
endif
|
||||
JDK_BUNDLE_NAME := jdk-$(BASE_NAME)_bin$(DEBUG_PART).tar.gz
|
||||
JRE_BUNDLE_NAME := jre-$(BASE_NAME)_bin$(DEBUG_PART).tar.gz
|
||||
JDK_SYMBOLS_BUNDLE_NAME := jdk-$(BASE_NAME)_bin$(DEBUG_PART)-symbols.tar.gz
|
||||
JRE_SYMBOLS_BUNDLE_NAME := jre-$(BASE_NAME)_bin$(DEBUG_PART)-symbols.tar.gz
|
||||
ifeq ($(OPENJDK_TARGET_OS), windows)
|
||||
DEMOS_BUNDLE_NAME := jdk-$(BASE_NAME)_demo$(DEBUG_PART).zip
|
||||
else
|
||||
DEMOS_BUNDLE_NAME := jdk-$(BASE_NAME)_demo$(DEBUG_PART).tar.gz
|
||||
endif
|
||||
TEST_BUNDLE_NAME := jdk-$(BASE_NAME)_bin-tests$(DEBUG_PART).tar.gz
|
||||
DOCS_BUNDLE_NAME := jdk-$(BASE_NAME)_doc-api-spec$(DEBUG_PART).tar.gz
|
||||
|
||||
JDK_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JDK_BUNDLE_NAME)
|
||||
JRE_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JRE_BUNDLE_NAME)
|
||||
JDK_SYMBOLS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JDK_SYMBOLS_BUNDLE_NAME)
|
||||
JRE_SYMBOLS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JRE_SYMBOLS_BUNDLE_NAME)
|
||||
DEMOS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(DEMOS_BUNDLE_NAME)
|
||||
TEST_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(TEST_BUNDLE_NAME)
|
||||
DOCS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(DOCS_BUNDLE_NAME)
|
||||
|
||||
# This macro is called to allow inclusion of closed source counterparts.
|
||||
# Unless overridden in closed sources, it expands to nothing.
|
||||
|
@ -274,14 +274,19 @@ compare_file_types() {
|
||||
|
||||
$MKDIR -p $WORK_DIR
|
||||
|
||||
FILE_TYPES_FILTER="$SED \
|
||||
-e 's/BuildID[^,]*//' \
|
||||
-e 's/last modified: .*//' \
|
||||
"
|
||||
|
||||
echo -n File types...
|
||||
found=""
|
||||
for f in `cd $OTHER_DIR && $FIND . ! -type d`
|
||||
do
|
||||
if [ ! -f ${OTHER_DIR}/$f ]; then continue; fi
|
||||
if [ ! -f ${THIS_DIR}/$f ]; then continue; fi
|
||||
OF=`cd ${OTHER_DIR} && $FILE -h $f | $SED 's/BuildID[^,]*//g'`
|
||||
TF=`cd ${THIS_DIR} && $FILE -h $f | $SED 's/BuildID[^,]*//g'`
|
||||
OF=$(cd ${OTHER_DIR} && $FILE -h $f | eval $FILE_TYPES_FILTER)
|
||||
TF=$(cd ${THIS_DIR} && $FILE -h $f | eval $FILE_TYPES_FILTER)
|
||||
if [ "$OF" != "$TF" ]
|
||||
then
|
||||
if [ "`echo $OF | $GREP -c 'Zip archive data'`" -gt 0 ] \
|
||||
@ -320,7 +325,7 @@ compare_general_files() {
|
||||
! -name "*.obj" ! -name "*.o" ! -name "JavaControlPanelHelper" \
|
||||
! -name "JavaUpdater" ! -name "JavaWSApplicationStub" \
|
||||
! -name "jspawnhelper" ! -name "JavawsLauncher" ! -name "*.a" \
|
||||
! -name "finish_installation" ! -name "Sparkle" \
|
||||
! -name "finish_installation" ! -name "Sparkle" ! -name "*.tar.gz" \
|
||||
| $GREP -v "./bin/" | $SORT | $FILTER)
|
||||
|
||||
echo Other files with binary differences...
|
||||
@ -423,6 +428,10 @@ compare_zip_file() {
|
||||
then
|
||||
(cd $THIS_UNZIPDIR && $UNARCHIVE $THIS_ZIP)
|
||||
(cd $OTHER_UNZIPDIR && $UNARCHIVE $OTHER_ZIP)
|
||||
elif [ "$TYPE" = "gz" ]
|
||||
then
|
||||
(cd $THIS_UNZIPDIR && $GUNZIP -c $THIS_ZIP | $TAR xf -)
|
||||
(cd $OTHER_UNZIPDIR && $GUNZIP -c $OTHER_ZIP | $TAR xf -)
|
||||
else
|
||||
(cd $THIS_UNZIPDIR && $JIMAGE extract $THIS_ZIP)
|
||||
(cd $OTHER_UNZIPDIR && $JIMAGE extract $OTHER_ZIP)
|
||||
@ -526,10 +535,11 @@ compare_all_zip_files() {
|
||||
OTHER_DIR=$2
|
||||
WORK_DIR=$3
|
||||
|
||||
ZIPS=$(cd $THIS_DIR && $FIND . -type f -name "*.zip" | $SORT | $FILTER )
|
||||
ZIPS=$(cd $THIS_DIR && $FIND . -type f -name "*.zip" -o -name "*.tar.gz" \
|
||||
| $SORT | $FILTER )
|
||||
|
||||
if [ -n "$ZIPS" ]; then
|
||||
echo Zip files...
|
||||
echo Zip/tar.gz files...
|
||||
|
||||
return_value=0
|
||||
for f in $ZIPS; do
|
||||
@ -913,7 +923,7 @@ compare_bin_file() {
|
||||
FULLDUMP_MSG=" "
|
||||
DIFF_FULLDUMP=
|
||||
if [[ "$KNOWN_FULLDUMP_DIFF $ACCEPTED_FULLDUMP_DIFF" = *"$BIN_FILE"* ]]; then
|
||||
FULLDUMP_MSG=" ! "
|
||||
FULLDUMP_MSG=" ! "
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
@ -155,6 +155,14 @@ addBuildDir() {
|
||||
printf "%s\n" "$mn" >> $IDEA_ANT
|
||||
}
|
||||
|
||||
JTREG_HOME=" <property name=\"jtreg.home\" value=\"####\" />"
|
||||
|
||||
addJtregHome() {
|
||||
DIR=`dirname $SPEC`
|
||||
mn="`echo "$JTREG_HOME" | sed -e s@"\(.*\)####\(.*\)"@"\1$JT_HOME\2"@`"
|
||||
printf "%s\n" "$mn" >> $IDEA_ANT
|
||||
}
|
||||
|
||||
### Generate ant.xml
|
||||
|
||||
rm -f $IDEA_ANT
|
||||
@ -162,6 +170,8 @@ while IFS= read -r line
|
||||
do
|
||||
if echo "$line" | egrep "^ .* <property name=\"module.name\"" > /dev/null ; then
|
||||
addModuleName
|
||||
elif echo "$line" | egrep "^ .* <property name=\"jtreg.home\"" > /dev/null ; then
|
||||
addJtregHome
|
||||
elif echo "$line" | egrep "^ .* <property name=\"build.target.dir\"" > /dev/null ; then
|
||||
addBuildDir
|
||||
else
|
||||
|
@ -215,11 +215,11 @@ var getJibProfilesCommon = function (input) {
|
||||
var common = {};
|
||||
|
||||
common.dependencies = ["boot_jdk", "gnumake", "jtreg"],
|
||||
common.default_make_targets = ["product-images", "test-image"],
|
||||
common.default_make_targets = ["product-bundles", "test-bundles"],
|
||||
common.default_make_targets_debug = common.default_make_targets;
|
||||
common.default_make_targets_slowdebug = common.default_make_targets;
|
||||
common.configure_args = ["--enable-jtreg-failure-handler"],
|
||||
common.configure_args_32bit = ["--with-target-bits=32", "--with-jvm-variants=client,server"],
|
||||
common.configure_args_32bit = ["--with-target-bits=32"],
|
||||
common.configure_args_debug = ["--enable-debug"],
|
||||
common.configure_args_slowdebug = ["--with-debug-level=slowdebug"],
|
||||
common.organization = "jpg.infra.builddeps"
|
||||
@ -245,7 +245,7 @@ var getJibProfilesProfiles = function (input, common) {
|
||||
target_cpu: "x64",
|
||||
dependencies: concat(common.dependencies, "devkit"),
|
||||
configure_args: concat(common.configure_args, "--with-zlib=system"),
|
||||
default_make_targets: concat(common.default_make_targets, "docs-image")
|
||||
default_make_targets: concat(common.default_make_targets, "docs-bundles")
|
||||
},
|
||||
|
||||
"linux-x86": {
|
||||
@ -254,7 +254,7 @@ var getJibProfilesProfiles = function (input, common) {
|
||||
build_cpu: "x64",
|
||||
dependencies: concat(common.dependencies, "devkit"),
|
||||
configure_args: concat(common.configure_args, common.configure_args_32bit,
|
||||
"--with-zlib=system"),
|
||||
"--with-jvm-variants=minimal,client,server", "--with-zlib=system"),
|
||||
default_make_targets: common.default_make_targets
|
||||
},
|
||||
|
||||
@ -295,7 +295,8 @@ var getJibProfilesProfiles = function (input, common) {
|
||||
target_cpu: "x86",
|
||||
build_cpu: "x64",
|
||||
dependencies: concat(common.dependencies, "devkit", "freetype"),
|
||||
configure_args: concat(common.configure_args, common.configure_args_32bit),
|
||||
configure_args: concat(common.configure_args,
|
||||
"--with-jvm-variants=client,server", common.configure_args_32bit),
|
||||
default_make_targets: common.default_make_targets
|
||||
}
|
||||
};
|
||||
|
@ -361,3 +361,4 @@ cc30faa2da498c478e89ab062ff160653ca1b170 jdk-9+113
|
||||
7dfa7377a5e601b8f740741a9a80e04c72dd04d6 jdk-9+116
|
||||
7a1b36bf2fe55a9a7732489ccdd326c910329a7e jdk-9+117
|
||||
8c2c2d17f7ce92a31c9ccb44a122ec62f5a85ace jdk-9+118
|
||||
daf533920b1266603b5cbdab31908d2a931c5361 jdk-9+119
|
||||
|
@ -521,3 +521,4 @@ b64432bae5271735fd53300b2005b713e98ef411 jdk-9+114
|
||||
61a214186dae6811dd989e9165e42f7dbf02acde jdk-9+116
|
||||
88170d3642905b9e6cac03e8efcc976885a7e6da jdk-9+117
|
||||
9b1075cac08dc836ec32e7b368415cbe3aceaf8c jdk-9+118
|
||||
15f3fe264872766bcb205696198f0c1502420e17 jdk-9+119
|
||||
|
@ -83,6 +83,21 @@ suite = {
|
||||
"workingSets" : "API,JVMCI",
|
||||
},
|
||||
|
||||
"jdk.vm.ci.code.test" : {
|
||||
"subDir" : "test/compiler/jvmci",
|
||||
"sourceDirs" : ["src"],
|
||||
"dependencies" : [
|
||||
"mx:JUNIT",
|
||||
"jdk.vm.ci.amd64",
|
||||
"jdk.vm.ci.sparc",
|
||||
"jdk.vm.ci.code",
|
||||
"jdk.vm.ci.hotspot",
|
||||
],
|
||||
"checkstyle" : "jdk.vm.ci.services",
|
||||
"javaCompliance" : "1.8",
|
||||
"workingSets" : "API,JVMCI",
|
||||
},
|
||||
|
||||
"jdk.vm.ci.runtime" : {
|
||||
"subDir" : "src/jdk.vm.ci/share/classes",
|
||||
"sourceDirs" : ["src"],
|
||||
@ -164,7 +179,7 @@ suite = {
|
||||
"subDir" : "test/compiler/jvmci",
|
||||
"sourceDirs" : ["src"],
|
||||
"dependencies" : [
|
||||
"mx:TESTNG",
|
||||
"TESTNG",
|
||||
"jdk.vm.ci.hotspot",
|
||||
],
|
||||
"checkstyle" : "jdk.vm.ci.services",
|
||||
|
@ -1,895 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Top level gnumake file for hotspot builds
|
||||
#
|
||||
# Default is to build the both product images and construct an export dir.
|
||||
# The default export directory name is `pwd`/export-$(PLATFORM).
|
||||
#
|
||||
# Use: 'gnumake help' for more information.
|
||||
#
|
||||
# This makefile uses the default settings for where to find compilers and
|
||||
# tools, and obeys the ALT_* variable settings used by the other JDK
|
||||
# workspaces.
|
||||
#
|
||||
|
||||
# Expected/optional make variables defined on make command line:
|
||||
# LP64=1 or ARCH_DATA_MODEL=64 for 64bit build
|
||||
#
|
||||
# Expected/optional make variables or environment variables:
|
||||
# ALT_SLASH_JAVA Location of /java or J:
|
||||
# ALT_BOOTDIR Previous JDK home directory for javac compiler
|
||||
# ALT_OUTPUTDIR Output directory to use for hotspot build
|
||||
# ALT_EXPORT_PATH Directory to export hotspot build to
|
||||
# ALT_JDK_IMPORT_PATH Current JDK build (only for create_jdk rules)
|
||||
# ALT_JDK_TARGET_IMPORT_PATH Current JDK build when cross-compiling
|
||||
#
|
||||
# Version strings and numbers:
|
||||
# VERSION_SHORT Current JDK version (e.g. 9.0.0)
|
||||
# JDK_PREVIOUS_VERSION Previous (bootdir) JDK version (e.g. 1.5.0) (Only needed
|
||||
# to facilitate standalone build.)
|
||||
# VERSION_STRING Full version string to use (e.g. "9.0.0-ea-b42")
|
||||
# VERSION_MAJOR Major number for version (e.g. 9)
|
||||
# VERSION_MINOR Minor number for version (e.g. 0)
|
||||
# VERSION_SECURITY Security number for version (e.g. 0)
|
||||
# VERSION_PATCH Patch number for version (e.g. 0)
|
||||
#
|
||||
|
||||
# Default is build both product fastdebug and create export area
|
||||
|
||||
# Allow to build HotSpot in local directory from sources specified by GAMMADIR.
|
||||
# After make/defs.make GAMMADIR is defined.
|
||||
ifdef GAMMADIR
|
||||
ifndef ALT_OUTPUTDIR
|
||||
ALT_OUTPUTDIR := $(shell pwd)
|
||||
endif
|
||||
include $(GAMMADIR)/make/defs.make
|
||||
else
|
||||
include defs.make
|
||||
endif
|
||||
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
-include $(HS_ALT_MAKE)/Makefile.make
|
||||
|
||||
ifneq ($(ALT_OUTPUTDIR),)
|
||||
ALT_OUT=ALT_OUTPUTDIR=$(ALT_OUTPUTDIR)
|
||||
else
|
||||
ALT_OUT=
|
||||
endif
|
||||
|
||||
# Typical C1/C2 targets made available with this Makefile
|
||||
C1_VM_TARGETS=product1 fastdebug1 optimized1 debug1
|
||||
C2_VM_TARGETS=product fastdebug optimized debug
|
||||
CORE_VM_TARGETS=productcore fastdebugcore optimizedcore debugcore
|
||||
ZERO_VM_TARGETS=productzero fastdebugzero optimizedzero debugzero
|
||||
SHARK_VM_TARGETS=productshark fastdebugshark optimizedshark debugshark
|
||||
MINIMAL1_VM_TARGETS=productminimal1 fastdebugminimal1 debugminimal1
|
||||
|
||||
COMMON_VM_PRODUCT_TARGETS=product product1 docs export_product
|
||||
COMMON_VM_FASTDEBUG_TARGETS=fastdebug fastdebug1 docs export_fastdebug
|
||||
COMMON_VM_DEBUG_TARGETS=debug debug1 docs export_debug
|
||||
COMMON_VM_OPTIMIZED_TARGETS=optimized optimized1 docs export_optimized
|
||||
|
||||
# JDK directory list
|
||||
JDK_DIRS=bin include lib demo
|
||||
|
||||
all: all_product all_fastdebug
|
||||
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
all_product: productminimal1
|
||||
all_fastdebug: fastdebugminimal1
|
||||
all_debug: debugminimal1
|
||||
endif
|
||||
|
||||
ifdef BUILD_CLIENT_ONLY
|
||||
all_product: product1 docs export_product
|
||||
all_fastdebug: fastdebug1 docs export_fastdebug
|
||||
all_debug: debug1 docs export_debug
|
||||
all_optimized: optimized1 docs export_optimized
|
||||
else
|
||||
ifeq ($(MACOSX_UNIVERSAL),true)
|
||||
all_product: universal_product
|
||||
all_fastdebug: universal_fastdebug
|
||||
all_debug: universal_debug
|
||||
all_optimized: universal_optimized
|
||||
else
|
||||
all_product: $(COMMON_VM_PRODUCT_TARGETS)
|
||||
all_fastdebug: $(COMMON_VM_FASTDEBUG_TARGETS)
|
||||
all_debug: $(COMMON_VM_DEBUG_TARGETS)
|
||||
all_optimized: $(COMMON_VM_OPTIMIZED_TARGETS)
|
||||
endif
|
||||
endif
|
||||
|
||||
allzero: all_productzero all_fastdebugzero
|
||||
all_productzero: productzero docs export_product
|
||||
all_fastdebugzero: fastdebugzero docs export_fastdebug
|
||||
all_debugzero: debugzero docs export_debug
|
||||
all_optimizedzero: optimizedzero docs export_optimized
|
||||
|
||||
allshark: all_productshark all_fastdebugshark
|
||||
all_productshark: productshark docs export_product
|
||||
all_fastdebugshark: fastdebugshark docs export_fastdebug
|
||||
all_debugshark: debugshark docs export_debug
|
||||
all_optimizedshark: optimizedshark docs export_optimized
|
||||
|
||||
allcore: all_productcore all_fastdebugcore
|
||||
all_productcore: productcore docs export_product
|
||||
all_fastdebugcore: fastdebugcore docs export_fastdebug
|
||||
all_debugcore: debugcore docs export_debug
|
||||
all_optimizedcore: optimizedcore docs export_optimized
|
||||
|
||||
# Do everything
|
||||
world: all create_jdk
|
||||
|
||||
# Build or export docs
|
||||
docs:
|
||||
ifeq ($(OSNAME),windows)
|
||||
@$(ECHO) "No docs ($(VM_TARGET)) for windows"
|
||||
else
|
||||
# We specify 'BUILD_FLAVOR=product' so that the proper
|
||||
# ENABLE_FULL_DEBUG_SYMBOLS value is used.
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(MAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
$(MAKE_ARGS) BUILD_FLAVOR=product docs
|
||||
endif
|
||||
|
||||
# Output directories
|
||||
C1_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_compiler1
|
||||
C2_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_compiler2
|
||||
CORE_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_core
|
||||
MINIMAL1_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_minimal1
|
||||
ZERO_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_zero
|
||||
SHARK_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_shark
|
||||
|
||||
# Build variation of hotspot
|
||||
$(C1_VM_TARGETS):
|
||||
$(CD) $(GAMMADIR)/make; \
|
||||
$(MAKE) BUILD_DIR=$(C1_DIR) BUILD_FLAVOR=$(@:%1=%) VM_TARGET=$@ generic_build1 $(ALT_OUT)
|
||||
|
||||
$(C2_VM_TARGETS):
|
||||
$(CD) $(GAMMADIR)/make; \
|
||||
$(MAKE) BUILD_DIR=$(C2_DIR) BUILD_FLAVOR=$@ VM_TARGET=$@ generic_build2 $(ALT_OUT)
|
||||
|
||||
$(CORE_VM_TARGETS):
|
||||
$(CD) $(GAMMADIR)/make; \
|
||||
$(MAKE) BUILD_DIR=$(CORE_DIR) BUILD_FLAVOR=$(@:%core=%) VM_TARGET=$@ generic_buildcore $(ALT_OUT)
|
||||
|
||||
$(ZERO_VM_TARGETS):
|
||||
$(CD) $(GAMMADIR)/make; \
|
||||
$(MAKE) BUILD_DIR=$(ZERO_DIR) BUILD_FLAVOR=$(@:%zero=%) VM_TARGET=$@ generic_buildzero $(ALT_OUT)
|
||||
|
||||
$(SHARK_VM_TARGETS):
|
||||
$(CD) $(GAMMADIR)/make; \
|
||||
$(MAKE) BUILD_DIR=$(SHARK_DIR) BUILD_FLAVOR=$(@:%shark=%) VM_TARGET=$@ generic_buildshark $(ALT_OUT)
|
||||
|
||||
$(MINIMAL1_VM_TARGETS):
|
||||
$(CD) $(GAMMADIR)/make; \
|
||||
$(MAKE) BUILD_DIR=$(MINIMAL1_DIR) BUILD_FLAVOR=$(@:%minimal1=%) VM_TARGET=$@ generic_buildminimal1 $(ALT_OUT)
|
||||
|
||||
# Install hotspot script in build directory
|
||||
HOTSPOT_SCRIPT=$(BUILD_DIR)/$(BUILD_FLAVOR)/hotspot
|
||||
$(HOTSPOT_SCRIPT): $(GAMMADIR)/make/hotspot.script
|
||||
$(QUIETLY) $(MKDIR) -p $(BUILD_DIR)/$(BUILD_FLAVOR)
|
||||
$(QUIETLY) cat $< | sed -e 's|@@LIBARCH@@|$(LIBARCH)|g' | sed -e 's|@@JDK_IMPORT_PATH@@|$(JDK_IMPORT_PATH)|g' > $@
|
||||
$(QUIETLY) chmod +x $@
|
||||
|
||||
# Build compiler1 (client) rule, different for platforms
|
||||
generic_build1: $(HOTSPOT_SCRIPT)
|
||||
$(MKDIR) -p $(OUTPUTDIR)
|
||||
ifeq ($(OSNAME),windows)
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(NMAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
Variant=compiler1 \
|
||||
WorkSpace=$(ABS_GAMMADIR) \
|
||||
BootStrapDir=$(ABS_BOOTDIR) \
|
||||
BuildUser=$(USERNAME) \
|
||||
$(MAKE_ARGS) $(VM_TARGET:%1=%)
|
||||
else
|
||||
@$(ECHO) "No compiler1 ($(VM_TARGET)) for ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)"
|
||||
endif
|
||||
else
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(MAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
$(MAKE_ARGS) $(VM_TARGET)
|
||||
else
|
||||
@$(ECHO) "No compiler1 ($(VM_TARGET)) for ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)"
|
||||
endif
|
||||
endif
|
||||
|
||||
# Build compiler2 (server) rule, different for platforms
|
||||
generic_build2: $(HOTSPOT_SCRIPT)
|
||||
$(MKDIR) -p $(OUTPUTDIR)
|
||||
ifeq ($(OSNAME),windows)
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(NMAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
Variant=compiler2 \
|
||||
WorkSpace=$(ABS_GAMMADIR) \
|
||||
BootStrapDir=$(ABS_BOOTDIR) \
|
||||
BuildUser=$(USERNAME) \
|
||||
$(MAKE_ARGS) $(VM_TARGET)
|
||||
else
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(MAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
$(MAKE_ARGS) $(VM_TARGET)
|
||||
endif
|
||||
|
||||
# NOTE: Changes in this file was just to facilitate comparison when
|
||||
# developing the new build, and should not be integrated.
|
||||
generic_buildcore: $(HOTSPOT_SCRIPT)
|
||||
#ifeq ($(HS_ARCH),ppc)
|
||||
# ifeq ($(ARCH_DATA_MODEL),64)
|
||||
$(MKDIR) -p $(OUTPUTDIR)
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(MAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
$(MAKE_ARGS) $(VM_TARGET)
|
||||
# else
|
||||
# @$(ECHO) "No ($(VM_TARGET)) for ppc ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)"
|
||||
# endif
|
||||
#else
|
||||
# @$(ECHO) "No ($(VM_TARGET)) for $(HS_ARCH)"
|
||||
#endif
|
||||
|
||||
generic_buildzero: $(HOTSPOT_SCRIPT)
|
||||
$(MKDIR) -p $(OUTPUTDIR)
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(MAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
$(MAKE_ARGS) $(VM_TARGET)
|
||||
|
||||
generic_buildshark: $(HOTSPOT_SCRIPT)
|
||||
$(MKDIR) -p $(OUTPUTDIR)
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(MAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
$(MAKE_ARGS) $(VM_TARGET)
|
||||
|
||||
generic_buildminimal1: $(HOTSPOT_SCRIPT)
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
$(MKDIR) -p $(OUTPUTDIR)
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
ifeq ($(OSNAME),windows)
|
||||
$(ECHO) "No ($(VM_TARGET)) for $(OSNAME) ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)" ;
|
||||
else
|
||||
ifeq ($(OSNAME),solaris)
|
||||
$(ECHO) "No ($(VM_TARGET)) for $(OSNAME) ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)" ;
|
||||
else
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(MAKE) -f $(ABS_OS_MAKEFILE) $(MAKE_ARGS) $(VM_TARGET) ;
|
||||
endif
|
||||
endif
|
||||
else
|
||||
@$(ECHO) "No ($(VM_TARGET)) for $(OSNAME) ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)"
|
||||
endif
|
||||
else
|
||||
@$(ECHO) "Error: trying to build a minimal target but JVM_VARIANT_MINIMAL1 is not true."
|
||||
endif
|
||||
|
||||
remove_old_debuginfo:
|
||||
ifeq ($(JVM_VARIANT_CLIENT), true)
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
ifeq ($(OSNAME), windows)
|
||||
$(RM) -f $(EXPORT_CLIENT_DIR)/jvm.map $(EXPORT_CLIENT_DIR)/jvm.pdb
|
||||
else
|
||||
$(RM) -f $(EXPORT_CLIENT_DIR)/libjvm.debuginfo
|
||||
endif
|
||||
else
|
||||
$(RM) -f $(EXPORT_CLIENT_DIR)/libjvm.diz
|
||||
endif
|
||||
endif
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_SERVER) $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
ifeq ($(OSNAME), windows)
|
||||
$(RM) -f $(EXPORT_SERVER_DIR)/jvm.map $(EXPORT_SERVER_DIR)/jvm.pdb
|
||||
else
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(RM) -rf $(EXPORT_SERVER_DIR)/libjvm.dylib.dSYM
|
||||
else
|
||||
$(RM) -f $(EXPORT_SERVER_DIR)/libjvm.debuginfo
|
||||
endif
|
||||
endif
|
||||
else
|
||||
$(RM) -f $(EXPORT_SERVER_DIR)/libjvm.diz
|
||||
endif
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(RM) -f $(EXPORT_MINIMAL_DIR)/libjvm.debuginfo
|
||||
else
|
||||
$(RM) -f $(EXPORT_MINIMAL_DIR)/libjvm.diz
|
||||
endif
|
||||
endif
|
||||
|
||||
# Export file rule
|
||||
generic_export: $(EXPORT_LIST) remove_old_debuginfo
|
||||
|
||||
export_product:
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%=%) generic_export
|
||||
export_fastdebug:
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%=%) EXPORT_SUBDIR=/$(@:export_%=%) generic_export
|
||||
export_debug:
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%=%) EXPORT_SUBDIR=/$(@:export_%=%) generic_export
|
||||
export_optimized:
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%=%) EXPORT_SUBDIR=/$(@:export_%=%) generic_export
|
||||
|
||||
export_product_jdk::
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%_jdk=%) ALT_EXPORT_PATH=$(JDK_IMAGE_DIR) generic_export
|
||||
export_optimized_jdk::
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%_jdk=%) ALT_EXPORT_PATH=$(JDK_IMAGE_DIR)/$(@:export_%_jdk=%) generic_export
|
||||
export_fastdebug_jdk::
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%_jdk=%) ALT_EXPORT_PATH=$(JDK_IMAGE_DIR)/$(@:export_%_jdk=%) generic_export
|
||||
export_debug_jdk::
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%_jdk=%) ALT_EXPORT_PATH=$(JDK_IMAGE_DIR)/$(@:export_%_jdk=%) generic_export
|
||||
|
||||
# Export file copy rules
|
||||
XUSAGE=$(HS_SRC_DIR)/share/vm/Xusage.txt
|
||||
DOCS_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_docs
|
||||
C1_BUILD_DIR =$(C1_DIR)/$(BUILD_FLAVOR)
|
||||
C2_BUILD_DIR =$(C2_DIR)/$(BUILD_FLAVOR)
|
||||
CORE_BUILD_DIR =$(CORE_DIR)/$(BUILD_FLAVOR)
|
||||
MINIMAL1_BUILD_DIR=$(MINIMAL1_DIR)/$(BUILD_FLAVOR)
|
||||
ZERO_BUILD_DIR =$(ZERO_DIR)/$(BUILD_FLAVOR)
|
||||
SHARK_BUILD_DIR =$(SHARK_DIR)/$(BUILD_FLAVOR)
|
||||
|
||||
# Server (C2)
|
||||
ifeq ($(JVM_VARIANT_SERVER), true)
|
||||
# Common
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(C2_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(C2_BUILD_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(C2_BUILD_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Windows
|
||||
$(EXPORT_SERVER_DIR)/%.dll: $(C2_BUILD_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.pdb: $(C2_BUILD_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.map: $(C2_BUILD_DIR)/%.map
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.lib: $(C2_BUILD_DIR)/%.lib
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.diz: $(C2_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.dll: $(C2_BUILD_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.pdb: $(C2_BUILD_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.map: $(C2_BUILD_DIR)/%.map
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(C2_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(C2_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.$(LIBRARY_SUFFIX): $(C2_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.debuginfo: $(C2_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(C2_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.debuginfo: $(C2_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.diz: $(C2_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.diz: $(C2_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
# MacOS X
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.dSYM: $(C2_BUILD_DIR)/%.dSYM
|
||||
$(install-dir)
|
||||
$(EXPORT_SERVER_DIR)/%.dSYM: $(C2_BUILD_DIR)/%.dSYM
|
||||
$(install-dir)
|
||||
$(EXPORT_SERVER_DIR)/%.symbols: $(C2_BUILD_DIR)/%.symbols
|
||||
$(install-file)
|
||||
endif
|
||||
|
||||
# Client (C1)
|
||||
ifeq ($(JVM_VARIANT_CLIENT), true)
|
||||
# Common
|
||||
$(EXPORT_CLIENT_DIR)/%.diz: $(C1_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(C1_BUILD_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(C1_BUILD_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Windows
|
||||
$(EXPORT_CLIENT_DIR)/%.dll: $(C1_BUILD_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.pdb: $(C1_BUILD_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.map: $(C1_BUILD_DIR)/%.map
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.lib: $(C1_BUILD_DIR)/%.lib
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.diz: $(C1_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.dll: $(C1_BUILD_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.pdb: $(C1_BUILD_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.map: $(C1_BUILD_DIR)/%.map
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(C1_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.$(LIBRARY_SUFFIX): $(C1_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.$(LIBRARY_SUFFIX): $(C1_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.debuginfo: $(C1_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.debuginfo: $(C1_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.debuginfo: $(C1_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.diz: $(C1_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.diz: $(C1_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
# MacOS X
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.dSYM: $(C1_BUILD_DIR)/%.dSYM
|
||||
$(install-dir)
|
||||
$(EXPORT_CLIENT_DIR)/%.dSYM: $(C1_BUILD_DIR)/%.dSYM
|
||||
$(install-dir)
|
||||
endif
|
||||
|
||||
# Minimal1
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1), true)
|
||||
# Common
|
||||
$(EXPORT_MINIMAL_DIR)/%.diz: $(MINIMAL1_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(MINIMAL1_BUILD_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(MINIMAL1_BUILD_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Windows
|
||||
$(EXPORT_MINIMAL_DIR)/%.dll: $(MINIMAL1_BUILD_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.pdb: $(MINIMAL1_BUILD_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.map: $(MINIMAL1_BUILD_DIR)/%.map
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.lib: $(MINIMAL1_BUILD_DIR)/%.lib
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.diz: $(MINIMAL1_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.dll: $(MINIMAL1_BUILD_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.pdb: $(MINIMAL1_BUILD_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_BIN_DIR)/%.map: $(MINIMAL1_BUILD_DIR)/%.map
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(MINIMAL1_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.$(LIBRARY_SUFFIX): $(MINIMAL1_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.$(LIBRARY_SUFFIX): $(MINIMAL1_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.debuginfo: $(MINIMAL1_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.debuginfo: $(MINIMAL1_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.debuginfo: $(MINIMAL1_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.diz: $(MINIMAL1_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.diz: $(MINIMAL1_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
# MacOS X does not support Minimal1 config
|
||||
endif
|
||||
|
||||
# Zero
|
||||
ifeq ($(JVM_VARIANT_ZERO), true)
|
||||
# Common
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(ZERO_BUILD_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(ZERO_BUILD_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(ZERO_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.debuginfo: $(ZERO_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.diz: $(ZERO_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(ZERO_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(ZERO_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(ZERO_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
# MacOS X
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.dSYM: $(ZERO_BUILD_DIR)/%.dSYM
|
||||
$(install-dir)
|
||||
$(EXPORT_SERVER_DIR)/%.dSYM: $(ZERO_BUILD_DIR)/%.dSYM
|
||||
$(install-dir)
|
||||
endif
|
||||
|
||||
# Core
|
||||
ifeq ($(JVM_VARIANT_CORE), true)
|
||||
# Common
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(CORE_BUILD_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(CORE_BUILD_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(CORE_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.debuginfo: $(CORE_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.diz: $(CORE_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(CORE_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(CORE_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(CORE_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
|
||||
# Shark
|
||||
ifeq ($(JVM_VARIANT_ZEROSHARK), true)
|
||||
# Common
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(SHARK_BUILD_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(SHARK_BUILD_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(SHARK_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.debuginfo): $(SHARK_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.diz: $(SHARK_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(SHARK_BUILD_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(SHARK_BUILD_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(SHARK_BUILD_DIR)/%.diz
|
||||
$(install-file)
|
||||
# MacOS X
|
||||
$(EXPORT_LIB_ARCH_DIR)/%.dSYM: $(SHARK_BUILD_DIR)/%.dSYM
|
||||
$(install-dir)
|
||||
$(EXPORT_SERVER_DIR)/%.dSYM: $(SHARK_BUILD_DIR)/%.dSYM
|
||||
$(install-dir)
|
||||
endif
|
||||
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(HS_SRC_DIR)/share/vm/code/%
|
||||
$(install-file)
|
||||
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(HS_SRC_DIR)/share/vm/prims/%
|
||||
$(install-file)
|
||||
|
||||
HS_JNI_ARCH_SRC=$(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(HS_ARCH)/vm/jni_$(HS_ARCH).h)
|
||||
$(EXPORT_INCLUDE_DIR)/$(JDK_INCLUDE_SUBDIR)/jni_md.h: $(HS_JNI_ARCH_SRC)
|
||||
$(install-file)
|
||||
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(HS_SRC_DIR)/share/vm/services/%
|
||||
$(install-file)
|
||||
|
||||
JFR_EXISTS=$(shell if [ -d $(HS_ALT_SRC) ]; then echo 1; else echo 0; fi)
|
||||
# export jfr.h
|
||||
ifeq ($JFR_EXISTS,1)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(HS_ALT_SRC)/share/vm/jfr/%
|
||||
$(install-file)
|
||||
else
|
||||
$(EXPORT_INCLUDE_DIR)/jfr.h:
|
||||
endif
|
||||
|
||||
# Doc files (jvmti.html)
|
||||
$(EXPORT_DOCS_DIR)/platform/jvmti/%: $(DOCS_DIR)/%
|
||||
$(install-file)
|
||||
|
||||
# Xusage file
|
||||
$(EXPORT_SERVER_DIR)/Xusage.txt $(EXPORT_CLIENT_DIR)/Xusage.txt $(EXPORT_MINIMAL_DIR)/Xusage.txt: $(XUSAGE)
|
||||
$(prep-target)
|
||||
$(RM) $@.temp
|
||||
$(SED) 's/\(separated by \)[;:]/\1$(PATH_SEP)/g' $< > $@.temp
|
||||
$(MV) $@.temp $@
|
||||
|
||||
#
|
||||
# Clean rules
|
||||
#
|
||||
clobber clean: clean_build clean_export clean_jdk
|
||||
clean_build:
|
||||
$(RM) -r $(C1_DIR)
|
||||
$(RM) -r $(C2_DIR)
|
||||
$(RM) -r $(CORE_DIR)
|
||||
$(RM) -r $(ZERO_DIR)
|
||||
$(RM) -r $(SHARK_DIR)
|
||||
$(RM) -r $(MINIMAL1_DIR)
|
||||
clean_export:
|
||||
$(RM) -r $(EXPORT_PATH)
|
||||
clean_jdk:
|
||||
$(RM) -r $(JDK_IMAGE_DIR)
|
||||
|
||||
#
|
||||
# Create JDK and place this build into it
|
||||
#
|
||||
create_jdk: copy_jdk update_jdk
|
||||
|
||||
update_jdk: export_product_jdk export_fastdebug_jdk test_jdk
|
||||
|
||||
copy_jdk: $(JDK_IMAGE_DIR)/bin/java
|
||||
|
||||
$(JDK_IMAGE_DIR)/bin/java:
|
||||
$(RM) -r $(JDK_IMAGE_DIR)
|
||||
$(MKDIR) -p $(JDK_IMAGE_DIR)
|
||||
($(CD) $(JDK_IMPORT_PATH) && \
|
||||
$(TAR) -cf - *) | \
|
||||
($(CD) $(JDK_IMAGE_DIR) && $(TAR) -xf -)
|
||||
|
||||
|
||||
# Testing the built JVM
|
||||
RUN_JVM=JAVA_HOME=$(JDK_IMPORT_PATH) $(JDK_IMPORT_PATH)/bin/java -d$(ARCH_DATA_MODEL) -XXaltjvm=$(ALTJVM_DIR) -Dsun.java.launcher.is_altjvm=true
|
||||
generic_test:
|
||||
@$(ECHO) "Running with: $(ALTJVM_DIR)"
|
||||
@$(RUN_JVM) -Xinternalversion
|
||||
@$(RUN_JVM) -showversion -help
|
||||
|
||||
# C2 test targets
|
||||
test_product test_optimized test_fastdebug test_debug:
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(C2_DIR)/$(@:test_%=%)"
|
||||
|
||||
# C1 test targets
|
||||
test_product1 test_optimized1 test_fastdebug1 test_debug1:
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(C1_DIR)/$(@:test_%1=%)"
|
||||
else
|
||||
@$(ECHO) "No compiler1 ($(@:test_%=%)) for ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)"
|
||||
endif
|
||||
|
||||
# Zero test targets
|
||||
test_productzero test_optimizedzero test_fastdebugzero test_debugzero:
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(ZERO_DIR)/$(@:test_%zero=%)"
|
||||
|
||||
# Shark test targets
|
||||
test_productshark test_optimizedshark test_fastdebugshark test_debugshark:
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(SHARK_DIR)/$(@:test_%shark=%)"
|
||||
|
||||
# Minimal1 test targets
|
||||
test_productminimal1 test_optimizedminimal1 test_fastdebugminimal1 test_debugminimal1:
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(MINIMAL1_DIR)/$(@:test_%minimal1=%)"
|
||||
|
||||
|
||||
test_jdk:
|
||||
ifeq ($(JVM_VARIANT_CLIENT), true)
|
||||
$(JDK_IMAGE_DIR)/bin/java -d$(ARCH_DATA_MODEL) -client -Xinternalversion
|
||||
$(JDK_IMAGE_DIR)/bin/java -d$(ARCH_DATA_MODEL) -client -version
|
||||
endif
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_SERVER)\
|
||||
$(JVM_VARIANT_ZERO)$(JVM_VARIANT_ZEROSHARK)), true)
|
||||
$(JDK_IMAGE_DIR)/bin/java -d$(ARCH_DATA_MODEL) -server -Xinternalversion
|
||||
$(JDK_IMAGE_DIR)/bin/java -d$(ARCH_DATA_MODEL) -server -version
|
||||
endif
|
||||
|
||||
copy_product_jdk::
|
||||
$(RM) -r $(JDK_IMAGE_DIR)
|
||||
$(MKDIR) -p $(JDK_IMAGE_DIR)
|
||||
($(CD) $(JDK_IMPORT_PATH) && \
|
||||
$(TAR) -cf - $(JDK_DIRS)) | \
|
||||
($(CD) $(JDK_IMAGE_DIR) && $(TAR) -xf -)
|
||||
|
||||
copy_fastdebug_jdk::
|
||||
$(RM) -r $(JDK_IMAGE_DIR)/fastdebug
|
||||
$(MKDIR) -p $(JDK_IMAGE_DIR)/fastdebug
|
||||
if [ -d $(JDK_IMPORT_PATH)/fastdebug ] ; then \
|
||||
($(CD) $(JDK_IMPORT_PATH)/fastdebug && \
|
||||
$(TAR) -cf - $(JDK_DIRS)) | \
|
||||
($(CD) $(JDK_IMAGE_DIR)/fastdebug && $(TAR) -xf -) ; \
|
||||
else \
|
||||
($(CD) $(JDK_IMPORT_PATH) && \
|
||||
$(TAR) -cf - $(JDK_DIRS)) | \
|
||||
($(CD) $(JDK_IMAGE_DIR)/fastdebug && $(TAR) -xf -) ; \
|
||||
fi
|
||||
|
||||
copy_debug_jdk::
|
||||
$(RM) -r $(JDK_IMAGE_DIR)/debug
|
||||
$(MKDIR) -p $(JDK_IMAGE_DIR)/debug
|
||||
if [ -d $(JDK_IMPORT_PATH)/debug ] ; then \
|
||||
($(CD) $(JDK_IMPORT_PATH)/debug && \
|
||||
$(TAR) -cf - $(JDK_DIRS)) | \
|
||||
($(CD) $(JDK_IMAGE_DIR)/debug && $(TAR) -xf -) ; \
|
||||
elif [ -d $(JDK_IMPORT_PATH)/fastdebug ] ; then \
|
||||
($(CD) $(JDK_IMPORT_PATH)/fastdebug && \
|
||||
$(TAR) -cf - $(JDK_DIRS)) | \
|
||||
($(CD) $(JDK_IMAGE_DIR)/debug && $(TAR) -xf -) ; \
|
||||
else \
|
||||
($(CD) $(JDK_IMPORT_PATH) && \
|
||||
$(TAR) -cf - $(JDK_DIRS)) | \
|
||||
($(CD) $(JDK_IMAGE_DIR)/debug && $(TAR) -xf -) ; \
|
||||
fi
|
||||
|
||||
copy_optimized_jdk::
|
||||
$(RM) -r $(JDK_IMAGE_DIR)/optimized
|
||||
$(MKDIR) -p $(JDK_IMAGE_DIR)/optimized
|
||||
if [ -d $(JDK_IMPORT_PATH)/optimized ] ; then \
|
||||
($(CD) $(JDK_IMPORT_PATH)/optimized && \
|
||||
$(TAR) -cf - $(JDK_DIRS)) | \
|
||||
($(CD) $(JDK_IMAGE_DIR)/optimized && $(TAR) -xf -) ; \
|
||||
else \
|
||||
($(CD) $(JDK_IMPORT_PATH) && \
|
||||
$(TAR) -cf - $(JDK_DIRS)) | \
|
||||
($(CD) $(JDK_IMAGE_DIR)/optimized && $(TAR) -xf -) ; \
|
||||
fi
|
||||
|
||||
#
|
||||
# Check target
|
||||
#
|
||||
check: variable_check
|
||||
|
||||
#
|
||||
# Help target
|
||||
#
|
||||
help: intro_help target_help variable_help notes_help examples_help
|
||||
|
||||
# Intro help message
|
||||
intro_help:
|
||||
@$(ECHO) \
|
||||
"Makefile for the Hotspot workspace."
|
||||
@$(ECHO) \
|
||||
"Default behavior is to build and create an export area for the j2se builds."
|
||||
|
||||
# Target help
|
||||
target_help:
|
||||
@$(ECHO) "help: This help message"
|
||||
@$(ECHO) "all: Same as: all_product all_fastdebug"
|
||||
@$(ECHO) "world: Same as: all create_jdk"
|
||||
@$(ECHO) "all_product: Same as: product product1 export_product"
|
||||
@$(ECHO) "all_fastdebug: Same as: fastdebug fastdebug1 export_fastdebug"
|
||||
@$(ECHO) "all_debug: Same as: debug debug1 export_debug"
|
||||
@$(ECHO) "all_optimized: Same as: optimized optimized1 export_optimized"
|
||||
@$(ECHO) "clean: Clean all areas"
|
||||
@$(ECHO) "export_product: Export product files to EXPORT_PATH"
|
||||
@$(ECHO) "export_fastdebug: Export fastdebug files to EXPORT_PATH"
|
||||
@$(ECHO) "export_debug: Export debug files to EXPORT_PATH"
|
||||
@$(ECHO) "export_optimized: Export optimized files to EXPORT_PATH"
|
||||
@$(ECHO) "create_jdk: Create JDK image, export all files into it"
|
||||
@$(ECHO) "update_jdk: Update JDK image with fresh exported files"
|
||||
@$(ECHO) " "
|
||||
@$(ECHO) "Other targets are:"
|
||||
@$(ECHO) " $(C1_VM_TARGETS)"
|
||||
@$(ECHO) " $(C2_VM_TARGETS)"
|
||||
@$(ECHO) " $(MINIMAL1_VM_TARGETS)"
|
||||
|
||||
# Variable help (only common ones used by this workspace)
|
||||
variable_help: variable_help_intro variable_list variable_help_end
|
||||
variable_help_intro:
|
||||
@$(ECHO) "--- Common Variables ---"
|
||||
variable_help_end:
|
||||
@$(ECHO) " "
|
||||
@$(ECHO) "--- Make Arguments ---"
|
||||
@$(ECHO) "MAKE_ARGS=$(MAKE_ARGS)"
|
||||
|
||||
# One line descriptions for the variables
|
||||
SLASH_JAVA.desc = Root of all build tools, e.g. /java or J:
|
||||
OUTPUTDIR.desc = Output directory, default is build/<osname>
|
||||
BOOTDIR.desc = JDK used to compile agent java source and test with
|
||||
JDK_IMPORT_PATH.desc = Promoted JDK to copy for 'create_jdk'
|
||||
JDK_IMAGE_DIR.desc = Directory to place JDK to copy
|
||||
EXPORT_PATH.desc = Directory to place files to export for JDK build
|
||||
|
||||
# Make variables to print out (description and value)
|
||||
VARIABLE_PRINTVAL_LIST += \
|
||||
SLASH_JAVA \
|
||||
OUTPUTDIR \
|
||||
BOOTDIR \
|
||||
JDK_IMPORT_PATH \
|
||||
JDK_IMAGE_DIR \
|
||||
EXPORT_PATH
|
||||
|
||||
# Make variables that should refer to directories that exist
|
||||
VARIABLE_CHECKDIR_LIST += \
|
||||
SLASH_JAVA \
|
||||
BOOTDIR \
|
||||
JDK_IMPORT_PATH
|
||||
|
||||
# For pattern rules below, so all are treated the same
|
||||
DO_PRINTVAL_LIST=$(VARIABLE_PRINTVAL_LIST:%=%.printval)
|
||||
DO_CHECKDIR_LIST=$(VARIABLE_CHECKDIR_LIST:%=%.checkdir)
|
||||
|
||||
# Complete variable check
|
||||
variable_check: $(DO_CHECKDIR_LIST)
|
||||
variable_list: $(DO_PRINTVAL_LIST) variable_check
|
||||
|
||||
# Pattern rule for printing out a variable
|
||||
%.printval:
|
||||
@$(ECHO) " ALT_$* - $($*.desc)"
|
||||
@$(ECHO) " $*=$($*)"
|
||||
|
||||
# Pattern rule for checking to see if a variable with a directory exists
|
||||
%.checkdir:
|
||||
@if [ ! -d $($*) ] ; then \
|
||||
$(ECHO) "WARNING: $* does not exist, try $(MAKE) sanity"; \
|
||||
fi
|
||||
|
||||
# Pattern rule for checking to see if a variable with a file exists
|
||||
%.checkfil:
|
||||
@if [ ! -f $($*) ] ; then \
|
||||
$(ECHO) "WARNING: $* does not exist, try $(MAKE) sanity"; \
|
||||
fi
|
||||
|
||||
# Misc notes on help
|
||||
notes_help:
|
||||
@$(ECHO) \
|
||||
"--- Notes --- "
|
||||
@$(ECHO) \
|
||||
"- JDK_IMPORT_PATH must refer to a compatible build, not all past promoted"
|
||||
@$(ECHO) \
|
||||
" builds or previous release JDK builds will work."
|
||||
@$(ECHO) \
|
||||
"- The fastest builds have been when the workspace and the BOOTDIR are on"
|
||||
@$(ECHO) \
|
||||
" local disk."
|
||||
|
||||
examples_help:
|
||||
@$(ECHO) \
|
||||
"--- Examples --- "
|
||||
@$(ECHO) \
|
||||
" $(MAKE) all"
|
||||
@$(ECHO) \
|
||||
" $(MAKE) world"
|
||||
@$(ECHO) \
|
||||
" $(MAKE) ALT_BOOTDIR=/opt/java/jdk$(JDK_PREVIOUS_VERSION)"
|
||||
@$(ECHO) \
|
||||
" $(MAKE) ALT_JDK_IMPORT_PATH=/opt/java/jdk$(VERSION_STRING)"
|
||||
|
||||
# Universal build support
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
ifeq ($(MACOSX_UNIVERSAL),true)
|
||||
include $(GAMMADIR)/make/$(OSNAME)/makefiles/universal.gmk
|
||||
endif
|
||||
endif
|
||||
|
||||
# Compatibility for transition to new naming
|
||||
warn_jvmg_deprecated:
|
||||
echo "Warning: The jvmg target has been replaced with debug"
|
||||
echo "Warning: Please update your usage"
|
||||
|
||||
jvmg: warn_jvmg_deprecated debug
|
||||
|
||||
jvmg1: warn_jvmg_deprecated debug1
|
||||
|
||||
jvmgminimal1: warn_jvmg_deprecated debugminimal1
|
||||
|
||||
jvmgcore: warn_jvmg_deprecated debugcore
|
||||
|
||||
jvmgzero: warn_jvmg_deprecated debugzero
|
||||
|
||||
jvmgshark: warn_jvmg_deprecated debugshark
|
||||
|
||||
# JPRT rule to build this workspace
|
||||
include $(GAMMADIR)/make/jprt.gmk
|
||||
|
||||
.PHONY: all world clobber clean help $(C1_VM_TARGETS) $(C2_VM_TARGETS) \
|
||||
$(MINIMAL1_VM_TARGETS) \
|
||||
generic_build1 generic_build2 generic_buildminimal1 generic_export \
|
||||
export_product export_fastdebug export_debug export_optimized \
|
||||
export_jdk_product export_jdk_fastdebug export_jdk_debug \
|
||||
create_jdk copy_jdk update_jdk test_jdk \
|
||||
copy_product_jdk copy_fastdebug_jdk copy_debug_jdk \
|
||||
$(HS_ALT_MAKE)/Makefile.make remove_old_debuginfo
|
||||
|
||||
.NOTPARALLEL:
|
@ -1,369 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2015 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This makefile creates a build tree and lights off a build.
|
||||
# You can go back into the build tree and perform rebuilds or
|
||||
# incremental builds as desired. Be sure to reestablish
|
||||
# environment variable settings for LD_LIBRARY_PATH and JAVA_HOME.
|
||||
|
||||
# The make process now relies on java and javac. These can be
|
||||
# specified either implicitly on the PATH, by setting the
|
||||
# (JDK-inherited) ALT_BOOTDIR environment variable to full path to a
|
||||
# JDK in which bin/java and bin/javac are present and working (e.g.,
|
||||
# /usr/local/java/jdk1.3/solaris), or via the (JDK-inherited)
|
||||
# default BOOTDIR path value. Note that one of ALT_BOOTDIR
|
||||
# or BOOTDIR has to be set. We do *not* search javac, javah, rmic etc.
|
||||
# from the PATH.
|
||||
#
|
||||
# One can set ALT_BOOTDIR or BOOTDIR to point to a jdk that runs on
|
||||
# an architecture that differs from the target architecture, as long
|
||||
# as the bootstrap jdk runs under the same flavor of OS as the target
|
||||
# (i.e., if the target is linux, point to a jdk that runs on a linux
|
||||
# box). In order to use such a bootstrap jdk, set the make variable
|
||||
# REMOTE to the desired remote command mechanism, e.g.,
|
||||
#
|
||||
# make REMOTE="rsh -l me myotherlinuxbox"
|
||||
|
||||
# No tests on Aix.
|
||||
TEST_IN_BUILD=false
|
||||
|
||||
ifeq ($(GAMMADIR),)
|
||||
include ../../make/defs.make
|
||||
else
|
||||
include $(GAMMADIR)/make/defs.make
|
||||
endif
|
||||
include $(GAMMADIR)/make/$(OSNAME)/makefiles/rules.make
|
||||
|
||||
ifndef CC_INTERP
|
||||
ifndef FORCE_TIERED
|
||||
FORCE_TIERED=1
|
||||
endif
|
||||
endif
|
||||
|
||||
ifdef LP64
|
||||
ifeq ("$(filter $(LP64_ARCH),$(BUILDARCH))","")
|
||||
_JUNK_ := $(shell echo >&2 \
|
||||
$(OSNAME) $(ARCH) "*** ERROR: this platform does not support 64-bit compilers!")
|
||||
@exit 1
|
||||
endif
|
||||
endif
|
||||
|
||||
# we need to set up LP64 correctly to satisfy sanity checks in adlc
|
||||
ifneq ("$(filter $(LP64_ARCH),$(BUILDARCH))","")
|
||||
MFLAGS += " LP64=1 "
|
||||
endif
|
||||
|
||||
# pass USE_SUNCC further, through MFLAGS
|
||||
ifdef USE_SUNCC
|
||||
MFLAGS += " USE_SUNCC=1 "
|
||||
endif
|
||||
|
||||
# The following renders pathnames in generated Makefiles valid on
|
||||
# machines other than the machine containing the build tree.
|
||||
#
|
||||
# For example, let's say my build tree lives on /files12 on
|
||||
# exact.east.sun.com. This logic will cause GAMMADIR to begin with
|
||||
# /net/exact/files12/...
|
||||
#
|
||||
# We only do this on SunOS variants, for a couple of reasons:
|
||||
# * It is extremely rare that source trees exist on other systems
|
||||
# * It has been claimed that the Linux automounter is flakey, so
|
||||
# changing GAMMADIR in a way that exercises the automounter could
|
||||
# prove to be a source of unreliability in the build process.
|
||||
# Obviously, this Makefile is only relevant on SunOS boxes to begin
|
||||
# with, but the SunOS conditionalization will make it easier to
|
||||
# combine Makefiles in the future (assuming we ever do that).
|
||||
|
||||
ifeq ($(OSNAME),solaris)
|
||||
|
||||
# prepend current directory to relative pathnames.
|
||||
NEW_GAMMADIR := \
|
||||
$(shell echo $(GAMMADIR) | \
|
||||
sed -e "s=^\([^/].*\)=$(shell pwd)/\1=" \
|
||||
)
|
||||
unexport NEW_GAMMADIR
|
||||
|
||||
# If NEW_GAMMADIR doesn't already start with "/net/":
|
||||
ifeq ($(strip $(filter /net/%,$(NEW_GAMMADIR))),)
|
||||
# prepend /net/$(HOST)
|
||||
# remove /net/$(HOST) if name already began with /home/
|
||||
# remove /net/$(HOST) if name already began with /java/
|
||||
# remove /net/$(HOST) if name already began with /lab/
|
||||
NEW_GAMMADIR := \
|
||||
$(shell echo $(NEW_GAMMADIR) | \
|
||||
sed -e "s=^\(.*\)=/net/$(HOST)\1=" \
|
||||
-e "s=^/net/$(HOST)/home/=/home/=" \
|
||||
-e "s=^/net/$(HOST)/java/=/java/=" \
|
||||
-e "s=^/net/$(HOST)/lab/=/lab/=" \
|
||||
)
|
||||
# Don't use the new value for GAMMADIR unless a file with the new
|
||||
# name actually exists.
|
||||
ifneq ($(wildcard $(NEW_GAMMADIR)),)
|
||||
GAMMADIR := $(NEW_GAMMADIR)
|
||||
endif
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
# BUILDARCH is set to "zero" for Zero builds. VARIANTARCH
|
||||
# is used to give the build directories meaningful names.
|
||||
VARIANTARCH = $(subst i386,i486,$(ZERO_LIBARCH))
|
||||
|
||||
# There is a (semi-) regular correspondence between make targets and actions:
|
||||
#
|
||||
# Target Tree Type Build Dir
|
||||
#
|
||||
# debug compiler2 <os>_<arch>_compiler2/debug
|
||||
# fastdebug compiler2 <os>_<arch>_compiler2/fastdebug
|
||||
# optimized compiler2 <os>_<arch>_compiler2/optimized
|
||||
# product compiler2 <os>_<arch>_compiler2/product
|
||||
#
|
||||
# debug1 compiler1 <os>_<arch>_compiler1/debug
|
||||
# fastdebug1 compiler1 <os>_<arch>_compiler1/fastdebug
|
||||
# optimized1 compiler1 <os>_<arch>_compiler1/optimized
|
||||
# product1 compiler1 <os>_<arch>_compiler1/product
|
||||
#
|
||||
# debugcore core <os>_<arch>_core/debug
|
||||
# fastdebugcore core <os>_<arch>_core/fastdebug
|
||||
# optimizedcore core <os>_<arch>_core/optimized
|
||||
# productcore core <os>_<arch>_core/product
|
||||
#
|
||||
# debugzero zero <os>_<arch>_zero/debug
|
||||
# fastdebugzero zero <os>_<arch>_zero/fastdebug
|
||||
# optimizedzero zero <os>_<arch>_zero/optimized
|
||||
# productzero zero <os>_<arch>_zero/product
|
||||
#
|
||||
# debugshark shark <os>_<arch>_shark/debug
|
||||
# fastdebugshark shark <os>_<arch>_shark/fastdebug
|
||||
# optimizedshark shark <os>_<arch>_shark/optimized
|
||||
# productshark shark <os>_<arch>_shark/product
|
||||
#
|
||||
# fastdebugminimal1 minimal1 <os>_<arch>_minimal1/fastdebug
|
||||
# productminimal1 minimal1 <os>_<arch>_minimal1/product
|
||||
#
|
||||
# What you get with each target:
|
||||
#
|
||||
# debug* - debug compile with asserts enabled
|
||||
# fastdebug* - optimized compile, but with asserts enabled
|
||||
# optimized* - optimized compile, no asserts
|
||||
# product* - the shippable thing: optimized compile, no asserts, -DPRODUCT
|
||||
|
||||
# This target list needs to be coordinated with the usage message
|
||||
# in the build.sh script:
|
||||
TARGETS = debug fastdebug optimized product
|
||||
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
SUBDIR_DOCS = $(OSNAME)_$(VARIANTARCH)_docs
|
||||
else
|
||||
SUBDIR_DOCS = $(OSNAME)_$(BUILDARCH)_docs
|
||||
endif
|
||||
SUBDIRS_C1 = $(addprefix $(OSNAME)_$(BUILDARCH)_compiler1/,$(TARGETS))
|
||||
SUBDIRS_C2 = $(addprefix $(OSNAME)_$(BUILDARCH)_compiler2/,$(TARGETS))
|
||||
SUBDIRS_TIERED = $(addprefix $(OSNAME)_$(BUILDARCH)_tiered/,$(TARGETS))
|
||||
SUBDIRS_CORE = $(addprefix $(OSNAME)_$(BUILDARCH)_core/,$(TARGETS))
|
||||
SUBDIRS_ZERO = $(addprefix $(OSNAME)_$(VARIANTARCH)_zero/,$(TARGETS))
|
||||
SUBDIRS_SHARK = $(addprefix $(OSNAME)_$(VARIANTARCH)_shark/,$(TARGETS))
|
||||
SUBDIRS_MINIMAL1 = $(addprefix $(OSNAME)_$(BUILDARCH)_minimal1/,$(TARGETS))
|
||||
|
||||
TARGETS_C2 = $(TARGETS)
|
||||
TARGETS_C1 = $(addsuffix 1,$(TARGETS))
|
||||
TARGETS_TIERED = $(addsuffix tiered,$(TARGETS))
|
||||
TARGETS_CORE = $(addsuffix core,$(TARGETS))
|
||||
TARGETS_ZERO = $(addsuffix zero,$(TARGETS))
|
||||
TARGETS_SHARK = $(addsuffix shark,$(TARGETS))
|
||||
TARGETS_MINIMAL1 = $(addsuffix minimal1,$(TARGETS))
|
||||
|
||||
BUILDTREE_MAKE = $(GAMMADIR)/make/$(OSNAME)/makefiles/buildtree.make
|
||||
BUILDTREE_VARS = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OSNAME) SRCARCH=$(SRCARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH)
|
||||
BUILDTREE_VARS += HOTSPOT_VERSION_STRING=$(HOTSPOT_VERSION_STRING) VERSION_STRING=$(VERSION_STRING)
|
||||
BUILDTREE_VARS += ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS) OBJCOPY=$(OBJCOPY) STRIP_POLICY=$(STRIP_POLICY) ZIP_DEBUGINFO_FILES=$(ZIP_DEBUGINFO_FILES) ZIPEXE=$(ZIPEXE)
|
||||
|
||||
BUILDTREE = $(MAKE) -f $(BUILDTREE_MAKE) $(BUILDTREE_VARS)
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
# Could make everything by default, but that would take a while.
|
||||
all:
|
||||
@echo "Try '$(MAKE) <target> ...' where <target> is one or more of"
|
||||
@echo " $(TARGETS_C2)"
|
||||
@echo " $(TARGETS_C1)"
|
||||
@echo " $(TARGETS_CORE)"
|
||||
@echo " $(TARGETS_ZERO)"
|
||||
@echo " $(TARGETS_SHARK)"
|
||||
@echo " $(TARGETS_MINIMAL1)"
|
||||
|
||||
checks: check_os_version check_j2se_version
|
||||
|
||||
# We do not want people accidentally building on old systems (e.g. Linux 2.2.x,
|
||||
# Solaris 2.5.1, 2.6).
|
||||
# Disable this check by setting DISABLE_HOTSPOT_OS_VERSION_CHECK=ok.
|
||||
|
||||
SUPPORTED_OS_VERSION = AIX
|
||||
OS_VERSION := $(shell uname -a)
|
||||
EMPTY_IF_NOT_SUPPORTED = $(filter $(SUPPORTED_OS_VERSION),$(OS_VERSION))
|
||||
|
||||
check_os_version:
|
||||
ifeq ($(DISABLE_HOTSPOT_OS_VERSION_CHECK)$(EMPTY_IF_NOT_SUPPORTED),)
|
||||
$(QUIETLY) >&2 echo "*** This OS is not supported:" `uname -a`; exit 1;
|
||||
endif
|
||||
|
||||
# jvmti.make requires XSLT (J2SE 1.4.x or newer):
|
||||
XSLT_CHECK = $(REMOTE) $(RUN.JAVAP) javax.xml.transform.TransformerFactory
|
||||
# If not found then fail fast.
|
||||
check_j2se_version:
|
||||
$(QUIETLY) if ! $(XSLT_CHECK) > /dev/null 2>&1; then \
|
||||
$(REMOTE) $(RUN.JAVA) -version; \
|
||||
echo "*** An XSLT processor (J2SE 1.4.x or newer) is required" \
|
||||
"to bootstrap this build" 1>&2; \
|
||||
exit 1; \
|
||||
fi
|
||||
|
||||
$(SUBDIRS_TIERED): $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=tiered
|
||||
|
||||
$(SUBDIRS_C2): $(BUILDTREE_MAKE)
|
||||
ifeq ($(FORCE_TIERED),1)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=tiered FORCE_TIERED=1
|
||||
else
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=compiler2
|
||||
endif
|
||||
|
||||
$(SUBDIRS_C1): $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=compiler1
|
||||
|
||||
$(SUBDIRS_CORE): $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=core
|
||||
|
||||
$(SUBDIRS_ZERO): $(BUILDTREE_MAKE) platform_zero
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=zero VARIANTARCH=$(VARIANTARCH)
|
||||
|
||||
$(SUBDIRS_SHARK): $(BUILDTREE_MAKE) platform_zero
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=shark VARIANTARCH=$(VARIANTARCH)
|
||||
|
||||
$(SUBDIRS_MINIMAL1): $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=minimal1
|
||||
|
||||
|
||||
platform_zero: $(GAMMADIR)/make/$(OSNAME)/platform_zero.in
|
||||
$(SED) 's/@ZERO_ARCHDEF@/$(ZERO_ARCHDEF)/g;s/@ZERO_LIBARCH@/$(ZERO_LIBARCH)/g;' < $< > $@
|
||||
|
||||
# Define INSTALL=y at command line to automatically copy JVM into JAVA_HOME
|
||||
|
||||
$(TARGETS_C2): $(SUBDIRS_C2)
|
||||
cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_TIERED): $(SUBDIRS_TIERED)
|
||||
cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_C1): $(SUBDIRS_C1)
|
||||
cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_CORE): $(SUBDIRS_CORE)
|
||||
cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_ZERO): $(SUBDIRS_ZERO)
|
||||
cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_SHARK): $(SUBDIRS_SHARK)
|
||||
cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_MINIMAL1): $(SUBDIRS_MINIMAL1)
|
||||
cd $(OSNAME)_$(BUILDARCH)_minimal1/$(patsubst %minimal1,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_minimal1/$(patsubst %minimal1,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
# Just build the tree, and nothing else:
|
||||
tree: $(SUBDIRS_C2)
|
||||
tree1: $(SUBDIRS_C1)
|
||||
treecore: $(SUBDIRS_CORE)
|
||||
treezero: $(SUBDIRS_ZERO)
|
||||
treeshark: $(SUBDIRS_SHARK)
|
||||
treeminimal1: $(SUBDIRS_MINIMAL1)
|
||||
|
||||
# Doc target. This is the same for all build options.
|
||||
# Hence create a docs directory beside ...$(ARCH)_[...]
|
||||
# We specify 'BUILD_FLAVOR=product' so that the proper
|
||||
# ENABLE_FULL_DEBUG_SYMBOLS value is used.
|
||||
docs: checks
|
||||
$(QUIETLY) mkdir -p $(SUBDIR_DOCS)
|
||||
$(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) BUILD_FLAVOR=product jvmtidocs
|
||||
|
||||
# Synonyms for win32-like targets.
|
||||
compiler2: debug product
|
||||
|
||||
compiler1: debug1 product1
|
||||
|
||||
core: debugcore productcore
|
||||
|
||||
zero: debugzero productzero
|
||||
|
||||
shark: debugshark productshark
|
||||
|
||||
clean_docs:
|
||||
rm -rf $(SUBDIR_DOCS)
|
||||
|
||||
clean_compiler1 clean_compiler2 clean_core clean_zero clean_shark clean_minimal1:
|
||||
rm -rf $(OSNAME)_$(BUILDARCH)_$(subst clean_,,$@)
|
||||
|
||||
clean: clean_compiler2 clean_compiler1 clean_core clean_zero clean_shark clean_minimal1 clean_docs
|
||||
|
||||
include $(GAMMADIR)/make/cscope.make
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
.PHONY: $(TARGETS_C2) $(TARGETS_C1) $(TARGETS_CORE) $(TARGETS_ZERO) $(TARGETS_SHARK) $(TARGETS_MINIMAL1)
|
||||
.PHONY: tree tree1 treecore treezero treeshark
|
||||
.PHONY: all compiler1 compiler2 core zero shark
|
||||
.PHONY: clean clean_compiler1 clean_compiler2 clean_core clean_zero clean_shark docs clean_docs
|
||||
.PHONY: checks check_os_version check_j2se_version
|
||||
|
||||
.NOTPARALLEL:
|
@ -1,23 +0,0 @@
|
||||
#! /bin/sh
|
||||
#
|
||||
# This file is used by adlc.make to selectively update generated
|
||||
# adlc files. Because source and target diretories are relative
|
||||
# paths, this file is copied to the target build directory before
|
||||
# use.
|
||||
#
|
||||
# adlc-updater <file> <source-dir> <target-dir>
|
||||
#
|
||||
fix_lines() {
|
||||
# repair bare #line directives in $1 to refer to $2
|
||||
# and add an override of __FILE__ with just the basename on the
|
||||
# first line of the file.
|
||||
awk < $1 > $1+ -v F2=$2 '
|
||||
BEGIN { print "#line 1 \"" F2 "\""; }
|
||||
/^#line 999999$/ {print "#line " (NR+1) " \"" F2 "\""; next}
|
||||
{print}
|
||||
'
|
||||
mv $1+ $1
|
||||
}
|
||||
fix_lines $2/$1 $1
|
||||
[ -f $3/$1 ] && cmp -s $2/$1 $3/$1 || \
|
||||
( [ -f $3/$1 ] && echo Updating $3/$1 ; touch $2/made-change ; mv $2/$1 $3/$1 )
|
@ -1,87 +0,0 @@
|
||||
#! /bin/sh
|
||||
#
|
||||
# Copyright (c) 1999, 2014, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This script is used only from top.make.
|
||||
# The macro $(MFLAGS-adjusted) calls this script to
|
||||
# adjust the "-j" arguments to take into account
|
||||
# the HOTSPOT_BUILD_JOBS variable. The default
|
||||
# handling of the "-j" argument by gnumake does
|
||||
# not meet our needs, so we must adjust it ourselves.
|
||||
|
||||
# This argument adjustment applies to two recursive
|
||||
# calls to "$(MAKE) $(MFLAGS-adjusted)" in top.make.
|
||||
# One invokes adlc.make, and the other invokes vm.make.
|
||||
# The adjustment propagates the desired concurrency
|
||||
# level down to the sub-make (of the adlc or vm).
|
||||
# The default behavior of gnumake is to run all
|
||||
# sub-makes without concurrency ("-j1").
|
||||
|
||||
# Also, we use a make variable rather than an explicit
|
||||
# "-j<N>" argument to control this setting, so that
|
||||
# the concurrency setting (which must be tuned separately
|
||||
# for each MP system) can be set via an environment variable.
|
||||
# The recommended setting is 1.5x to 2x the number of available
|
||||
# CPUs on the MP system, which is large enough to keep the CPUs
|
||||
# busy (even though some jobs may be I/O bound) but not too large,
|
||||
# we may presume, to overflow the system's swap space.
|
||||
|
||||
set -eu
|
||||
|
||||
default_build_jobs=4
|
||||
|
||||
case $# in
|
||||
[12]) true;;
|
||||
*) >&2 echo "Usage: $0 ${MFLAGS} ${HOTSPOT_BUILD_JOBS}"; exit 2;;
|
||||
esac
|
||||
|
||||
MFLAGS=$1
|
||||
HOTSPOT_BUILD_JOBS=${2-}
|
||||
|
||||
# Normalize any -jN argument to the form " -j${HBJ}"
|
||||
MFLAGS=`
|
||||
echo "$MFLAGS" \
|
||||
| sed '
|
||||
s/^-/ -/
|
||||
s/ -\([^ I][^ I]*\)j/ -\1 -j/
|
||||
s/ -j[0-9][0-9]*/ -j/
|
||||
s/ -j\([^ ]\)/ -j -\1/
|
||||
s/ -j/ -j'${HOTSPOT_BUILD_JOBS:-${default_build_jobs}}'/
|
||||
' `
|
||||
|
||||
case ${HOTSPOT_BUILD_JOBS} in \
|
||||
|
||||
'') case ${MFLAGS} in
|
||||
*\ -j*)
|
||||
>&2 echo "# Note: -jN is ineffective for setting parallelism in this makefile."
|
||||
>&2 echo "# please set HOTSPOT_BUILD_JOBS=${default_build_jobs} in the command line or environment."
|
||||
esac;;
|
||||
|
||||
?*) case ${MFLAGS} in
|
||||
*\ -j*) true;;
|
||||
*) MFLAGS="-j${HOTSPOT_BUILD_JOBS} ${MFLAGS}";;
|
||||
esac;;
|
||||
esac
|
||||
|
||||
echo "${MFLAGS}"
|
@ -1,225 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This makefile (adlc.make) is included from the adlc.make in the
|
||||
# build directories.
|
||||
# It knows how to compile, link, and run the adlc.
|
||||
|
||||
include $(GAMMADIR)/make/$(Platform_os_family)/makefiles/rules.make
|
||||
|
||||
# #########################################################################
|
||||
|
||||
# OUTDIR must be the same as AD_Dir = $(GENERATED)/adfiles in top.make:
|
||||
GENERATED = ../generated
|
||||
OUTDIR = $(GENERATED)/adfiles
|
||||
|
||||
ARCH = $(Platform_arch)
|
||||
OS = $(Platform_os_family)
|
||||
|
||||
SOURCE.AD = $(OUTDIR)/$(OS)_$(Platform_arch_model).ad
|
||||
|
||||
ifeq ("${Platform_arch_model}", "${Platform_arch}")
|
||||
SOURCES.AD = \
|
||||
$(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(ARCH)/vm/$(Platform_arch_model).ad)
|
||||
else
|
||||
SOURCES.AD = \
|
||||
$(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(ARCH)/vm/$(Platform_arch_model).ad) \
|
||||
$(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(ARCH)/vm/$(Platform_arch).ad)
|
||||
endif
|
||||
|
||||
EXEC = $(OUTDIR)/adlc
|
||||
|
||||
# set VPATH so make knows where to look for source files
|
||||
Src_Dirs_V += $(GAMMADIR)/src/share/vm/adlc
|
||||
VPATH += $(Src_Dirs_V:%=%:)
|
||||
|
||||
# set INCLUDES for C preprocessor
|
||||
Src_Dirs_I += $(GAMMADIR)/src/share/vm/adlc $(GENERATED)
|
||||
INCLUDES += $(Src_Dirs_I:%=-I%)
|
||||
|
||||
# set flags for adlc compilation
|
||||
CXXFLAGS = $(SYSDEFS) $(INCLUDES)
|
||||
|
||||
# Force assertions on.
|
||||
CXXFLAGS += -DASSERT
|
||||
|
||||
# CFLAGS_WARN holds compiler options to suppress/enable warnings.
|
||||
# Suppress warnings (for now)
|
||||
CFLAGS_WARN = -w
|
||||
CFLAGS += $(CFLAGS_WARN)
|
||||
|
||||
OBJECTNAMES = \
|
||||
adlparse.o \
|
||||
archDesc.o \
|
||||
arena.o \
|
||||
dfa.o \
|
||||
dict2.o \
|
||||
filebuff.o \
|
||||
forms.o \
|
||||
formsopt.o \
|
||||
formssel.o \
|
||||
main.o \
|
||||
adlc-opcodes.o \
|
||||
output_c.o \
|
||||
output_h.o \
|
||||
|
||||
OBJECTS = $(OBJECTNAMES:%=$(OUTDIR)/%)
|
||||
|
||||
GENERATEDNAMES = \
|
||||
ad_$(Platform_arch_model).cpp \
|
||||
ad_$(Platform_arch_model).hpp \
|
||||
ad_$(Platform_arch_model)_clone.cpp \
|
||||
ad_$(Platform_arch_model)_expand.cpp \
|
||||
ad_$(Platform_arch_model)_format.cpp \
|
||||
ad_$(Platform_arch_model)_gen.cpp \
|
||||
ad_$(Platform_arch_model)_misc.cpp \
|
||||
ad_$(Platform_arch_model)_peephole.cpp \
|
||||
ad_$(Platform_arch_model)_pipeline.cpp \
|
||||
adGlobals_$(Platform_arch_model).hpp \
|
||||
dfa_$(Platform_arch_model).cpp \
|
||||
|
||||
GENERATEDFILES = $(GENERATEDNAMES:%=$(OUTDIR)/%)
|
||||
|
||||
# #########################################################################
|
||||
|
||||
all: $(EXEC)
|
||||
|
||||
$(EXEC) : $(OBJECTS)
|
||||
@echo $(LOG_INFO) Making adlc
|
||||
$(QUIETLY) $(HOST.LINK_NOPROF.CXX) -o $(EXEC) $(OBJECTS)
|
||||
|
||||
# Random dependencies:
|
||||
$(OBJECTS): opcodes.hpp classes.hpp adlc.hpp adlcVMDeps.hpp adlparse.hpp archDesc.hpp arena.hpp dict2.hpp filebuff.hpp forms.hpp formsopt.hpp formssel.hpp
|
||||
|
||||
# The source files refer to ostream.h, which sparcworks calls iostream.h
|
||||
$(OBJECTS): ostream.h
|
||||
|
||||
ostream.h :
|
||||
@echo >$@ '#include <iostream.h>'
|
||||
|
||||
dump:
|
||||
: OUTDIR=$(OUTDIR)
|
||||
: OBJECTS=$(OBJECTS)
|
||||
: products = $(GENERATEDFILES)
|
||||
|
||||
all: $(GENERATEDFILES)
|
||||
|
||||
$(GENERATEDFILES): refresh_adfiles
|
||||
|
||||
# Get a unique temporary directory name, so multiple makes can run in parallel.
|
||||
# Note that product files are updated via "mv", which is atomic.
|
||||
TEMPDIR := $(OUTDIR)/mktmp$(shell echo $$$$)
|
||||
|
||||
# Debuggable by default
|
||||
CFLAGS += -g
|
||||
|
||||
# Pass -D flags into ADLC.
|
||||
ADLCFLAGS += $(SYSDEFS)
|
||||
|
||||
# Note "+="; it is a hook so flags.make can add more flags, like -g or -DFOO.
|
||||
ADLCFLAGS += -q -T
|
||||
|
||||
ADLCFLAGS += -g
|
||||
|
||||
ifdef LP64
|
||||
ADLCFLAGS += -D_LP64
|
||||
else
|
||||
ADLCFLAGS += -U_LP64
|
||||
endif
|
||||
|
||||
#
|
||||
# adlc_updater is a simple sh script, under sccs control. It is
|
||||
# used to selectively update generated adlc files. This should
|
||||
# provide a nice compilation speed improvement.
|
||||
#
|
||||
ADLC_UPDATER_DIRECTORY = $(GAMMADIR)/make/$(OS)
|
||||
ADLC_UPDATER = adlc_updater
|
||||
$(ADLC_UPDATER): $(ADLC_UPDATER_DIRECTORY)/$(ADLC_UPDATER)
|
||||
$(QUIETLY) cp $< $@; chmod +x $@
|
||||
|
||||
# This action refreshes all generated adlc files simultaneously.
|
||||
# The way it works is this:
|
||||
# 1) create a scratch directory to work in.
|
||||
# 2) if the current working directory does not have $(ADLC_UPDATER), copy it.
|
||||
# 3) run the compiled adlc executable. This will create new adlc files in the scratch directory.
|
||||
# 4) call $(ADLC_UPDATER) on each generated adlc file. It will selectively update changed or missing files.
|
||||
# 5) If we actually updated any files, echo a notice.
|
||||
#
|
||||
refresh_adfiles: $(EXEC) $(SOURCE.AD) $(ADLC_UPDATER)
|
||||
@rm -rf $(TEMPDIR); mkdir $(TEMPDIR)
|
||||
$(QUIETLY) $(EXEC) $(ADLCFLAGS) $(SOURCE.AD) \
|
||||
-c$(TEMPDIR)/ad_$(Platform_arch_model).cpp -h$(TEMPDIR)/ad_$(Platform_arch_model).hpp -a$(TEMPDIR)/dfa_$(Platform_arch_model).cpp -v$(TEMPDIR)/adGlobals_$(Platform_arch_model).hpp \
|
||||
|| { rm -rf $(TEMPDIR); exit 1; }
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model).cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model).hpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_clone.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_expand.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_format.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_gen.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_misc.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_peephole.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_pipeline.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) adGlobals_$(Platform_arch_model).hpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) dfa_$(Platform_arch_model).cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) [ -f $(TEMPDIR)/made-change ] \
|
||||
|| echo $(LOG_INFO) "Rescanned $(SOURCE.AD) but encountered no changes."
|
||||
$(QUIETLY) rm -rf $(TEMPDIR)
|
||||
|
||||
|
||||
# #########################################################################
|
||||
|
||||
$(SOURCE.AD): $(SOURCES.AD)
|
||||
$(QUIETLY) $(PROCESS_AD_FILES) $(SOURCES.AD) > $(SOURCE.AD)
|
||||
|
||||
#PROCESS_AD_FILES = cat
|
||||
# Pass through #line directives, in case user enables -g option above:
|
||||
PROCESS_AD_FILES = awk '{ \
|
||||
if (CUR_FN != FILENAME) { CUR_FN=FILENAME; NR_BASE=NR-1; need_lineno=1 } \
|
||||
if (need_lineno && $$0 !~ /\/\//) \
|
||||
{ print "\n\n\#line " (NR-NR_BASE) " \"" FILENAME "\""; need_lineno=0 }; \
|
||||
print }'
|
||||
|
||||
$(OUTDIR)/%.o: %.cpp
|
||||
@echo $(LOG_INFO) Compiling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(HOST.COMPILE.CXX) -o $@ $< $(COMPILE_DONE)
|
||||
|
||||
# Some object files are given a prefix, to disambiguate
|
||||
# them from objects of the same name built for the VM.
|
||||
$(OUTDIR)/adlc-%.o: %.cpp
|
||||
@echo $(LOG_INFO) Compiling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(HOST.COMPILE.CXX) -o $@ $< $(COMPILE_DONE)
|
||||
|
||||
# #########################################################################
|
||||
|
||||
clean:
|
||||
rm $(OBJECTS)
|
||||
|
||||
cleanall:
|
||||
rm $(OBJECTS) $(EXEC)
|
||||
|
||||
# #########################################################################
|
||||
|
||||
.PHONY: all dump refresh_adfiles clean cleanall
|
@ -1,18 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# If we're cross compiling use that path for nm
|
||||
if [ "$CROSS_COMPILE_ARCH" != "" ]; then
|
||||
NM=$ALT_COMPILER_PATH/nm
|
||||
else
|
||||
# On AIX we have to prevent that we pick up the 'nm' version from the GNU binutils
|
||||
# which may be installed under /opt/freeware/bin. So better use an absolute path here!
|
||||
NM=/usr/bin/nm
|
||||
fi
|
||||
|
||||
$NM -X64 -B -C $* \
|
||||
| awk '{
|
||||
if (($2="d" || $2="D") && ($3 ~ /^__vft/ || $3 ~ /^gHotSpotVM/)) print "\t" $3 ";"
|
||||
if ($3 ~ /^UseSharedSpaces$/) print "\t" $3 ";"
|
||||
if ($3 ~ /^SharedArchivePath__9Arguments$/) print "\t" $3 ";"
|
||||
}' \
|
||||
| sort -u
|
@ -1,351 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Usage:
|
||||
#
|
||||
# $(MAKE) -f buildtree.make SRCARCH=srcarch BUILDARCH=buildarch LIBARCH=libarch
|
||||
# GAMMADIR=dir OS_FAMILY=os VARIANT=variant
|
||||
#
|
||||
# The macros ARCH, GAMMADIR, OS_FAMILY and VARIANT must be defined in the
|
||||
# environment or on the command-line:
|
||||
#
|
||||
# ARCH - sparc, i486, ... HotSpot cpu and os_cpu source directory
|
||||
# BUILDARCH - build directory
|
||||
# LIBARCH - the corresponding directory in JDK/JRE
|
||||
# GAMMADIR - top of workspace
|
||||
# OS_FAMILY - operating system
|
||||
# VARIANT - core, compiler1, compiler2, or tiered
|
||||
# VERSION_STRING - the JDK version string as specified by JEP-223
|
||||
# HOTSPOT_VERSION_STRING - the same as VERSION_STRING, unless overridden by a standalone build
|
||||
#
|
||||
# Builds the directory trees with makefiles plus some convenience files in
|
||||
# each directory:
|
||||
#
|
||||
# Makefile - for "make foo"
|
||||
# flags.make - with macro settings
|
||||
# vm.make - to support making "$(MAKE) -v vm.make" in makefiles
|
||||
# adlc.make -
|
||||
# trace.make - generate tracing event and type definitions
|
||||
# jvmti.make - generate JVMTI bindings from the spec (JSR-163)
|
||||
#
|
||||
# The makefiles are split this way so that "make foo" will run faster by not
|
||||
# having to read the dependency files for the vm.
|
||||
|
||||
-include $(SPEC)
|
||||
include $(GAMMADIR)/make/scm.make
|
||||
include $(GAMMADIR)/make/defs.make
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
|
||||
# 'gmake MAKE_VERBOSE=y' or 'gmake QUIETLY=' gives all the gory details.
|
||||
QUIETLY$(MAKE_VERBOSE) = @
|
||||
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
PLATFORM_FILE = $(shell dirname $(shell dirname $(shell pwd)))/platform_zero
|
||||
else
|
||||
ifdef USE_SUNCC
|
||||
PLATFORM_FILE = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH).suncc
|
||||
else
|
||||
PLATFORM_FILE = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Allow overriding of the arch part of the directory but default
|
||||
# to BUILDARCH if nothing is specified
|
||||
ifeq ($(VARIANTARCH),)
|
||||
VARIANTARCH=$(BUILDARCH)
|
||||
endif
|
||||
|
||||
ifdef FORCE_TIERED
|
||||
ifeq ($(VARIANT),tiered)
|
||||
PLATFORM_DIR = $(OS_FAMILY)_$(VARIANTARCH)_compiler2
|
||||
else
|
||||
PLATFORM_DIR = $(OS_FAMILY)_$(VARIANTARCH)_$(VARIANT)
|
||||
endif
|
||||
else
|
||||
PLATFORM_DIR = $(OS_FAMILY)_$(VARIANTARCH)_$(VARIANT)
|
||||
endif
|
||||
|
||||
#
|
||||
# We do two levels of exclusion in the shared directory.
|
||||
# TOPLEVEL excludes are pruned, they are not recursively searched,
|
||||
# but lower level directories can be named without fear of collision.
|
||||
# ALWAYS excludes are excluded at any level in the directory tree.
|
||||
#
|
||||
|
||||
ALWAYS_EXCLUDE_DIRS = $(SCM_DIRS)
|
||||
|
||||
ifeq ($(VARIANT),tiered)
|
||||
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name agent
|
||||
else
|
||||
ifeq ($(VARIANT),compiler2)
|
||||
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name c1 -o -name agent
|
||||
else
|
||||
# compiler1 and core use the same exclude list
|
||||
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name opto -o -name libadt -o -name agent
|
||||
endif
|
||||
endif
|
||||
|
||||
# Get things from the platform file.
|
||||
COMPILER = $(shell sed -n 's/^compiler[ ]*=[ ]*//p' $(PLATFORM_FILE))
|
||||
|
||||
SIMPLE_DIRS = \
|
||||
$(PLATFORM_DIR)/generated/dependencies \
|
||||
$(PLATFORM_DIR)/generated/adfiles \
|
||||
$(PLATFORM_DIR)/generated/jvmtifiles \
|
||||
$(PLATFORM_DIR)/generated/tracefiles
|
||||
|
||||
TARGETS = debug fastdebug optimized product
|
||||
SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS))
|
||||
|
||||
# For dependencies and recursive makes.
|
||||
BUILDTREE_MAKE = $(GAMMADIR)/make/$(OS_FAMILY)/makefiles/buildtree.make
|
||||
|
||||
BUILDTREE_TARGETS = Makefile flags.make flags_vm.make vm.make adlc.make jvmti.make trace.make
|
||||
|
||||
BUILDTREE_VARS = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OS_FAMILY) \
|
||||
SRCARCH=$(SRCARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH) VARIANT=$(VARIANT)
|
||||
|
||||
# Define variables to be set in flags.make.
|
||||
# Default values are set in make/defs.make.
|
||||
|
||||
# Set BUILD_USER from system-dependent hints: $LOGNAME, $(whoami)
|
||||
ifndef HOTSPOT_BUILD_USER
|
||||
HOTSPOT_BUILD_USER := $(shell echo $$LOGNAME)
|
||||
endif
|
||||
ifndef HOTSPOT_BUILD_USER
|
||||
HOTSPOT_BUILD_USER := $(shell whoami)
|
||||
endif
|
||||
# Define HOTSPOT_VM_DISTRO based on settings in make/openjdk_distro
|
||||
# or make/hotspot_distro.
|
||||
ifndef HOTSPOT_VM_DISTRO
|
||||
ifeq ($(call if-has-altsrc,$(HS_COMMON_SRC)/,true,false),true)
|
||||
include $(GAMMADIR)/make/hotspot_distro
|
||||
else
|
||||
include $(GAMMADIR)/make/openjdk_distro
|
||||
endif
|
||||
endif
|
||||
|
||||
# if hotspot-only build and/or OPENJDK isn't passed down, need to set OPENJDK
|
||||
ifndef OPENJDK
|
||||
ifneq ($(call if-has-altsrc,$(HS_COMMON_SRC)/,true,false),true)
|
||||
OPENJDK=true
|
||||
endif
|
||||
endif
|
||||
|
||||
BUILDTREE_VARS += HOTSPOT_VERSION_STRING=$(HOTSPOT_VERSION_STRING) VERSION_STRING=$(VERSION_STRING)
|
||||
|
||||
BUILDTREE = \
|
||||
$(MAKE) -f $(BUILDTREE_MAKE) $(BUILDTREE_TARGETS) $(BUILDTREE_VARS)
|
||||
|
||||
BUILDTREE_COMMENT = echo "\# Generated by $(BUILDTREE_MAKE)"
|
||||
|
||||
all: $(SUBMAKE_DIRS)
|
||||
|
||||
# Run make in each subdirectory recursively.
|
||||
$(SUBMAKE_DIRS): $(SIMPLE_DIRS) FORCE
|
||||
$(QUIETLY) [ -d $@ ] || { mkdir -p $@; }
|
||||
+$(QUIETLY) cd $@ && $(BUILDTREE) TARGET=$(@F)
|
||||
$(QUIETLY) touch $@
|
||||
|
||||
$(SIMPLE_DIRS):
|
||||
$(QUIETLY) mkdir -p $@
|
||||
|
||||
# Convenience macro which takes a source relative path, applies $(1) to the
|
||||
# absolute path, and then replaces $(GAMMADIR) in the result with a
|
||||
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile.
|
||||
gamma-path=$(subst $(GAMMADIR),\$$(GAMMADIR),$(call $(1),$(HS_COMMON_SRC)/$(2)))
|
||||
|
||||
# This bit is needed to enable local rebuilds.
|
||||
# Unless the makefile itself sets LP64, any environmental
|
||||
# setting of LP64 will interfere with the build.
|
||||
LP64_SETTING/32 = LP64 = \#empty
|
||||
LP64_SETTING/64 = LP64 = 1
|
||||
|
||||
DATA_MODE/ppc64 = 64
|
||||
|
||||
DATA_MODE = $(DATA_MODE/$(BUILDARCH))
|
||||
|
||||
flags.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo "Platform_file = $(PLATFORM_FILE)" | sed 's|$(GAMMADIR)|$$(GAMMADIR)|'; \
|
||||
sed -n '/=/s/^ */Platform_/p' < $(PLATFORM_FILE); \
|
||||
echo; \
|
||||
echo "GAMMADIR = $(GAMMADIR)"; \
|
||||
echo "HS_ALT_MAKE = $(HS_ALT_MAKE)"; \
|
||||
echo "OSNAME = $(OSNAME)"; \
|
||||
echo "SYSDEFS = \$$(Platform_sysdefs)"; \
|
||||
echo "SRCARCH = $(SRCARCH)"; \
|
||||
echo "BUILDARCH = $(BUILDARCH)"; \
|
||||
echo "LIBARCH = $(LIBARCH)"; \
|
||||
echo "TARGET = $(TARGET)"; \
|
||||
echo "HOTSPOT_VERSION_STRING = $(HOTSPOT_VERSION_STRING)"; \
|
||||
echo "VERSION_STRING = $(VERSION_STRING)"; \
|
||||
echo "HOTSPOT_BUILD_USER = $(HOTSPOT_BUILD_USER)"; \
|
||||
echo "HOTSPOT_VM_DISTRO = $(HOTSPOT_VM_DISTRO)"; \
|
||||
echo "OPENJDK = $(OPENJDK)"; \
|
||||
echo "$(LP64_SETTING/$(DATA_MODE))"; \
|
||||
echo; \
|
||||
echo "# Used for platform dispatching"; \
|
||||
echo "TARGET_DEFINES = -DTARGET_OS_FAMILY_\$$(Platform_os_family)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_ARCH_\$$(Platform_arch)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_ARCH_MODEL_\$$(Platform_arch_model)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_OS_ARCH_\$$(Platform_os_arch)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_OS_ARCH_MODEL_\$$(Platform_os_arch_model)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_COMPILER_\$$(Platform_compiler)"; \
|
||||
echo "CFLAGS += \$$(TARGET_DEFINES)"; \
|
||||
echo; \
|
||||
echo "Src_Dirs_V = \\"; \
|
||||
sed 's/$$/ \\/;s|$(GAMMADIR)|$$(GAMMADIR)|' ../shared_dirs.lst; \
|
||||
echo "$(call gamma-path,altsrc,cpu/$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,cpu/$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os_cpu/$(OS_FAMILY)_$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os_cpu/$(OS_FAMILY)_$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os/$(OS_FAMILY)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os/$(OS_FAMILY)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os/posix/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os/posix/vm)"; \
|
||||
echo; \
|
||||
echo "Src_Dirs_I = \\"; \
|
||||
echo "$(call gamma-path,altsrc,share/vm/prims) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,share/vm/prims) \\"; \
|
||||
echo "$(call gamma-path,altsrc,share/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,share/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,share/vm/precompiled) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,share/vm/precompiled) \\"; \
|
||||
echo "$(call gamma-path,altsrc,cpu/$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,cpu/$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os_cpu/$(OS_FAMILY)_$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os_cpu/$(OS_FAMILY)_$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os/$(OS_FAMILY)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os/$(OS_FAMILY)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os/posix/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os/posix/vm)"; \
|
||||
[ -n "$(CFLAGS_BROWSE)" ] && \
|
||||
echo && echo "CFLAGS_BROWSE = $(CFLAGS_BROWSE)"; \
|
||||
[ -n "$(ENABLE_FULL_DEBUG_SYMBOLS)" ] && \
|
||||
echo && echo "ENABLE_FULL_DEBUG_SYMBOLS = $(ENABLE_FULL_DEBUG_SYMBOLS)"; \
|
||||
[ -n "$(OBJCOPY)" ] && \
|
||||
echo && echo "OBJCOPY = $(OBJCOPY)"; \
|
||||
[ -n "$(STRIP_POLICY)" ] && \
|
||||
echo && echo "STRIP_POLICY = $(STRIP_POLICY)"; \
|
||||
[ -n "$(ZIP_DEBUGINFO_FILES)" ] && \
|
||||
echo && echo "ZIP_DEBUGINFO_FILES = $(ZIP_DEBUGINFO_FILES)"; \
|
||||
[ -n "$(ZIPEXE)" ] && \
|
||||
echo && echo "ZIPEXE = $(ZIPEXE)"; \
|
||||
[ -n "$(HOTSPOT_EXTRA_SYSDEFS)" ] && \
|
||||
echo && \
|
||||
echo "HOTSPOT_EXTRA_SYSDEFS\$$(HOTSPOT_EXTRA_SYSDEFS) = $(HOTSPOT_EXTRA_SYSDEFS)" && \
|
||||
echo "SYSDEFS += \$$(HOTSPOT_EXTRA_SYSDEFS)"; \
|
||||
[ -n "$(INCLUDE_TRACE)" ] && \
|
||||
echo && echo "INCLUDE_TRACE = $(INCLUDE_TRACE)"; \
|
||||
echo; \
|
||||
[ -n "$(SPEC)" ] && \
|
||||
echo "include $(SPEC)"; \
|
||||
echo "CP ?= cp"; \
|
||||
echo "MV ?= mv"; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(VARIANT).make"; \
|
||||
echo "include \$$(GAMMADIR)/make/excludeSrc.make"; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(COMPILER).make"; \
|
||||
) > $@
|
||||
|
||||
flags_vm.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(TARGET).make"; \
|
||||
) > $@
|
||||
|
||||
../shared_dirs.lst: $(BUILDTREE_MAKE) $(GAMMADIR)/src/share/vm
|
||||
@echo $(LOG_INFO) Creating directory list $@
|
||||
$(QUIETLY) if [ -d $(HS_ALT_SRC)/share/vm ]; then \
|
||||
find $(HS_ALT_SRC)/share/vm/* -prune \
|
||||
-type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \
|
||||
\( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; > $@; \
|
||||
fi;
|
||||
$(QUIETLY) find $(HS_COMMON_SRC)/share/vm/* -prune \
|
||||
-type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \
|
||||
\( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; >> $@
|
||||
|
||||
Makefile: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/top.make"; \
|
||||
) > $@
|
||||
|
||||
vm.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo include flags_vm.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
adlc.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
jvmti.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
trace.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
FORCE:
|
||||
|
||||
.PHONY: all FORCE
|
||||
|
||||
.NOTPARALLEL:
|
@ -1,32 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making server version of VM
|
||||
|
||||
TYPE=COMPILER2
|
||||
|
||||
VM_SUBDIR = server
|
||||
|
||||
CFLAGS += -DCOMPILER2
|
@ -1,33 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making core version of VM
|
||||
|
||||
# Select which files to use (in top.make)
|
||||
TYPE=CORE
|
||||
|
||||
# There is no "core" directory in JDK. Install core build in server directory.
|
||||
VM_SUBDIR = server
|
||||
|
||||
# Note: macros.hpp defines CORE
|
@ -1,41 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
|
||||
# Compiler specific DEBUG_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
DEBUG_CFLAGS/DEFAULT= $(DEBUG_CFLAGS)
|
||||
DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@))
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE)
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/aix/makefiles/mapfile-vers-debug
|
||||
|
||||
VERSION = debug
|
||||
SYSDEFS += -DASSERT -DDEBUG
|
||||
PICFLAGS = DEFAULT
|
@ -1,204 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2006, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# The common definitions for hotspot AIX builds.
|
||||
# Include the top level defs.make under make directory instead of this one.
|
||||
# This file is included into make/defs.make.
|
||||
|
||||
SLASH_JAVA ?= /java
|
||||
|
||||
define print_info
|
||||
ifneq ($$(LOG_LEVEL), warn)
|
||||
$$(shell echo >&2 "INFO: $1")
|
||||
endif
|
||||
endef
|
||||
|
||||
# Need PLATFORM (os-arch combo names) for jdk and hotspot, plus libarch name
|
||||
#ARCH:=$(shell uname -m)
|
||||
PATH_SEP = :
|
||||
ifeq ($(LP64), 1)
|
||||
ARCH_DATA_MODEL ?= 64
|
||||
else
|
||||
ARCH_DATA_MODEL ?= 32
|
||||
endif
|
||||
|
||||
ifeq ($(ARCH_DATA_MODEL), 64)
|
||||
ARCH = ppc64
|
||||
else
|
||||
ARCH = ppc
|
||||
endif
|
||||
|
||||
# PPC
|
||||
ifeq ($(ARCH), ppc)
|
||||
#ARCH_DATA_MODEL = 32
|
||||
PLATFORM = aix-ppc
|
||||
VM_PLATFORM = aix_ppc
|
||||
HS_ARCH = ppc
|
||||
endif
|
||||
|
||||
# PPC64
|
||||
ifeq ($(ARCH), ppc64)
|
||||
#ARCH_DATA_MODEL = 64
|
||||
MAKE_ARGS += LP64=1
|
||||
PLATFORM = aix-ppc64
|
||||
VM_PLATFORM = aix_ppc64
|
||||
HS_ARCH = ppc
|
||||
endif
|
||||
|
||||
# On 32 bit aix we build server and client, on 64 bit just server.
|
||||
ifeq ($(JVM_VARIANTS),)
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
JVM_VARIANTS:=client,server
|
||||
JVM_VARIANT_CLIENT:=true
|
||||
JVM_VARIANT_SERVER:=true
|
||||
else
|
||||
JVM_VARIANTS:=server
|
||||
JVM_VARIANT_SERVER:=true
|
||||
endif
|
||||
endif
|
||||
|
||||
# The Full Debug Symbols (FDS) default for BUILD_FLAVOR == product
|
||||
# builds is enabled with debug info files ZIP'ed to save space. For
|
||||
# BUILD_FLAVOR != product builds, FDS is always enabled, after all a
|
||||
# debug build without debug info isn't very useful.
|
||||
# The ZIP_DEBUGINFO_FILES option only has meaning when FDS is enabled.
|
||||
#
|
||||
# If you invoke a build with FULL_DEBUG_SYMBOLS=0, then FDS will be
|
||||
# disabled for a BUILD_FLAVOR == product build.
|
||||
#
|
||||
# Note: Use of a different variable name for the FDS override option
|
||||
# versus the FDS enabled check is intentional (FULL_DEBUG_SYMBOLS
|
||||
# versus ENABLE_FULL_DEBUG_SYMBOLS). For auto build systems that pass
|
||||
# in options via environment variables, use of distinct variables
|
||||
# prevents strange behaviours. For example, in a BUILD_FLAVOR !=
|
||||
# product build, the FULL_DEBUG_SYMBOLS environment variable will be
|
||||
# 0, but the ENABLE_FULL_DEBUG_SYMBOLS make variable will be 1. If
|
||||
# the same variable name is used, then different values can be picked
|
||||
# up by different parts of the build. Just to be clear, we only need
|
||||
# two variable names because the incoming option value can be
|
||||
# overridden in some situations, e.g., a BUILD_FLAVOR != product
|
||||
# build.
|
||||
|
||||
# Due to the multiple sub-make processes that occur this logic gets
|
||||
# executed multiple times. We reduce the noise by at least checking that
|
||||
# BUILD_FLAVOR has been set.
|
||||
ifneq ($(BUILD_FLAVOR),)
|
||||
ifeq ($(BUILD_FLAVOR), product)
|
||||
FULL_DEBUG_SYMBOLS ?= 1
|
||||
ENABLE_FULL_DEBUG_SYMBOLS = $(FULL_DEBUG_SYMBOLS)
|
||||
else
|
||||
# debug variants always get Full Debug Symbols (if available)
|
||||
ENABLE_FULL_DEBUG_SYMBOLS = 1
|
||||
endif
|
||||
$(eval $(call print_info, "ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS)"))
|
||||
# since objcopy is optional, we set ZIP_DEBUGINFO_FILES later
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
# Default OBJCOPY comes from GNU Binutils on Linux
|
||||
ifeq ($(CROSS_COMPILE_ARCH),)
|
||||
DEF_OBJCOPY=/usr/bin/objcopy
|
||||
else
|
||||
# Assume objcopy is part of the cross-compilation toolset
|
||||
ifneq ($(ALT_COMPILER_PATH),)
|
||||
DEF_OBJCOPY=$(ALT_COMPILER_PATH)/objcopy
|
||||
endif
|
||||
endif
|
||||
OBJCOPY=$(shell test -x $(DEF_OBJCOPY) && echo $(DEF_OBJCOPY))
|
||||
ifneq ($(ALT_OBJCOPY),)
|
||||
$(eval $(call print_info, "ALT_OBJCOPY=$(ALT_OBJCOPY)"))
|
||||
OBJCOPY=$(shell test -x $(ALT_OBJCOPY) && echo $(ALT_OBJCOPY))
|
||||
endif
|
||||
|
||||
ifeq ($(OBJCOPY),)
|
||||
$(eval $(call print_info, "no objcopy cmd found so cannot create .debuginfo files. You may need to set ALT_OBJCOPY."))
|
||||
ENABLE_FULL_DEBUG_SYMBOLS=0
|
||||
$(eval $(call print_info, "ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS)"))
|
||||
else
|
||||
$(eval $(call print_info, "$(OBJCOPY) cmd found so will create .debuginfo files."))
|
||||
|
||||
# Library stripping policies for .debuginfo configs:
|
||||
# all_strip - strips everything from the library
|
||||
# min_strip - strips most stuff from the library; leaves minimum symbols
|
||||
# no_strip - does not strip the library at all
|
||||
#
|
||||
# Oracle security policy requires "all_strip". A waiver was granted on
|
||||
# 2011.09.01 that permits using "min_strip" in the Java JDK and Java JRE.
|
||||
#
|
||||
# Currently, STRIP_POLICY is only used when Full Debug Symbols is enabled.
|
||||
#
|
||||
STRIP_POLICY ?= min_strip
|
||||
|
||||
$(eval $(call print_info, "STRIP_POLICY=$(STRIP_POLICY)"))
|
||||
|
||||
ZIP_DEBUGINFO_FILES ?= 1
|
||||
|
||||
$(eval $(call print_info, "ZIP_DEBUGINFO_FILES=$(ZIP_DEBUGINFO_FILES)"))
|
||||
endif
|
||||
endif # ENABLE_FULL_DEBUG_SYMBOLS=1
|
||||
endif # BUILD_FLAVOR
|
||||
|
||||
# unused JDK_INCLUDE_SUBDIR=aix
|
||||
|
||||
# Library suffix
|
||||
LIBRARY_SUFFIX=so
|
||||
|
||||
EXPORT_LIST += $(EXPORT_DOCS_DIR)/platform/jvmti/jvmti.html
|
||||
|
||||
# client and server subdirectories have symbolic links to ../libjsig.so
|
||||
EXPORT_LIST += $(EXPORT_LIB_ARCH_DIR)/libjsig.$(LIBRARY_SUFFIX)
|
||||
#ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
# ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# EXPORT_LIST += $(EXPORT_LIB_ARCH_DIR)/libjsig.diz
|
||||
# else
|
||||
# EXPORT_LIST += $(EXPORT_LIB_ARCH_DIR)/libjsig.debuginfo
|
||||
# endif
|
||||
#endif
|
||||
EXPORT_SERVER_DIR = $(EXPORT_LIB_ARCH_DIR)/server
|
||||
EXPORT_CLIENT_DIR = $(EXPORT_LIB_ARCH_DIR)/client
|
||||
EXPORT_MINIMAL_DIR = $(EXPORT_LIB_ARCH_DIR)/minimal
|
||||
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_SERVER) $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK) $(JVM_VARIANT_CORE)), true)
|
||||
EXPORT_LIST += $(EXPORT_SERVER_DIR)/Xusage.txt
|
||||
EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.$(LIBRARY_SUFFIX)
|
||||
# ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
# ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.diz
|
||||
# else
|
||||
# EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.debuginfo
|
||||
# endif
|
||||
# endif
|
||||
endif
|
||||
|
||||
ifeq ($(JVM_VARIANT_CLIENT),true)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/Xusage.txt
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.$(LIBRARY_SUFFIX)
|
||||
# ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
# ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.diz
|
||||
# else
|
||||
# EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.debuginfo
|
||||
# endif
|
||||
# endif
|
||||
endif
|
@ -1,27 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Linux does not build jvm_db
|
||||
LIBJVM_DB =
|
||||
|
@ -1,72 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
|
||||
# Compiler specific OPT_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
# Pare down optimization to -O2 if xlCV10.1 is in use.
|
||||
OPT_CFLAGS/DEFAULT= $(OPT_CFLAGS) $(QV10_OPT_CONSERVATIVE)
|
||||
OPT_CFLAGS/BYFILE = $(OPT_CFLAGS/$@)$(OPT_CFLAGS/DEFAULT$(OPT_CFLAGS/$@))
|
||||
|
||||
# (OPT_CFLAGS/SLOWER is also available, to alter compilation of buggy files)
|
||||
|
||||
ifeq ($(BUILDARCH), ia64)
|
||||
# Bug in GCC, causes hang. -O1 will override the -O3 specified earlier
|
||||
OPT_CFLAGS/callGenerator.o += -O1
|
||||
OPT_CFLAGS/ciTypeFlow.o += -O1
|
||||
OPT_CFLAGS/compile.o += -O1
|
||||
OPT_CFLAGS/concurrentMarkSweepGeneration.o += -O1
|
||||
OPT_CFLAGS/doCall.o += -O1
|
||||
OPT_CFLAGS/generateOopMap.o += -O1
|
||||
OPT_CFLAGS/generateOptoStub.o += -O1
|
||||
OPT_CFLAGS/graphKit.o += -O1
|
||||
OPT_CFLAGS/instanceKlass.o += -O1
|
||||
OPT_CFLAGS/interpreterRT_ia64.o += -O1
|
||||
OPT_CFLAGS/output.o += -O1
|
||||
OPT_CFLAGS/parse1.o += -O1
|
||||
OPT_CFLAGS/runtime.o += -O1
|
||||
OPT_CFLAGS/synchronizer.o += -O1
|
||||
endif
|
||||
|
||||
|
||||
# If you set HOTSPARC_GENERIC=yes, you disable all OPT_CFLAGS settings
|
||||
CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/aix/makefiles/mapfile-vers-debug
|
||||
|
||||
# xlc 10.1 parameters for ipa linkage.
|
||||
# - remove ipa linkage altogether. Does not seem to benefit performance,
|
||||
# but increases code footprint.
|
||||
# - this is a debug build in the end. Extra effort for ipa linkage is thus
|
||||
# not justified.
|
||||
LFLAGS_QIPA=
|
||||
|
||||
VERSION = optimized
|
||||
SYSDEFS += -DASSERT
|
||||
PICFLAGS = DEFAULT
|
@ -1,87 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 2014, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Rules to build signal interposition library, used by vm.make
|
||||
|
||||
# libjsig.so: signal interposition library
|
||||
JSIG = jsig
|
||||
LIBJSIG = lib$(JSIG).so
|
||||
|
||||
LIBJSIG_DEBUGINFO = lib$(JSIG).debuginfo
|
||||
LIBJSIG_DIZ = lib$(JSIG).diz
|
||||
|
||||
JSIGSRCDIR = $(GAMMADIR)/src/os/$(Platform_os_family)/vm
|
||||
|
||||
DEST_JSIG = $(JDK_LIBDIR)/$(LIBJSIG)
|
||||
DEST_JSIG_DEBUGINFO = $(JDK_LIBDIR)/$(LIBJSIG_DEBUGINFO)
|
||||
DEST_JSIG_DIZ = $(JDK_LIBDIR)/$(LIBJSIG_DIZ)
|
||||
|
||||
LIBJSIG_MAPFILE = $(MAKEFILES_DIR)/mapfile-vers-jsig
|
||||
|
||||
# On Linux we really dont want a mapfile, as this library is small
|
||||
# and preloaded using LD_PRELOAD, making functions private will
|
||||
# cause problems with interposing. See CR: 6466665
|
||||
# LFLAGS_JSIG += $(MAPFLAG:FILENAME=$(LIBJSIG_MAPFILE))
|
||||
|
||||
LFLAGS_JSIG += -D_GNU_SOURCE -D_REENTRANT $(LDFLAGS_HASH_STYLE)
|
||||
|
||||
LFLAGS_JSIG += $(BIN_UTILS)
|
||||
|
||||
# DEBUG_BINARIES overrides everything, use full -g debug information
|
||||
ifeq ($(DEBUG_BINARIES), true)
|
||||
JSIG_DEBUG_CFLAGS = -g
|
||||
endif
|
||||
|
||||
$(LIBJSIG): $(JSIGSRCDIR)/jsig.c $(LIBJSIG_MAPFILE)
|
||||
@echo $(LOG_INFO) Making signal interposition lib...
|
||||
$(QUIETLY) $(CXX) $(SYMFLAG) $(ARCHFLAG) $(SHARED_FLAG) $(PICFLAG) \
|
||||
$(LFLAGS_JSIG) $(JSIG_DEBUG_CFLAGS) -o $@ $< -ldl
|
||||
|
||||
#ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
# $(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJSIG_DEBUGINFO)
|
||||
# $(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJSIG_DEBUGINFO) $@
|
||||
# ifeq ($(STRIP_POLICY),all_strip)
|
||||
# $(QUIETLY) $(STRIP) $@
|
||||
# else
|
||||
# ifeq ($(STRIP_POLICY),min_strip)
|
||||
# $(QUIETLY) $(STRIP) -g $@
|
||||
# # implied else here is no stripping at all
|
||||
# endif
|
||||
# endif
|
||||
# ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# $(ZIPEXE) -q -y $(LIBJSIG_DIZ) $(LIBJSIG_DEBUGINFO)
|
||||
# $(RM) $(LIBJSIG_DEBUGINFO)
|
||||
# endif
|
||||
#endif
|
||||
|
||||
install_jsig: $(LIBJSIG)
|
||||
@echo "Copying $(LIBJSIG) to $(DEST_JSIG)"
|
||||
$(QUIETLY) test -f $(LIBJSIG_DEBUGINFO) && \
|
||||
$(CP) -f $(LIBJSIG_DEBUGINFO) $(DEST_JSIG_DEBUGINFO)
|
||||
$(QUIETLY) test -f $(LIBJSIG_DIZ) && \
|
||||
$(CP) -f $(LIBJSIG_DIZ) $(DEST_JSIG_DIZ)
|
||||
$(QUIETLY) $(CP) -f $(LIBJSIG) $(DEST_JSIG) && echo "Done"
|
||||
|
||||
.PHONY: install_jsig
|
@ -1,117 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This makefile (jvmti.make) is included from the jvmti.make in the
|
||||
# build directories.
|
||||
#
|
||||
# It knows how to build and run the tools to generate jvmti.
|
||||
|
||||
include $(GAMMADIR)/make/aix/makefiles/rules.make
|
||||
|
||||
# #########################################################################
|
||||
|
||||
TOPDIR = $(shell echo `pwd`)
|
||||
GENERATED = $(TOPDIR)/../generated
|
||||
JvmtiOutDir = $(GENERATED)/jvmtifiles
|
||||
|
||||
JvmtiSrcDir = $(GAMMADIR)/src/share/vm/prims
|
||||
InterpreterSrcDir = $(GAMMADIR)/src/share/vm/interpreter
|
||||
|
||||
# set VPATH so make knows where to look for source files
|
||||
Src_Dirs_V += $(JvmtiSrcDir)
|
||||
VPATH += $(Src_Dirs_V:%=%:)
|
||||
|
||||
JvmtiGeneratedNames = \
|
||||
jvmtiEnv.hpp \
|
||||
jvmtiEnter.cpp \
|
||||
jvmtiEnterTrace.cpp \
|
||||
jvmtiEnvRecommended.cpp \
|
||||
bytecodeInterpreterWithChecks.cpp \
|
||||
jvmti.h \
|
||||
|
||||
JvmtiEnvFillSource = $(JvmtiSrcDir)/jvmtiEnvFill.java
|
||||
JvmtiEnvFillClass = $(JvmtiOutDir)/jvmtiEnvFill.class
|
||||
|
||||
JvmtiGenSource = $(JvmtiSrcDir)/jvmtiGen.java
|
||||
JvmtiGenClass = $(JvmtiOutDir)/jvmtiGen.class
|
||||
|
||||
JvmtiGeneratedFiles = $(JvmtiGeneratedNames:%=$(JvmtiOutDir)/%)
|
||||
|
||||
XSLT = $(QUIETLY) $(REMOTE) $(RUN.JAVA) -classpath $(JvmtiOutDir) jvmtiGen
|
||||
|
||||
.PHONY: all jvmtidocs clean cleanall
|
||||
|
||||
# #########################################################################
|
||||
|
||||
all: $(JvmtiGeneratedFiles)
|
||||
|
||||
both = $(JvmtiGenClass) $(JvmtiSrcDir)/jvmti.xml $(JvmtiSrcDir)/jvmtiLib.xsl
|
||||
|
||||
$(JvmtiGenClass): $(JvmtiGenSource)
|
||||
$(QUIETLY) $(REMOTE) $(COMPILE.JAVAC) -d $(JvmtiOutDir) $(JvmtiGenSource)
|
||||
|
||||
$(JvmtiEnvFillClass): $(JvmtiEnvFillSource)
|
||||
$(QUIETLY) $(REMOTE) $(COMPILE.JAVAC) -d $(JvmtiOutDir) $(JvmtiEnvFillSource)
|
||||
|
||||
$(JvmtiOutDir)/jvmtiEnter.cpp: $(both) $(JvmtiSrcDir)/jvmtiEnter.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiEnter.xsl -OUT $(JvmtiOutDir)/jvmtiEnter.cpp -PARAM interface jvmti
|
||||
|
||||
$(JvmtiOutDir)/bytecodeInterpreterWithChecks.cpp: $(JvmtiGenClass) $(InterpreterSrcDir)/bytecodeInterpreter.cpp $(InterpreterSrcDir)/bytecodeInterpreterWithChecks.xml $(InterpreterSrcDir)/bytecodeInterpreterWithChecks.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(InterpreterSrcDir)/bytecodeInterpreterWithChecks.xml -XSL $(InterpreterSrcDir)/bytecodeInterpreterWithChecks.xsl -OUT $(JvmtiOutDir)/bytecodeInterpreterWithChecks.cpp
|
||||
|
||||
$(JvmtiOutDir)/jvmtiEnterTrace.cpp: $(both) $(JvmtiSrcDir)/jvmtiEnter.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiEnter.xsl -OUT $(JvmtiOutDir)/jvmtiEnterTrace.cpp -PARAM interface jvmti -PARAM trace Trace
|
||||
|
||||
$(JvmtiOutDir)/jvmtiEnvRecommended.cpp: $(both) $(JvmtiSrcDir)/jvmtiEnv.xsl $(JvmtiSrcDir)/jvmtiEnv.cpp $(JvmtiEnvFillClass)
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiEnv.xsl -OUT $(JvmtiOutDir)/jvmtiEnvStub.cpp
|
||||
$(QUIETLY) $(REMOTE) $(RUN.JAVA) -classpath $(JvmtiOutDir) jvmtiEnvFill $(JvmtiSrcDir)/jvmtiEnv.cpp $(JvmtiOutDir)/jvmtiEnvStub.cpp $(JvmtiOutDir)/jvmtiEnvRecommended.cpp
|
||||
|
||||
$(JvmtiOutDir)/jvmtiEnv.hpp: $(both) $(JvmtiSrcDir)/jvmtiHpp.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiHpp.xsl -OUT $(JvmtiOutDir)/jvmtiEnv.hpp
|
||||
|
||||
$(JvmtiOutDir)/jvmti.h: $(both) $(JvmtiSrcDir)/jvmtiH.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiH.xsl -OUT $(JvmtiOutDir)/jvmti.h
|
||||
|
||||
jvmtidocs: $(JvmtiOutDir)/jvmti.html
|
||||
|
||||
$(JvmtiOutDir)/jvmti.html: $(both) $(JvmtiSrcDir)/jvmti.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmti.xsl -OUT $(JvmtiOutDir)/jvmti.html
|
||||
|
||||
# #########################################################################
|
||||
|
||||
clean :
|
||||
rm $(JvmtiGenClass) $(JvmtiEnvFillClass) $(JvmtiGeneratedFiles)
|
||||
|
||||
cleanall :
|
||||
rm $(JvmtiGenClass) $(JvmtiEnvFillClass) $(JvmtiGeneratedFiles)
|
||||
|
||||
# #########################################################################
|
@ -1,56 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2002, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Define public interface.
|
||||
|
||||
SUNWprivate_1.1 {
|
||||
global:
|
||||
JVM_handle_linux_signal;
|
||||
|
||||
# debug JVM
|
||||
JVM_AccessVMBooleanFlag;
|
||||
JVM_AccessVMIntFlag;
|
||||
JVM_VMBreakPoint;
|
||||
|
||||
# miscellaneous functions
|
||||
jio_fprintf;
|
||||
jio_printf;
|
||||
jio_snprintf;
|
||||
jio_vfprintf;
|
||||
jio_vsnprintf;
|
||||
numa_warn;
|
||||
numa_error;
|
||||
|
||||
# Needed because there is no JVM interface for this.
|
||||
sysThreadAvailableStackWithSlack;
|
||||
|
||||
# This is for Forte Analyzer profiling support.
|
||||
AsyncGetCallTrace;
|
||||
|
||||
# INSERT VTABLE SYMBOLS HERE
|
||||
|
||||
local:
|
||||
*;
|
||||
};
|
||||
|
@ -1,38 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Define library interface.
|
||||
|
||||
SUNWprivate_1.1 {
|
||||
global:
|
||||
JVM_begin_signal_setting;
|
||||
JVM_end_signal_setting;
|
||||
JVM_get_libjsig_version;
|
||||
JVM_get_signal_action;
|
||||
sigaction;
|
||||
signal;
|
||||
sigset;
|
||||
local:
|
||||
*;
|
||||
};
|
@ -1,51 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2002, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Define public interface.
|
||||
|
||||
SUNWprivate_1.1 {
|
||||
global:
|
||||
JVM_handle_linux_signal;
|
||||
|
||||
# miscellaneous functions
|
||||
jio_fprintf;
|
||||
jio_printf;
|
||||
jio_snprintf;
|
||||
jio_vfprintf;
|
||||
jio_vsnprintf;
|
||||
numa_warn;
|
||||
numa_error;
|
||||
|
||||
# Needed because there is no JVM interface for this.
|
||||
sysThreadAvailableStackWithSlack;
|
||||
|
||||
# This is for Forte Analyzer profiling support.
|
||||
AsyncGetCallTrace;
|
||||
|
||||
# INSERT VTABLE SYMBOLS HERE
|
||||
|
||||
local:
|
||||
*;
|
||||
};
|
||||
|
@ -1,93 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2004, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2015 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Produce 64 bits object files.
|
||||
CFLAGS += -q64
|
||||
|
||||
# Balanced tuning for recent versions of the POWER architecture (if supported by xlc).
|
||||
QTUNE=$(if $(CXX_SUPPORTS_BALANCED_TUNING),balanced,pwr5)
|
||||
|
||||
# Try to speed up the interpreter: use ppc64 instructions and inline
|
||||
# glue code for external functions.
|
||||
OPT_CFLAGS += -qarch=ppc64 -qtune=$(QTUNE) -qinlglue
|
||||
|
||||
# We need variable length arrays
|
||||
CFLAGS += -qlanglvl=c99vla
|
||||
# Just to check for unwanted macro redefinitions
|
||||
CFLAGS += -qlanglvl=noredefmac
|
||||
|
||||
# Suppress those "implicit private" warnings xlc gives.
|
||||
# - The omitted keyword "private" is assumed for base class "...".
|
||||
CFLAGS += -qsuppress=1540-0198
|
||||
|
||||
# Suppress the following numerous warning:
|
||||
# - 1540-1090 (I) The destructor of "..." might not be called.
|
||||
# - 1500-010: (W) WARNING in ...: Infinite loop. Program may not stop.
|
||||
# There are several infinite loops in the vm, suppress.
|
||||
# - 1540-1639 (I) The behavior of long type bit fields has changed ...
|
||||
# ... long type bit fields now default to long, not int.
|
||||
CFLAGS += -qsuppress=1540-1090 -qsuppress=1500-010 -qsuppress=1540-1639
|
||||
|
||||
# Suppress
|
||||
# - 540-1088 (W) The exception specification is being ignored.
|
||||
# caused by throw() in declaration of new() in nmethod.hpp.
|
||||
CFLAGS += -qsuppress=1540-1088
|
||||
|
||||
# Turn off floating-point optimizations that may alter program semantics
|
||||
OPT_CFLAGS += -qstrict
|
||||
|
||||
# Disable aggressive optimizations for functions in sharedRuntimeTrig.cpp
|
||||
# and sharedRuntimeTrans.cpp on ppc64.
|
||||
# -qstrict turns off the following optimizations:
|
||||
# * Performing code motion and scheduling on computations such as loads
|
||||
# and floating-point computations that may trigger an exception.
|
||||
# * Relaxing conformance to IEEE rules.
|
||||
# * Reassociating floating-point expressions.
|
||||
# When using '-qstrict' there still remains one problem
|
||||
# in javasoft.sqe.tests.api.java.lang.Math.sin5Tests when run in compile-all
|
||||
# mode, so don't optimize sharedRuntimeTrig.cpp at all.
|
||||
OPT_CFLAGS/sharedRuntimeTrig.o = $(OPT_CFLAGS/NOOPT)
|
||||
OPT_CFLAGS/sharedRuntimeTrans.o = $(OPT_CFLAGS/NOOPT)
|
||||
|
||||
# Xlc 10.1 parameters for aggressive optimization:
|
||||
# - qhot=level=1: Most aggressive loop optimizations.
|
||||
# - qignerrno: Assume errno is not modified by system calls.
|
||||
# - qinline: Inline method calls. No suboptions for c++ compiles.
|
||||
# - qxflag=ASMMIDCOALFIX: Activate fix for -O3 problem in interpreter loop.
|
||||
# - qxflag=asmfastsync: Activate fix for performance problem with inline assembler with memory clobber.
|
||||
QV10_OPT=$(if $(CXX_IS_V10),-qxflag=ASMMIDCOALFIX -qxflag=asmfastsync)
|
||||
QV10_OPT_AGGRESSIVE=$(if $(CXX_IS_V10),-qhot=level=1 -qignerrno -qinline)
|
||||
QV10_OPT_CONSERVATIVE=$(if $(CXX_IS_V10),-qhot=level=1 -qignerrno -qinline)
|
||||
|
||||
# Disallow inlining for synchronizer.cpp, but perform O3 optimizations.
|
||||
OPT_CFLAGS/synchronizer.o = $(OPT_CFLAGS) -qnoinline
|
||||
|
||||
# Set all the xlC V10.1 options here.
|
||||
OPT_CFLAGS += $(QV10_OPT) $(QV10_OPT_AGGRESSIVE)
|
||||
|
||||
export OBJECT_MODE=64
|
||||
|
||||
# Also build launcher as 64 bit executable.
|
||||
LAUNCHERFLAGS += -q64
|
@ -1,58 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making optimized version of Gamma VM
|
||||
# (This is the "product", not the "release" version.)
|
||||
|
||||
# Compiler specific OPT_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
OPT_CFLAGS/DEFAULT= $(OPT_CFLAGS)
|
||||
OPT_CFLAGS/BYFILE = $(OPT_CFLAGS/$@)$(OPT_CFLAGS/DEFAULT$(OPT_CFLAGS/$@))
|
||||
|
||||
# (OPT_CFLAGS/SLOWER is also available, to alter compilation of buggy files)
|
||||
|
||||
# If you set HOTSPARC_GENERIC=yes, you disable all OPT_CFLAGS settings
|
||||
CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/aix/makefiles/mapfile-vers-product
|
||||
|
||||
# Remove ipa linkage altogether. Does not seem to benfit performance, but increases code footprint.
|
||||
LFLAGS_QIPA=
|
||||
|
||||
SYSDEFS += -DPRODUCT
|
||||
VERSION = optimized
|
||||
|
||||
# use -g to strip library as -x will discard its symbol table; -x is fine for
|
||||
# executables.
|
||||
# Note: these macros are not used in .debuginfo configs
|
||||
STRIP_LIBJVM = $(STRIP) -g $@ || exit 1;
|
||||
STRIP_AOUT = $(STRIP) -x $@ || exit 1;
|
||||
|
||||
# If we can create .debuginfo files, then the VM is stripped in vm.make
|
||||
# and this macro is not used.
|
||||
# LINK_LIB.CXX/POST_HOOK += $(STRIP_$(LINK_INTO))
|
@ -1,208 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2003, 2014, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Common rules/macros for the vm, adlc.
|
||||
|
||||
# Tell make that .cpp is important
|
||||
.SUFFIXES: .cpp $(SUFFIXES)
|
||||
|
||||
DEMANGLER = c++filt
|
||||
DEMANGLE = $(DEMANGLER) < $@ > .$@ && $(MV) -f .$@ $@
|
||||
|
||||
# $(CC) is the c compiler (cc/gcc), $(CXX) is the c++ compiler (CC/g++).
|
||||
CC_COMPILE = $(CC) $(CXXFLAGS) $(CFLAGS)
|
||||
CXX_COMPILE = $(CXX) $(CXXFLAGS) $(CFLAGS)
|
||||
|
||||
AS.S = $(AS) $(ASFLAGS)
|
||||
|
||||
COMPILE.CC = $(CC_COMPILE) -c
|
||||
GENASM.CC = $(CC_COMPILE) -S
|
||||
LINK.CC = $(CC) $(LFLAGS) $(AOUT_FLAGS) $(PROF_AOUT_FLAGS)
|
||||
LINK_LIB.CC = $(CC) $(LFLAGS) $(SHARED_FLAG)
|
||||
PREPROCESS.CC = $(CC_COMPILE) -E
|
||||
|
||||
COMPILE.CXX = $(CXX_COMPILE) -c
|
||||
GENASM.CXX = $(CXX_COMPILE) -S
|
||||
LINK.CXX = $(CXX) $(LFLAGS) $(AOUT_FLAGS) $(PROF_AOUT_FLAGS)
|
||||
LINK_NOPROF.CXX = $(CXX) $(LFLAGS) $(AOUT_FLAGS)
|
||||
LINK_LIB.CXX = $(CXX) $(LFLAGS) $(SHARED_FLAG)
|
||||
PREPROCESS.CXX = $(CXX_COMPILE) -E
|
||||
|
||||
# cross compiling the jvm with c2 requires host compilers to build
|
||||
# adlc tool
|
||||
|
||||
HOST.CXX_COMPILE = $(HOSTCXX) $(CXXFLAGS) $(CFLAGS)
|
||||
HOST.COMPILE.CXX = $(HOST.CXX_COMPILE) -c
|
||||
HOST.LINK_NOPROF.CXX = $(HOSTCXX) $(LFLAGS) $(AOUT_FLAGS)
|
||||
|
||||
|
||||
# Effect of REMOVE_TARGET is to delete out-of-date files during "gnumake -k".
|
||||
REMOVE_TARGET = rm -f $@
|
||||
|
||||
# Note use of ALT_BOOTDIR to explicitly specify location of java and
|
||||
# javac; this is the same environment variable used in the J2SE build
|
||||
# process for overriding the default spec, which is BOOTDIR.
|
||||
# Note also that we fall back to using JAVA_HOME if neither of these is
|
||||
# specified.
|
||||
|
||||
ifdef ALT_BOOTDIR
|
||||
|
||||
RUN.JAVA = $(ALT_BOOTDIR)/bin/java
|
||||
RUN.JAVAP = $(ALT_BOOTDIR)/bin/javap
|
||||
RUN.JAVAH = $(ALT_BOOTDIR)/bin/javah
|
||||
RUN.JAR = $(ALT_BOOTDIR)/bin/jar
|
||||
COMPILE.JAVAC = $(ALT_BOOTDIR)/bin/javac
|
||||
COMPILE.RMIC = $(ALT_BOOTDIR)/bin/rmic
|
||||
BOOT_JAVA_HOME = $(ALT_BOOTDIR)
|
||||
|
||||
else
|
||||
|
||||
ifdef BOOTDIR
|
||||
|
||||
RUN.JAVA = $(BOOTDIR)/bin/java
|
||||
RUN.JAVAP = $(BOOTDIR)/bin/javap
|
||||
RUN.JAVAH = $(BOOTDIR)/bin/javah
|
||||
RUN.JAR = $(BOOTDIR)/bin/jar
|
||||
COMPILE.JAVAC = $(BOOTDIR)/bin/javac
|
||||
COMPILE.RMIC = $(BOOTDIR)/bin/rmic
|
||||
BOOT_JAVA_HOME = $(BOOTDIR)
|
||||
|
||||
else
|
||||
|
||||
ifdef JAVA_HOME
|
||||
|
||||
RUN.JAVA = $(JAVA_HOME)/bin/java
|
||||
RUN.JAVAP = $(JAVA_HOME)/bin/javap
|
||||
RUN.JAVAH = $(JAVA_HOME)/bin/javah
|
||||
RUN.JAR = $(JAVA_HOME)/bin/jar
|
||||
COMPILE.JAVAC = $(JAVA_HOME)/bin/javac
|
||||
COMPILE.RMIC = $(JAVA_HOME)/bin/rmic
|
||||
BOOT_JAVA_HOME = $(JAVA_HOME)
|
||||
|
||||
else
|
||||
|
||||
# take from the PATH, if ALT_BOOTDIR, BOOTDIR and JAVA_HOME are not defined
|
||||
|
||||
RUN.JAVA = java
|
||||
RUN.JAVAP = javap
|
||||
RUN.JAVAH = javah
|
||||
RUN.JAR = jar
|
||||
COMPILE.JAVAC = javac
|
||||
COMPILE.RMIC = rmic
|
||||
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
COMPILE.JAVAC += $(BOOTSTRAP_JAVAC_FLAGS)
|
||||
|
||||
SUM = /usr/bin/sum
|
||||
|
||||
# 'gmake MAKE_VERBOSE=y' gives all the gory details.
|
||||
QUIETLY$(MAKE_VERBOSE) = @
|
||||
RUN.JAR$(MAKE_VERBOSE) += >/dev/null
|
||||
|
||||
# Settings for javac
|
||||
JAVAC_FLAGS = -g -encoding ascii
|
||||
|
||||
# Prefer BOOT_JDK_SOURCETARGET if it's set (typically by the top build system)
|
||||
# Fall back to the values here if it's not set (hotspot only builds)
|
||||
ifeq ($(BOOT_JDK_SOURCETARGET),)
|
||||
BOOTSTRAP_SOURCETARGET := -source 8 -target 8
|
||||
else
|
||||
BOOTSTRAP_SOURCETARGET := $(BOOT_JDK_SOURCETARGET)
|
||||
endif
|
||||
|
||||
BOOTSTRAP_JAVAC_FLAGS = $(JAVAC_FLAGS) $(BOOTSTRAP_SOURCETARGET)
|
||||
|
||||
# With parallel makes, print a message at the end of compilation.
|
||||
ifeq ($(findstring j,$(MFLAGS)),j)
|
||||
COMPILE_DONE = && { echo Done with $<; }
|
||||
endif
|
||||
|
||||
# Include $(NONPIC_OBJ_FILES) definition
|
||||
ifndef LP64
|
||||
include $(GAMMADIR)/make/pic.make
|
||||
endif
|
||||
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
# The non-PIC object files are only generated for 32 bit platforms.
|
||||
ifdef LP64
|
||||
%.o: %.cpp
|
||||
@echo $(LOG_INFO) Compiling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(COMPILE.CXX) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE)
|
||||
else
|
||||
%.o: %.cpp
|
||||
@echo $(LOG_INFO) Compiling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(if $(findstring $@, $(NONPIC_OBJ_FILES)), \
|
||||
$(subst $(VM_PICFLAG), ,$(COMPILE.CXX)) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE), \
|
||||
$(COMPILE.CXX) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE))
|
||||
endif
|
||||
|
||||
%.o: %.s
|
||||
@echo $(LOG_INFO) Assembling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(AS.S) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE)
|
||||
|
||||
%.s: %.cpp
|
||||
@echo $(LOG_INFO) Generating assembly for $<
|
||||
$(QUIETLY) $(GENASM.CXX) -o $@ $<
|
||||
$(QUIETLY) $(DEMANGLE) $(COMPILE_DONE)
|
||||
|
||||
# Intermediate files (for debugging macros)
|
||||
%.i: %.cpp
|
||||
@echo $(LOG_INFO) Preprocessing $< to $@
|
||||
$(QUIETLY) $(PREPROCESS.CXX) $< > $@ $(COMPILE_DONE)
|
||||
|
||||
# Override gnumake built-in rules which do sccs get operations badly.
|
||||
# (They put the checked out code in the current directory, not in the
|
||||
# directory of the original file.) Since this is a symptom of a teamware
|
||||
# failure, and since not all problems can be detected by gnumake due
|
||||
# to incomplete dependency checking... just complain and stop.
|
||||
%:: s.%
|
||||
@echo "========================================================="
|
||||
@echo File $@
|
||||
@echo is out of date with respect to its SCCS file.
|
||||
@echo This file may be from an unresolved Teamware conflict.
|
||||
@echo This is also a symptom of a Teamware bringover/putback failure
|
||||
@echo in which SCCS files are updated but not checked out.
|
||||
@echo Check for other out of date files in your workspace.
|
||||
@echo "========================================================="
|
||||
@exit 666
|
||||
|
||||
%:: SCCS/s.%
|
||||
@echo "========================================================="
|
||||
@echo File $@
|
||||
@echo is out of date with respect to its SCCS file.
|
||||
@echo This file may be from an unresolved Teamware conflict.
|
||||
@echo This is also a symptom of a Teamware bringover/putback failure
|
||||
@echo in which SCCS files are updated but not checked out.
|
||||
@echo Check for other out of date files in your workspace.
|
||||
@echo "========================================================="
|
||||
@exit 666
|
||||
|
||||
.PHONY: default
|
@ -1,32 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2006, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2015 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making tiered version of VM
|
||||
|
||||
TYPE=TIERED
|
||||
|
||||
VM_SUBDIR = server
|
||||
|
||||
CFLAGS += -DCOMPILER2 -DCOMPILER1
|
@ -1,147 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2014, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# top.make is included in the Makefile in the build directories.
|
||||
# It DOES NOT include the vm dependency info in order to be faster.
|
||||
# Its main job is to implement the incremental form of make lists.
|
||||
# It also:
|
||||
# -builds and runs adlc via adlc.make
|
||||
# -generates JVMTI source and docs via jvmti.make (JSR-163)
|
||||
|
||||
# It assumes the following flags are set:
|
||||
# CFLAGS Platform_file, Src_Dirs_I, Src_Dirs_V, SYSDEFS, AOUT, Obj_Files
|
||||
|
||||
# -- D. Ungar (5/97) from a file by Bill Bush
|
||||
|
||||
# Don't override the built-in $(MAKE).
|
||||
# Instead, use "gmake" (or "gnumake") from the command line. --Rose
|
||||
#MAKE = gmake
|
||||
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
TOPDIR = $(shell echo `pwd`)
|
||||
GENERATED = $(TOPDIR)/../generated
|
||||
VM = $(GAMMADIR)/src/share/vm
|
||||
Plat_File = $(Platform_file)
|
||||
CDG = cd $(GENERATED);
|
||||
|
||||
ifneq ($(USE_PRECOMPILED_HEADER),0)
|
||||
UpdatePCH = $(MAKE) -f vm.make $(PRECOMPILED_HEADER) $(MFLAGS)
|
||||
else
|
||||
UpdatePCH = \# precompiled header is not used
|
||||
endif
|
||||
|
||||
Cached_plat = $(GENERATED)/platform.current
|
||||
|
||||
AD_Dir = $(GENERATED)/adfiles
|
||||
ADLC = $(AD_Dir)/adlc
|
||||
AD_Spec = $(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(Platform_arch)/vm/$(Platform_arch_model).ad)
|
||||
AD_Src = $(call altsrc-replace,$(HS_COMMON_SRC)/share/vm/adlc)
|
||||
AD_Names = ad_$(Platform_arch_model).hpp ad_$(Platform_arch_model).cpp
|
||||
AD_Files = $(AD_Names:%=$(AD_Dir)/%)
|
||||
|
||||
# AD_Files_If_Required/COMPILER1 = ad_stuff
|
||||
AD_Files_If_Required/COMPILER2 = ad_stuff
|
||||
AD_Files_If_Required/TIERED = ad_stuff
|
||||
AD_Files_If_Required = $(AD_Files_If_Required/$(TYPE))
|
||||
|
||||
# Wierd argument adjustment for "gnumake -j..."
|
||||
adjust-mflags = $(GENERATED)/adjust-mflags
|
||||
# If SPEC is set, it's from configure and it's already controlling concurrency
|
||||
# for us. Skip setting -j with HOTSPOT_BUILD_JOBS.
|
||||
ifeq ($(SPEC), )
|
||||
MFLAGS-adjusted = -r `$(adjust-mflags) "$(MFLAGS)" "$(HOTSPOT_BUILD_JOBS)"`
|
||||
else
|
||||
MFLAGS-adjusted = -r $(MFLAGS)
|
||||
endif
|
||||
|
||||
|
||||
# default target: update lists, make vm
|
||||
# done in stages to force sequential order with parallel make
|
||||
#
|
||||
|
||||
default: vm_build_preliminaries the_vm
|
||||
@echo All done.
|
||||
|
||||
# This is an explicit dependency for the sake of parallel makes.
|
||||
vm_build_preliminaries: checks $(Cached_plat) $(AD_Files_If_Required) trace_stuff jvmti_stuff
|
||||
@# We need a null action here, so implicit rules don't get consulted.
|
||||
|
||||
$(Cached_plat): $(Plat_File)
|
||||
$(CDG) $(CP) $(Plat_File) $(Cached_plat)
|
||||
|
||||
# make AD files as necessary
|
||||
ad_stuff: $(Cached_plat) $(adjust-mflags)
|
||||
@$(MAKE) -f adlc.make $(MFLAGS-adjusted)
|
||||
|
||||
# generate JVMTI files from the spec
|
||||
jvmti_stuff: $(Cached_plat) $(adjust-mflags)
|
||||
@$(MAKE) -f jvmti.make $(MFLAGS-adjusted)
|
||||
|
||||
# generate trace files
|
||||
trace_stuff: jvmti_stuff $(Cached_plat) $(adjust-mflags)
|
||||
@$(MAKE) -f trace.make $(MFLAGS-adjusted)
|
||||
|
||||
# and the VM: must use other makefile with dependencies included
|
||||
|
||||
# We have to go to great lengths to get control over the -jN argument
|
||||
# to the recursive invocation of vm.make. The problem is that gnumake
|
||||
# resets -jN to -j1 for recursive runs. (How helpful.)
|
||||
# Note that the user must specify the desired parallelism level via a
|
||||
# command-line or environment variable name HOTSPOT_BUILD_JOBS.
|
||||
$(adjust-mflags): $(GAMMADIR)/make/$(Platform_os_family)/makefiles/adjust-mflags.sh
|
||||
@+rm -f $@ $@+
|
||||
@+cat $< > $@+
|
||||
@+chmod +x $@+
|
||||
@+mv $@+ $@
|
||||
|
||||
the_vm: vm_build_preliminaries $(adjust-mflags)
|
||||
+@$(UpdatePCH)
|
||||
@$(MAKE) -f vm.make $(MFLAGS-adjusted)
|
||||
|
||||
install gamma: the_vm
|
||||
@$(MAKE) -f vm.make $@
|
||||
|
||||
# next rules support "make foo.[ois]"
|
||||
|
||||
%.o %.i %.s:
|
||||
+$(UpdatePCH)
|
||||
$(MAKE) -f vm.make $(MFLAGS) $@
|
||||
#$(MAKE) -f vm.make $@
|
||||
|
||||
# this should force everything to be rebuilt
|
||||
clean:
|
||||
rm -f $(GENERATED)/*.class
|
||||
$(MAKE) -f vm.make $(MFLAGS) clean
|
||||
|
||||
# just in case it doesn't, this should do it
|
||||
realclean:
|
||||
$(MAKE) -f vm.make $(MFLAGS) clean
|
||||
rm -fr $(GENERATED)
|
||||
|
||||
.PHONY: default vm_build_preliminaries
|
||||
.PHONY: lists ad_stuff jvmti_stuff the_vm clean realclean
|
||||
.PHONY: checks check_os_version install
|
||||
|
||||
.NOTPARALLEL:
|
@ -1,119 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2003, 2016, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This makefile (trace.make) is included from the trace.make in the
|
||||
# build directories.
|
||||
#
|
||||
# It knows how to build and run the tools to generate trace files.
|
||||
|
||||
include $(GAMMADIR)/make/aix/makefiles/rules.make
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
# #########################################################################
|
||||
|
||||
HAS_ALT_SRC := false
|
||||
ifndef OPENJDK
|
||||
ifneq ($(wildcard $(HS_ALT_SRC)/share/vm/trace), )
|
||||
HAS_ALT_SRC := true
|
||||
endif
|
||||
endif
|
||||
|
||||
TOPDIR = $(shell echo `pwd`)
|
||||
GENERATED = $(TOPDIR)/../generated
|
||||
JvmtiOutDir = $(GENERATED)/jvmtifiles
|
||||
TraceOutDir = $(GENERATED)/tracefiles
|
||||
|
||||
TraceAltSrcDir = $(HS_ALT_SRC)/share/vm/trace
|
||||
TraceSrcDir = $(HS_COMMON_SRC)/share/vm/trace
|
||||
|
||||
# set VPATH so make knows where to look for source files
|
||||
Src_Dirs_V += $(TraceSrcDir) $(TraceAltSrcDir)
|
||||
VPATH += $(Src_Dirs_V:%=%:)
|
||||
|
||||
TraceGeneratedNames = \
|
||||
traceEventClasses.hpp \
|
||||
traceEventIds.hpp \
|
||||
traceTypes.hpp
|
||||
|
||||
ifeq ($(HAS_ALT_SRC), true)
|
||||
TraceGeneratedNames += \
|
||||
traceRequestables.hpp \
|
||||
traceEventControl.hpp
|
||||
endif
|
||||
|
||||
TraceGeneratedFiles = $(TraceGeneratedNames:%=$(TraceOutDir)/%)
|
||||
|
||||
XSLT = $(REMOTE) $(RUN.JAVA) -classpath $(JvmtiOutDir) jvmtiGen
|
||||
|
||||
TraceXml = $(TraceSrcDir)/trace.xml
|
||||
ifeq ($(HAS_ALT_SRC), true)
|
||||
TraceXml = $(TraceAltSrcDir)/trace.xml
|
||||
endif
|
||||
|
||||
XML_DEPS = $(TraceXml) $(TraceSrcDir)/tracetypes.xml \
|
||||
$(TraceSrcDir)/trace.dtd $(TraceSrcDir)/xinclude.mod \
|
||||
$(TraceSrcDir)/tracerelationdecls.xml $(TraceSrcDir)/traceevents.xml
|
||||
ifeq ($(HAS_ALT_SRC), true)
|
||||
XML_DEPS += $(TraceAltSrcDir)/traceeventscustom.xml \
|
||||
$(TraceAltSrcDir)/traceeventtypes.xml
|
||||
endif
|
||||
|
||||
.PHONY: all clean cleanall
|
||||
|
||||
# #########################################################################
|
||||
|
||||
all: $(TraceGeneratedFiles)
|
||||
|
||||
GENERATE_CODE= \
|
||||
$(QUIETLY) echo $(LOG_INFO) Generating $@; \
|
||||
$(XSLT) -IN $(word 1,$^) -XSL $(word 2,$^) -OUT $@
|
||||
|
||||
$(TraceOutDir)/traceEventIds.hpp: $(TraceXml) $(TraceSrcDir)/traceEventIds.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
$(TraceOutDir)/traceTypes.hpp: $(TraceXml) $(TraceSrcDir)/traceTypes.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
ifeq ($(HAS_ALT_SRC), false)
|
||||
|
||||
$(TraceOutDir)/traceEventClasses.hpp: $(TraceXml) $(TraceSrcDir)/traceEventClasses.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
else
|
||||
|
||||
$(TraceOutDir)/traceEventClasses.hpp: $(TraceXml) $(TraceAltSrcDir)/traceEventClasses.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
$(TraceOutDir)/traceRequestables.hpp: $(TraceXml) $(TraceAltSrcDir)/traceRequestables.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
$(TraceOutDir)/traceEventControl.hpp: $(TraceXml) $(TraceAltSrcDir)/traceEventControl.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
endif
|
||||
|
||||
# #########################################################################
|
||||
|
||||
clean cleanall:
|
||||
rm $(TraceGeneratedFiles)
|
@ -1,370 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Rules to build JVM and related libraries, included from vm.make in the build
|
||||
# directory.
|
||||
|
||||
# Common build rules.
|
||||
MAKEFILES_DIR=$(GAMMADIR)/make/$(Platform_os_family)/makefiles
|
||||
include $(MAKEFILES_DIR)/rules.make
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
default: build
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# Defs
|
||||
|
||||
GENERATED = ../generated
|
||||
DEP_DIR = $(GENERATED)/dependencies
|
||||
|
||||
# reads the generated files defining the set of .o's and the .o .h dependencies
|
||||
-include $(DEP_DIR)/*.d
|
||||
|
||||
# read machine-specific adjustments (%%% should do this via buildtree.make?)
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
include $(MAKEFILES_DIR)/zeroshark.make
|
||||
else
|
||||
include $(MAKEFILES_DIR)/$(BUILDARCH).make
|
||||
endif
|
||||
|
||||
# set VPATH so make knows where to look for source files
|
||||
# Src_Dirs_V is everything in src/share/vm/*, plus the right os/*/vm and cpu/*/vm
|
||||
# The adfiles directory contains ad_<arch>.[ch]pp.
|
||||
# The jvmtifiles directory contains jvmti*.[ch]pp
|
||||
Src_Dirs_V += $(GENERATED)/adfiles $(GENERATED)/jvmtifiles $(GENERATED)/tracefiles
|
||||
VPATH += $(Src_Dirs_V:%=%:)
|
||||
|
||||
# set INCLUDES for C preprocessor.
|
||||
Src_Dirs_I += $(GENERATED)
|
||||
# The order is important for the precompiled headers to work.
|
||||
INCLUDES += $(PRECOMPILED_HEADER_DIR:%=-I%) $(Src_Dirs_I:%=-I%)
|
||||
|
||||
# SYMFLAG is used by jsig.make
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
# always build with debug info when we can create .debuginfo files
|
||||
SYMFLAG = -g
|
||||
else
|
||||
ifeq (${VERSION}, debug)
|
||||
SYMFLAG = -g
|
||||
else
|
||||
SYMFLAG =
|
||||
endif
|
||||
endif
|
||||
|
||||
# The following variables are defined in the generated flags.make file.
|
||||
JDK_VER_DEFS = -DVERSION_MAJOR=$(VERSION_MAJOR) \
|
||||
-DVERSION_MINOR=$(VERSION_MINOR) \
|
||||
-DVERSION_SECURITY=$(VERSION_SECURITY) \
|
||||
-DVERSION_PATCH=$(VERSION_PATCH) \
|
||||
-DVERSION_BUILD=$(VERSION_BUILD)
|
||||
VM_VER_DEFS = -DHOTSPOT_VERSION_STRING="\"$(HOTSPOT_VERSION_STRING)\"" \
|
||||
-DVERSION_STRING="\"$(VERSION_STRING)\"" \
|
||||
-DDEBUG_LEVEL="\"$(DEBUG_LEVEL)\"" \
|
||||
$(JDK_VER_DEFS)
|
||||
HS_LIB_ARCH = -DHOTSPOT_LIB_ARCH=\"$(LIBARCH)\"
|
||||
BUILD_USER = -DHOTSPOT_BUILD_USER="\"$(HOTSPOT_BUILD_USER)\""
|
||||
VM_DISTRO = -DHOTSPOT_VM_DISTRO="\"$(HOTSPOT_VM_DISTRO)\""
|
||||
|
||||
CXXFLAGS = \
|
||||
${SYSDEFS} \
|
||||
${INCLUDES} \
|
||||
${BUILD_USER} \
|
||||
${HS_LIB_ARCH} \
|
||||
${VM_DISTRO}
|
||||
|
||||
# This is VERY important! The version define must only be supplied to vm_version.o
|
||||
# If not, ccache will not re-use the cache at all, since the version string might contain
|
||||
# a time and date.
|
||||
CXXFLAGS/vm_version.o += ${VM_VER_DEFS}
|
||||
|
||||
CXXFLAGS/BYFILE = $(CXXFLAGS/$@)
|
||||
|
||||
# File specific flags
|
||||
CXXFLAGS += $(CXXFLAGS/BYFILE)
|
||||
|
||||
|
||||
# CFLAGS_WARN holds compiler options to suppress/enable warnings.
|
||||
CFLAGS += $(CFLAGS_WARN/BYFILE)
|
||||
|
||||
# Do not use C++ exception handling
|
||||
CFLAGS += $(CFLAGS/NOEX)
|
||||
|
||||
# Extra flags from gnumake's invocation or environment
|
||||
CFLAGS += $(EXTRA_CFLAGS)
|
||||
LFLAGS += $(EXTRA_CFLAGS)
|
||||
|
||||
# Don't set excutable bit on stack segment
|
||||
# the same could be done by separate execstack command
|
||||
#LFLAGS += -Xlinker -z -Xlinker noexecstack
|
||||
|
||||
LIBS += -lm -ldl -lpthread
|
||||
|
||||
# By default, link the *.o into the library, not the executable.
|
||||
LINK_INTO$(LINK_INTO) = LIBJVM
|
||||
|
||||
JDK_LIBDIR = $(JAVA_HOME)/lib/$(LIBARCH)
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# jvm_db & dtrace
|
||||
include $(MAKEFILES_DIR)/dtrace.make
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# JVM
|
||||
|
||||
JVM = jvm
|
||||
LIBJVM = lib$(JVM).so
|
||||
|
||||
LIBJVM_DEBUGINFO = lib$(JVM).debuginfo
|
||||
LIBJVM_DIZ = lib$(JVM).diz
|
||||
|
||||
SPECIAL_PATHS:=adlc c1 gc opto shark libadt
|
||||
|
||||
SOURCE_PATHS=\
|
||||
$(shell find $(HS_COMMON_SRC)/share/vm/* -type d \! \
|
||||
\( -name DUMMY $(foreach dir,$(SPECIAL_PATHS),-o -name $(dir)) \))
|
||||
SOURCE_PATHS+=$(HS_COMMON_SRC)/os/$(Platform_os_family)/vm
|
||||
SOURCE_PATHS+=$(HS_COMMON_SRC)/os/posix/vm
|
||||
SOURCE_PATHS+=$(HS_COMMON_SRC)/cpu/$(SRCARCH)/vm
|
||||
SOURCE_PATHS+=$(HS_COMMON_SRC)/os_cpu/$(Platform_os_family)_$(SRCARCH)/vm
|
||||
|
||||
CORE_PATHS=$(foreach path,$(SOURCE_PATHS),$(call altsrc,$(path)) $(path))
|
||||
CORE_PATHS+=$(GENERATED)/jvmtifiles $(GENERATED)/tracefiles
|
||||
|
||||
ifneq ($(INCLUDE_TRACE), false)
|
||||
CORE_PATHS+=$(shell if [ -d $(HS_ALT_SRC)/share/vm/jfr ]; then \
|
||||
find $(HS_ALT_SRC)/share/vm/jfr -type d; \
|
||||
fi)
|
||||
endif
|
||||
|
||||
COMPILER1_PATHS := $(call altsrc,$(HS_COMMON_SRC)/share/vm/c1)
|
||||
COMPILER1_PATHS += $(HS_COMMON_SRC)/share/vm/c1
|
||||
|
||||
COMPILER2_PATHS := $(call altsrc,$(HS_COMMON_SRC)/share/vm/opto)
|
||||
COMPILER2_PATHS += $(call altsrc,$(HS_COMMON_SRC)/share/vm/libadt)
|
||||
COMPILER2_PATHS += $(HS_COMMON_SRC)/share/vm/opto
|
||||
COMPILER2_PATHS += $(HS_COMMON_SRC)/share/vm/libadt
|
||||
COMPILER2_PATHS += $(GENERATED)/adfiles
|
||||
|
||||
SHARK_PATHS := $(GAMMADIR)/src/share/vm/shark
|
||||
|
||||
# Include dirs per type.
|
||||
Src_Dirs/CORE := $(CORE_PATHS)
|
||||
Src_Dirs/COMPILER1 := $(CORE_PATHS) $(COMPILER1_PATHS)
|
||||
Src_Dirs/COMPILER2 := $(CORE_PATHS) $(COMPILER2_PATHS)
|
||||
Src_Dirs/TIERED := $(CORE_PATHS) $(COMPILER1_PATHS) $(COMPILER2_PATHS)
|
||||
Src_Dirs/ZERO := $(CORE_PATHS)
|
||||
Src_Dirs/SHARK := $(CORE_PATHS) $(SHARK_PATHS)
|
||||
Src_Dirs := $(Src_Dirs/$(TYPE))
|
||||
|
||||
COMPILER2_SPECIFIC_FILES := opto libadt bcEscapeAnalyzer.cpp c2_\* runtime_\*
|
||||
COMPILER1_SPECIFIC_FILES := c1_\*
|
||||
SHARK_SPECIFIC_FILES := shark
|
||||
ZERO_SPECIFIC_FILES := zero
|
||||
|
||||
# Always exclude these.
|
||||
Src_Files_EXCLUDE += jsig.c jvmtiEnvRecommended.cpp jvmtiEnvStub.cpp
|
||||
|
||||
# Exclude per type.
|
||||
Src_Files_EXCLUDE/CORE := $(COMPILER1_SPECIFIC_FILES) $(COMPILER2_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES) ciTypeFlow.cpp
|
||||
Src_Files_EXCLUDE/COMPILER1 := $(COMPILER2_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES) ciTypeFlow.cpp
|
||||
Src_Files_EXCLUDE/COMPILER2 := $(COMPILER1_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES)
|
||||
Src_Files_EXCLUDE/TIERED := $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES)
|
||||
Src_Files_EXCLUDE/ZERO := $(COMPILER1_SPECIFIC_FILES) $(COMPILER2_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES) ciTypeFlow.cpp
|
||||
Src_Files_EXCLUDE/SHARK := $(COMPILER1_SPECIFIC_FILES) $(COMPILER2_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES)
|
||||
|
||||
Src_Files_EXCLUDE += $(Src_Files_EXCLUDE/$(TYPE))
|
||||
|
||||
# Disable ELF decoder on AIX (AIX uses XCOFF).
|
||||
Src_Files_EXCLUDE += decoder_elf.cpp elfFile.cpp elfStringTable.cpp elfSymbolTable.cpp elfFuncDescTable.cpp
|
||||
|
||||
# Special handling of arch model.
|
||||
ifeq ($(Platform_arch_model), x86_32)
|
||||
Src_Files_EXCLUDE += \*x86_64\*
|
||||
endif
|
||||
ifeq ($(Platform_arch_model), x86_64)
|
||||
Src_Files_EXCLUDE += \*x86_32\*
|
||||
endif
|
||||
|
||||
# Locate all source files in the given directory, excluding files in Src_Files_EXCLUDE.
|
||||
define findsrc
|
||||
$(notdir $(shell find $(1)/. ! -name . -prune \
|
||||
-a \( -name \*.c -o -name \*.cpp -o -name \*.s \) \
|
||||
-a ! \( -name DUMMY $(addprefix -o -name ,$(Src_Files_EXCLUDE)) \)))
|
||||
endef
|
||||
|
||||
Src_Files := $(foreach e,$(Src_Dirs),$(call findsrc,$(e)))
|
||||
|
||||
Obj_Files = $(sort $(addsuffix .o,$(basename $(Src_Files))))
|
||||
|
||||
JVM_OBJ_FILES = $(Obj_Files)
|
||||
|
||||
vm_version.o: $(filter-out vm_version.o,$(JVM_OBJ_FILES))
|
||||
|
||||
MAPFILE_SHARE := $(GAMMADIR)/make/share/makefiles/mapfile-vers
|
||||
|
||||
mapfile : $(MAPFILE) $(MAPFILE_SHARE) vm.def
|
||||
rm -f $@
|
||||
awk '{ if ($$0 ~ "INSERT VTABLE SYMBOLS HERE") \
|
||||
{ system ("cat ${MAPFILE_SHARE} vm.def"); } \
|
||||
else \
|
||||
{ print $$0 } \
|
||||
}' > $@ < $(MAPFILE)
|
||||
|
||||
mapfile_reorder : mapfile $(REORDERFILE)
|
||||
rm -f $@
|
||||
cat $^ > $@
|
||||
|
||||
vm.def: $(Res_Files) $(Obj_Files)
|
||||
sh $(GAMMADIR)/make/aix/makefiles/build_vm_def.sh *.o > $@
|
||||
|
||||
ifeq ($(JVM_VARIANT_ZEROSHARK), true)
|
||||
STATIC_CXX = false
|
||||
else
|
||||
ifeq ($(ZERO_LIBARCH), ppc64)
|
||||
STATIC_CXX = false
|
||||
else
|
||||
STATIC_CXX = true
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(LINK_INTO),AOUT)
|
||||
LIBJVM.o =
|
||||
LIBJVM_MAPFILE =
|
||||
LIBS_VM = $(LIBS)
|
||||
else
|
||||
LIBJVM.o = $(JVM_OBJ_FILES)
|
||||
LIBJVM_MAPFILE$(LDNOMAP) = mapfile_reorder
|
||||
LFLAGS_VM$(LDNOMAP) += $(MAPFLAG:FILENAME=$(LIBJVM_MAPFILE))
|
||||
# xlC_r ignores the -o= syntax
|
||||
# LFLAGS_VM += $(SONAMEFLAG:SONAME=$(LIBJVM))
|
||||
|
||||
# JVM is statically linked with libgcc[_s] and libstdc++; this is needed to
|
||||
# get around library dependency and compatibility issues. Must use gcc not
|
||||
# g++ to link.
|
||||
LIBS_VM += $(STATIC_STDCXX) $(LIBS)
|
||||
endif
|
||||
|
||||
LINK_VM = $(LINK_LIB.CXX)
|
||||
|
||||
# create loadmap for libjvm.so by default. Helps in diagnosing some problems.
|
||||
LFLAGS_VM += -bloadmap:libjvm.loadmap
|
||||
|
||||
# rule for building precompiled header
|
||||
$(PRECOMPILED_HEADER):
|
||||
$(QUIETLY) echo $(LOG_INFO) Generating precompiled header $@
|
||||
$(QUIETLY) mkdir -p $(PRECOMPILED_HEADER_DIR)
|
||||
$(QUIETLY) $(COMPILE.CXX) $(DEPFLAGS) -x c++-header $(PRECOMPILED_HEADER_SRC) -o $@ $(COMPILE_DONE)
|
||||
|
||||
# making the library:
|
||||
|
||||
ifneq ($(JVM_BASE_ADDR),)
|
||||
# By default shared library is linked at base address == 0. Modify the
|
||||
# linker script if JVM prefers a different base location. It can also be
|
||||
# implemented with 'prelink -r'. But 'prelink' is not (yet) available on
|
||||
# our build platform (AS-2.1).
|
||||
LD_SCRIPT = libjvm.so.lds
|
||||
$(LD_SCRIPT): $(LIBJVM_MAPFILE)
|
||||
$(QUIETLY) { \
|
||||
rm -rf $@; \
|
||||
$(LINK_VM) -Wl,--verbose $(LFLAGS_VM) 2>&1 | \
|
||||
sed -e '/^======/,/^======/!d' \
|
||||
-e '/^======/d' \
|
||||
-e 's/0\( + SIZEOF_HEADERS\)/$(JVM_BASE_ADDR)\1/' \
|
||||
> $@; \
|
||||
}
|
||||
LD_SCRIPT_FLAG = -Wl,-T,$(LD_SCRIPT)
|
||||
endif
|
||||
|
||||
# With more recent Redhat releases (or the cutting edge version Fedora), if
|
||||
# SELinux is configured to be enabled, the runtime linker will fail to apply
|
||||
# the text relocation to libjvm.so considering that it is built as a non-PIC
|
||||
# DSO. To workaround that, we run chcon to libjvm.so after it is built. See
|
||||
# details in bug 6538311.
|
||||
$(LIBJVM): $(LIBJVM.o) $(LIBJVM_MAPFILE) $(LD_SCRIPT)
|
||||
$(QUIETLY) { \
|
||||
echo $(LOG_INFO) Linking vm...; \
|
||||
$(LINK_LIB.CXX/PRE_HOOK) \
|
||||
$(LINK_VM) $(LD_SCRIPT_FLAG) \
|
||||
$(LFLAGS_VM) -o $@ $(sort $(LIBJVM.o)) $(LIBS_VM); \
|
||||
$(LINK_LIB.CXX/POST_HOOK) \
|
||||
rm -f $@.1; ln -s $@ $@.1; \
|
||||
}
|
||||
# No security contexts on AIX
|
||||
# if [ \"$(CROSS_COMPILE_ARCH)\" = \"\" ] ; then \
|
||||
# if [ -x /usr/sbin/selinuxenabled ] ; then \
|
||||
# /usr/sbin/selinuxenabled; \
|
||||
# if [ $$? = 0 ] ; then \
|
||||
# /usr/bin/chcon -t textrel_shlib_t $@; \
|
||||
# if [ $$? != 0 ]; then \
|
||||
# echo "ERROR: Cannot chcon $@"; \
|
||||
# fi \
|
||||
# fi \
|
||||
# fi \
|
||||
# fi \
|
||||
# }
|
||||
|
||||
#ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
# $(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJVM_DEBUGINFO)
|
||||
# $(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJVM_DEBUGINFO) $@
|
||||
# ifeq ($(STRIP_POLICY),all_strip)
|
||||
# $(QUIETLY) $(STRIP) $@
|
||||
# else
|
||||
# ifeq ($(STRIP_POLICY),min_strip)
|
||||
# $(QUIETLY) $(STRIP) -g $@
|
||||
# # implied else here is no stripping at all
|
||||
# endif
|
||||
# endif
|
||||
# ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# $(ZIPEXE) -q -y $(LIBJVM_DIZ) $(LIBJVM_DEBUGINFO)
|
||||
# $(RM) $(LIBJVM_DEBUGINFO)
|
||||
# endif
|
||||
#endif
|
||||
|
||||
DEST_SUBDIR = $(JDK_LIBDIR)/$(VM_SUBDIR)
|
||||
DEST_JVM = $(DEST_SUBDIR)/$(LIBJVM)
|
||||
DEST_JVM_DEBUGINFO = $(DEST_SUBDIR)/$(LIBJVM_DEBUGINFO)
|
||||
DEST_JVM_DIZ = $(DEST_SUBDIR)/$(LIBJVM_DIZ)
|
||||
|
||||
install_jvm: $(LIBJVM)
|
||||
@echo "Copying $(LIBJVM) to $(DEST_JVM)"
|
||||
$(QUIETLY) test -f $(LIBJVM_DEBUGINFO) && \
|
||||
$(CP) -f $(LIBJVM_DEBUGINFO) $(DEST_JVM_DEBUGINFO)
|
||||
$(QUIETLY) test -f $(LIBJVM_DIZ) && \
|
||||
$(CP) -f $(LIBJVM_DIZ) $(DEST_JVM_DIZ)
|
||||
$(QUIETLY) $(CP) -f $(LIBJVM) $(DEST_JVM) && echo "Done"
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# Other files
|
||||
|
||||
# Signal interposition library
|
||||
include $(MAKEFILES_DIR)/jsig.make
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
build: $(LIBJVM) $(LAUNCHER) $(LIBJSIG) $(LIBJVM_DB)
|
||||
|
||||
install: install_jvm install_jsig
|
||||
|
||||
.PHONY: default build install install_jvm
|
@ -1,172 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2015 SAP SE. 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# CC, CXX & AS
|
||||
|
||||
# Set compiler explicitly
|
||||
CXX = $(COMPILER_PATH)xlC_r
|
||||
CC = $(COMPILER_PATH)xlc_r
|
||||
HOSTCXX = $(CXX)
|
||||
HOSTCC = $(CC)
|
||||
|
||||
AS = $(CC) -c
|
||||
|
||||
# get xlc version which comes as VV.RR.MMMM.LLLL where 'VV' is the version,
|
||||
# 'RR' is the release, 'MMMM' is the modification and 'LLLL' is the level.
|
||||
# We only use 'VV.RR.LLLL' to avoid integer overflows in bash when comparing
|
||||
# the version numbers (some shells only support 32-bit integer compares!).
|
||||
CXX_VERSION := $(shell $(CXX) -qversion 2>&1 | \
|
||||
sed -n 's/.*Version: \([0-9]\{2\}\).\([0-9]\{2\}\).[0-9]\{4\}.\([0-9]\{4\}\)/\1\2\3/p')
|
||||
|
||||
# xlc 08.00.0000.0023 and higher supports -qtune=balanced
|
||||
CXX_SUPPORTS_BALANCED_TUNING := $(shell if [ $(CXX_VERSION) -ge 08000023 ] ; then echo "true" ; fi)
|
||||
# xlc 10.01 is used with aggressive optimizations to boost performance
|
||||
CXX_IS_V10 := $(shell if [ $(CXX_VERSION) -ge 10010000 ] ; then echo "true" ; fi)
|
||||
|
||||
# check for precompiled headers support
|
||||
|
||||
# Switch off the precompiled header support. Neither xlC 8.0 nor xlC 10.0
|
||||
# support precompiled headers. Both "understand" the command line switches "-qusepcomp" and
|
||||
# "-qgenpcomp" but when we specify them the following message is printed:
|
||||
# "1506-755 (W) The -qusepcomp option is not supported in this release."
|
||||
USE_PRECOMPILED_HEADER = 0
|
||||
ifneq ($(USE_PRECOMPILED_HEADER),0)
|
||||
PRECOMPILED_HEADER_DIR=.
|
||||
PRECOMPILED_HEADER_SRC=$(GAMMADIR)/src/share/vm/precompiled/precompiled.hpp
|
||||
PRECOMPILED_HEADER=$(PRECOMPILED_HEADER_DIR)/precompiled.hpp.gch
|
||||
endif
|
||||
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Compiler flags
|
||||
|
||||
# position-independent code
|
||||
PICFLAG = -qpic=large
|
||||
|
||||
VM_PICFLAG/LIBJVM = $(PICFLAG)
|
||||
VM_PICFLAG/AOUT =
|
||||
VM_PICFLAG = $(VM_PICFLAG/$(LINK_INTO))
|
||||
|
||||
CFLAGS += $(VM_PICFLAG)
|
||||
CFLAGS += -qnortti
|
||||
CFLAGS += -qnoeh
|
||||
|
||||
# for compiler-level tls
|
||||
CFLAGS += -qtls=default
|
||||
|
||||
CFLAGS += -D_REENTRANT
|
||||
# no xlc counterpart for -fcheck-new
|
||||
# CFLAGS += -fcheck-new
|
||||
|
||||
# We need to define this on the command line if we want to use the the
|
||||
# predefined format specifiers from "inttypes.h". Otherwise system headrs
|
||||
# can indirectly include inttypes.h before we define __STDC_FORMAT_MACROS
|
||||
# in globalDefinitions.hpp
|
||||
CFLAGS += -D__STDC_FORMAT_MACROS
|
||||
|
||||
ARCHFLAG = -q64
|
||||
|
||||
CFLAGS += $(ARCHFLAG)
|
||||
AOUT_FLAGS += $(ARCHFLAG)
|
||||
LFLAGS += $(ARCHFLAG)
|
||||
ASFLAGS += $(ARCHFLAG)
|
||||
|
||||
# Use C++ Interpreter
|
||||
ifdef CC_INTERP
|
||||
CFLAGS += -DCC_INTERP
|
||||
endif
|
||||
|
||||
# Keep temporary files (.ii, .s)
|
||||
# no counterpart on xlc for -save-temps, -pipe
|
||||
|
||||
# Compiler warnings are treated as errors
|
||||
# Do not treat warnings as errors
|
||||
# WARNINGS_ARE_ERRORS = -Werror
|
||||
# Except for a few acceptable ones
|
||||
# ACCEPTABLE_WARNINGS = -Wpointer-arith -Wconversion -Wsign-compare
|
||||
# CFLAGS_WARN/DEFAULT = $(WARNINGS_ARE_ERRORS) $(ACCEPTABLE_WARNINGS)
|
||||
CFLAGS_WARN/COMMON =
|
||||
CFLAGS_WARN/DEFAULT = $(CFLAGS_WARN/COMMON) $(EXTRA_WARNINGS)
|
||||
# Special cases
|
||||
CFLAGS_WARN/BYFILE = $(CFLAGS_WARN/$@)$(CFLAGS_WARN/DEFAULT$(CFLAGS_WARN/$@))
|
||||
|
||||
# The flags to use for an optimized build
|
||||
OPT_CFLAGS += -O3
|
||||
|
||||
# Hotspot uses very unstrict aliasing turn this optimization off
|
||||
OPT_CFLAGS += -qalias=noansi
|
||||
|
||||
OPT_CFLAGS/NOOPT=-qnoopt
|
||||
|
||||
DEPFLAGS = -qmakedep=gcc -MF $(DEP_DIR)/$(@:%=%.d)
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Linker flags
|
||||
|
||||
# statically link libstdc++.so, work with gcc but ignored by g++
|
||||
STATIC_STDCXX = -Wl,-lC_r
|
||||
|
||||
# Enable linker optimization
|
||||
# no counterpart on xlc for this
|
||||
# LFLAGS += -Xlinker -O1
|
||||
|
||||
# Use $(MAPFLAG:FILENAME=real_file_name) to specify a map file.
|
||||
# MAPFLAG = -Xlinker --version-script=FILENAME
|
||||
|
||||
# Build shared library
|
||||
SHARED_FLAG = -q64 -b64 -bexpall -G -bnoentry -qmkshrobj -brtl -bnolibpath -bernotok
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Debug flags
|
||||
|
||||
# Always compile with '-g' to get symbols in the stacktraces in the hs_err file
|
||||
DEBUG_CFLAGS += -g
|
||||
FASTDEBUG_CFLAGS += -g
|
||||
OPT_CFLAGS += -g
|
||||
|
||||
# DEBUG_BINARIES overrides everything, use full -g debug information
|
||||
ifeq ($(DEBUG_BINARIES), true)
|
||||
DEBUG_CFLAGS = -g
|
||||
CFLAGS += $(DEBUG_CFLAGS)
|
||||
endif
|
||||
|
||||
# If we are building HEADLESS, pass on to VM
|
||||
# so it can set the java.awt.headless property
|
||||
ifdef HEADLESS
|
||||
CFLAGS += -DHEADLESS
|
||||
endif
|
||||
|
||||
# We are building Embedded for a small device
|
||||
# favor code space over speed
|
||||
ifdef MINIMIZE_RAM_USAGE
|
||||
CFLAGS += -DMINIMIZE_RAM_USAGE
|
||||
endif
|
||||
|
||||
ifdef CROSS_COMPILE_ARCH
|
||||
STRIP = $(ALT_COMPILER_PATH)/strip
|
||||
else
|
||||
STRIP = strip
|
||||
endif
|
@ -1,17 +0,0 @@
|
||||
os_family = aix
|
||||
|
||||
arch = ppc
|
||||
|
||||
arch_model = ppc_64
|
||||
|
||||
os_arch = aix_ppc
|
||||
|
||||
os_arch_model = aix_ppc_64
|
||||
|
||||
lib_arch = ppc64
|
||||
|
||||
compiler = xlc
|
||||
|
||||
gnu_dis_arch = ppc64
|
||||
|
||||
sysdefs = -DAIX -DPPC64
|
@ -1,96 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2011, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This file defines variables and macros which are used in the makefiles to
|
||||
# allow distributions to augment or replace common hotspot code with
|
||||
# distribution-specific source files. This capability is disabled when
|
||||
# an OPENJDK build is requested, unless HS_ALT_SRC_REL has been set externally.
|
||||
|
||||
# Requires: GAMMADIR
|
||||
# Provides:
|
||||
# variables: HS_COMMON_SRC, HS_ALT_SRC, HS_COMMON_SRC_REL, and HS_ALT_SRC_REL
|
||||
# functions: altsrc-equiv, if-has-altsrc, altsrc, altsrc-replace
|
||||
|
||||
HS_COMMON_SRC_REL=src
|
||||
|
||||
ifneq ($(OPENJDK),true)
|
||||
# This needs to be changed to a more generic location, but we keep it
|
||||
# as this for now for compatibility
|
||||
HS_ALT_SRC_REL=src/closed
|
||||
else
|
||||
HS_ALT_SRC_REL=NO_SUCH_PATH
|
||||
endif
|
||||
|
||||
HS_COMMON_SRC=$(GAMMADIR)/$(HS_COMMON_SRC_REL)
|
||||
HS_ALT_SRC=$(GAMMADIR)/$(HS_ALT_SRC_REL)
|
||||
|
||||
## altsrc-equiv
|
||||
#
|
||||
# Convert a common source path to an alternative source path
|
||||
#
|
||||
# Parameter: An absolute path into the common sources
|
||||
# Result: The matching path to the alternate-source location
|
||||
#
|
||||
altsrc-equiv=$(subst $(HS_COMMON_SRC)/,$(HS_ALT_SRC)/,$(1))
|
||||
|
||||
|
||||
## if-has-altsrc
|
||||
#
|
||||
# Conditional macro to test for the existence of an alternate source path
|
||||
#
|
||||
# Parameter: An absolute path into the common sources
|
||||
# Parameter: Result if the alternative-source location exists
|
||||
# Parameter: Result if the alternative-source location does not exist
|
||||
# Result: expands to parameter 2 or 3 depending on existence of alternate source
|
||||
#
|
||||
if-has-altsrc=$(if $(wildcard $(call altsrc-equiv,$(1))),$(2),$(3))
|
||||
|
||||
|
||||
## altsrc
|
||||
#
|
||||
# Converts common source path to alternate source path if the alternate
|
||||
# path exists, otherwise evaluates to nul (empty string)
|
||||
#
|
||||
# Parameter: An absolute path into the common sources
|
||||
# Result: The equivalent path to the alternate-source location, if such a
|
||||
# location exists on the filesystem. Otherwise it expands to empty.
|
||||
#
|
||||
altsrc=$(call if-has-altsrc,$(1),$(call altsrc-equiv,$(1)))
|
||||
|
||||
## commonsrc
|
||||
#
|
||||
# Returns parameter.
|
||||
#
|
||||
commonsrc=$(1)
|
||||
|
||||
|
||||
## altsrc-replace
|
||||
#
|
||||
# Converts a common source path to an alternate source path if the alternate
|
||||
# source path exists. Otherwise it evaluates to the input common source path.
|
||||
#
|
||||
# Parameter: An absolute path into the common sources
|
||||
# Result: A path to either the common or alternate sources
|
||||
#
|
||||
altsrc-replace=$(call if-has-altsrc,$(1),$(call altsrc-equiv,$(1)),$(1))
|
@ -1,386 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This makefile creates a build tree and lights off a build.
|
||||
# You can go back into the build tree and perform rebuilds or
|
||||
# incremental builds as desired. Be sure to reestablish
|
||||
# environment variable settings for LD_LIBRARY_PATH and JAVA_HOME.
|
||||
|
||||
# The make process now relies on java and javac. These can be
|
||||
# specified either implicitly on the PATH, by setting the
|
||||
# (JDK-inherited) ALT_BOOTDIR environment variable to full path to a
|
||||
# JDK in which bin/java and bin/javac are present and working (e.g.,
|
||||
# /usr/local/java/jdk1.3/solaris), or via the (JDK-inherited)
|
||||
# default BOOTDIR path value. Note that one of ALT_BOOTDIR
|
||||
# or BOOTDIR has to be set. We do *not* search javac, javah, rmic etc.
|
||||
# from the PATH.
|
||||
#
|
||||
# One can set ALT_BOOTDIR or BOOTDIR to point to a jdk that runs on
|
||||
# an architecture that differs from the target architecture, as long
|
||||
# as the bootstrap jdk runs under the same flavor of OS as the target
|
||||
# (i.e., if the target is linux, point to a jdk that runs on a linux
|
||||
# box). In order to use such a bootstrap jdk, set the make variable
|
||||
# REMOTE to the desired remote command mechanism, e.g.,
|
||||
#
|
||||
# make REMOTE="rsh -l me myotherlinuxbox"
|
||||
|
||||
ifeq ($(GAMMADIR),)
|
||||
include ../../make/defs.make
|
||||
else
|
||||
include $(GAMMADIR)/make/defs.make
|
||||
endif
|
||||
include $(GAMMADIR)/make/$(OSNAME)/makefiles/rules.make
|
||||
|
||||
ifndef CC_INTERP
|
||||
ifndef FORCE_TIERED
|
||||
FORCE_TIERED=1
|
||||
endif
|
||||
endif
|
||||
|
||||
ifdef LP64
|
||||
ifeq ("$(filter $(LP64_ARCH),$(BUILDARCH))","")
|
||||
_JUNK_ := $(shell echo >&2 \
|
||||
$(OSNAME) $(ARCH) "*** ERROR: this platform does not support 64-bit compilers!")
|
||||
@exit 1
|
||||
endif
|
||||
endif
|
||||
|
||||
# we need to set up LP64 correctly to satisfy sanity checks in adlc
|
||||
ifneq ("$(filter $(LP64_ARCH),$(BUILDARCH))","")
|
||||
MFLAGS += " LP64=1 "
|
||||
endif
|
||||
|
||||
# pass USE_SUNCC further, through MFLAGS
|
||||
ifdef USE_SUNCC
|
||||
MFLAGS += " USE_SUNCC=1 "
|
||||
endif
|
||||
|
||||
# The following renders pathnames in generated Makefiles valid on
|
||||
# machines other than the machine containing the build tree.
|
||||
#
|
||||
# For example, let's say my build tree lives on /files12 on
|
||||
# exact.east.sun.com. This logic will cause GAMMADIR to begin with
|
||||
# /net/exact/files12/...
|
||||
#
|
||||
# We only do this on SunOS variants, for a couple of reasons:
|
||||
# * It is extremely rare that source trees exist on other systems
|
||||
# * It has been claimed that the Linux automounter is flakey, so
|
||||
# changing GAMMADIR in a way that exercises the automounter could
|
||||
# prove to be a source of unreliability in the build process.
|
||||
# Obviously, this Makefile is only relevant on SunOS boxes to begin
|
||||
# with, but the SunOS conditionalization will make it easier to
|
||||
# combine Makefiles in the future (assuming we ever do that).
|
||||
|
||||
ifeq ($(OSNAME),solaris)
|
||||
|
||||
# prepend current directory to relative pathnames.
|
||||
NEW_GAMMADIR := \
|
||||
$(shell echo $(GAMMADIR) | \
|
||||
sed -e "s=^\([^/].*\)=$(shell pwd)/\1=" \
|
||||
)
|
||||
unexport NEW_GAMMADIR
|
||||
|
||||
# If NEW_GAMMADIR doesn't already start with "/net/":
|
||||
ifeq ($(strip $(filter /net/%,$(NEW_GAMMADIR))),)
|
||||
# prepend /net/$(HOST)
|
||||
# remove /net/$(HOST) if name already began with /home/
|
||||
# remove /net/$(HOST) if name already began with /java/
|
||||
# remove /net/$(HOST) if name already began with /lab/
|
||||
NEW_GAMMADIR := \
|
||||
$(shell echo $(NEW_GAMMADIR) | \
|
||||
sed -e "s=^\(.*\)=/net/$(HOST)\1=" \
|
||||
-e "s=^/net/$(HOST)/home/=/home/=" \
|
||||
-e "s=^/net/$(HOST)/java/=/java/=" \
|
||||
-e "s=^/net/$(HOST)/lab/=/lab/=" \
|
||||
)
|
||||
# Don't use the new value for GAMMADIR unless a file with the new
|
||||
# name actually exists.
|
||||
ifneq ($(wildcard $(NEW_GAMMADIR)),)
|
||||
GAMMADIR := $(NEW_GAMMADIR)
|
||||
endif
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
# BUILDARCH is set to "zero" for Zero builds. VARIANTARCH
|
||||
# is used to give the build directories meaningful names.
|
||||
VARIANTARCH = $(subst i386,i486,$(ZERO_LIBARCH))
|
||||
|
||||
# There is a (semi-) regular correspondence between make targets and actions:
|
||||
#
|
||||
# Target Tree Type Build Dir
|
||||
#
|
||||
# debug compiler2 <os>_<arch>_compiler2/debug
|
||||
# fastdebug compiler2 <os>_<arch>_compiler2/fastdebug
|
||||
# optimized compiler2 <os>_<arch>_compiler2/optimized
|
||||
# product compiler2 <os>_<arch>_compiler2/product
|
||||
#
|
||||
# debug1 compiler1 <os>_<arch>_compiler1/debug
|
||||
# fastdebug1 compiler1 <os>_<arch>_compiler1/fastdebug
|
||||
# optimized1 compiler1 <os>_<arch>_compiler1/optimized
|
||||
# product1 compiler1 <os>_<arch>_compiler1/product
|
||||
#
|
||||
# debugcore core <os>_<arch>_core/debug
|
||||
# fastdebugcore core <os>_<arch>_core/fastdebug
|
||||
# optimizedcore core <os>_<arch>_core/optimized
|
||||
# productcore core <os>_<arch>_core/product
|
||||
#
|
||||
# debugzero zero <os>_<arch>_zero/debug
|
||||
# fastdebugzero zero <os>_<arch>_zero/fastdebug
|
||||
# optimizedzero zero <os>_<arch>_zero/optimized
|
||||
# productzero zero <os>_<arch>_zero/product
|
||||
#
|
||||
# debugshark shark <os>_<arch>_shark/debug
|
||||
# fastdebugshark shark <os>_<arch>_shark/fastdebug
|
||||
# optimizedshark shark <os>_<arch>_shark/optimized
|
||||
# productshark shark <os>_<arch>_shark/product
|
||||
#
|
||||
# fastdebugminimal1 minimal1 <os>_<arch>_minimal1/fastdebug
|
||||
# debugminimal1 minimal1 <os>_<arch>_minimal1/debug
|
||||
# productminimal1 minimal1 <os>_<arch>_minimal1/product
|
||||
#
|
||||
# What you get with each target:
|
||||
#
|
||||
# debug* - debug compile with asserts enabled
|
||||
# fastdebug* - optimized compile, but with asserts enabled
|
||||
# optimized* - optimized compile, no asserts
|
||||
# product* - the shippable thing: optimized compile, no asserts, -DPRODUCT
|
||||
|
||||
# This target list needs to be coordinated with the usage message
|
||||
# in the build.sh script:
|
||||
TARGETS = debug fastdebug optimized product
|
||||
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
SUBDIR_DOCS = $(OSNAME)_$(VARIANTARCH)_docs
|
||||
else
|
||||
SUBDIR_DOCS = $(OSNAME)_$(BUILDARCH)_docs
|
||||
endif
|
||||
SUBDIRS_C1 = $(addprefix $(OSNAME)_$(BUILDARCH)_compiler1/,$(TARGETS))
|
||||
SUBDIRS_C2 = $(addprefix $(OSNAME)_$(BUILDARCH)_compiler2/,$(TARGETS))
|
||||
SUBDIRS_TIERED = $(addprefix $(OSNAME)_$(BUILDARCH)_tiered/,$(TARGETS))
|
||||
SUBDIRS_CORE = $(addprefix $(OSNAME)_$(BUILDARCH)_core/,$(TARGETS))
|
||||
SUBDIRS_ZERO = $(addprefix $(OSNAME)_$(VARIANTARCH)_zero/,$(TARGETS))
|
||||
SUBDIRS_SHARK = $(addprefix $(OSNAME)_$(VARIANTARCH)_shark/,$(TARGETS))
|
||||
SUBDIRS_MINIMAL1 = $(addprefix $(OSNAME)_$(BUILDARCH)_minimal1/,$(TARGETS))
|
||||
|
||||
TARGETS_C2 = $(TARGETS)
|
||||
TARGETS_C1 = $(addsuffix 1,$(TARGETS))
|
||||
TARGETS_TIERED = $(addsuffix tiered,$(TARGETS))
|
||||
TARGETS_CORE = $(addsuffix core,$(TARGETS))
|
||||
TARGETS_ZERO = $(addsuffix zero,$(TARGETS))
|
||||
TARGETS_SHARK = $(addsuffix shark,$(TARGETS))
|
||||
TARGETS_MINIMAL1 = $(addsuffix minimal1,$(TARGETS))
|
||||
|
||||
BUILDTREE_MAKE = $(GAMMADIR)/make/$(OSNAME)/makefiles/buildtree.make
|
||||
BUILDTREE_VARS = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OSNAME) SRCARCH=$(SRCARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH) LIBRARY_SUFFIX=$(LIBRARY_SUFFIX)
|
||||
BUILDTREE_VARS += HOTSPOT_VERSION_STRING=$(HOTSPOT_VERSION_STRING) VERSION_STRING=$(VERSION_STRING)
|
||||
BUILDTREE_VARS += ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS) OBJCOPY=$(OBJCOPY) STRIP_POLICY=$(STRIP_POLICY) ZIP_DEBUGINFO_FILES=$(ZIP_DEBUGINFO_FILES) ZIPEXE=$(ZIPEXE)
|
||||
|
||||
BUILDTREE = $(MAKE) -f $(BUILDTREE_MAKE) $(BUILDTREE_VARS)
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
# Could make everything by default, but that would take a while.
|
||||
all:
|
||||
@echo "Try '$(MAKE) <target> ...' where <target> is one or more of"
|
||||
@echo " $(TARGETS_C2)"
|
||||
@echo " $(TARGETS_C1)"
|
||||
@echo " $(TARGETS_CORE)"
|
||||
@echo " $(TARGETS_ZERO)"
|
||||
@echo " $(TARGETS_SHARK)"
|
||||
@echo " $(TARGETS_MINIMAL1)"
|
||||
|
||||
checks: check_os_version check_j2se_version
|
||||
|
||||
# We do not want people accidentally building on old systems (e.g. Linux 2.2.x,
|
||||
# Solaris 2.5.1, 2.6).
|
||||
# Disable this check by setting DISABLE_HOTSPOT_OS_VERSION_CHECK=ok.
|
||||
|
||||
#SUPPORTED_OS_VERSION = 2.4% 2.5% 2.6% 2.7%
|
||||
DISABLE_HOTSPOT_OS_VERSION_CHECK = ok
|
||||
OS_VERSION := $(shell uname -r)
|
||||
EMPTY_IF_NOT_SUPPORTED = $(filter $(SUPPORTED_OS_VERSION),$(OS_VERSION))
|
||||
|
||||
check_os_version:
|
||||
ifeq ($(DISABLE_HOTSPOT_OS_VERSION_CHECK)$(EMPTY_IF_NOT_SUPPORTED),)
|
||||
$(QUIETLY) >&2 echo "*** This OS is not supported:" `uname -a`; exit 1;
|
||||
endif
|
||||
|
||||
# jvmti.make requires XSLT (J2SE 1.4.x or newer):
|
||||
XSLT_CHECK = $(REMOTE) $(RUN.JAVAP) javax.xml.transform.TransformerFactory
|
||||
# If not found then fail fast.
|
||||
check_j2se_version:
|
||||
$(QUIETLY) if ! $(XSLT_CHECK) > /dev/null 2>&1; then \
|
||||
$(REMOTE) $(RUN.JAVA) -version; \
|
||||
echo "*** An XSLT processor (J2SE 1.4.x or newer) is required" \
|
||||
"to bootstrap this build" 1>&2; \
|
||||
exit 1; \
|
||||
fi
|
||||
|
||||
$(SUBDIRS_TIERED): $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=tiered
|
||||
|
||||
$(SUBDIRS_C2): $(BUILDTREE_MAKE)
|
||||
ifeq ($(FORCE_TIERED),1)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=tiered FORCE_TIERED=1
|
||||
else
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=compiler2
|
||||
endif
|
||||
|
||||
$(SUBDIRS_C1): $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=compiler1
|
||||
|
||||
$(SUBDIRS_CORE): $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=core
|
||||
|
||||
$(SUBDIRS_ZERO): $(BUILDTREE_MAKE) platform_zero
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=zero VARIANTARCH=$(VARIANTARCH)
|
||||
|
||||
$(SUBDIRS_SHARK): $(BUILDTREE_MAKE) platform_zero
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=shark VARIANTARCH=$(VARIANTARCH)
|
||||
|
||||
$(SUBDIRS_MINIMAL1): $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
|
||||
+$(BUILDTREE) VARIANT=minimal1
|
||||
|
||||
platform_zero: $(GAMMADIR)/make/$(OSNAME)/platform_zero.in
|
||||
$(SED) 's/@ZERO_ARCHDEF@/$(ZERO_ARCHDEF)/g;s/@ZERO_LIBARCH@/$(ZERO_LIBARCH)/g;' < $< > $@
|
||||
|
||||
# Define INSTALL=y at command line to automatically copy JVM into JAVA_HOME
|
||||
|
||||
$(TARGETS_C2): $(SUBDIRS_C2)
|
||||
cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_TIERED): $(SUBDIRS_TIERED)
|
||||
cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_C1): $(SUBDIRS_C1)
|
||||
cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_CORE): $(SUBDIRS_CORE)
|
||||
cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_ZERO): $(SUBDIRS_ZERO)
|
||||
cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_SHARK): $(SUBDIRS_SHARK)
|
||||
cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
$(TARGETS_MINIMAL1): $(SUBDIRS_MINIMAL1)
|
||||
cd $(OSNAME)_$(BUILDARCH)_minimal1/$(patsubst %minimal1,%,$@) && $(MAKE) $(MFLAGS)
|
||||
ifdef INSTALL
|
||||
cd $(OSNAME)_$(BUILDARCH)_minimal1/$(patsubst %minimal1,%,$@) && $(MAKE) $(MFLAGS) install
|
||||
endif
|
||||
|
||||
# Just build the tree, and nothing else:
|
||||
tree: $(SUBDIRS_C2)
|
||||
tree1: $(SUBDIRS_C1)
|
||||
treecore: $(SUBDIRS_CORE)
|
||||
treezero: $(SUBDIRS_ZERO)
|
||||
treeshark: $(SUBDIRS_SHARK)
|
||||
treeminimal1: $(SUBDIRS_MINIMAL1)
|
||||
|
||||
# Doc target. This is the same for all build options.
|
||||
# Hence create a docs directory beside ...$(ARCH)_[...]
|
||||
# We specify 'BUILD_FLAVOR=product' so that the proper
|
||||
# ENABLE_FULL_DEBUG_SYMBOLS value is used.
|
||||
docs: checks
|
||||
$(QUIETLY) mkdir -p $(SUBDIR_DOCS)
|
||||
$(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) BUILD_FLAVOR=product jvmtidocs
|
||||
|
||||
# Synonyms for win32-like targets.
|
||||
compiler2: debug product
|
||||
|
||||
compiler1: debug1 product1
|
||||
|
||||
core: debugcore productcore
|
||||
|
||||
zero: debugzero productzero
|
||||
|
||||
shark: debugshark productshark
|
||||
|
||||
warn_jvmg_deprecated:
|
||||
echo "Warning: The jvmg target has been replaced with debug"
|
||||
echo "Warning: Please update your usage"
|
||||
|
||||
jvmg: warn_jvmg_deprecated debug
|
||||
|
||||
jvmg1: warn_jvmg_deprecated debug1
|
||||
|
||||
jvmgcore: warn_jvmg_deprecated debugcore
|
||||
|
||||
jvmgzero: warn_jvmg_deprecated debugzero
|
||||
|
||||
jvmgshark: warn_jvmg_deprecated debugshark
|
||||
|
||||
clean_docs:
|
||||
rm -rf $(SUBDIR_DOCS)
|
||||
|
||||
clean_compiler1 clean_compiler2 clean_core clean_zero clean_shark clean_minimal1:
|
||||
rm -rf $(OSNAME)_$(BUILDARCH)_$(subst clean_,,$@)
|
||||
|
||||
clean: clean_compiler2 clean_compiler1 clean_core clean_zero clean_shark clean_minimal1 clean_docs
|
||||
|
||||
include $(GAMMADIR)/make/cscope.make
|
||||
|
||||
#
|
||||
# Include alternate Makefile if it exists.
|
||||
#
|
||||
-include $(HS_ALT_MAKE)/$(OSNAME)/Makefile.make
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
.PHONY: $(TARGETS_C2) $(TARGETS_C1) $(TARGETS_CORE) $(TARGETS_ZERO) $(TARGETS_SHARK) $(TARGETS_MINIMAL1)
|
||||
.PHONY: tree tree1 treecore treezero treeshark
|
||||
.PHONY: all compiler1 compiler2 core zero shark
|
||||
.PHONY: clean clean_compiler1 clean_compiler2 clean_core clean_zero clean_shark docs clean_docs
|
||||
.PHONY: checks check_os_version check_j2se_version
|
||||
.PHONY: $(HS_ALT_MAKE)/$(OSNAME)/Makefile.make
|
||||
|
||||
.NOTPARALLEL:
|
@ -1,26 +0,0 @@
|
||||
Copyright (c) 2007, 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.
|
||||
|
||||
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.
|
||||
|
||||
________________________________________________________________________
|
||||
|
||||
Please refer to the comments in the Makefile in this directory
|
||||
for instructions how to build the Solaris versions.
|
||||
|
@ -1,23 +0,0 @@
|
||||
#! /bin/sh
|
||||
#
|
||||
# This file is used by adlc.make to selectively update generated
|
||||
# adlc files. Because source and target diretories are relative
|
||||
# paths, this file is copied to the target build directory before
|
||||
# use.
|
||||
#
|
||||
# adlc-updater <file> <source-dir> <target-dir>
|
||||
#
|
||||
fix_lines() {
|
||||
# repair bare #line directives in $1 to refer to $2
|
||||
# and add an override of __FILE__ with just the basename on the
|
||||
# first line of the file.
|
||||
awk < $1 > $1+ -v F2=$2 '
|
||||
BEGIN { print "#line 1 \"" F2 "\""; }
|
||||
/^#line 999999$/ {print "#line " (NR+1) " \"" F2 "\""; next}
|
||||
{print}
|
||||
'
|
||||
mv $1+ $1
|
||||
}
|
||||
fix_lines $2/$1 $1
|
||||
[ -f $3/$1 ] && cmp -s $2/$1 $3/$1 || \
|
||||
( [ -f $3/$1 ] && echo Updating $3/$1 ; touch $2/made-change ; mv $2/$1 $3/$1 )
|
@ -1,87 +0,0 @@
|
||||
#! /bin/sh
|
||||
#
|
||||
# Copyright (c) 1999, 2008, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This script is used only from top.make.
|
||||
# The macro $(MFLAGS-adjusted) calls this script to
|
||||
# adjust the "-j" arguments to take into account
|
||||
# the HOTSPOT_BUILD_JOBS variable. The default
|
||||
# handling of the "-j" argument by gnumake does
|
||||
# not meet our needs, so we must adjust it ourselves.
|
||||
|
||||
# This argument adjustment applies to two recursive
|
||||
# calls to "$(MAKE) $(MFLAGS-adjusted)" in top.make.
|
||||
# One invokes adlc.make, and the other invokes vm.make.
|
||||
# The adjustment propagates the desired concurrency
|
||||
# level down to the sub-make (of the adlc or vm).
|
||||
# The default behavior of gnumake is to run all
|
||||
# sub-makes without concurrency ("-j1").
|
||||
|
||||
# Also, we use a make variable rather than an explicit
|
||||
# "-j<N>" argument to control this setting, so that
|
||||
# the concurrency setting (which must be tuned separately
|
||||
# for each MP system) can be set via an environment variable.
|
||||
# The recommended setting is 1.5x to 2x the number of available
|
||||
# CPUs on the MP system, which is large enough to keep the CPUs
|
||||
# busy (even though some jobs may be I/O bound) but not too large,
|
||||
# we may presume, to overflow the system's swap space.
|
||||
|
||||
set -eu
|
||||
|
||||
default_build_jobs=4
|
||||
|
||||
case $# in
|
||||
[12]) true;;
|
||||
*) >&2 echo "Usage: $0 ${MFLAGS} ${HOTSPOT_BUILD_JOBS}"; exit 2;;
|
||||
esac
|
||||
|
||||
MFLAGS=$1
|
||||
HOTSPOT_BUILD_JOBS=${2-}
|
||||
|
||||
# Normalize any -jN argument to the form " -j${HBJ}"
|
||||
MFLAGS=`
|
||||
echo "$MFLAGS" \
|
||||
| sed '
|
||||
s/^-/ -/
|
||||
s/ -\([^ I][^ I]*\)j/ -\1 -j/
|
||||
s/ -j[0-9][0-9]*/ -j/
|
||||
s/ -j\([^ ]\)/ -j -\1/
|
||||
s/ -j/ -j'${HOTSPOT_BUILD_JOBS:-${default_build_jobs}}'/
|
||||
' `
|
||||
|
||||
case ${HOTSPOT_BUILD_JOBS} in \
|
||||
|
||||
'') case ${MFLAGS} in
|
||||
*\ -j*)
|
||||
>&2 echo "# Note: -jN is ineffective for setting parallelism in this makefile."
|
||||
>&2 echo "# please set HOTSPOT_BUILD_JOBS=${default_build_jobs} in the command line or environment."
|
||||
esac;;
|
||||
|
||||
?*) case ${MFLAGS} in
|
||||
*\ -j*) true;;
|
||||
*) MFLAGS="-j${HOTSPOT_BUILD_JOBS} ${MFLAGS}";;
|
||||
esac;;
|
||||
esac
|
||||
|
||||
echo "${MFLAGS}"
|
@ -1,233 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This makefile (adlc.make) is included from the adlc.make in the
|
||||
# build directories.
|
||||
# It knows how to compile, link, and run the adlc.
|
||||
|
||||
include $(GAMMADIR)/make/$(Platform_os_family)/makefiles/rules.make
|
||||
|
||||
# #########################################################################
|
||||
|
||||
# OUTDIR must be the same as AD_Dir = $(GENERATED)/adfiles in top.make:
|
||||
GENERATED = ../generated
|
||||
OUTDIR = $(GENERATED)/adfiles
|
||||
|
||||
ARCH = $(Platform_arch)
|
||||
OS = $(Platform_os_family)
|
||||
|
||||
SOURCE.AD = $(OUTDIR)/$(OS)_$(Platform_arch_model).ad
|
||||
|
||||
ifeq ("${Platform_arch_model}", "${Platform_arch}")
|
||||
SOURCES.AD = \
|
||||
$(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(ARCH)/vm/$(Platform_arch_model).ad)
|
||||
else
|
||||
SOURCES.AD = \
|
||||
$(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(ARCH)/vm/$(Platform_arch_model).ad) \
|
||||
$(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(ARCH)/vm/$(Platform_arch).ad)
|
||||
endif
|
||||
|
||||
EXEC = $(OUTDIR)/adlc
|
||||
|
||||
# set VPATH so make knows where to look for source files
|
||||
Src_Dirs_V += $(GAMMADIR)/src/share/vm/adlc
|
||||
VPATH += $(Src_Dirs_V:%=%:)
|
||||
|
||||
# set INCLUDES for C preprocessor
|
||||
Src_Dirs_I += $(GAMMADIR)/src/share/vm/adlc $(GENERATED)
|
||||
INCLUDES += $(Src_Dirs_I:%=-I%)
|
||||
|
||||
# set flags for adlc compilation
|
||||
CXXFLAGS = $(SYSDEFS) $(INCLUDES)
|
||||
|
||||
# Force assertions on.
|
||||
CXXFLAGS += -DASSERT
|
||||
|
||||
# CFLAGS_WARN holds compiler options to suppress/enable warnings.
|
||||
# Compiler warnings are treated as errors
|
||||
ifneq ($(COMPILER_WARNINGS_FATAL),false)
|
||||
CFLAGS_WARN = $(WARNINGS_ARE_ERRORS)
|
||||
endif
|
||||
CFLAGS += $(CFLAGS_WARN)
|
||||
|
||||
OBJECTNAMES = \
|
||||
adlparse.o \
|
||||
archDesc.o \
|
||||
arena.o \
|
||||
dfa.o \
|
||||
dict2.o \
|
||||
filebuff.o \
|
||||
forms.o \
|
||||
formsopt.o \
|
||||
formssel.o \
|
||||
main.o \
|
||||
adlc-opcodes.o \
|
||||
output_c.o \
|
||||
output_h.o \
|
||||
|
||||
OBJECTS = $(OBJECTNAMES:%=$(OUTDIR)/%)
|
||||
|
||||
GENERATEDNAMES = \
|
||||
ad_$(Platform_arch_model).cpp \
|
||||
ad_$(Platform_arch_model).hpp \
|
||||
ad_$(Platform_arch_model)_clone.cpp \
|
||||
ad_$(Platform_arch_model)_expand.cpp \
|
||||
ad_$(Platform_arch_model)_format.cpp \
|
||||
ad_$(Platform_arch_model)_gen.cpp \
|
||||
ad_$(Platform_arch_model)_misc.cpp \
|
||||
ad_$(Platform_arch_model)_peephole.cpp \
|
||||
ad_$(Platform_arch_model)_pipeline.cpp \
|
||||
adGlobals_$(Platform_arch_model).hpp \
|
||||
dfa_$(Platform_arch_model).cpp \
|
||||
|
||||
GENERATEDFILES = $(GENERATEDNAMES:%=$(OUTDIR)/%)
|
||||
|
||||
# #########################################################################
|
||||
|
||||
all: $(EXEC)
|
||||
|
||||
$(EXEC) : $(OBJECTS)
|
||||
@echo $(LOG_INFO) Making adlc
|
||||
$(QUIETLY) $(HOST.LINK_NOPROF.CXX) -o $(EXEC) $(OBJECTS)
|
||||
|
||||
# Random dependencies:
|
||||
$(OBJECTS): opcodes.hpp classes.hpp adlc.hpp adlcVMDeps.hpp adlparse.hpp archDesc.hpp arena.hpp dict2.hpp filebuff.hpp forms.hpp formsopt.hpp formssel.hpp
|
||||
|
||||
# The source files refer to ostream.h, which sparcworks calls iostream.h
|
||||
$(OBJECTS): ostream.h
|
||||
|
||||
ostream.h :
|
||||
@echo >$@ '#include <iostream.h>'
|
||||
|
||||
dump:
|
||||
: OUTDIR=$(OUTDIR)
|
||||
: OBJECTS=$(OBJECTS)
|
||||
: products = $(GENERATEDFILES)
|
||||
|
||||
all: $(GENERATEDFILES)
|
||||
|
||||
$(GENERATEDFILES): refresh_adfiles
|
||||
|
||||
# Get a unique temporary directory name, so multiple makes can run in parallel.
|
||||
# Note that product files are updated via "mv", which is atomic.
|
||||
TEMPDIR := $(OUTDIR)/mktmp$(shell echo $$$$)
|
||||
|
||||
# Debuggable by default
|
||||
CFLAGS += -g
|
||||
|
||||
# Pass -D flags into ADLC.
|
||||
ADLCFLAGS += $(SYSDEFS)
|
||||
|
||||
# Note "+="; it is a hook so flags.make can add more flags, like -g or -DFOO.
|
||||
ADLCFLAGS += -q -T
|
||||
|
||||
# Normally, debugging is done directly on the ad_<arch>*.cpp files.
|
||||
# But -g will put #line directives in those files pointing back to <arch>.ad.
|
||||
# Some builds of gcc 3.2 have a bug that gets tickled by the extra #line directives
|
||||
# so skip it for 3.2 and ealier.
|
||||
ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 3 \) \| \( \( $(CC_VER_MAJOR) = 3 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0"
|
||||
ADLCFLAGS += -g
|
||||
endif
|
||||
|
||||
ifdef LP64
|
||||
ADLCFLAGS += -D_LP64
|
||||
else
|
||||
ADLCFLAGS += -U_LP64
|
||||
endif
|
||||
|
||||
#
|
||||
# adlc_updater is a simple sh script, under sccs control. It is
|
||||
# used to selectively update generated adlc files. This should
|
||||
# provide a nice compilation speed improvement.
|
||||
#
|
||||
ADLC_UPDATER_DIRECTORY = $(GAMMADIR)/make/$(OS)
|
||||
ADLC_UPDATER = adlc_updater
|
||||
$(ADLC_UPDATER): $(ADLC_UPDATER_DIRECTORY)/$(ADLC_UPDATER)
|
||||
$(QUIETLY) cp $< $@; chmod +x $@
|
||||
|
||||
# This action refreshes all generated adlc files simultaneously.
|
||||
# The way it works is this:
|
||||
# 1) create a scratch directory to work in.
|
||||
# 2) if the current working directory does not have $(ADLC_UPDATER), copy it.
|
||||
# 3) run the compiled adlc executable. This will create new adlc files in the scratch directory.
|
||||
# 4) call $(ADLC_UPDATER) on each generated adlc file. It will selectively update changed or missing files.
|
||||
# 5) If we actually updated any files, echo a notice.
|
||||
#
|
||||
refresh_adfiles: $(EXEC) $(SOURCE.AD) $(ADLC_UPDATER)
|
||||
@rm -rf $(TEMPDIR); mkdir $(TEMPDIR)
|
||||
$(QUIETLY) $(EXEC) $(ADLCFLAGS) $(SOURCE.AD) \
|
||||
-c$(TEMPDIR)/ad_$(Platform_arch_model).cpp -h$(TEMPDIR)/ad_$(Platform_arch_model).hpp -a$(TEMPDIR)/dfa_$(Platform_arch_model).cpp -v$(TEMPDIR)/adGlobals_$(Platform_arch_model).hpp \
|
||||
|| { rm -rf $(TEMPDIR); exit 1; }
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model).cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model).hpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_clone.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_expand.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_format.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_gen.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_misc.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_peephole.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) ad_$(Platform_arch_model)_pipeline.cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) adGlobals_$(Platform_arch_model).hpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) ./$(ADLC_UPDATER) dfa_$(Platform_arch_model).cpp $(TEMPDIR) $(OUTDIR)
|
||||
$(QUIETLY) [ -f $(TEMPDIR)/made-change ] \
|
||||
|| echo $(LOG_INFO) "Rescanned $(SOURCE.AD) but encountered no changes."
|
||||
$(QUIETLY) rm -rf $(TEMPDIR)
|
||||
|
||||
|
||||
# #########################################################################
|
||||
|
||||
$(SOURCE.AD): $(SOURCES.AD)
|
||||
$(QUIETLY) $(PROCESS_AD_FILES) $(SOURCES.AD) > $(SOURCE.AD)
|
||||
|
||||
#PROCESS_AD_FILES = cat
|
||||
# Pass through #line directives, in case user enables -g option above:
|
||||
PROCESS_AD_FILES = awk '{ \
|
||||
if (CUR_FN != FILENAME) { CUR_FN=FILENAME; NR_BASE=NR-1; need_lineno=1 } \
|
||||
if (need_lineno && $$0 !~ /\/\//) \
|
||||
{ print "\n\n\#line " (NR-NR_BASE) " \"" FILENAME "\""; need_lineno=0 }; \
|
||||
print }'
|
||||
|
||||
$(OUTDIR)/%.o: %.cpp
|
||||
@echo $(LOG_INFO) Compiling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(HOST.COMPILE.CXX) -o $@ $< $(COMPILE_DONE)
|
||||
|
||||
# Some object files are given a prefix, to disambiguate
|
||||
# them from objects of the same name built for the VM.
|
||||
$(OUTDIR)/adlc-%.o: %.cpp
|
||||
@echo $(LOG_INFO) Compiling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(HOST.COMPILE.CXX) -o $@ $< $(COMPILE_DONE)
|
||||
|
||||
# #########################################################################
|
||||
|
||||
clean :
|
||||
rm $(OBJECTS)
|
||||
|
||||
cleanall :
|
||||
rm $(OBJECTS) $(EXEC)
|
||||
|
||||
# #########################################################################
|
||||
|
||||
.PHONY: all dump refresh_adfiles clean cleanall
|
@ -1,47 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2003, 2016, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# The copied fdlibm routines in sharedRuntimeTrig.o must not be optimized
|
||||
OPT_CFLAGS/sharedRuntimeTrig.o = $(OPT_CFLAGS/NOOPT)
|
||||
# The copied fdlibm routines in sharedRuntimeTrans.o must not be optimized
|
||||
OPT_CFLAGS/sharedRuntimeTrans.o = $(OPT_CFLAGS/NOOPT)
|
||||
# Must also specify if CPU is little endian
|
||||
CFLAGS += -DVM_LITTLE_ENDIAN
|
||||
|
||||
CFLAGS += -D_LP64=1
|
||||
|
||||
# The serviceability agent relies on frame pointer (%rbp) to walk thread stack
|
||||
ifndef USE_SUNCC
|
||||
CFLAGS += -fno-omit-frame-pointer
|
||||
endif
|
||||
|
||||
OPT_CFLAGS/compactingPermGenGen.o = -O1
|
||||
|
||||
# The debug flag is added to OPT_CFLAGS, but lost in case of per-file overrides
|
||||
# of OPT_CFLAGS. Restore it here.
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
OPT_CFLAGS/sharedRuntimeTrig.o += -g
|
||||
OPT_CFLAGS/sharedRuntimeTrans.o += -g
|
||||
OPT_CFLAGS/compactingPermGenGen.o += -g
|
||||
endif
|
@ -1,27 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2008, 2016, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
Obj_Files += bsd_arm.o
|
||||
|
||||
CFLAGS += -DVM_LITTLE_ENDIAN
|
@ -1,12 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# If we're cross compiling use that path for nm
|
||||
if [ "$CROSS_COMPILE_ARCH" != "" ]; then
|
||||
NM=$ALT_COMPILER_PATH/nm
|
||||
else
|
||||
NM=nm
|
||||
fi
|
||||
|
||||
$NM -Uj $* | awk '
|
||||
{ if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 }
|
||||
'
|
@ -1,370 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Usage:
|
||||
#
|
||||
# $(MAKE) -f buildtree.make SRCARCH=srcarch BUILDARCH=buildarch LIBARCH=libarch
|
||||
# GAMMADIR=dir OS_FAMILY=os VARIANT=variant
|
||||
#
|
||||
# The macros ARCH, GAMMADIR, OS_FAMILY and VARIANT must be defined in the
|
||||
# environment or on the command-line:
|
||||
#
|
||||
# ARCH - sparc, i486, ... HotSpot cpu and os_cpu source directory
|
||||
# BUILDARCH - build directory
|
||||
# LIBARCH - the corresponding directory in JDK/JRE
|
||||
# GAMMADIR - top of workspace
|
||||
# OS_FAMILY - operating system
|
||||
# VARIANT - core, compiler1, compiler2, or tiered
|
||||
# VERSION_STRING - the JDK version string as specified by JEP-223
|
||||
# HOTSPOT_VERSION_STRING - the same as VERSION_STRING, unless overridden by a standalone build
|
||||
#
|
||||
# Builds the directory trees with makefiles plus some convenience files in
|
||||
# each directory:
|
||||
#
|
||||
# Makefile - for "make foo"
|
||||
# flags.make - with macro settings
|
||||
# vm.make - to support making "$(MAKE) -v vm.make" in makefiles
|
||||
# adlc.make -
|
||||
# trace.make - generate tracing event and type definitions
|
||||
# jvmti.make - generate JVMTI bindings from the spec (JSR-163)
|
||||
#
|
||||
# The makefiles are split this way so that "make foo" will run faster by not
|
||||
# having to read the dependency files for the vm.
|
||||
|
||||
# needs to be set here since this Makefile doesn't include defs.make
|
||||
OS_VENDOR:=$(shell uname -s)
|
||||
|
||||
-include $(SPEC)
|
||||
include $(GAMMADIR)/make/scm.make
|
||||
include $(GAMMADIR)/make/defs.make
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
|
||||
# 'gmake MAKE_VERBOSE=y' or 'gmake QUIETLY=' gives all the gory details.
|
||||
QUIETLY$(MAKE_VERBOSE) = @
|
||||
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
PLATFORM_FILE = $(shell dirname $(shell dirname $(shell pwd)))/platform_zero
|
||||
else
|
||||
ifdef USE_SUNCC
|
||||
PLATFORM_FILE = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH).suncc
|
||||
else
|
||||
PLATFORM_FILE = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Allow overriding of the arch part of the directory but default
|
||||
# to BUILDARCH if nothing is specified
|
||||
ifeq ($(VARIANTARCH),)
|
||||
VARIANTARCH=$(BUILDARCH)
|
||||
endif
|
||||
|
||||
ifdef FORCE_TIERED
|
||||
ifeq ($(VARIANT),tiered)
|
||||
PLATFORM_DIR = $(OS_FAMILY)_$(VARIANTARCH)_compiler2
|
||||
else
|
||||
PLATFORM_DIR = $(OS_FAMILY)_$(VARIANTARCH)_$(VARIANT)
|
||||
endif
|
||||
else
|
||||
PLATFORM_DIR = $(OS_FAMILY)_$(VARIANTARCH)_$(VARIANT)
|
||||
endif
|
||||
|
||||
#
|
||||
# We do two levels of exclusion in the shared directory.
|
||||
# TOPLEVEL excludes are pruned, they are not recursively searched,
|
||||
# but lower level directories can be named without fear of collision.
|
||||
# ALWAYS excludes are excluded at any level in the directory tree.
|
||||
#
|
||||
|
||||
ALWAYS_EXCLUDE_DIRS = $(SCM_DIRS)
|
||||
|
||||
ifeq ($(VARIANT),tiered)
|
||||
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name agent
|
||||
else
|
||||
ifeq ($(VARIANT),compiler2)
|
||||
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name c1 -o -name agent
|
||||
else
|
||||
# compiler1 and core use the same exclude list
|
||||
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name opto -o -name libadt -o -name agent
|
||||
endif
|
||||
endif
|
||||
|
||||
# Get things from the platform file.
|
||||
COMPILER = $(shell sed -n 's/^compiler[ ]*=[ ]*//p' $(PLATFORM_FILE))
|
||||
|
||||
# dtracefiles is used on BSD versions that implement Dtrace (like MacOS X)
|
||||
SIMPLE_DIRS = \
|
||||
$(PLATFORM_DIR)/generated/dependencies \
|
||||
$(PLATFORM_DIR)/generated/adfiles \
|
||||
$(PLATFORM_DIR)/generated/jvmtifiles \
|
||||
$(PLATFORM_DIR)/generated/tracefiles \
|
||||
$(PLATFORM_DIR)/generated/dtracefiles
|
||||
|
||||
TARGETS = debug fastdebug optimized product
|
||||
SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS))
|
||||
|
||||
# For dependencies and recursive makes.
|
||||
BUILDTREE_MAKE = $(GAMMADIR)/make/$(OS_FAMILY)/makefiles/buildtree.make
|
||||
|
||||
# dtrace.make is used on BSD versions that implement Dtrace (like MacOS X)
|
||||
BUILDTREE_TARGETS = Makefile flags.make flags_vm.make vm.make adlc.make jvmti.make trace.make dtrace.make
|
||||
|
||||
BUILDTREE_VARS = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OS_FAMILY) \
|
||||
SRCARCH=$(SRCARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH) VARIANT=$(VARIANT)
|
||||
|
||||
# Define variables to be set in flags.make.
|
||||
# Default values are set in make/defs.make.
|
||||
|
||||
# Set BUILD_USER from system-dependent hints: $LOGNAME, $(whoami)
|
||||
ifndef HOTSPOT_BUILD_USER
|
||||
HOTSPOT_BUILD_USER := $(shell echo $$LOGNAME)
|
||||
endif
|
||||
ifndef HOTSPOT_BUILD_USER
|
||||
HOTSPOT_BUILD_USER := $(shell whoami)
|
||||
endif
|
||||
# Define HOTSPOT_VM_DISTRO based on settings in make/openjdk_distro
|
||||
# or make/hotspot_distro.
|
||||
ifndef HOTSPOT_VM_DISTRO
|
||||
ifeq ($(call if-has-altsrc,$(HS_COMMON_SRC)/,true,false),true)
|
||||
include $(GAMMADIR)/make/hotspot_distro
|
||||
else
|
||||
include $(GAMMADIR)/make/openjdk_distro
|
||||
endif
|
||||
endif
|
||||
|
||||
# if hotspot-only build and/or OPENJDK isn't passed down, need to set OPENJDK
|
||||
ifndef OPENJDK
|
||||
ifneq ($(call if-has-altsrc,$(HS_COMMON_SRC)/,true,false),true)
|
||||
OPENJDK=true
|
||||
endif
|
||||
endif
|
||||
|
||||
BUILDTREE_VARS += HOTSPOT_VERSION_STRING=$(HOTSPOT_VERSION_STRING) VERSION_STRING=$(VERSION_STRING)
|
||||
|
||||
BUILDTREE = \
|
||||
$(MAKE) -f $(BUILDTREE_MAKE) $(BUILDTREE_TARGETS) $(BUILDTREE_VARS)
|
||||
|
||||
BUILDTREE_COMMENT = echo "\# Generated by $(BUILDTREE_MAKE)"
|
||||
|
||||
all: $(SUBMAKE_DIRS)
|
||||
|
||||
# Run make in each subdirectory recursively.
|
||||
$(SUBMAKE_DIRS): $(SIMPLE_DIRS) FORCE
|
||||
$(QUIETLY) [ -d $@ ] || { mkdir -p $@; }
|
||||
+$(QUIETLY) cd $@ && $(BUILDTREE) TARGET=$(@F)
|
||||
$(QUIETLY) touch $@
|
||||
|
||||
$(SIMPLE_DIRS):
|
||||
$(QUIETLY) mkdir -p $@
|
||||
|
||||
# Convenience macro which takes a source relative path, applies $(1) to the
|
||||
# absolute path, and then replaces $(GAMMADIR) in the result with a
|
||||
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile.
|
||||
gamma-path=$(subst $(GAMMADIR),\$$(GAMMADIR),$(call $(1),$(HS_COMMON_SRC)/$(2)))
|
||||
|
||||
# This bit is needed to enable local rebuilds.
|
||||
# Unless the makefile itself sets LP64, any environmental
|
||||
# setting of LP64 will interfere with the build.
|
||||
LP64_SETTING/32 = LP64 = \#empty
|
||||
LP64_SETTING/64 = LP64 = 1
|
||||
|
||||
DATA_MODE/i486 = 32
|
||||
DATA_MODE/amd64 = 64
|
||||
|
||||
DATA_MODE = $(DATA_MODE/$(BUILDARCH))
|
||||
|
||||
flags.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo "Platform_file = $(PLATFORM_FILE)" | sed 's|$(GAMMADIR)|$$(GAMMADIR)|'; \
|
||||
sed -n '/=/s/^ */Platform_/p' < $(PLATFORM_FILE); \
|
||||
echo; \
|
||||
echo "GAMMADIR = $(GAMMADIR)"; \
|
||||
echo "HS_ALT_MAKE = $(HS_ALT_MAKE)"; \
|
||||
echo "OSNAME = $(OSNAME)"; \
|
||||
echo "SYSDEFS = \$$(Platform_sysdefs)"; \
|
||||
echo "SRCARCH = $(SRCARCH)"; \
|
||||
echo "BUILDARCH = $(BUILDARCH)"; \
|
||||
echo "LIBARCH = $(LIBARCH)"; \
|
||||
echo "TARGET = $(TARGET)"; \
|
||||
echo "HOTSPOT_VERSION_STRING = $(HOTSPOT_VERSION_STRING)"; \
|
||||
echo "VERSION_STRING = $(VERSION_STRING)"; \
|
||||
echo "HOTSPOT_BUILD_USER = $(HOTSPOT_BUILD_USER)"; \
|
||||
echo "HOTSPOT_VM_DISTRO = $(HOTSPOT_VM_DISTRO)"; \
|
||||
echo "OPENJDK = $(OPENJDK)"; \
|
||||
echo "$(LP64_SETTING/$(DATA_MODE))"; \
|
||||
echo; \
|
||||
echo "STATIC_BUILD = $(STATIC_BUILD)"; \
|
||||
echo "COMPILER_WARNINGS_FATAL = $(COMPILER_WARNINGS_FATAL)"; \
|
||||
echo "EXTRA_LDFLAGS = $(EXTRA_LDFLAGS)"; \
|
||||
echo "LIBRARY_SUFFIX = $(LIBRARY_SUFFIX)"; \
|
||||
echo; \
|
||||
echo "# Used for platform dispatching"; \
|
||||
echo "TARGET_DEFINES = -DTARGET_OS_FAMILY_\$$(Platform_os_family)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_ARCH_\$$(Platform_arch)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_ARCH_MODEL_\$$(Platform_arch_model)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_OS_ARCH_\$$(Platform_os_arch)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_OS_ARCH_MODEL_\$$(Platform_os_arch_model)"; \
|
||||
echo "TARGET_DEFINES += -DTARGET_COMPILER_\$$(Platform_compiler)"; \
|
||||
echo "CFLAGS += \$$(TARGET_DEFINES)"; \
|
||||
echo; \
|
||||
echo "Src_Dirs_V = \\"; \
|
||||
sed 's/$$/ \\/;s|$(GAMMADIR)|$$(GAMMADIR)|' ../shared_dirs.lst; \
|
||||
echo "$(call gamma-path,altsrc,cpu/$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,cpu/$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os_cpu/$(OS_FAMILY)_$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os_cpu/$(OS_FAMILY)_$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os/$(OS_FAMILY)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os/$(OS_FAMILY)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os/posix/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os/posix/vm)"; \
|
||||
echo; \
|
||||
echo "Src_Dirs_I = \\"; \
|
||||
echo "$(call gamma-path,altsrc,share/vm/prims) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,share/vm/prims) \\"; \
|
||||
echo "$(call gamma-path,altsrc,share/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,share/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,share/vm/precompiled) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,share/vm/precompiled) \\"; \
|
||||
echo "$(call gamma-path,altsrc,cpu/$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,cpu/$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os_cpu/$(OS_FAMILY)_$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os_cpu/$(OS_FAMILY)_$(SRCARCH)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os/$(OS_FAMILY)/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os/$(OS_FAMILY)/vm) \\"; \
|
||||
echo "$(call gamma-path,altsrc,os/posix/vm) \\"; \
|
||||
echo "$(call gamma-path,commonsrc,os/posix/vm)"; \
|
||||
[ -n "$(CFLAGS_BROWSE)" ] && \
|
||||
echo && echo "CFLAGS_BROWSE = $(CFLAGS_BROWSE)"; \
|
||||
[ -n "$(ENABLE_FULL_DEBUG_SYMBOLS)" ] && \
|
||||
echo && echo "ENABLE_FULL_DEBUG_SYMBOLS = $(ENABLE_FULL_DEBUG_SYMBOLS)"; \
|
||||
[ -n "$(OBJCOPY)" ] && \
|
||||
echo && echo "OBJCOPY = $(OBJCOPY)"; \
|
||||
[ -n "$(STRIP_POLICY)" ] && \
|
||||
echo && echo "STRIP_POLICY = $(STRIP_POLICY)"; \
|
||||
[ -n "$(ZIP_DEBUGINFO_FILES)" ] && \
|
||||
echo && echo "ZIP_DEBUGINFO_FILES = $(ZIP_DEBUGINFO_FILES)"; \
|
||||
[ -n "$(ZIPEXE)" ] && \
|
||||
echo && echo "ZIPEXE = $(ZIPEXE)"; \
|
||||
[ -n "$(HOTSPOT_EXTRA_SYSDEFS)" ] && \
|
||||
echo && \
|
||||
echo "HOTSPOT_EXTRA_SYSDEFS\$$(HOTSPOT_EXTRA_SYSDEFS) = $(HOTSPOT_EXTRA_SYSDEFS)" && \
|
||||
echo "SYSDEFS += \$$(HOTSPOT_EXTRA_SYSDEFS)"; \
|
||||
echo; \
|
||||
[ -n "$(SPEC)" ] && \
|
||||
echo "include $(SPEC)"; \
|
||||
echo "CP ?= cp"; \
|
||||
echo "MV ?= mv"; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(VARIANT).make"; \
|
||||
echo "include \$$(GAMMADIR)/make/excludeSrc.make"; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(COMPILER).make"; \
|
||||
) > $@
|
||||
|
||||
flags_vm.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(TARGET).make"; \
|
||||
) > $@
|
||||
|
||||
../shared_dirs.lst: $(BUILDTREE_MAKE) $(GAMMADIR)/src/share/vm
|
||||
@echo $(LOG_INFO) Creating directory list $@
|
||||
$(QUIETLY) if [ -d $(HS_ALT_SRC)/share/vm ]; then \
|
||||
find $(HS_ALT_SRC)/share/vm/* -prune \
|
||||
-type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \
|
||||
\( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; > $@; \
|
||||
fi;
|
||||
$(QUIETLY) find $(HS_COMMON_SRC)/share/vm/* -prune \
|
||||
-type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \
|
||||
\( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; >> $@
|
||||
|
||||
Makefile: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/top.make"; \
|
||||
) > $@
|
||||
|
||||
vm.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo include flags_vm.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
adlc.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
jvmti.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
trace.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
dtrace.make: $(BUILDTREE_MAKE)
|
||||
@echo $(LOG_INFO) Creating $@ ...
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
echo include flags.make; \
|
||||
echo; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
|
||||
) > $@
|
||||
|
||||
FORCE:
|
||||
|
||||
.PHONY: all FORCE
|
||||
|
||||
.NOTPARALLEL:
|
@ -1,34 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2008, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making client version of VM
|
||||
|
||||
TYPE=COMPILER1
|
||||
|
||||
VM_SUBDIR = client
|
||||
|
||||
# We don't support the JVMCI in a client VM.
|
||||
INCLUDE_JVMCI := false
|
||||
|
||||
CFLAGS += -DCOMPILER1
|
@ -1,31 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2008, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making server version of VM
|
||||
|
||||
TYPE=COMPILER2
|
||||
|
||||
VM_SUBDIR = server
|
||||
|
||||
CFLAGS += -DCOMPILER2
|
@ -1,33 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2010, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making core version of VM
|
||||
|
||||
# Select which files to use (in top.make)
|
||||
TYPE=CORE
|
||||
|
||||
# There is no "core" directory in JDK. Install core build in server directory.
|
||||
VM_SUBDIR = server
|
||||
|
||||
# Note: macros.hpp defines CORE
|
@ -1,160 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 2008, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
#
|
||||
# The cscope.out file is made in the current directory and spans the entire
|
||||
# source tree.
|
||||
#
|
||||
# Things to note:
|
||||
# 1. We use relative names for cscope.
|
||||
# 2. We *don't* remove the old cscope.out file, because cscope is smart
|
||||
# enough to only build what has changed. It can be confused, however,
|
||||
# if files are renamed or removed, so it may be necessary to manually
|
||||
# remove cscope.out if a lot of reorganization has occurred.
|
||||
#
|
||||
|
||||
include $(GAMMADIR)/make/scm.make
|
||||
|
||||
NAWK = awk
|
||||
RM = rm -f
|
||||
HG = hg
|
||||
CS_TOP = ../..
|
||||
|
||||
CSDIRS = $(CS_TOP)/src $(CS_TOP)/build
|
||||
CSINCS = $(CSDIRS:%=-I%)
|
||||
|
||||
CSCOPE = cscope
|
||||
CSCOPE_FLAGS = -b
|
||||
|
||||
# Allow .java files to be added from the environment (CSCLASSES=yes).
|
||||
ifdef CSCLASSES
|
||||
ADDCLASSES= -o -name '*.java'
|
||||
endif
|
||||
|
||||
# Adding CClassHeaders also pushes the file count of a full workspace up about
|
||||
# 200 files (these files also don't exist in a new workspace, and thus will
|
||||
# cause the recreation of the database as they get created, which might seem
|
||||
# a little confusing). Thus allow these files to be added from the environment
|
||||
# (CSHEADERS=yes).
|
||||
ifndef CSHEADERS
|
||||
RMCCHEADERS= -o -name CClassHeaders
|
||||
endif
|
||||
|
||||
# Use CS_GENERATED=x to include auto-generated files in the build directories.
|
||||
ifdef CS_GENERATED
|
||||
CS_ADD_GENERATED = -o -name '*.incl'
|
||||
else
|
||||
CS_PRUNE_GENERATED = -o -name '${OS}_*_core' -o -name '${OS}_*_compiler?'
|
||||
endif
|
||||
|
||||
# OS-specific files for other systems are excluded by default. Use CS_OS=yes
|
||||
# to include platform-specific files for other platforms.
|
||||
ifndef CS_OS
|
||||
CS_OS = linux macos solaris win32 bsd
|
||||
CS_PRUNE_OS = $(patsubst %,-o -name '*%*',$(filter-out ${OS},${CS_OS}))
|
||||
endif
|
||||
|
||||
# Processor-specific files for other processors are excluded by default. Use
|
||||
# CS_CPU=x to include platform-specific files for other platforms.
|
||||
ifndef CS_CPU
|
||||
CS_CPU = i486 sparc amd64 ia64
|
||||
CS_PRUNE_CPU = $(patsubst %,-o -name '*%*',$(filter-out ${SRCARCH},${CS_CPU}))
|
||||
endif
|
||||
|
||||
# What files should we include? A simple rule might be just those files under
|
||||
# SCCS control, however this would miss files we create like the opcodes and
|
||||
# CClassHeaders. The following attempts to find everything that is *useful*.
|
||||
# (.del files are created by sccsrm, demo directories contain many .java files
|
||||
# that probably aren't useful for development, and the pkgarchive may contain
|
||||
# duplicates of files within the source hierarchy).
|
||||
|
||||
# Directories to exclude.
|
||||
CS_PRUNE_STD = $(SCM_DIRS) \
|
||||
-o -name '.del-*' \
|
||||
-o -name '*demo' \
|
||||
-o -name pkgarchive
|
||||
|
||||
CS_PRUNE = $(CS_PRUNE_STD) \
|
||||
$(CS_PRUNE_OS) \
|
||||
$(CS_PRUNE_CPU) \
|
||||
$(CS_PRUNE_GENERATED) \
|
||||
$(RMCCHEADERS)
|
||||
|
||||
# File names to include.
|
||||
CSFILENAMES = -name '*.[ch]pp' \
|
||||
-o -name '*.[Ccshlxy]' \
|
||||
$(CS_ADD_GENERATED) \
|
||||
-o -name '*.il' \
|
||||
-o -name '*.cc' \
|
||||
-o -name '*[Mm]akefile*' \
|
||||
-o -name '*.gmk' \
|
||||
-o -name '*.make' \
|
||||
-o -name '*.ad' \
|
||||
$(ADDCLASSES)
|
||||
|
||||
.PRECIOUS: cscope.out
|
||||
|
||||
cscope cscope.out: cscope.files FORCE
|
||||
$(CSCOPE) $(CSCOPE_FLAGS)
|
||||
|
||||
# The .raw file is reordered here in an attempt to make cscope display the most
|
||||
# relevant files first.
|
||||
cscope.files: .cscope.files.raw
|
||||
echo "$(CSINCS)" > $@
|
||||
-egrep -v "\.java|\/make\/" $< >> $@
|
||||
-fgrep ".java" $< >> $@
|
||||
-fgrep "/make/" $< >> $@
|
||||
|
||||
.cscope.files.raw: .nametable.files
|
||||
-find $(CSDIRS) -type d \( $(CS_PRUNE) \) -prune -o \
|
||||
-type f \( $(CSFILENAMES) \) -print > $@
|
||||
|
||||
cscope.clean: nametable.clean
|
||||
-$(RM) cscope.out cscope.files .cscope.files.raw
|
||||
|
||||
TAGS: cscope.files FORCE
|
||||
egrep -v '^-|^$$' $< | etags --members -
|
||||
|
||||
TAGS.clean: nametable.clean
|
||||
-$(RM) TAGS
|
||||
|
||||
# .nametable.files and .nametable.files.tmp are used to determine if any files
|
||||
# were added to/deleted from/renamed in the workspace. If not, then there's
|
||||
# normally no need to rebuild the cscope database. To force a rebuild of
|
||||
# the cscope database: gmake nametable.clean.
|
||||
.nametable.files: .nametable.files.tmp
|
||||
( cmp -s $@ $< ) || ( cp $< $@ )
|
||||
-$(RM) $<
|
||||
|
||||
# `hg status' is slightly faster than `hg fstatus'. Both are
|
||||
# quite a bit slower on an NFS mounted file system, so this is
|
||||
# really geared towards repos on local file systems.
|
||||
.nametable.files.tmp:
|
||||
-$(HG) fstatus -acmn > $@
|
||||
nametable.clean:
|
||||
-$(RM) .nametable.files .nametable.files.tmp
|
||||
|
||||
FORCE:
|
||||
|
||||
.PHONY: cscope cscope.clean TAGS.clean nametable.clean FORCE
|
@ -1,45 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
|
||||
# Compiler specific DEBUG_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
DEBUG_CFLAGS/DEFAULT= $(DEBUG_CFLAGS)
|
||||
DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@))
|
||||
|
||||
# _NMT_NOINLINE_ informs NMT that no inlining by Compiler
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE) -D_NMT_NOINLINE_
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-debug
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-darwin-debug
|
||||
endif
|
||||
|
||||
VERSION = debug
|
||||
SYSDEFS += -DASSERT
|
||||
PICFLAGS = DEFAULT
|
@ -1,382 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2006, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# The common definitions for hotspot bsd builds.
|
||||
# Include the top level defs.make under make directory instead of this one.
|
||||
# This file is included into make/defs.make.
|
||||
|
||||
SLASH_JAVA ?= /java
|
||||
|
||||
define print_info
|
||||
ifneq ($$(LOG_LEVEL), warn)
|
||||
$$(shell echo >&2 "INFO: $1")
|
||||
endif
|
||||
endef
|
||||
|
||||
# Need PLATFORM (os-arch combo names) for jdk and hotspot, plus libarch name
|
||||
ARCH:=$(shell uname -m)
|
||||
PATH_SEP = :
|
||||
ifeq ($(LP64), 1)
|
||||
ARCH_DATA_MODEL ?= 64
|
||||
else
|
||||
ARCH_DATA_MODEL ?= 32
|
||||
endif
|
||||
|
||||
# zero
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
ifeq ($(ARCH_DATA_MODEL), 64)
|
||||
MAKE_ARGS += LP64=1
|
||||
endif
|
||||
PLATFORM = bsd-zero
|
||||
VM_PLATFORM = bsd_$(subst i386,i486,$(ZERO_LIBARCH))
|
||||
HS_ARCH = zero
|
||||
ARCH = zero
|
||||
endif
|
||||
|
||||
# ia64
|
||||
ifeq ($(ARCH), ia64)
|
||||
ARCH_DATA_MODEL = 64
|
||||
MAKE_ARGS += LP64=1
|
||||
PLATFORM = bsd-ia64
|
||||
VM_PLATFORM = bsd_ia64
|
||||
HS_ARCH = ia64
|
||||
endif
|
||||
|
||||
# sparc
|
||||
ifeq ($(ARCH), sparc64)
|
||||
ifeq ($(ARCH_DATA_MODEL), 64)
|
||||
ARCH_DATA_MODEL = 64
|
||||
MAKE_ARGS += LP64=1
|
||||
PLATFORM = bsd-sparcv9
|
||||
VM_PLATFORM = bsd_sparcv9
|
||||
else
|
||||
ARCH_DATA_MODEL = 32
|
||||
PLATFORM = bsd-sparc
|
||||
VM_PLATFORM = bsd_sparc
|
||||
endif
|
||||
HS_ARCH = sparc
|
||||
endif
|
||||
|
||||
# amd64
|
||||
ifneq (,$(findstring $(ARCH), amd64 x86_64))
|
||||
ifeq ($(ARCH_DATA_MODEL), 64)
|
||||
ARCH_DATA_MODEL = 64
|
||||
MAKE_ARGS += LP64=1
|
||||
PLATFORM = bsd-amd64
|
||||
VM_PLATFORM = bsd_amd64
|
||||
HS_ARCH = x86
|
||||
else
|
||||
ARCH_DATA_MODEL = 32
|
||||
PLATFORM = bsd-i586
|
||||
VM_PLATFORM = bsd_i486
|
||||
HS_ARCH = x86
|
||||
# We have to reset ARCH to i386 since SRCARCH relies on it
|
||||
ARCH = i386
|
||||
endif
|
||||
endif
|
||||
|
||||
# i386
|
||||
ifeq ($(ARCH), i386)
|
||||
ifeq ($(ARCH_DATA_MODEL), 64)
|
||||
ARCH_DATA_MODEL = 64
|
||||
MAKE_ARGS += LP64=1
|
||||
PLATFORM = bsd-amd64
|
||||
VM_PLATFORM = bsd_amd64
|
||||
HS_ARCH = x86
|
||||
# We have to reset ARCH to amd64 since SRCARCH relies on it
|
||||
ARCH = amd64
|
||||
else
|
||||
ARCH_DATA_MODEL = 32
|
||||
PLATFORM = bsd-i586
|
||||
VM_PLATFORM = bsd_i486
|
||||
HS_ARCH = x86
|
||||
endif
|
||||
endif
|
||||
|
||||
# ARM
|
||||
ifeq ($(ARCH), arm)
|
||||
ARCH_DATA_MODEL = 32
|
||||
PLATFORM = bsd-arm
|
||||
VM_PLATFORM = bsd_arm
|
||||
HS_ARCH = arm
|
||||
endif
|
||||
|
||||
# PPC
|
||||
ifeq ($(ARCH), ppc)
|
||||
ARCH_DATA_MODEL = 32
|
||||
PLATFORM = bsd-ppc
|
||||
VM_PLATFORM = bsd_ppc
|
||||
HS_ARCH = ppc
|
||||
endif
|
||||
|
||||
# On 32 bit bsd we build server and client, on 64 bit just server.
|
||||
ifeq ($(JVM_VARIANTS),)
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
JVM_VARIANTS:=client,server
|
||||
JVM_VARIANT_CLIENT:=true
|
||||
JVM_VARIANT_SERVER:=true
|
||||
else
|
||||
JVM_VARIANTS:=server
|
||||
JVM_VARIANT_SERVER:=true
|
||||
endif
|
||||
endif
|
||||
|
||||
OS_VENDOR:=$(shell uname -s)
|
||||
|
||||
# The Full Debug Symbols (FDS) default for BUILD_FLAVOR == product
|
||||
# builds is enabled with debug info files ZIP'ed to save space. For
|
||||
# BUILD_FLAVOR != product builds, FDS is always enabled, after all a
|
||||
# debug build without debug info isn't very useful.
|
||||
# The ZIP_DEBUGINFO_FILES option only has meaning when FDS is enabled.
|
||||
#
|
||||
# If you invoke a build with FULL_DEBUG_SYMBOLS=0, then FDS will be
|
||||
# disabled for a BUILD_FLAVOR == product build.
|
||||
#
|
||||
# Note: Use of a different variable name for the FDS override option
|
||||
# versus the FDS enabled check is intentional (FULL_DEBUG_SYMBOLS
|
||||
# versus ENABLE_FULL_DEBUG_SYMBOLS). For auto build systems that pass
|
||||
# in options via environment variables, use of distinct variables
|
||||
# prevents strange behaviours. For example, in a BUILD_FLAVOR !=
|
||||
# product build, the FULL_DEBUG_SYMBOLS environment variable will be
|
||||
# 0, but the ENABLE_FULL_DEBUG_SYMBOLS make variable will be 1. If
|
||||
# the same variable name is used, then different values can be picked
|
||||
# up by different parts of the build. Just to be clear, we only need
|
||||
# two variable names because the incoming option value can be
|
||||
# overridden in some situations, e.g., a BUILD_FLAVOR != product
|
||||
# build.
|
||||
|
||||
# Due to the multiple sub-make processes that occur this logic gets
|
||||
# executed multiple times. We reduce the noise by at least checking that
|
||||
# BUILD_FLAVOR has been set.
|
||||
ifneq ($(BUILD_FLAVOR),)
|
||||
# FULL_DEBUG_SYMBOLS not created for individual static libraries
|
||||
ifeq ($(STATIC_BUILD),false)
|
||||
ifeq ($(BUILD_FLAVOR), product)
|
||||
FULL_DEBUG_SYMBOLS ?= 1
|
||||
ENABLE_FULL_DEBUG_SYMBOLS = $(FULL_DEBUG_SYMBOLS)
|
||||
else
|
||||
# debug variants always get Full Debug Symbols (if available)
|
||||
ENABLE_FULL_DEBUG_SYMBOLS = 1
|
||||
endif
|
||||
endif
|
||||
$(eval $(call print_info, "ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS)"))
|
||||
# since objcopy is optional, we set ZIP_DEBUGINFO_FILES later
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# MacOS X doesn't use OBJCOPY or STRIP_POLICY
|
||||
OBJCOPY=
|
||||
STRIP_POLICY=
|
||||
ZIP_DEBUGINFO_FILES ?= 1
|
||||
else
|
||||
# Default OBJCOPY comes from GNU Binutils on BSD
|
||||
ifeq ($(CROSS_COMPILE_ARCH),)
|
||||
DEF_OBJCOPY=/usr/bin/objcopy
|
||||
else
|
||||
# Assume objcopy is part of the cross-compilation toolset
|
||||
ifneq ($(ALT_COMPILER_PATH),)
|
||||
DEF_OBJCOPY=$(ALT_COMPILER_PATH)/objcopy
|
||||
endif
|
||||
endif
|
||||
OBJCOPY=$(shell test -x $(DEF_OBJCOPY) && echo $(DEF_OBJCOPY))
|
||||
ifneq ($(ALT_OBJCOPY),)
|
||||
$(eval $(call print_info, "ALT_OBJCOPY=$(ALT_OBJCOPY)"))
|
||||
OBJCOPY=$(shell test -x $(ALT_OBJCOPY) && echo $(ALT_OBJCOPY))
|
||||
endif
|
||||
|
||||
ifeq ($(OBJCOPY),)
|
||||
$(eval $(call print_info, "no objcopy cmd found so cannot create .debuginfo" \
|
||||
"files. You may need to set ALT_OBJCOPY."))
|
||||
ENABLE_FULL_DEBUG_SYMBOLS=0
|
||||
$(eval $(call print_info, "ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS)"))
|
||||
else
|
||||
$(eval $(call print_info, "$(OBJCOPY) cmd found so will create .debuginfo" \
|
||||
"files."))
|
||||
|
||||
# Library stripping policies for .debuginfo configs:
|
||||
# all_strip - strips everything from the library
|
||||
# min_strip - strips most stuff from the library; leaves
|
||||
# minimum symbols
|
||||
# no_strip - does not strip the library at all
|
||||
#
|
||||
# Oracle security policy requires "all_strip". A waiver was
|
||||
# granted on 2011.09.01 that permits using "min_strip" in the
|
||||
# Java JDK and Java JRE.
|
||||
#
|
||||
# Currently, STRIP_POLICY is only used when Full Debug Symbols
|
||||
# is enabled.
|
||||
#
|
||||
STRIP_POLICY ?= min_strip
|
||||
|
||||
$(eval $(call print_info, "STRIP_POLICY=$(STRIP_POLICY)"))
|
||||
|
||||
ZIP_DEBUGINFO_FILES ?= 1
|
||||
endif
|
||||
|
||||
$(eval $(call print_info, "ZIP_DEBUGINFO_FILES=$(ZIP_DEBUGINFO_FILES)"))
|
||||
endif
|
||||
endif # ENABLE_FULL_DEBUG_SYMBOLS=1
|
||||
endif # BUILD_FLAVOR
|
||||
|
||||
JDK_INCLUDE_SUBDIR=bsd
|
||||
|
||||
# Library suffix
|
||||
ifneq ($(STATIC_BUILD),true)
|
||||
ifeq ($(OS_VENDOR),Darwin)
|
||||
LIBRARY_SUFFIX=dylib
|
||||
else
|
||||
LIBRARY_SUFFIX=so
|
||||
endif
|
||||
else
|
||||
LIBRARY_SUFFIX=a
|
||||
endif
|
||||
|
||||
|
||||
EXPORT_LIST += $(EXPORT_DOCS_DIR)/platform/jvmti/jvmti.html
|
||||
|
||||
# jsig library not needed for static builds
|
||||
ifneq ($(STATIC_BUILD),true)
|
||||
# client and server subdirectories have symbolic links to ../libjsig.so
|
||||
EXPORT_LIST += $(EXPORT_LIB_ARCH_DIR)/libjsig.$(LIBRARY_SUFFIX)
|
||||
endif
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
EXPORT_LIST += $(EXPORT_LIB_ARCH_DIR)/libjsig.diz
|
||||
else
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
EXPORT_LIST += $(EXPORT_LIB_ARCH_DIR)/libjsig.$(LIBRARY_SUFFIX).dSYM
|
||||
else
|
||||
EXPORT_LIST += $(EXPORT_LIB_ARCH_DIR)/libjsig.debuginfo
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
EXPORT_SERVER_DIR = $(EXPORT_LIB_ARCH_DIR)/server
|
||||
EXPORT_CLIENT_DIR = $(EXPORT_LIB_ARCH_DIR)/client
|
||||
EXPORT_MINIMAL_DIR = $(EXPORT_LIB_ARCH_DIR)/minimal
|
||||
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_SERVER) $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
EXPORT_LIST += $(EXPORT_SERVER_DIR)/Xusage.txt
|
||||
EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.$(LIBRARY_SUFFIX)
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.symbols
|
||||
endif
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.diz
|
||||
else
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.$(LIBRARY_SUFFIX).dSYM
|
||||
else
|
||||
EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.debuginfo
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(JVM_VARIANT_CLIENT),true)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/Xusage.txt
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.$(LIBRARY_SUFFIX)
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.symbols
|
||||
endif
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.diz
|
||||
else
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.$(LIBRARY_SUFFIX).dSYM
|
||||
else
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.debuginfo
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
EXPORT_LIST += $(EXPORT_MINIMAL_DIR)/Xusage.txt
|
||||
EXPORT_LIST += $(EXPORT_MINIMAL_DIR)/libjvm.$(LIBRARY_SUFFIX)
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
EXPORT_LIST += $(EXPORT_MINIMAL_DIR)/libjvm.symbols
|
||||
endif
|
||||
endif
|
||||
|
||||
# Universal build settings
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# Build universal binaries by default on Mac OS X
|
||||
MACOSX_UNIVERSAL = true
|
||||
ifneq ($(ALT_MACOSX_UNIVERSAL),)
|
||||
MACOSX_UNIVERSAL = $(ALT_MACOSX_UNIVERSAL)
|
||||
endif
|
||||
MAKE_ARGS += MACOSX_UNIVERSAL=$(MACOSX_UNIVERSAL)
|
||||
|
||||
# Universal settings
|
||||
ifeq ($(MACOSX_UNIVERSAL), true)
|
||||
|
||||
# Set universal export path but avoid using ARCH or PLATFORM subdirs
|
||||
EXPORT_PATH=$(OUTPUTDIR)/export-universal$(EXPORT_SUBDIR)
|
||||
ifneq ($(ALT_EXPORT_PATH),)
|
||||
EXPORT_PATH=$(ALT_EXPORT_PATH)
|
||||
endif
|
||||
|
||||
# Set universal image dir
|
||||
JDK_IMAGE_DIR=$(OUTPUTDIR)/jdk-universal$(EXPORT_SUBDIR)
|
||||
ifneq ($(ALT_JDK_IMAGE_DIR),)
|
||||
JDK_IMAGE_DIR=$(ALT_JDK_IMAGE_DIR)
|
||||
endif
|
||||
|
||||
# Binaries to 'universalize' if built
|
||||
ifneq ($(STATIC_BUILD),true)
|
||||
UNIVERSAL_LIPO_LIST += $(EXPORT_LIB_DIR)/libjsig.$(LIBRARY_SUFFIX)
|
||||
endif
|
||||
UNIVERSAL_LIPO_LIST += $(EXPORT_LIB_DIR)/server/libjvm.$(LIBRARY_SUFFIX)
|
||||
UNIVERSAL_LIPO_LIST += $(EXPORT_LIB_DIR)/client/libjvm.$(LIBRARY_SUFFIX)
|
||||
|
||||
# Files to simply copy in place
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/server/Xusage.txt
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/client/Xusage.txt
|
||||
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/server/libjvm.symbols
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/client/libjvm.symbols
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/minimal/libjvm.symbols
|
||||
endif
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/server/libjvm.diz
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/client/libjvm.diz
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/libjsig.diz
|
||||
else
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/server/libjvm.$(LIBRARY_SUFFIX).dSYM
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/client/libjvm.$(LIBRARY_SUFFIX).dSYM
|
||||
UNIVERSAL_COPY_LIST += $(EXPORT_LIB_DIR)/libjsig.$(LIBRARY_SUFFIX).dSYM
|
||||
endif
|
||||
endif
|
||||
|
||||
endif
|
||||
endif
|
@ -1,333 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Rules to build jvm_db/dtrace, used by vm.make
|
||||
|
||||
# We build libjvm_dtrace/libjvm_db/dtrace for COMPILER1 and COMPILER2
|
||||
# but not for CORE configuration.
|
||||
|
||||
ifneq ("${TYPE}", "CORE")
|
||||
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# we build dtrace for macosx using USDT2 probes
|
||||
|
||||
DtraceOutDir = $(GENERATED)/dtracefiles
|
||||
|
||||
# Bsd does not build libjvm_db, does not compile on macosx
|
||||
# disabled in build: rule in vm.make
|
||||
JVM_DB = libjvm_db
|
||||
LIBJVM_DB = libjvm_db.$(LIBRARY_SUFFIX)
|
||||
|
||||
LIBJVM_DB_DEBUGINFO = libjvm_db.$(LIBRARY_SUFFIX).dSYM
|
||||
LIBJVM_DB_DIZ = libjvm_db.diz
|
||||
|
||||
JVM_DTRACE = jvm_dtrace
|
||||
LIBJVM_DTRACE = libjvm_dtrace.$(LIBRARY_SUFFIX)
|
||||
|
||||
LIBJVM_DTRACE_DEBUGINFO = libjvm_dtrace.$(LIBRARY_SUFFIX).dSYM
|
||||
LIBJVM_DTRACE_DIZ = libjvm_dtrace.diz
|
||||
|
||||
JVMOFFS = JvmOffsets
|
||||
JVMOFFS.o = $(JVMOFFS).o
|
||||
GENOFFS = generate$(JVMOFFS)
|
||||
|
||||
DTRACE_SRCDIR = $(GAMMADIR)/src/os/$(Platform_os_family)/dtrace
|
||||
DTRACE_COMMON_SRCDIR = $(GAMMADIR)/src/os/posix/dtrace
|
||||
DTRACE = dtrace
|
||||
DTRACE.o = $(DTRACE).o
|
||||
|
||||
# to remove '-g' option which causes link problems
|
||||
# also '-z nodefs' is used as workaround
|
||||
GENOFFS_CFLAGS = $(shell echo $(CFLAGS) | sed -e 's/ -g / /g' -e 's/ -g0 / /g';)
|
||||
|
||||
ifdef LP64
|
||||
DTRACE_OPTS = -D_LP64
|
||||
endif
|
||||
|
||||
# making libjvm_db
|
||||
|
||||
# Use mapfile with libjvm_db.so
|
||||
LIBJVM_DB_MAPFILE = # no mapfile for usdt2 # $(MAKEFILES_DIR)/mapfile-vers-jvm_db
|
||||
|
||||
# Use mapfile with libjvm_dtrace.so
|
||||
LIBJVM_DTRACE_MAPFILE = # no mapfile for usdt2 # $(MAKEFILES_DIR)/mapfile-vers-jvm_dtrace
|
||||
|
||||
LFLAGS_JVM_DB += $(PICFLAG) # -D_REENTRANT
|
||||
LFLAGS_JVM_DTRACE += $(PICFLAG) # -D_REENTRANT
|
||||
|
||||
ISA = $(subst i386,i486,$(BUILDARCH))
|
||||
|
||||
# Making 64/libjvm_db.so: 64-bit version of libjvm_db.so which handles 32-bit libjvm.so
|
||||
ifneq ("${ISA}","${BUILDARCH}")
|
||||
|
||||
XLIBJVM_DIR = 64
|
||||
XLIBJVM_DB = $(XLIBJVM_DIR)/$(LIBJVM_DB)
|
||||
XLIBJVM_DTRACE = $(XLIBJVM_DIR)/$(LIBJVM_DTRACE)
|
||||
XARCH = $(subst sparcv9,v9,$(shell echo $(ISA)))
|
||||
|
||||
XLIBJVM_DB_DEBUGINFO = $(XLIBJVM_DIR)/$(LIBJVM_DB_DEBUGINFO)
|
||||
XLIBJVM_DB_DIZ = $(XLIBJVM_DIR)/$(LIBJVM_DB_DIZ)
|
||||
XLIBJVM_DTRACE_DEBUGINFO = $(XLIBJVM_DIR)/$(LIBJVM_DTRACE_DEBUGINFO)
|
||||
XLIBJVM_DTRACE_DIZ = $(XLIBJVM_DIR)/$(LIBJVM_DTRACE_DIZ)
|
||||
|
||||
$(XLIBJVM_DB): $(DTRACE_SRCDIR)/$(JVM_DB).c $(JVMOFFS).h $(LIBJVM_DB_MAPFILE)
|
||||
@echo $(LOG_INFO) Making $@
|
||||
$(QUIETLY) mkdir -p $(XLIBJVM_DIR) ; \
|
||||
$(CC) $(SYMFLAG) -xarch=$(XARCH) -D$(TYPE) -I. -I$(GENERATED) \
|
||||
$(SHARED_FLAG) $(LFLAGS_JVM_DB) -o $@ $(DTRACE_SRCDIR)/$(JVM_DB).c #-lc
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(DSYMUTIL) $@
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# Do this part in the $(XLIBJVM_DIR) subdir so $(XLIBJVM_DIR)
|
||||
# is not in the archived name:
|
||||
( cd $(XLIBJVM_DIR) && $(ZIPEXE) -q -r -y $(LIBJVM_DB_DIZ) $(LIBJVM_DB_DEBUGINFO) )
|
||||
$(RM) -r $(XLIBJVM_DB_DEBUGINFO)
|
||||
endif
|
||||
else
|
||||
$(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(XLIBJVM_DB_DEBUGINFO)
|
||||
# Do this part in the $(XLIBJVM_DIR) subdir so $(XLIBJVM_DIR)
|
||||
# is not in the link name:
|
||||
$(QUIETLY) ( cd $(XLIBJVM_DIR) && $(OBJCOPY) --add-gnu-debuglink=$(LIBJVM_DB_DEBUGINFO) $(LIBJVM_DB) )
|
||||
ifeq ($(STRIP_POLICY),all_strip)
|
||||
$(QUIETLY) $(STRIP) $@
|
||||
else
|
||||
ifeq ($(STRIP_POLICY),min_strip)
|
||||
$(QUIETLY) $(STRIP) -x $@
|
||||
# implied else here is no stripping at all
|
||||
endif
|
||||
endif
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# Do this part in the $(XLIBJVM_DIR) subdir so $(XLIBJVM_DIR)
|
||||
# is not in the archived name:
|
||||
( cd $(XLIBJVM_DIR) && $(ZIPEXE) -q -y $(LIBJVM_DB_DIZ) $(LIBJVM_DB_DEBUGINFO) )
|
||||
$(RM) $(XLIBJVM_DB_DEBUGINFO)
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
$(XLIBJVM_DTRACE): $(DTRACE_SRCDIR)/$(JVM_DTRACE).c $(DTRACE_SRCDIR)/$(JVM_DTRACE).h $(LIBJVM_DTRACE_MAPFILE)
|
||||
@echo $(LOG_INFO) Making $@
|
||||
$(QUIETLY) mkdir -p $(XLIBJVM_DIR) ; \
|
||||
$(CC) $(SYMFLAG) -xarch=$(XARCH) -D$(TYPE) -I. \
|
||||
$(SHARED_FLAG) $(LFLAGS_JVM_DTRACE) -o $@ $(DTRACE_SRCDIR)/$(JVM_DTRACE).c #-lc -lthread -ldoor
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(DSYMUTIL) $@
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# Do this part in the $(XLIBJVM_DIR) subdir so $(XLIBJVM_DIR)
|
||||
# is not in the archived name:
|
||||
( cd $(XLIBJVM_DIR) && $(ZIPEXE) -q -r -y $(LIBJVM_DTRACE_DIZ) $(LIBJVM_DTRACE_DEBUGINFO) )
|
||||
$(RM) -r $(XLIBJVM_DTRACE_DEBUGINFO)
|
||||
endif
|
||||
else
|
||||
$(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(XLIBJVM_DTRACE_DEBUGINFO)
|
||||
# Do this part in the $(XLIBJVM_DIR) subdir so $(XLIBJVM_DIR)
|
||||
# is not in the link name:
|
||||
( cd $(XLIBJVM_DIR) && $(OBJCOPY) --add-gnu-debuglink=$(LIBJVM_DTRACE_DEBUGINFO) $(LIBJVM_DTRACE) )
|
||||
ifeq ($(STRIP_POLICY),all_strip)
|
||||
$(QUIETLY) $(STRIP) $@
|
||||
else
|
||||
ifeq ($(STRIP_POLICY),min_strip)
|
||||
$(QUIETLY) $(STRIP) -x $@
|
||||
# implied else here is no stripping at all
|
||||
endif
|
||||
endif
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
# Do this part in the $(XLIBJVM_DIR) subdir so $(XLIBJVM_DIR)
|
||||
# is not in the archived name:
|
||||
( cd $(XLIBJVM_DIR) && $(ZIPEXE) -q -y $(LIBJVM_DTRACE_DIZ) $(LIBJVM_DTRACE_DEBUGINFO) )
|
||||
$(RM) $(XLIBJVM_DTRACE_DEBUGINFO)
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
endif # ifneq ("${ISA}","${BUILDARCH}")
|
||||
|
||||
LFLAGS_GENOFFS += -L.
|
||||
|
||||
lib$(GENOFFS).$(LIBRARY_SUFFIX): $(DTRACE_SRCDIR)/$(GENOFFS).cpp $(DTRACE_SRCDIR)/$(GENOFFS).h \
|
||||
$(LIBJVM.o)
|
||||
$(QUIETLY) $(CXX) $(CXXFLAGS) $(GENOFFS_CFLAGS) $(SHARED_FLAG) $(PICFLAG) \
|
||||
$(LFLAGS_GENOFFS) -o $@ $(DTRACE_SRCDIR)/$(GENOFFS).cpp -ljvm
|
||||
|
||||
$(GENOFFS): $(DTRACE_SRCDIR)/$(GENOFFS)Main.c lib$(GENOFFS).$(LIBRARY_SUFFIX)
|
||||
$(QUIETLY) $(LINK.CXX) -o $@ $(DTRACE_SRCDIR)/$(GENOFFS)Main.c \
|
||||
./lib$(GENOFFS).$(LIBRARY_SUFFIX)
|
||||
|
||||
# $@.tmp is created first to avoid an empty $(JVMOFFS).h if an error occurs.
|
||||
$(JVMOFFS).h: $(GENOFFS)
|
||||
$(QUIETLY) DYLD_LIBRARY_PATH=.:$(DYLD_LIBRARY_PATH) ./$(GENOFFS) -header > $@.tmp; touch $@; \
|
||||
if diff $@.tmp $@ > /dev/null 2>&1 ; \
|
||||
then rm -f $@.tmp; \
|
||||
else rm -f $@; mv $@.tmp $@; \
|
||||
fi
|
||||
|
||||
$(JVMOFFS)Index.h: $(GENOFFS)
|
||||
$(QUIETLY) DYLD_LIBRARY_PATH=.:$(DYLD_LIBRARY_PATH) ./$(GENOFFS) -index > $@.tmp; touch $@; \
|
||||
if diff $@.tmp $@ > /dev/null 2>&1 ; \
|
||||
then rm -f $@.tmp; \
|
||||
else rm -f $@; mv $@.tmp $@; \
|
||||
fi
|
||||
|
||||
$(JVMOFFS).cpp: $(GENOFFS) $(JVMOFFS).h $(JVMOFFS)Index.h
|
||||
$(QUIETLY) DYLD_LIBRARY_PATH=.:$(DYLD_LIBRARY_PATH) ./$(GENOFFS) -table > $@.tmp; touch $@; \
|
||||
if diff $@.tmp $@ > /dev/null 2>&1; \
|
||||
then rm -f $@.tmp; \
|
||||
else rm -f $@; mv $@.tmp $@; \
|
||||
fi
|
||||
|
||||
$(JVMOFFS.o): $(JVMOFFS).h $(JVMOFFS).cpp
|
||||
$(QUIETLY) $(CXX) -c -I. -o $@ $(ARCHFLAG) -D$(TYPE) $(JVMOFFS).cpp
|
||||
|
||||
$(LIBJVM_DB): $(DTRACE_SRCDIR)/$(JVM_DB).c $(JVMOFFS.o) $(XLIBJVM_DB) $(LIBJVM_DB_MAPFILE)
|
||||
@echo $(LOG_INFO) Making $@
|
||||
$(QUIETLY) $(CC) $(SYMFLAG) $(ARCHFLAG) -D$(TYPE) -I. -I$(GENERATED) \
|
||||
$(SHARED_FLAG) $(LFLAGS_JVM_DB) -o $@ $(DTRACE_SRCDIR)/$(JVM_DB).c -Wall # -lc
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(DSYMUTIL) $@
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(ZIPEXE) -q -r -y $(LIBJVM_DB_DIZ) $(LIBJVM_DB_DEBUGINFO)
|
||||
$(RM) -r $(LIBJVM_DB_DEBUGINFO)
|
||||
endif
|
||||
else
|
||||
$(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJVM_DB_DEBUGINFO)
|
||||
$(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJVM_DB_DEBUGINFO) $@
|
||||
ifeq ($(STRIP_POLICY),all_strip)
|
||||
$(QUIETLY) $(STRIP) $@
|
||||
else
|
||||
ifeq ($(STRIP_POLICY),min_strip)
|
||||
$(QUIETLY) $(STRIP) -x $@
|
||||
# implied else here is no stripping at all
|
||||
endif
|
||||
endif
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(ZIPEXE) -q -y $(LIBJVM_DB_DIZ) $(LIBJVM_DB_DEBUGINFO)
|
||||
$(RM) $(LIBJVM_DB_DEBUGINFO)
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
$(LIBJVM_DTRACE): $(DTRACE_SRCDIR)/$(JVM_DTRACE).c $(XLIBJVM_DTRACE) $(DTRACE_SRCDIR)/$(JVM_DTRACE).h $(LIBJVM_DTRACE_MAPFILE)
|
||||
@echo $(LOG_INFO) Making $@
|
||||
$(QUIETLY) $(CC) $(SYMFLAG) $(ARCHFLAG) -D$(TYPE) -I. \
|
||||
$(SHARED_FLAG) $(LFLAGS_JVM_DTRACE) -o $@ $(DTRACE_SRCDIR)/$(JVM_DTRACE).c #-lc -lthread -ldoor
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(DSYMUTIL) $@
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(ZIPEXE) -q -r -y $(LIBJVM_DTRACE_DIZ) $(LIBJVM_DTRACE_DEBUGINFO)
|
||||
$(RM) -r $(LIBJVM_DTRACE_DEBUGINFO)
|
||||
endif
|
||||
else
|
||||
$(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJVM_DTRACE_DEBUGINFO)
|
||||
$(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJVM_DTRACE_DEBUGINFO) $@
|
||||
ifeq ($(STRIP_POLICY),all_strip)
|
||||
$(QUIETLY) $(STRIP) $@
|
||||
else
|
||||
ifeq ($(STRIP_POLICY),min_strip)
|
||||
$(QUIETLY) $(STRIP) -x $@
|
||||
# implied else here is no stripping at all
|
||||
endif
|
||||
endif
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(ZIPEXE) -q -y $(LIBJVM_DTRACE_DIZ) $(LIBJVM_DTRACE_DEBUGINFO)
|
||||
$(RM) $(LIBJVM_DTRACE_DEBUGINFO)
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
|
||||
$(DtraceOutDir):
|
||||
mkdir $(DtraceOutDir)
|
||||
|
||||
# When building using a devkit, dtrace cannot find the correct preprocessor so
|
||||
# we run it explicitly before runing dtrace.
|
||||
$(DtraceOutDir)/hotspot.h: $(DTRACE_COMMON_SRCDIR)/hotspot.d | $(DtraceOutDir)
|
||||
$(QUIETLY) $(CC) -E $(DTRACE_OPTS) -I. -x c $(DTRACE_COMMON_SRCDIR)/hotspot.d > $(DtraceOutDir)/hotspot.d
|
||||
$(QUIETLY) $(DTRACE_PROG) -h -o $@ -s $(DtraceOutDir)/hotspot.d
|
||||
|
||||
$(DtraceOutDir)/hotspot_jni.h: $(DTRACE_COMMON_SRCDIR)/hotspot_jni.d | $(DtraceOutDir)
|
||||
$(QUIETLY) $(CC) -E $(DTRACE_OPTS) -I. -x c $(DTRACE_COMMON_SRCDIR)/hotspot_jni.d > $(DtraceOutDir)/hotspot_jni.d
|
||||
$(QUIETLY) $(DTRACE_PROG) -h -o $@ -s $(DtraceOutDir)/hotspot_jni.d
|
||||
|
||||
$(DtraceOutDir)/hs_private.h: $(DTRACE_COMMON_SRCDIR)/hs_private.d | $(DtraceOutDir)
|
||||
$(QUIETLY) $(CC) -E $(DTRACE_OPTS) -I. -x c $(DTRACE_COMMON_SRCDIR)/hs_private.d > $(DtraceOutDir)/hs_private.d
|
||||
$(QUIETLY) $(DTRACE_PROG) -h -o $@ -s $(DtraceOutDir)/hs_private.d
|
||||
|
||||
dtrace_gen_headers: $(DtraceOutDir)/hotspot.h $(DtraceOutDir)/hotspot_jni.h $(DtraceOutDir)/hs_private.h
|
||||
|
||||
|
||||
.PHONY: dtraceCheck
|
||||
|
||||
SYSTEM_DTRACE_PROG = /usr/sbin/dtrace
|
||||
systemDtraceFound := $(wildcard ${SYSTEM_DTRACE_PROG})
|
||||
|
||||
ifneq ("$(systemDtraceFound)", "")
|
||||
DTRACE_PROG=$(SYSTEM_DTRACE_PROG)
|
||||
else
|
||||
|
||||
endif
|
||||
|
||||
ifneq ("${DTRACE_PROG}", "")
|
||||
ifeq ("${HOTSPOT_DISABLE_DTRACE_PROBES}", "")
|
||||
|
||||
DTRACE_OBJS = $(DTRACE.o) #$(JVMOFFS.o)
|
||||
CFLAGS += -DDTRACE_ENABLED #$(DTRACE_INCL)
|
||||
|
||||
|
||||
dtraceCheck:
|
||||
|
||||
dtrace_stuff: dtrace_gen_headers
|
||||
$(QUIETLY) echo $(LOG_INFO) "dtrace headers generated"
|
||||
|
||||
|
||||
else # manually disabled
|
||||
|
||||
dtraceCheck:
|
||||
$(QUIETLY) echo $(LOG_INFO) "**NOTICE** Dtrace support disabled via environment variable"
|
||||
|
||||
dtrace_stuff:
|
||||
|
||||
endif # ifeq ("${HOTSPOT_DISABLE_DTRACE_PROBES}", "")
|
||||
|
||||
else # No dtrace program found
|
||||
|
||||
dtraceCheck:
|
||||
$(QUIETLY) echo $(LOG_INFO) "**NOTICE** Dtrace support disabled: not supported by system"
|
||||
|
||||
dtrace_stuff:
|
||||
|
||||
endif # ifneq ("${dtraceFound}", "")
|
||||
|
||||
endif # ifeq ($(OS_VENDOR), Darwin)
|
||||
|
||||
|
||||
else # CORE build
|
||||
|
||||
dtraceCheck:
|
||||
$(QUIETLY) echo $(LOG_INFO) "**NOTICE** Dtrace support disabled for CORE builds"
|
||||
|
||||
endif # ifneq ("${TYPE}", "CORE")
|
@ -1,59 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
|
||||
# Compiler specific DEBUG_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
# They may also specify FASTDEBUG_CFLAGS, but it defaults to DEBUG_CFLAGS.
|
||||
|
||||
FASTDEBUG_CFLAGS$(FASTDEBUG_CFLAGS) = $(DEBUG_CFLAGS)
|
||||
|
||||
# Compiler specific OPT_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
OPT_CFLAGS/DEFAULT= $(OPT_CFLAGS)
|
||||
OPT_CFLAGS/BYFILE = $(OPT_CFLAGS/$@)$(OPT_CFLAGS/DEFAULT$(OPT_CFLAGS/$@))
|
||||
|
||||
# (OPT_CFLAGS/SLOWER is also available, to alter compilation of buggy files)
|
||||
|
||||
# If you set HOTSPARC_GENERIC=yes, you disable all OPT_CFLAGS settings
|
||||
CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# The following lines are copied from debug.make, except that we
|
||||
# consult FASTDEBUG_CFLAGS instead of DEBUG_CFLAGS.
|
||||
# Compiler specific DEBUG_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
DEBUG_CFLAGS/DEFAULT= $(FASTDEBUG_CFLAGS)
|
||||
DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@))
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE)
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-debug
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-darwin-debug
|
||||
endif
|
||||
|
||||
VERSION = fastdebug
|
||||
SYSDEFS += -DASSERT -DCHECK_UNHANDLED_OOPS
|
||||
PICFLAGS = DEFAULT
|
@ -1,543 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2016, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
OS_VENDOR = $(shell uname -s)
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# CC, CXX & AS
|
||||
|
||||
# If a SPEC is not set already, then use these defaults.
|
||||
ifeq ($(SPEC),)
|
||||
# When cross-compiling the ALT_COMPILER_PATH points
|
||||
# to the cross-compilation toolset
|
||||
ifdef CROSS_COMPILE_ARCH
|
||||
CXX = $(ALT_COMPILER_PATH)/g++
|
||||
CC = $(ALT_COMPILER_PATH)/gcc
|
||||
HOSTCXX = g++
|
||||
HOSTCC = gcc
|
||||
else ifneq ($(OS_VENDOR), Darwin)
|
||||
CXX = g++
|
||||
CC = gcc
|
||||
HOSTCXX = $(CXX)
|
||||
HOSTCC = $(CC)
|
||||
endif
|
||||
|
||||
# i486 hotspot requires -mstackrealign on Darwin.
|
||||
# llvm-gcc supports this in Xcode 3.2.6 and 4.0.
|
||||
# gcc-4.0 supports this on earlier versions.
|
||||
# Prefer llvm-gcc where available.
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
ifeq ($(origin CXX), default)
|
||||
CXX = llvm-g++
|
||||
endif
|
||||
ifeq ($(origin CC), default)
|
||||
CC = llvm-gcc
|
||||
endif
|
||||
|
||||
ifeq ($(ARCH), i486)
|
||||
LLVM_SUPPORTS_STACKREALIGN := $(shell \
|
||||
[ "0"`llvm-gcc -v 2>&1 | grep LLVM | sed -E "s/.*LLVM build ([0-9]+).*/\1/"` -gt "2333" ] \
|
||||
&& echo true || echo false)
|
||||
|
||||
ifeq ($(LLVM_SUPPORTS_STACKREALIGN), true)
|
||||
CXX32 ?= llvm-g++
|
||||
CC32 ?= llvm-gcc
|
||||
else
|
||||
CXX32 ?= g++-4.0
|
||||
CC32 ?= gcc-4.0
|
||||
endif
|
||||
CXX = $(CXX32)
|
||||
CC = $(CC32)
|
||||
endif
|
||||
|
||||
ifeq ($(USE_CLANG), true)
|
||||
CXX = clang++
|
||||
CC = clang
|
||||
endif
|
||||
|
||||
HOSTCXX = $(CXX)
|
||||
HOSTCC = $(CC)
|
||||
endif
|
||||
|
||||
AS = $(CC) -c
|
||||
endif
|
||||
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
ifeq ($(DSYMUTIL),)
|
||||
DSYMUTIL=dsymutil
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(USE_CLANG), true)
|
||||
CC_VER_MAJOR := $(shell $(CC) -v 2>&1 | grep version | sed "s/.*version \([0-9]*\.[0-9]*\).*/\1/" | cut -d'.' -f1)
|
||||
CC_VER_MINOR := $(shell $(CC) -v 2>&1 | grep version | sed "s/.*version \([0-9]*\.[0-9]*\).*/\1/" | cut -d'.' -f2)
|
||||
else
|
||||
# -dumpversion in gcc-2.91 shows "egcs-2.91.66". In later version, it only
|
||||
# prints the numbers (e.g. "2.95", "3.2.1")
|
||||
CC_VER_MAJOR := $(shell $(CC) -dumpversion | sed 's/egcs-//' | cut -d'.' -f1)
|
||||
CC_VER_MINOR := $(shell $(CC) -dumpversion | sed 's/egcs-//' | cut -d'.' -f2)
|
||||
CC_VER_MICRO := $(shell $(CC) -dumpversion | sed 's/egcs-//' | cut -d'.' -f3)
|
||||
endif
|
||||
|
||||
ifeq ($(USE_CLANG), true)
|
||||
# Clang has precompiled headers support by default, but the user can switch
|
||||
# it off by using 'USE_PRECOMPILED_HEADER=0'.
|
||||
ifdef LP64
|
||||
ifeq ($(USE_PRECOMPILED_HEADER),)
|
||||
USE_PRECOMPILED_HEADER=1
|
||||
endif
|
||||
else
|
||||
# We don't support precompiled headers on 32-bit builds because there some files are
|
||||
# compiled with -fPIC while others are compiled without (see 'NONPIC_OBJ_FILES' rules.make)
|
||||
# Clang produces an error if the PCH file was compiled with other options than the actual compilation unit.
|
||||
USE_PRECOMPILED_HEADER=0
|
||||
endif
|
||||
|
||||
ifeq ($(USE_PRECOMPILED_HEADER),1)
|
||||
|
||||
ifndef LP64
|
||||
$(error " Precompiled Headers only supported on 64-bit platforms!")
|
||||
endif
|
||||
|
||||
PRECOMPILED_HEADER_DIR=.
|
||||
PRECOMPILED_HEADER_SRC=$(GAMMADIR)/src/share/vm/precompiled/precompiled.hpp
|
||||
PRECOMPILED_HEADER=$(PRECOMPILED_HEADER_DIR)/precompiled.hpp.pch
|
||||
|
||||
PCH_FLAG = -include precompiled.hpp
|
||||
PCH_FLAG/DEFAULT = $(PCH_FLAG)
|
||||
PCH_FLAG/NO_PCH = -DNO_PCH
|
||||
PCH_FLAG/BY_FILE = $(PCH_FLAG/$@)$(PCH_FLAG/DEFAULT$(PCH_FLAG/$@))
|
||||
|
||||
VM_PCH_FLAG/LIBJVM = $(PCH_FLAG/BY_FILE)
|
||||
VM_PCH_FLAG/AOUT =
|
||||
VM_PCH_FLAG = $(VM_PCH_FLAG/$(LINK_INTO))
|
||||
|
||||
# We only use precompiled headers for the JVM build
|
||||
CFLAGS += $(VM_PCH_FLAG)
|
||||
|
||||
# The following files are compiled at various optimization
|
||||
# levels due to optimization issues encountered at the
|
||||
# 'OPT_CFLAGS_DEFAULT' level. The Clang compiler issues a compile
|
||||
# time error if there is an optimization level specification
|
||||
# skew between the PCH file and the C++ file. Especially if the
|
||||
# PCH file is compiled at a higher optimization level than
|
||||
# the C++ file. One solution might be to prepare extra optimization
|
||||
# level specific PCH files for the opt build and use them here, but
|
||||
# it's probably not worth the effort as long as only a few files
|
||||
# need this special handling.
|
||||
PCH_FLAG/loopTransform.o = $(PCH_FLAG/NO_PCH)
|
||||
PCH_FLAG/sharedRuntimeTrig.o = $(PCH_FLAG/NO_PCH)
|
||||
PCH_FLAG/sharedRuntimeTrans.o = $(PCH_FLAG/NO_PCH)
|
||||
PCH_FLAG/unsafe.o = $(PCH_FLAG/NO_PCH)
|
||||
PCH_FLAG/jvmciCompilerToVM.o = $(PCH_FLAG/NO_PCH)
|
||||
|
||||
endif
|
||||
else # ($(USE_CLANG), true)
|
||||
# check for precompiled headers support
|
||||
ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 3 \) \| \( \( $(CC_VER_MAJOR) = 3 \) \& \( $(CC_VER_MINOR) \>= 4 \) \))" "0"
|
||||
# Allow the user to turn off precompiled headers from the command line.
|
||||
ifneq ($(USE_PRECOMPILED_HEADER),0)
|
||||
PRECOMPILED_HEADER_DIR=.
|
||||
PRECOMPILED_HEADER_SRC=$(GAMMADIR)/src/share/vm/precompiled/precompiled.hpp
|
||||
PRECOMPILED_HEADER=$(PRECOMPILED_HEADER_DIR)/precompiled.hpp.gch
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
# -DDONT_USE_PRECOMPILED_HEADER will exclude all includes in precompiled.hpp.
|
||||
ifeq ($(USE_PRECOMPILED_HEADER),0)
|
||||
CFLAGS += -DDONT_USE_PRECOMPILED_HEADER
|
||||
endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Compiler flags
|
||||
|
||||
# position-independent code
|
||||
PICFLAG = -fPIC
|
||||
|
||||
VM_PICFLAG/LIBJVM = $(PICFLAG)
|
||||
VM_PICFLAG/AOUT =
|
||||
VM_PICFLAG = $(VM_PICFLAG/$(LINK_INTO))
|
||||
|
||||
ifeq ($(JVM_VARIANT_ZERO), true)
|
||||
CFLAGS += $(LIBFFI_CFLAGS)
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_ZEROSHARK), true)
|
||||
CFLAGS += $(LIBFFI_CFLAGS)
|
||||
CFLAGS += $(LLVM_CFLAGS)
|
||||
endif
|
||||
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
CXXFLAGS += -DSTATIC_BUILD
|
||||
CFLAGS += -DSTATIC_BUILD
|
||||
else
|
||||
CFLAGS += $(VM_PICFLAG)
|
||||
endif
|
||||
|
||||
CFLAGS += -fno-rtti
|
||||
CFLAGS += -fno-exceptions
|
||||
ifeq ($(USE_CLANG),)
|
||||
CFLAGS += -pthread
|
||||
CFLAGS += -fcheck-new
|
||||
# version 4 and above support fvisibility=hidden (matches jni_x86.h file)
|
||||
# except 4.1.2 gives pointless warnings that can't be disabled (afaik)
|
||||
ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0"
|
||||
CFLAGS += -fvisibility=hidden
|
||||
endif
|
||||
else
|
||||
CFLAGS += -fvisibility=hidden
|
||||
endif
|
||||
|
||||
ifeq ($(USE_CLANG), true)
|
||||
# Before Clang 3.1, we had to pass the stack alignment specification directly to llvm with the help of '-mllvm'
|
||||
# Starting with version 3.1, Clang understands the '-mstack-alignment' (and rejects '-mllvm -stack-alignment')
|
||||
ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 3 \) \| \( \( $(CC_VER_MAJOR) = 3 \) \& \( $(CC_VER_MINOR) \>= 1 \) \))" "0"
|
||||
STACK_ALIGNMENT_OPT = -mno-omit-leaf-frame-pointer -mstack-alignment=16
|
||||
else
|
||||
STACK_ALIGNMENT_OPT = -mno-omit-leaf-frame-pointer -mllvm -stack-alignment=16
|
||||
endif
|
||||
endif
|
||||
|
||||
ARCHFLAG = $(ARCHFLAG/$(BUILDARCH))
|
||||
ARCHFLAG/i486 = -m32 -march=i586
|
||||
ARCHFLAG/amd64 = -m64 $(STACK_ALIGNMENT_OPT)
|
||||
ARCHFLAG/ia64 =
|
||||
ARCHFLAG/sparc = -m32 -mcpu=v9
|
||||
ARCHFLAG/sparcv9 = -m64 -mcpu=v9
|
||||
ARCHFLAG/zero = $(ZERO_ARCHFLAG)
|
||||
|
||||
# Darwin-specific build flags
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# Ineffecient 16-byte stack re-alignment on Darwin/IA32
|
||||
ARCHFLAG/i486 += -mstackrealign
|
||||
endif
|
||||
|
||||
CFLAGS += $(ARCHFLAG)
|
||||
AOUT_FLAGS += $(ARCHFLAG)
|
||||
LFLAGS += $(ARCHFLAG)
|
||||
ASFLAGS += $(ARCHFLAG)
|
||||
|
||||
ifdef E500V2
|
||||
CFLAGS += -DE500V2
|
||||
endif
|
||||
|
||||
# Use C++ Interpreter
|
||||
ifdef CC_INTERP
|
||||
CFLAGS += -DCC_INTERP
|
||||
endif
|
||||
|
||||
# Keep temporary files (.ii, .s)
|
||||
ifdef NEED_ASM
|
||||
CFLAGS += -save-temps
|
||||
else
|
||||
CFLAGS += -pipe
|
||||
endif
|
||||
|
||||
# Compiler warnings are treated as errors
|
||||
ifneq ($(COMPILER_WARNINGS_FATAL),false)
|
||||
WARNINGS_ARE_ERRORS ?= -Werror
|
||||
endif
|
||||
|
||||
ifeq ($(USE_CLANG), true)
|
||||
# However we need to clean the code up before we can unrestrictedly enable this option with Clang
|
||||
WARNINGS_ARE_ERRORS += -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses
|
||||
WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-compare
|
||||
# Not yet supported by clang in Xcode 4.6.2
|
||||
# WARNINGS_ARE_ERRORS += -Wno-tautological-constant-out-of-range-compare
|
||||
WARNINGS_ARE_ERRORS += -Wno-delete-non-virtual-dtor -Wno-deprecated -Wno-format -Wno-dynamic-class-memaccess
|
||||
WARNINGS_ARE_ERRORS += -Wno-empty-body
|
||||
endif
|
||||
|
||||
WARNING_FLAGS = -Wpointer-arith -Wsign-compare -Wundef -Wunused-function -Wformat=2
|
||||
|
||||
ifeq ($(USE_CLANG),)
|
||||
# Since GCC 4.3, -Wconversion has changed its meanings to warn these implicit
|
||||
# conversions which might affect the values. Only enable it in earlier versions.
|
||||
ifeq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0"
|
||||
WARNINGS_FLAGS += -Wconversion
|
||||
endif
|
||||
endif
|
||||
|
||||
CFLAGS_WARN/DEFAULT = $(WARNINGS_ARE_ERRORS) $(WARNING_FLAGS)
|
||||
# Special cases
|
||||
CFLAGS_WARN/BYFILE = $(CFLAGS_WARN/$@)$(CFLAGS_WARN/DEFAULT$(CFLAGS_WARN/$@))
|
||||
# XXXDARWIN: for _dyld_bind_fully_image_containing_address
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
CFLAGS_WARN/os_bsd.o = $(CFLAGS_WARN/DEFAULT) -Wno-deprecated-declarations
|
||||
endif
|
||||
|
||||
# optimization control flags (Used by fastdebug and release variants)
|
||||
OPT_CFLAGS/NOOPT=-O0
|
||||
OPT_CFLAGS/DEBUG=-O0
|
||||
OPT_CFLAGS/SIZE=-Os
|
||||
OPT_CFLAGS/SPEED=-O3
|
||||
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# use -Os by default, unless -O3 can be proved to be worth the cost, as per policy
|
||||
# <https://wiki.openjdk.java.net/display/MacOSXPort/Compiler+Errata>
|
||||
OPT_CFLAGS_DEFAULT ?= SIZE
|
||||
else
|
||||
OPT_CFLAGS_DEFAULT ?= SPEED
|
||||
endif
|
||||
|
||||
# Hotspot uses very unstrict aliasing turn this optimization off
|
||||
# This option is added to CFLAGS rather than OPT_CFLAGS
|
||||
# so that OPT_CFLAGS overrides get this option too.
|
||||
CFLAGS += -fno-strict-aliasing
|
||||
|
||||
ifdef OPT_CFLAGS
|
||||
ifneq ("$(origin OPT_CFLAGS)", "command line")
|
||||
$(error " Use OPT_EXTRAS instead of OPT_CFLAGS to add extra flags to OPT_CFLAGS.")
|
||||
endif
|
||||
endif
|
||||
|
||||
OPT_CFLAGS = $(OPT_CFLAGS/$(OPT_CFLAGS_DEFAULT)) $(OPT_EXTRAS)
|
||||
|
||||
# The gcc compiler segv's on ia64 when compiling bytecodeInterpreter.cpp
|
||||
# if we use expensive-optimizations
|
||||
ifeq ($(BUILDARCH), ia64)
|
||||
OPT_CFLAGS += -fno-expensive-optimizations
|
||||
endif
|
||||
|
||||
# Work around some compiler bugs.
|
||||
ifeq ($(USE_CLANG), true)
|
||||
# Clang < 6 | <= 6.1 | <= 7.0
|
||||
ifeq ($(shell expr \
|
||||
$(CC_VER_MAJOR) \< 6 \| \
|
||||
\( $(CC_VER_MAJOR) = 6 \& $(CC_VER_MINOR) \<= 1 \) \| \
|
||||
\( $(CC_VER_MAJOR) = 7 \& $(CC_VER_MINOR) \<= 0 \) \
|
||||
), 1)
|
||||
OPT_CFLAGS/loopTransform.o += $(OPT_CFLAGS/NOOPT)
|
||||
OPT_CFLAGS/unsafe.o += -O1
|
||||
|
||||
# The debug flag is added to OPT_CFLAGS, but lost in case of per-file overrides
|
||||
# of OPT_CFLAGS. Restore it here.
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
OPT_CFLAGS/loopTransform.o += -g
|
||||
OPT_CFLAGS/unsafe.o += -g
|
||||
endif
|
||||
else
|
||||
$(error "Update compiler workarounds for Clang $(CC_VER_MAJOR).$(CC_VER_MINOR)")
|
||||
endif
|
||||
else
|
||||
# Do not allow GCC 4.1.1
|
||||
ifeq ($(shell expr $(CC_VER_MAJOR) = 4 \& $(CC_VER_MINOR) = 1 \& $(CC_VER_MICRO) = 1), 1)
|
||||
$(error "GCC $(CC_VER_MAJOR).$(CC_VER_MINOR).$(CC_VER_MICRO) not supported because of https://gcc.gnu.org/bugzilla/show_bug.cgi?id=27724")
|
||||
endif
|
||||
# 6835796. Problem in GCC 4.3.0 with mulnode.o optimized compilation.
|
||||
ifeq ($(shell expr $(CC_VER_MAJOR) = 4 \& $(CC_VER_MINOR) = 3), 1)
|
||||
OPT_CFLAGS/mulnode.o += $(OPT_CFLAGS/NOOPT)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Flags for generating make dependency flags.
|
||||
DEPFLAGS = -MMD -MP -MF $(DEP_DIR)/$(@:%=%.d)
|
||||
ifeq ($(USE_CLANG),)
|
||||
ifneq ($(CC_VER_MAJOR), 2)
|
||||
DEPFLAGS += -fpch-deps
|
||||
endif
|
||||
endif
|
||||
|
||||
# -DDONT_USE_PRECOMPILED_HEADER will exclude all includes in precompiled.hpp.
|
||||
ifeq ($(USE_PRECOMPILED_HEADER),0)
|
||||
CFLAGS += -DDONT_USE_PRECOMPILED_HEADER
|
||||
endif
|
||||
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# Setting these parameters makes it an error to link to macosx APIs that are
|
||||
# newer than the given OS version and makes the linked binaries compatible even
|
||||
# if built on a newer version of the OS.
|
||||
# The expected format is X.Y.Z
|
||||
ifeq ($(MACOSX_VERSION_MIN),)
|
||||
MACOSX_VERSION_MIN=10.7.0
|
||||
endif
|
||||
# The macro takes the version with no dots, ex: 1070
|
||||
CFLAGS += -DMAC_OS_X_VERSION_MAX_ALLOWED=$(subst .,,$(MACOSX_VERSION_MIN)) \
|
||||
-mmacosx-version-min=$(MACOSX_VERSION_MIN)
|
||||
LDFLAGS += -mmacosx-version-min=$(MACOSX_VERSION_MIN)
|
||||
endif
|
||||
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Assembler flags
|
||||
|
||||
# Enforce prerpocessing of .s files
|
||||
ASFLAGS += -x assembler-with-cpp
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Linker flags
|
||||
|
||||
# statically link libstdc++.so, work with gcc but ignored by g++
|
||||
STATIC_STDCXX = -Wl,-Bstatic -lstdc++ -Wl,-Bdynamic
|
||||
|
||||
# Ensure use libstdc++ on clang, not libc++
|
||||
ifeq ($(USE_CLANG), true)
|
||||
LFLAGS += -stdlib=libstdc++
|
||||
endif
|
||||
|
||||
ifeq ($(USE_CLANG),)
|
||||
# statically link libgcc and/or libgcc_s, libgcc does not exist before gcc-3.x.
|
||||
ifneq ($(CC_VER_MAJOR), 2)
|
||||
STATIC_LIBGCC += -static-libgcc
|
||||
endif
|
||||
|
||||
ifneq ($(OS_VENDOR), Darwin)
|
||||
ifneq (, findstring(debug,$(BUILD_FLAVOR)))
|
||||
# for relocations read-only
|
||||
LFLAGS += -Xlinker -z -Xlinker relro
|
||||
|
||||
ifeq ($(BUILD_FLAVOR), debug)
|
||||
# disable incremental relocations linking
|
||||
LFLAGS += -Xlinker -z -Xlinker now
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(BUILDARCH), ia64)
|
||||
LFLAGS += -Wl,-relax
|
||||
endif
|
||||
endif
|
||||
|
||||
# Use $(MAPFLAG:FILENAME=real_file_name) to specify a map file.
|
||||
MAPFLAG = -Xlinker --version-script=FILENAME
|
||||
|
||||
#
|
||||
# Shared Library
|
||||
#
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# Standard linker flags
|
||||
LFLAGS +=
|
||||
|
||||
# The apple linker has its own variant of mapfiles/version-scripts
|
||||
MAPFLAG = -Xlinker -exported_symbols_list -Xlinker FILENAME
|
||||
|
||||
# Use $(SONAMEFLAG:SONAME=soname) to specify the intrinsic name of a shared obj
|
||||
SONAMEFLAG =
|
||||
|
||||
# Build shared library
|
||||
SHARED_FLAG = -Wl,-install_name,@rpath/$(@F) -dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $(VM_PICFLAG)
|
||||
|
||||
# Keep symbols even they are not used
|
||||
#AOUT_FLAGS += -Xlinker -export-dynamic
|
||||
else
|
||||
# Enable linker optimization
|
||||
LFLAGS += -Xlinker -O1
|
||||
|
||||
# Use $(SONAMEFLAG:SONAME=soname) to specify the intrinsic name of a shared obj
|
||||
SONAMEFLAG = -Xlinker -soname=SONAME
|
||||
|
||||
# Build shared library
|
||||
SHARED_FLAG = -shared $(VM_PICFLAG)
|
||||
|
||||
# Keep symbols even they are not used
|
||||
AOUT_FLAGS += -Xlinker -export-dynamic
|
||||
endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Debug flags
|
||||
|
||||
ifeq ($(USE_CLANG), true)
|
||||
# Restrict the debug information created by Clang to avoid
|
||||
# too big object files and speed the build up a little bit
|
||||
# (see http://llvm.org/bugs/show_bug.cgi?id=7554)
|
||||
CFLAGS += -flimit-debug-info
|
||||
endif
|
||||
|
||||
# Allow no optimizations.
|
||||
DEBUG_CFLAGS=-O0
|
||||
|
||||
# DEBUG_BINARIES uses full -g debug information for all configs
|
||||
ifeq ($(DEBUG_BINARIES), true)
|
||||
CFLAGS += -g
|
||||
else
|
||||
# Use the stabs format for debugging information (this is the default
|
||||
# on gcc-2.91). It's good enough, has all the information about line
|
||||
# numbers and local variables, and libjvm.so is only about 16M.
|
||||
# Change this back to "-g" if you want the most expressive format.
|
||||
# (warning: that could easily inflate libjvm.so to 150M!)
|
||||
# Note: The Itanium gcc compiler crashes when using -gstabs.
|
||||
DEBUG_CFLAGS/ia64 = -g
|
||||
DEBUG_CFLAGS/amd64 = -g
|
||||
DEBUG_CFLAGS/arm = -g
|
||||
DEBUG_CFLAGS/ppc = -g
|
||||
DEBUG_CFLAGS += $(DEBUG_CFLAGS/$(BUILDARCH))
|
||||
ifeq ($(DEBUG_CFLAGS/$(BUILDARCH)),)
|
||||
ifeq ($(USE_CLANG), true)
|
||||
# Clang doesn't understand -gstabs
|
||||
DEBUG_CFLAGS += -g
|
||||
else
|
||||
DEBUG_CFLAGS += -gstabs
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
FASTDEBUG_CFLAGS/ia64 = -g
|
||||
FASTDEBUG_CFLAGS/amd64 = -g
|
||||
FASTDEBUG_CFLAGS/arm = -g
|
||||
FASTDEBUG_CFLAGS/ppc = -g
|
||||
FASTDEBUG_CFLAGS += $(FASTDEBUG_CFLAGS/$(BUILDARCH))
|
||||
ifeq ($(FASTDEBUG_CFLAGS/$(BUILDARCH)),)
|
||||
ifeq ($(USE_CLANG), true)
|
||||
# Clang doesn't understand -gstabs
|
||||
FASTDEBUG_CFLAGS += -g
|
||||
else
|
||||
FASTDEBUG_CFLAGS += -gstabs
|
||||
endif
|
||||
endif
|
||||
|
||||
OPT_CFLAGS/ia64 = -g
|
||||
OPT_CFLAGS/amd64 = -g
|
||||
OPT_CFLAGS/arm = -g
|
||||
OPT_CFLAGS/ppc = -g
|
||||
OPT_CFLAGS += $(OPT_CFLAGS/$(BUILDARCH))
|
||||
ifeq ($(OPT_CFLAGS/$(BUILDARCH)),)
|
||||
ifeq ($(USE_CLANG), true)
|
||||
# Clang doesn't understand -gstabs
|
||||
OPT_CFLAGS += -g
|
||||
else
|
||||
OPT_CFLAGS += -gstabs
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(USE_CLANG),)
|
||||
# Enable bounds checking.
|
||||
ifeq "$(shell expr \( $(CC_VER_MAJOR) \> 3 \) )" "1"
|
||||
# stack smashing checks.
|
||||
DEBUG_CFLAGS += -fstack-protector-all --param ssp-buffer-size=1
|
||||
endif
|
||||
endif
|
||||
|
||||
# If we are building HEADLESS, pass on to VM
|
||||
# so it can set the java.awt.headless property
|
||||
ifdef HEADLESS
|
||||
CFLAGS += -DHEADLESS
|
||||
endif
|
||||
|
||||
# We are building Embedded for a small device
|
||||
# favor code space over speed
|
||||
ifdef MINIMIZE_RAM_USAGE
|
||||
CFLAGS += -DMINIMIZE_RAM_USAGE
|
||||
endif
|
@ -1,29 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2008, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making premium version of VM
|
||||
|
||||
TYPE=HP
|
||||
|
||||
CFLAGS += -DCOMPILER2
|
@ -1,29 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2008, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making premium version of VM
|
||||
|
||||
TYPE=HP1
|
||||
|
||||
CFLAGS += -DCOMPILER1
|
@ -1,34 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2010, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# TLS helper, assembled from .s file
|
||||
|
||||
# The copied fdlibm routines in sharedRuntimeTrig.o must not be optimized
|
||||
OPT_CFLAGS/sharedRuntimeTrig.o = $(OPT_CFLAGS/NOOPT)
|
||||
# The copied fdlibm routines in sharedRuntimeTrans.o must not be optimized
|
||||
OPT_CFLAGS/sharedRuntimeTrans.o = $(OPT_CFLAGS/NOOPT)
|
||||
# Must also specify if CPU is little endian
|
||||
CFLAGS += -DVM_LITTLE_ENDIAN
|
||||
|
||||
OPT_CFLAGS/compactingPermGenGen.o = -O1
|
@ -1,41 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 2012, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
#
|
||||
# IA64 only uses c++ based interpreter
|
||||
CFLAGS += -DCC_INTERP -D_LP64=1 -DVM_LITTLE_ENDIAN
|
||||
ifeq ($(VERSION),debug)
|
||||
ASM_FLAGS= -DDEBUG
|
||||
else
|
||||
ASM_FLAGS=
|
||||
endif
|
||||
# workaround gcc bug in compiling varargs
|
||||
OPT_CFLAGS/jni.o = -O0
|
||||
|
||||
# gcc/ia64 has a bug that internal gcc functions linked with libjvm.so
|
||||
# are made public. Hiding those symbols will cause undefined symbol error
|
||||
# when VM is dropped into older JDK. We probably will need an IA64
|
||||
# mapfile to include those symbols as a workaround. Disable linker mapfile
|
||||
# for now.
|
||||
LDNOMAP=true
|
@ -1,110 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Rules to build signal interposition library, used by vm.make
|
||||
|
||||
# libjsig.so: signal interposition library
|
||||
JSIG = jsig
|
||||
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
LIBJSIG = lib$(JSIG).$(LIBRARY_SUFFIX)
|
||||
|
||||
LIBJSIG_DEBUGINFO = lib$(JSIG).$(LIBRARY_SUFFIX).dSYM
|
||||
LIBJSIG_DIZ = lib$(JSIG).diz
|
||||
else
|
||||
LIBJSIG = lib$(JSIG).so
|
||||
|
||||
LIBJSIG_DEBUGINFO = lib$(JSIG).debuginfo
|
||||
LIBJSIG_DIZ = lib$(JSIG).diz
|
||||
endif
|
||||
|
||||
JSIGSRCDIR = $(GAMMADIR)/src/os/$(Platform_os_family)/vm
|
||||
|
||||
DEST_JSIG = $(JDK_LIBDIR)/$(LIBJSIG)
|
||||
DEST_JSIG_DEBUGINFO = $(JDK_LIBDIR)/$(LIBJSIG_DEBUGINFO)
|
||||
DEST_JSIG_DIZ = $(JDK_LIBDIR)/$(LIBJSIG_DIZ)
|
||||
|
||||
LIBJSIG_MAPFILE = $(MAKEFILES_DIR)/mapfile-vers-jsig
|
||||
|
||||
# On Bsd we really dont want a mapfile, as this library is small
|
||||
# and preloaded using LD_PRELOAD, making functions private will
|
||||
# cause problems with interposing. See CR: 6466665
|
||||
# LFLAGS_JSIG += $(MAPFLAG:FILENAME=$(LIBJSIG_MAPFILE))
|
||||
|
||||
LFLAGS_JSIG += -D_GNU_SOURCE -pthread $(LDFLAGS_HASH_STYLE)
|
||||
|
||||
# DEBUG_BINARIES overrides everything, use full -g debug information
|
||||
ifeq ($(DEBUG_BINARIES), true)
|
||||
JSIG_DEBUG_CFLAGS = -g
|
||||
endif
|
||||
|
||||
$(LIBJSIG): $(JSIGSRCDIR)/jsig.c $(LIBJSIG_MAPFILE)
|
||||
@echo $(LOG_INFO) Making signal interposition lib...
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
$(QUIETLY) $(CC) -c $(SYMFLAG) $(EXTRA_CFLAGS) $(ARCHFLAG) $(PICFLAG) \
|
||||
$(LFLAGS_JSIG) $(JSIG_DEBUG_CFLAGS) -o $(JSIG).o $<
|
||||
$(QUIETLY) $(AR) $(ARFLAGS) $@ $(JSIG).o
|
||||
else
|
||||
$(QUIETLY) $(CC) $(SYMFLAG) $(ARCHFLAG) $(SHARED_FLAG) $(PICFLAG) \
|
||||
$(LFLAGS_JSIG) $(JSIG_DEBUG_CFLAGS) $(EXTRA_CFLAGS) -o $@ $<
|
||||
endif
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(DSYMUTIL) $@
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(ZIPEXE) -q -r -y $(LIBJSIG_DIZ) $(LIBJSIG_DEBUGINFO)
|
||||
$(RM) -r $(LIBJSIG_DEBUGINFO)
|
||||
endif
|
||||
else
|
||||
$(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJSIG_DEBUGINFO)
|
||||
$(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJSIG_DEBUGINFO) $@
|
||||
ifeq ($(STRIP_POLICY),all_strip)
|
||||
$(QUIETLY) $(STRIP) $@
|
||||
else
|
||||
ifeq ($(STRIP_POLICY),min_strip)
|
||||
$(QUIETLY) $(STRIP) -g $@
|
||||
# implied else here is no stripping at all
|
||||
endif
|
||||
endif
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(ZIPEXE) -q -y $(LIBJSIG_DIZ) $(LIBJSIG_DEBUGINFO)
|
||||
$(RM) $(LIBJSIG_DEBUGINFO)
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
install_jsig: $(LIBJSIG)
|
||||
@echo "Copying $(LIBJSIG) to $(DEST_JSIG)"
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(QUIETLY) test ! -d $(LIBJSIG_DEBUGINFO) || \
|
||||
$(CP) -f -r $(LIBJSIG_DEBUGINFO) $(DEST_JSIG_DEBUGINFO)
|
||||
else
|
||||
$(QUIETLY) test ! -f $(LIBJSIG_DEBUGINFO) || \
|
||||
$(CP) -f $(LIBJSIG_DEBUGINFO) $(DEST_JSIG_DEBUGINFO)
|
||||
endif
|
||||
$(QUIETLY) test ! -f $(LIBJSIG_DIZ) || \
|
||||
$(CP) -f $(LIBJSIG_DIZ) $(DEST_JSIG_DIZ)
|
||||
$(QUIETLY) $(CP) -f $(LIBJSIG) $(DEST_JSIG) && echo "Done"
|
||||
|
||||
.PHONY: install_jsig
|
@ -1,116 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2003, 2010, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This makefile (jvmti.make) is included from the jvmti.make in the
|
||||
# build directories.
|
||||
#
|
||||
# It knows how to build and run the tools to generate jvmti.
|
||||
|
||||
include $(GAMMADIR)/make/bsd/makefiles/rules.make
|
||||
|
||||
# #########################################################################
|
||||
|
||||
TOPDIR = $(shell echo `pwd`)
|
||||
GENERATED = $(TOPDIR)/../generated
|
||||
JvmtiOutDir = $(GENERATED)/jvmtifiles
|
||||
|
||||
JvmtiSrcDir = $(GAMMADIR)/src/share/vm/prims
|
||||
InterpreterSrcDir = $(GAMMADIR)/src/share/vm/interpreter
|
||||
|
||||
# set VPATH so make knows where to look for source files
|
||||
Src_Dirs_V += $(JvmtiSrcDir)
|
||||
VPATH += $(Src_Dirs_V:%=%:)
|
||||
|
||||
JvmtiGeneratedNames = \
|
||||
jvmtiEnv.hpp \
|
||||
jvmtiEnter.cpp \
|
||||
jvmtiEnterTrace.cpp \
|
||||
jvmtiEnvRecommended.cpp \
|
||||
bytecodeInterpreterWithChecks.cpp \
|
||||
jvmti.h \
|
||||
|
||||
JvmtiEnvFillSource = $(JvmtiSrcDir)/jvmtiEnvFill.java
|
||||
JvmtiEnvFillClass = $(JvmtiOutDir)/jvmtiEnvFill.class
|
||||
|
||||
JvmtiGenSource = $(JvmtiSrcDir)/jvmtiGen.java
|
||||
JvmtiGenClass = $(JvmtiOutDir)/jvmtiGen.class
|
||||
|
||||
JvmtiGeneratedFiles = $(JvmtiGeneratedNames:%=$(JvmtiOutDir)/%)
|
||||
|
||||
XSLT = $(QUIETLY) $(REMOTE) $(RUN.JAVA) -classpath $(JvmtiOutDir) jvmtiGen
|
||||
|
||||
.PHONY: all jvmtidocs clean cleanall
|
||||
|
||||
# #########################################################################
|
||||
|
||||
all: $(JvmtiGeneratedFiles)
|
||||
|
||||
both = $(JvmtiGenClass) $(JvmtiSrcDir)/jvmti.xml $(JvmtiSrcDir)/jvmtiLib.xsl
|
||||
|
||||
$(JvmtiGenClass): $(JvmtiGenSource)
|
||||
$(QUIETLY) $(REMOTE) $(COMPILE.JAVAC) -d $(JvmtiOutDir) $(JvmtiGenSource)
|
||||
|
||||
$(JvmtiEnvFillClass): $(JvmtiEnvFillSource)
|
||||
$(QUIETLY) $(REMOTE) $(COMPILE.JAVAC) -d $(JvmtiOutDir) $(JvmtiEnvFillSource)
|
||||
|
||||
$(JvmtiOutDir)/jvmtiEnter.cpp: $(both) $(JvmtiSrcDir)/jvmtiEnter.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiEnter.xsl -OUT $(JvmtiOutDir)/jvmtiEnter.cpp -PARAM interface jvmti
|
||||
|
||||
$(JvmtiOutDir)/bytecodeInterpreterWithChecks.cpp: $(JvmtiGenClass) $(InterpreterSrcDir)/bytecodeInterpreter.cpp $(InterpreterSrcDir)/bytecodeInterpreterWithChecks.xml $(InterpreterSrcDir)/bytecodeInterpreterWithChecks.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(InterpreterSrcDir)/bytecodeInterpreterWithChecks.xml -XSL $(InterpreterSrcDir)/bytecodeInterpreterWithChecks.xsl -OUT $(JvmtiOutDir)/bytecodeInterpreterWithChecks.cpp
|
||||
|
||||
$(JvmtiOutDir)/jvmtiEnterTrace.cpp: $(both) $(JvmtiSrcDir)/jvmtiEnter.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiEnter.xsl -OUT $(JvmtiOutDir)/jvmtiEnterTrace.cpp -PARAM interface jvmti -PARAM trace Trace
|
||||
|
||||
$(JvmtiOutDir)/jvmtiEnvRecommended.cpp: $(both) $(JvmtiSrcDir)/jvmtiEnv.xsl $(JvmtiSrcDir)/jvmtiEnv.cpp $(JvmtiEnvFillClass)
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiEnv.xsl -OUT $(JvmtiOutDir)/jvmtiEnvStub.cpp
|
||||
$(QUIETLY) $(REMOTE) $(RUN.JAVA) -classpath $(JvmtiOutDir) jvmtiEnvFill $(JvmtiSrcDir)/jvmtiEnv.cpp $(JvmtiOutDir)/jvmtiEnvStub.cpp $(JvmtiOutDir)/jvmtiEnvRecommended.cpp
|
||||
|
||||
$(JvmtiOutDir)/jvmtiEnv.hpp: $(both) $(JvmtiSrcDir)/jvmtiHpp.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiHpp.xsl -OUT $(JvmtiOutDir)/jvmtiEnv.hpp
|
||||
|
||||
$(JvmtiOutDir)/jvmti.h: $(both) $(JvmtiSrcDir)/jvmtiH.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmtiH.xsl -OUT $(JvmtiOutDir)/jvmti.h
|
||||
|
||||
jvmtidocs: $(JvmtiOutDir)/jvmti.html
|
||||
|
||||
$(JvmtiOutDir)/jvmti.html: $(both) $(JvmtiSrcDir)/jvmti.xsl
|
||||
@echo $(LOG_INFO) Generating $@
|
||||
$(XSLT) -IN $(JvmtiSrcDir)/jvmti.xml -XSL $(JvmtiSrcDir)/jvmti.xsl -OUT $(JvmtiOutDir)/jvmti.html
|
||||
|
||||
# #########################################################################
|
||||
|
||||
clean :
|
||||
rm $(JvmtiGenClass) $(JvmtiEnvFillClass) $(JvmtiGeneratedFiles)
|
||||
|
||||
cleanall :
|
||||
rm $(JvmtiGenClass) $(JvmtiEnvFillClass) $(JvmtiGeneratedFiles)
|
||||
|
||||
# #########################################################################
|
@ -1,40 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2002, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
# Only used for OSX/Darwin builds
|
||||
|
||||
# Define public interface.
|
||||
_JVM_handle_bsd_signal
|
||||
|
||||
# miscellaneous functions
|
||||
_jio_fprintf
|
||||
_jio_printf
|
||||
_jio_snprintf
|
||||
_jio_vfprintf
|
||||
_jio_vsnprintf
|
||||
|
||||
# This is for Forte Analyzer profiling support.
|
||||
_AsyncGetCallTrace
|
||||
|
||||
# INSERT VTABLE SYMBOLS HERE
|
||||
|
@ -1,40 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2002, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
# Only used for OSX/Darwin builds
|
||||
|
||||
# Define public interface.
|
||||
_JVM_handle_bsd_signal
|
||||
|
||||
# miscellaneous functions
|
||||
_jio_fprintf
|
||||
_jio_printf
|
||||
_jio_snprintf
|
||||
_jio_vfprintf
|
||||
_jio_vsnprintf
|
||||
|
||||
# This is for Forte Analyzer profiling support.
|
||||
_AsyncGetCallTrace
|
||||
|
||||
# INSERT VTABLE SYMBOLS HERE
|
||||
|
@ -1,51 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2002, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Define public interface.
|
||||
|
||||
SUNWprivate_1.1 {
|
||||
global:
|
||||
JVM_handle_linux_signal;
|
||||
|
||||
# miscellaneous functions
|
||||
jio_fprintf;
|
||||
jio_printf;
|
||||
jio_snprintf;
|
||||
jio_vfprintf;
|
||||
jio_vsnprintf;
|
||||
numa_warn;
|
||||
numa_error;
|
||||
|
||||
# Needed because there is no JVM interface for this.
|
||||
sysThreadAvailableStackWithSlack;
|
||||
|
||||
# This is for Forte Analyzer profiling support.
|
||||
AsyncGetCallTrace;
|
||||
|
||||
# INSERT VTABLE SYMBOLS HERE
|
||||
|
||||
local:
|
||||
*;
|
||||
};
|
||||
|
@ -1,40 +0,0 @@
|
||||
#
|
||||
|
||||
#
|
||||
# Copyright (c) 2005, 2008, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Define library interface.
|
||||
|
||||
SUNWprivate_1.1 {
|
||||
global:
|
||||
JVM_begin_signal_setting;
|
||||
JVM_end_signal_setting;
|
||||
JVM_get_libjsig_version;
|
||||
JVM_get_signal_action;
|
||||
sigaction;
|
||||
signal;
|
||||
sigset;
|
||||
local:
|
||||
*;
|
||||
};
|
@ -1,51 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2002, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Define public interface.
|
||||
|
||||
SUNWprivate_1.1 {
|
||||
global:
|
||||
JVM_handle_linux_signal;
|
||||
|
||||
# miscellaneous functions
|
||||
jio_fprintf;
|
||||
jio_printf;
|
||||
jio_snprintf;
|
||||
jio_vfprintf;
|
||||
jio_vsnprintf;
|
||||
numa_warn;
|
||||
numa_error;
|
||||
|
||||
# Needed because there is no JVM interface for this.
|
||||
sysThreadAvailableStackWithSlack;
|
||||
|
||||
# This is for Forte Analyzer profiling support.
|
||||
AsyncGetCallTrace;
|
||||
|
||||
# INSERT VTABLE SYMBOLS HERE
|
||||
|
||||
local:
|
||||
*;
|
||||
};
|
||||
|
@ -1,52 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2012, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
TYPE=MINIMAL1
|
||||
|
||||
# Force all variables to false, overriding any other
|
||||
# setting that may have occurred in the makefiles. These
|
||||
# can still be overridden by passing the variable as an
|
||||
# argument to 'make'
|
||||
INCLUDE_JVMTI := false
|
||||
INCLUDE_FPROF := false
|
||||
INCLUDE_VM_STRUCTS := false
|
||||
INCLUDE_JNI_CHECK := false
|
||||
INCLUDE_SERVICES := false
|
||||
INCLUDE_MANAGEMENT := false
|
||||
INCLUDE_ALL_GCS := false
|
||||
INCLUDE_NMT := false
|
||||
INCLUDE_TRACE := false
|
||||
INCLUDE_CDS := false
|
||||
INCLUDE_JVMCI := false
|
||||
|
||||
CXXFLAGS += -DMINIMAL_JVM -DCOMPILER1 -DVMTYPE=\"Minimal\"
|
||||
CFLAGS += -DMINIMAL_JVM -DCOMPILER1 -DVMTYPE=\"Minimal\"
|
||||
|
||||
Src_Dirs/MINIMAL1 = $(CORE_PATHS) $(COMPILER1_PATHS)
|
||||
|
||||
Src_Files_EXCLUDE/MINIMAL1 += $(COMPILER2_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES) ciTypeFlow.cpp
|
||||
|
||||
-include $(HS_ALT_MAKE)/$(OSNAME)/makefiles/minimal1.make
|
||||
|
||||
.PHONY: $(HS_ALT_MAKE)/$(OSNAME)/makefiles/minimal1.make
|
@ -1,46 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making optimized version of HotSpot VM
|
||||
# (This is the "product", not the "release" version.)
|
||||
|
||||
# Compiler specific OPT_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
OPT_CFLAGS/DEFAULT= $(OPT_CFLAGS)
|
||||
OPT_CFLAGS/BYFILE = $(OPT_CFLAGS/$@)$(OPT_CFLAGS/DEFAULT$(OPT_CFLAGS/$@))
|
||||
|
||||
# (OPT_CFLAGS/SLOWER is also available, to alter compilation of buggy files)
|
||||
|
||||
# If you set HOTSPARC_GENERIC=yes, you disable all OPT_CFLAGS settings
|
||||
CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-debug
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-darwin-debug
|
||||
endif
|
||||
|
||||
VERSION = optimized
|
@ -1,30 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2004, 2011, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# The copied fdlibm routines in sharedRuntimeTrig.o must not be optimized
|
||||
OPT_CFLAGS/sharedRuntimeTrig.o = $(OPT_CFLAGS/NOOPT)
|
||||
|
||||
# Must also specify if CPU is big endian
|
||||
CFLAGS += -DVM_BIG_ENDIAN
|
||||
|
@ -1,62 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making optimized version of HotSpot VM
|
||||
# (This is the "product", not the "release" version.)
|
||||
|
||||
# Compiler specific OPT_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
OPT_CFLAGS/DEFAULT= $(OPT_CFLAGS)
|
||||
OPT_CFLAGS/BYFILE = $(OPT_CFLAGS/$@)$(OPT_CFLAGS/DEFAULT$(OPT_CFLAGS/$@))
|
||||
|
||||
# (OPT_CFLAGS/SLOWER is also available, to alter compilation of buggy files)
|
||||
|
||||
# If you set HOTSPARC_GENERIC=yes, you disable all OPT_CFLAGS settings
|
||||
CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-product
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-darwin-product
|
||||
endif
|
||||
|
||||
SYSDEFS += -DPRODUCT
|
||||
VERSION = optimized
|
||||
|
||||
ifneq ($(OS_VENDOR), Darwin)
|
||||
# use -g to strip library as -x will discard its symbol table; -x is fine for
|
||||
# executables.
|
||||
ifdef CROSS_COMPILE_ARCH
|
||||
STRIP = $(ALT_COMPILER_PATH)/strip
|
||||
else
|
||||
STRIP = strip
|
||||
endif
|
||||
STRIP_LIBJVM = $(STRIP) -g $@ || exit 1;
|
||||
STRIP_AOUT = $(STRIP) -x $@ || exit 1;
|
||||
|
||||
# Don't strip in VM build; JDK build will strip libraries later
|
||||
# LINK_LIB.CXX/POST_HOOK += $(STRIP_$(LINK_INTO))
|
||||
endif
|
@ -1,212 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2003, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Common rules/macros for the vm, adlc.
|
||||
|
||||
# Tell make that .cpp is important
|
||||
.SUFFIXES: .cpp $(SUFFIXES)
|
||||
|
||||
DEMANGLER = c++filt
|
||||
DEMANGLE = $(DEMANGLER) < $@ > .$@ && $(MV) -f .$@ $@
|
||||
|
||||
# $(CC) is the c compiler (cc/gcc), $(CXX) is the c++ compiler (CC/g++).
|
||||
CC_COMPILE = $(CC) $(CXXFLAGS) $(CFLAGS)
|
||||
CXX_COMPILE = $(CXX) $(CXXFLAGS) $(CFLAGS)
|
||||
|
||||
AS.S = $(AS) $(ASFLAGS)
|
||||
|
||||
COMPILE.CC = $(CC_COMPILE) -c
|
||||
GENASM.CC = $(CC_COMPILE) -S
|
||||
LINK.CC = $(CC) $(LFLAGS) $(AOUT_FLAGS) $(PROF_AOUT_FLAGS)
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
LINK_LIB.CC = $(AR) $(ARFLAGS)
|
||||
else
|
||||
LINK_LIB.CC = $(CC) $(LFLAGS) $(SHARED_FLAG)
|
||||
endif
|
||||
PREPROCESS.CC = $(CC_COMPILE) -E
|
||||
|
||||
COMPILE.CXX = $(CXX_COMPILE) -c
|
||||
GENASM.CXX = $(CXX_COMPILE) -S
|
||||
LINK.CXX = $(CXX) $(LFLAGS) $(AOUT_FLAGS) $(PROF_AOUT_FLAGS)
|
||||
LINK_NOPROF.CXX = $(CXX) $(LFLAGS) $(AOUT_FLAGS)
|
||||
LINK_LIB.CXX = $(CXX) $(LFLAGS) $(SHARED_FLAG)
|
||||
PREPROCESS.CXX = $(CXX_COMPILE) -E
|
||||
|
||||
# cross compiling the jvm with c2 requires host compilers to build
|
||||
# adlc tool
|
||||
|
||||
HOST.CXX_COMPILE = $(HOSTCXX) $(CXXFLAGS) $(CFLAGS)
|
||||
HOST.COMPILE.CXX = $(HOST.CXX_COMPILE) -c
|
||||
HOST.LINK_NOPROF.CXX = $(HOSTCXX) $(LFLAGS) $(AOUT_FLAGS)
|
||||
|
||||
|
||||
# Effect of REMOVE_TARGET is to delete out-of-date files during "gnumake -k".
|
||||
REMOVE_TARGET = rm -f $@
|
||||
|
||||
# Note use of ALT_BOOTDIR to explicitly specify location of java and
|
||||
# javac; this is the same environment variable used in the J2SE build
|
||||
# process for overriding the default spec, which is BOOTDIR.
|
||||
# Note also that we fall back to using JAVA_HOME if neither of these is
|
||||
# specified.
|
||||
|
||||
ifdef ALT_BOOTDIR
|
||||
|
||||
RUN.JAVA = $(ALT_BOOTDIR)/bin/java
|
||||
RUN.JAVAP = $(ALT_BOOTDIR)/bin/javap
|
||||
RUN.JAVAH = $(ALT_BOOTDIR)/bin/javah
|
||||
RUN.JAR = $(ALT_BOOTDIR)/bin/jar
|
||||
COMPILE.JAVAC = $(ALT_BOOTDIR)/bin/javac
|
||||
COMPILE.RMIC = $(ALT_BOOTDIR)/bin/rmic
|
||||
BOOT_JAVA_HOME = $(ALT_BOOTDIR)
|
||||
|
||||
else
|
||||
|
||||
ifdef BOOTDIR
|
||||
|
||||
RUN.JAVA = $(BOOTDIR)/bin/java
|
||||
RUN.JAVAP = $(BOOTDIR)/bin/javap
|
||||
RUN.JAVAH = $(BOOTDIR)/bin/javah
|
||||
RUN.JAR = $(BOOTDIR)/bin/jar
|
||||
COMPILE.JAVAC = $(BOOTDIR)/bin/javac
|
||||
COMPILE.RMIC = $(BOOTDIR)/bin/rmic
|
||||
BOOT_JAVA_HOME = $(BOOTDIR)
|
||||
|
||||
else
|
||||
|
||||
ifdef JAVA_HOME
|
||||
|
||||
RUN.JAVA = $(JAVA_HOME)/bin/java
|
||||
RUN.JAVAP = $(JAVA_HOME)/bin/javap
|
||||
RUN.JAVAH = $(JAVA_HOME)/bin/javah
|
||||
RUN.JAR = $(JAVA_HOME)/bin/jar
|
||||
COMPILE.JAVAC = $(JAVA_HOME)/bin/javac
|
||||
COMPILE.RMIC = $(JAVA_HOME)/bin/rmic
|
||||
BOOT_JAVA_HOME = $(JAVA_HOME)
|
||||
|
||||
else
|
||||
|
||||
# take from the PATH, if ALT_BOOTDIR, BOOTDIR and JAVA_HOME are not defined
|
||||
|
||||
RUN.JAVA = java
|
||||
RUN.JAVAP = javap
|
||||
RUN.JAVAH = javah
|
||||
RUN.JAR = jar
|
||||
COMPILE.JAVAC = javac
|
||||
COMPILE.RMIC = rmic
|
||||
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
COMPILE.JAVAC += $(BOOTSTRAP_JAVAC_FLAGS)
|
||||
|
||||
SUM = /usr/bin/sum
|
||||
|
||||
# 'gmake MAKE_VERBOSE=y' gives all the gory details.
|
||||
QUIETLY$(MAKE_VERBOSE) = @
|
||||
RUN.JAR$(MAKE_VERBOSE) += >/dev/null
|
||||
|
||||
# Settings for javac
|
||||
JAVAC_FLAGS = -g -encoding ascii
|
||||
|
||||
# Prefer BOOT_JDK_SOURCETARGET if it's set (typically by the top build system)
|
||||
# Fall back to the values here if it's not set (hotspot only builds)
|
||||
ifeq ($(BOOT_JDK_SOURCETARGET),)
|
||||
BOOTSTRAP_SOURCETARGET := -source 8 -target 8
|
||||
else
|
||||
BOOTSTRAP_SOURCETARGET := $(BOOT_JDK_SOURCETARGET)
|
||||
endif
|
||||
|
||||
BOOTSTRAP_JAVAC_FLAGS = $(JAVAC_FLAGS) $(BOOTSTRAP_SOURCETARGET)
|
||||
|
||||
# With parallel makes, print a message at the end of compilation.
|
||||
ifeq ($(findstring j,$(MFLAGS)),j)
|
||||
COMPILE_DONE = && { echo Done with $<; }
|
||||
endif
|
||||
|
||||
# Include $(NONPIC_OBJ_FILES) definition
|
||||
ifndef LP64
|
||||
include $(GAMMADIR)/make/pic.make
|
||||
endif
|
||||
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
# The non-PIC object files are only generated for 32 bit platforms.
|
||||
ifdef LP64
|
||||
%.o: %.cpp
|
||||
@echo $(LOG_INFO) Compiling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(COMPILE.CXX) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE)
|
||||
else
|
||||
%.o: %.cpp
|
||||
@echo $(LOG_INFO) Compiling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(if $(findstring $@, $(NONPIC_OBJ_FILES)), \
|
||||
$(subst $(VM_PICFLAG), ,$(COMPILE.CXX)) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE), \
|
||||
$(COMPILE.CXX) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE))
|
||||
endif
|
||||
|
||||
%.o: %.s
|
||||
@echo $(LOG_INFO) Assembling $<
|
||||
$(QUIETLY) $(REMOVE_TARGET)
|
||||
$(QUIETLY) $(AS.S) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE)
|
||||
|
||||
%.s: %.cpp
|
||||
@echo $(LOG_INFO) Generating assembly for $<
|
||||
$(QUIETLY) $(GENASM.CXX) -o $@ $<
|
||||
$(QUIETLY) $(DEMANGLE) $(COMPILE_DONE)
|
||||
|
||||
# Intermediate files (for debugging macros)
|
||||
%.i: %.cpp
|
||||
@echo $(LOG_INFO) Preprocessing $< to $@
|
||||
$(QUIETLY) $(PREPROCESS.CXX) $< > $@ $(COMPILE_DONE)
|
||||
|
||||
# Override gnumake built-in rules which do sccs get operations badly.
|
||||
# (They put the checked out code in the current directory, not in the
|
||||
# directory of the original file.) Since this is a symptom of a teamware
|
||||
# failure, and since not all problems can be detected by gnumake due
|
||||
# to incomplete dependency checking... just complain and stop.
|
||||
%:: s.%
|
||||
@echo "========================================================="
|
||||
@echo File $@
|
||||
@echo is out of date with respect to its SCCS file.
|
||||
@echo This file may be from an unresolved Teamware conflict.
|
||||
@echo This is also a symptom of a Teamware bringover/putback failure
|
||||
@echo in which SCCS files are updated but not checked out.
|
||||
@echo Check for other out of date files in your workspace.
|
||||
@echo "========================================================="
|
||||
@exit 666
|
||||
|
||||
%:: SCCS/s.%
|
||||
@echo "========================================================="
|
||||
@echo File $@
|
||||
@echo is out of date with respect to its SCCS file.
|
||||
@echo This file may be from an unresolved Teamware conflict.
|
||||
@echo This is also a symptom of a Teamware bringover/putback failure
|
||||
@echo in which SCCS files are updated but not checked out.
|
||||
@echo Check for other out of date files in your workspace.
|
||||
@echo "========================================================="
|
||||
@exit 666
|
||||
|
||||
.PHONY: default
|
@ -1,32 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright 2008, 2010 Red Hat, Inc.
|
||||
# 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making Shark version of VM
|
||||
|
||||
TYPE = SHARK
|
||||
|
||||
VM_SUBDIR = server
|
||||
|
||||
CFLAGS += -DSHARK
|
@ -1,24 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 2010, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
@ -1,107 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# CC, CXX & AS
|
||||
|
||||
# If a SPEC is not set already, then use these defaults.
|
||||
ifeq ($(SPEC),)
|
||||
CXX = CC
|
||||
CC = cc
|
||||
AS = $(CC) -c
|
||||
|
||||
HOSTCXX = $(CXX)
|
||||
HOSTCC = $(CC)
|
||||
endif
|
||||
|
||||
ARCHFLAG = $(ARCHFLAG/$(BUILDARCH))
|
||||
ARCHFLAG/i486 = -m32
|
||||
ARCHFLAG/amd64 = -m64
|
||||
|
||||
CFLAGS += $(ARCHFLAG)
|
||||
AOUT_FLAGS += $(ARCHFLAG)
|
||||
LFLAGS += $(ARCHFLAG)
|
||||
ASFLAGS += $(ARCHFLAG)
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Compiler flags
|
||||
|
||||
# position-independent code
|
||||
PICFLAG = -KPIC
|
||||
|
||||
CFLAGS += $(PICFLAG)
|
||||
# no more exceptions
|
||||
CFLAGS += -features=no%except
|
||||
# Reduce code bloat by reverting back to 5.0 behavior for static initializers
|
||||
CFLAGS += -features=no%split_init
|
||||
# allow zero sized arrays
|
||||
CFLAGS += -features=zla
|
||||
|
||||
# Use C++ Interpreter
|
||||
ifdef CC_INTERP
|
||||
CFLAGS += -DCC_INTERP
|
||||
endif
|
||||
|
||||
# We don't need libCstd.so and librwtools7.so, only libCrun.so
|
||||
CFLAGS += -library=Crun
|
||||
LIBS += -lCrun
|
||||
|
||||
CFLAGS += -mt
|
||||
LFLAGS += -mt
|
||||
|
||||
# Compiler warnings are treated as errors
|
||||
#WARNINGS_ARE_ERRORS = -errwarn=%all
|
||||
CFLAGS_WARN/DEFAULT = $(WARNINGS_ARE_ERRORS)
|
||||
# Special cases
|
||||
CFLAGS_WARN/BYFILE = $(CFLAGS_WARN/$@)$(CFLAGS_WARN/DEFAULT$(CFLAGS_WARN/$@))
|
||||
|
||||
# The flags to use for an Optimized build
|
||||
OPT_CFLAGS+=-xO4
|
||||
OPT_CFLAGS/NOOPT=-xO0
|
||||
|
||||
# Flags for creating the dependency files.
|
||||
ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \>= 509), 1)
|
||||
DEPFLAGS = -xMMD -xMF $(DEP_DIR)/$(@:%=%.d)
|
||||
endif
|
||||
|
||||
# -DDONT_USE_PRECOMPILED_HEADER will exclude all includes in precompiled.hpp.
|
||||
CFLAGS += -DDONT_USE_PRECOMPILED_HEADER
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Linker flags
|
||||
|
||||
# Use $(MAPFLAG:FILENAME=real_file_name) to specify a map file.
|
||||
MAPFLAG = -Wl,--version-script=FILENAME
|
||||
|
||||
# Use $(SONAMEFLAG:SONAME=soname) to specify the intrinsic name of a shared obj
|
||||
SONAMEFLAG = -h SONAME
|
||||
|
||||
# Build shared library
|
||||
SHARED_FLAG = -G
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Debug flags
|
||||
DEBUG_CFLAGS += -g
|
||||
FASTDEBUG_CFLAGS = -g0
|
||||
|
@ -1,27 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2005, 2010, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
|
||||
# gcc 4.0 miscompiles this code in -m64
|
||||
OPT_CFLAGS/macro.o = -O0
|
||||
|
||||
CFLAGS += -D_LP64=1
|
@ -1,31 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2006, 2008, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making tiered version of VM
|
||||
|
||||
TYPE=TIERED
|
||||
|
||||
VM_SUBDIR = server
|
||||
|
||||
CFLAGS += -DCOMPILER2 -DCOMPILER1
|
@ -1,156 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2014, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# top.make is included in the Makefile in the build directories.
|
||||
# It DOES NOT include the vm dependency info in order to be faster.
|
||||
# Its main job is to implement the incremental form of make lists.
|
||||
# It also:
|
||||
# -builds and runs adlc via adlc.make
|
||||
# -generates JVMTI source and docs via jvmti.make (JSR-163)
|
||||
|
||||
# It assumes the following flags are set:
|
||||
# CFLAGS Platform_file, Src_Dirs_I, Src_Dirs_V, SYSDEFS, AOUT, Obj_Files
|
||||
|
||||
# -- D. Ungar (5/97) from a file by Bill Bush
|
||||
|
||||
# Don't override the built-in $(MAKE).
|
||||
# Instead, use "gmake" (or "gnumake") from the command line. --Rose
|
||||
#MAKE = gmake
|
||||
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
TOPDIR = $(shell echo `pwd`)
|
||||
GENERATED = $(TOPDIR)/../generated
|
||||
VM = $(GAMMADIR)/src/share/vm
|
||||
Plat_File = $(Platform_file)
|
||||
CDG = cd $(GENERATED);
|
||||
|
||||
ifneq ($(USE_PRECOMPILED_HEADER),0)
|
||||
UpdatePCH = $(MAKE) -f vm.make $(PRECOMPILED_HEADER) $(MFLAGS)
|
||||
else
|
||||
UpdatePCH = \# precompiled header is not used
|
||||
endif
|
||||
|
||||
Cached_plat = $(GENERATED)/platform.current
|
||||
|
||||
AD_Dir = $(GENERATED)/adfiles
|
||||
ADLC = $(AD_Dir)/adlc
|
||||
AD_Spec = $(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(Platform_arch)/vm/$(Platform_arch_model).ad)
|
||||
AD_Src = $(call altsrc-replace,$(HS_COMMON_SRC)/share/vm/adlc)
|
||||
AD_Names = ad_$(Platform_arch_model).hpp ad_$(Platform_arch_model).cpp
|
||||
AD_Files = $(AD_Names:%=$(AD_Dir)/%)
|
||||
|
||||
# AD_Files_If_Required/COMPILER1 = ad_stuff
|
||||
AD_Files_If_Required/COMPILER2 = ad_stuff
|
||||
AD_Files_If_Required/TIERED = ad_stuff
|
||||
AD_Files_If_Required = $(AD_Files_If_Required/$(TYPE))
|
||||
|
||||
# Wierd argument adjustment for "gnumake -j..."
|
||||
adjust-mflags = $(GENERATED)/adjust-mflags
|
||||
# If SPEC is set, it's from configure and it's already controlling concurrency
|
||||
# for us. Skip setting -j with HOTSPOT_BUILD_JOBS.
|
||||
ifeq ($(SPEC), )
|
||||
MFLAGS-adjusted = -r `$(adjust-mflags) "$(MFLAGS)" "$(HOTSPOT_BUILD_JOBS)"`
|
||||
else
|
||||
MFLAGS-adjusted = -r $(MFLAGS)
|
||||
endif
|
||||
|
||||
|
||||
# default target: update lists, make vm
|
||||
# done in stages to force sequential order with parallel make
|
||||
#
|
||||
|
||||
default: vm_build_preliminaries the_vm
|
||||
@echo All done.
|
||||
|
||||
# This is an explicit dependency for the sake of parallel makes.
|
||||
vm_build_preliminaries: checks $(Cached_plat) $(AD_Files_If_Required) jvmti_stuff trace_stuff dtrace_stuff
|
||||
@# We need a null action here, so implicit rules don't get consulted.
|
||||
|
||||
$(Cached_plat): $(Plat_File)
|
||||
$(CDG) $(CP) $(Plat_File) $(Cached_plat)
|
||||
|
||||
# make AD files as necessary
|
||||
ad_stuff: $(Cached_plat) $(adjust-mflags)
|
||||
@$(MAKE) -f adlc.make $(MFLAGS-adjusted)
|
||||
|
||||
# generate JVMTI files from the spec
|
||||
jvmti_stuff: $(Cached_plat) $(adjust-mflags)
|
||||
@$(MAKE) -f jvmti.make $(MFLAGS-adjusted)
|
||||
|
||||
# generate trace files
|
||||
trace_stuff: jvmti_stuff $(Cached_plat) $(adjust-mflags)
|
||||
@$(MAKE) -f trace.make $(MFLAGS-adjusted)
|
||||
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# generate dtrace header files
|
||||
dtrace_stuff: $(Cached_plat) $(adjust-mflags)
|
||||
@$(MAKE) -f dtrace.make dtrace_stuff $(MFLAGS-adjusted) GENERATED=$(GENERATED)
|
||||
else
|
||||
dtrace_stuff:
|
||||
@# We need a null action here, so implicit rules don't get consulted.
|
||||
endif
|
||||
|
||||
# and the VM: must use other makefile with dependencies included
|
||||
|
||||
# We have to go to great lengths to get control over the -jN argument
|
||||
# to the recursive invocation of vm.make. The problem is that gnumake
|
||||
# resets -jN to -j1 for recursive runs. (How helpful.)
|
||||
# Note that the user must specify the desired parallelism level via a
|
||||
# command-line or environment variable name HOTSPOT_BUILD_JOBS.
|
||||
$(adjust-mflags): $(GAMMADIR)/make/$(Platform_os_family)/makefiles/adjust-mflags.sh
|
||||
@+rm -f $@ $@+
|
||||
@+cat $< > $@+
|
||||
@+chmod +x $@+
|
||||
@+mv $@+ $@
|
||||
|
||||
the_vm: vm_build_preliminaries $(adjust-mflags)
|
||||
+@$(UpdatePCH)
|
||||
@$(MAKE) -f vm.make $(MFLAGS-adjusted)
|
||||
|
||||
install : the_vm
|
||||
@$(MAKE) -f vm.make $@
|
||||
|
||||
# next rules support "make foo.[ois]"
|
||||
|
||||
%.o %.i %.s:
|
||||
+$(UpdatePCH)
|
||||
$(MAKE) -f vm.make $(MFLAGS) $@
|
||||
#$(MAKE) -f vm.make $@
|
||||
|
||||
# this should force everything to be rebuilt
|
||||
clean:
|
||||
rm -f $(GENERATED)/*.class
|
||||
$(MAKE) -f vm.make $(MFLAGS) clean
|
||||
|
||||
# just in case it doesn't, this should do it
|
||||
realclean:
|
||||
$(MAKE) -f vm.make $(MFLAGS) clean
|
||||
rm -fr $(GENERATED)
|
||||
|
||||
.PHONY: default vm_build_preliminaries
|
||||
.PHONY: lists ad_stuff jvmti_stuff the_vm clean realclean
|
||||
.PHONY: checks check_os_version install
|
||||
|
||||
.NOTPARALLEL:
|
@ -1,119 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2003, 2016, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# This makefile (trace.make) is included from the trace.make in the
|
||||
# build directories.
|
||||
#
|
||||
# It knows how to build and run the tools to generate trace files.
|
||||
|
||||
include $(GAMMADIR)/make/bsd/makefiles/rules.make
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
# #########################################################################
|
||||
|
||||
HAS_ALT_SRC := false
|
||||
ifndef OPENJDK
|
||||
ifneq ($(wildcard $(HS_ALT_SRC)/share/vm/trace), )
|
||||
HAS_ALT_SRC := true
|
||||
endif
|
||||
endif
|
||||
|
||||
TOPDIR = $(shell echo `pwd`)
|
||||
GENERATED = $(TOPDIR)/../generated
|
||||
JvmtiOutDir = $(GENERATED)/jvmtifiles
|
||||
TraceOutDir = $(GENERATED)/tracefiles
|
||||
|
||||
TraceAltSrcDir = $(HS_ALT_SRC)/share/vm/trace
|
||||
TraceSrcDir = $(HS_COMMON_SRC)/share/vm/trace
|
||||
|
||||
# set VPATH so make knows where to look for source files
|
||||
Src_Dirs_V += $(TraceSrcDir) $(TraceAltSrcDir)
|
||||
VPATH += $(Src_Dirs_V:%=%:)
|
||||
|
||||
TraceGeneratedNames = \
|
||||
traceEventClasses.hpp \
|
||||
traceEventIds.hpp \
|
||||
traceTypes.hpp
|
||||
|
||||
ifeq ($(HAS_ALT_SRC), true)
|
||||
TraceGeneratedNames += \
|
||||
traceRequestables.hpp \
|
||||
traceEventControl.hpp
|
||||
endif
|
||||
|
||||
TraceGeneratedFiles = $(TraceGeneratedNames:%=$(TraceOutDir)/%)
|
||||
|
||||
XSLT = $(REMOTE) $(RUN.JAVA) -classpath $(JvmtiOutDir) jvmtiGen
|
||||
|
||||
TraceXml = $(TraceSrcDir)/trace.xml
|
||||
ifeq ($(HAS_ALT_SRC), true)
|
||||
TraceXml = $(TraceAltSrcDir)/trace.xml
|
||||
endif
|
||||
|
||||
XML_DEPS = $(TraceXml) $(TraceSrcDir)/tracetypes.xml \
|
||||
$(TraceSrcDir)/trace.dtd $(TraceSrcDir)/xinclude.mod \
|
||||
$(TraceSrcDir)/tracerelationdecls.xml $(TraceSrcDir)/traceevents.xml
|
||||
ifeq ($(HAS_ALT_SRC), true)
|
||||
XML_DEPS += $(TraceAltSrcDir)/traceeventscustom.xml \
|
||||
$(TraceAltSrcDir)/traceeventtypes.xml
|
||||
endif
|
||||
|
||||
.PHONY: all clean cleanall
|
||||
|
||||
# #########################################################################
|
||||
|
||||
all: $(TraceGeneratedFiles)
|
||||
|
||||
GENERATE_CODE= \
|
||||
$(QUIETLY) echo $(LOG_INFO) Generating $@; \
|
||||
$(XSLT) -IN $(word 1,$^) -XSL $(word 2,$^) -OUT $@
|
||||
|
||||
$(TraceOutDir)/traceEventIds.hpp: $(TraceXml) $(TraceSrcDir)/traceEventIds.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
$(TraceOutDir)/traceTypes.hpp: $(TraceXml) $(TraceSrcDir)/traceTypes.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
ifeq ($(HAS_ALT_SRC), false)
|
||||
|
||||
$(TraceOutDir)/traceEventClasses.hpp: $(TraceXml) $(TraceSrcDir)/traceEventClasses.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
else
|
||||
|
||||
$(TraceOutDir)/traceEventClasses.hpp: $(TraceXml) $(TraceAltSrcDir)/traceEventClasses.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
$(TraceOutDir)/traceRequestables.hpp: $(TraceXml) $(TraceAltSrcDir)/traceRequestables.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
$(TraceOutDir)/traceEventControl.hpp: $(TraceXml) $(TraceAltSrcDir)/traceEventControl.xsl $(XML_DEPS)
|
||||
$(GENERATE_CODE)
|
||||
|
||||
endif
|
||||
|
||||
# #########################################################################
|
||||
|
||||
clean cleanall:
|
||||
rm $(TraceGeneratedFiles)
|
@ -1,126 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2006, 2013, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# macosx universal builds
|
||||
universal_product:
|
||||
$(MAKE) MACOSX_UNIVERSAL=true all_product_universal
|
||||
universal_optimized:
|
||||
$(MAKE) MACOSX_UNIVERSAL=true all_optimized_universal
|
||||
universal_fastdebug:
|
||||
$(MAKE) MACOSX_UNIVERSAL=true all_fastdebug_universal
|
||||
universal_debug:
|
||||
$(MAKE) MACOSX_UNIVERSAL=true all_debug_universal
|
||||
|
||||
|
||||
# Universal builds include 1 or more architectures in a single binary
|
||||
all_product_universal:
|
||||
# $(QUIETLY) $(MAKE) ARCH_DATA_MODEL=32 $(COMMON_VM_PRODUCT_TARGETS)
|
||||
$(QUIETLY) $(MAKE) ARCH_DATA_MODEL=64 $(COMMON_VM_PRODUCT_TARGETS)
|
||||
$(QUIETLY) $(MAKE) BUILD_FLAVOR=product EXPORT_SUBDIR= universalize
|
||||
all_optimized_universal:
|
||||
# $(QUIETLY) $(MAKE) ARCH_DATA_MODEL=32 $(COMMON_VM_OPTIMIZED_TARGETS)
|
||||
$(QUIETLY) $(MAKE) ARCH_DATA_MODEL=64 $(COMMON_VM_OPTIMIZED_TARGETS)
|
||||
$(QUIETLY) $(MAKE) BUILD_FLAVOR=optimized EXPORT_SUBDIR=/optimized universalize
|
||||
all_fastdebug_universal:
|
||||
# $(QUIETLY) $(MAKE) ARCH_DATA_MODEL=32 $(COMMON_VM_FASTDEBUG_TARGETS)
|
||||
$(QUIETLY) $(MAKE) ARCH_DATA_MODEL=64 $(COMMON_VM_FASTDEBUG_TARGETS)
|
||||
$(QUIETLY) $(MAKE) BUILD_FLAVOR=fastdebug EXPORT_SUBDIR=/fastdebug universalize
|
||||
all_debug_universal:
|
||||
# $(QUIETLY) $(MAKE) ARCH_DATA_MODEL=32 $(COMMON_VM_DEBUG_TARGETS)
|
||||
$(QUIETLY) $(MAKE) ARCH_DATA_MODEL=64 $(COMMON_VM_DEBUG_TARGETS)
|
||||
$(QUIETLY) $(MAKE) BUILD_FLAVOR=debug EXPORT_SUBDIR=/debug universalize
|
||||
|
||||
|
||||
# Consolidate architecture builds into a single Universal binary
|
||||
universalize: $(UNIVERSAL_LIPO_LIST) $(UNIVERSAL_COPY_LIST)
|
||||
$(RM) -r $(EXPORT_PATH)/lib/{i386,amd64}
|
||||
|
||||
LIPO ?= lipo
|
||||
|
||||
# Package built libraries in a universal binary
|
||||
$(UNIVERSAL_LIPO_LIST):
|
||||
BUILT_LIPO_FILES="`find $(EXPORT_LIB_DIR)/{i386,amd64}/$(subst $(EXPORT_LIB_DIR)/,,$@) 2>/dev/null`" || test $$? = "1"; \
|
||||
if [ -n "$${BUILT_LIPO_FILES}" ]; then \
|
||||
$(MKDIR) -p $(shell dirname $@); \
|
||||
$(LIPO) -create -output $@ $${BUILT_LIPO_FILES}; \
|
||||
fi
|
||||
|
||||
|
||||
# Copy built non-universal binaries in place
|
||||
# - copies directories; including empty dirs
|
||||
# - copies files, symlinks, other non-directory files
|
||||
$(UNIVERSAL_COPY_LIST):
|
||||
BUILT_COPY_FILES="`find $(EXPORT_LIB_DIR)/{i386,amd64}/$(subst $(EXPORT_LIB_DIR)/,,$@) -prune 2>/dev/null`" || test $$? = "1"; \
|
||||
if [ -n "$${BUILT_COPY_FILES}" ]; then \
|
||||
for i in $${BUILT_COPY_FILES}; do \
|
||||
$(MKDIR) -p $(shell dirname $@); \
|
||||
$(CP) -R $${i} $@; \
|
||||
done; \
|
||||
fi
|
||||
|
||||
|
||||
# Replace arch specific binaries with universal binaries
|
||||
# Do not touch lib/{client,server}/libjsig.$(LIBRARY_SUFFIX)
|
||||
# That symbolic link belongs to the 'jdk' build.
|
||||
export_universal:
|
||||
$(RM) -r $(EXPORT_PATH)/lib/{i386,amd64}
|
||||
$(RM) -r $(JDK_IMAGE_DIR)/lib/{i386,amd64}
|
||||
($(CD) $(EXPORT_PATH) && \
|
||||
$(TAR) -cf - *) | \
|
||||
($(CD) $(JDK_IMAGE_DIR) && $(TAR) -xpf -)
|
||||
|
||||
|
||||
# Overlay universal binaries
|
||||
# Do not touch lib/{client,server}/libjsig.$(LIBRARY_SUFFIX)
|
||||
# That symbolic link belongs to the 'jdk' build.
|
||||
copy_universal:
|
||||
$(RM) -r $(JDK_IMAGE_DIR)$(COPY_SUBDIR)/lib/{i386,amd64}
|
||||
($(CD) $(EXPORT_PATH)$(COPY_SUBDIR) && \
|
||||
$(TAR) -cf - *) | \
|
||||
($(CD) $(JDK_IMAGE_DIR)$(COPY_SUBDIR) && $(TAR) -xpf -)
|
||||
|
||||
|
||||
# Additional processing for universal builds
|
||||
export_product_jdk::
|
||||
$(MAKE) EXPORT_SUBDIR= export_universal
|
||||
export_optimized_jdk::
|
||||
$(MAKE) EXPORT_SUBDIR=/optimized export_universal
|
||||
export_fastdebug_jdk::
|
||||
$(MAKE) EXPORT_SUBDIR=/fastdebug export_universal
|
||||
export_debug_jdk::
|
||||
$(MAKE) EXPORT_SUBDIR=/debug export_universal
|
||||
copy_product_jdk::
|
||||
$(MAKE) COPY_SUBDIR= copy_universal
|
||||
copy_optimized_jdk::
|
||||
$(MAKE) COPY_SUBDIR=/optimized copy_universal
|
||||
copy_fastdebug_jdk::
|
||||
$(MAKE) COPY_SUBDIR=/fastdebug copy_universal
|
||||
copy_debug_jdk::
|
||||
$(MAKE) COPY_SUBDIR=/debug copy_universal
|
||||
|
||||
.PHONY: universal_product universal_fastdebug universal_debug \
|
||||
all_product_universal all_fastdebug_universal all_debug_universal \
|
||||
universal_optimized all_optimized_universal \
|
||||
universalize export_universal copy_universal \
|
||||
$(UNIVERSAL_LIPO_LIST) $(UNIVERSAL_COPY_LIST)
|
@ -1,438 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Rules to build JVM and related libraries, included from vm.make in the build
|
||||
# directory.
|
||||
|
||||
# Common build rules.
|
||||
MAKEFILES_DIR=$(GAMMADIR)/make/$(Platform_os_family)/makefiles
|
||||
include $(MAKEFILES_DIR)/rules.make
|
||||
include $(GAMMADIR)/make/altsrc.make
|
||||
|
||||
default: build
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# Defs
|
||||
|
||||
GENERATED = ../generated
|
||||
DEP_DIR = $(GENERATED)/dependencies
|
||||
|
||||
# reads the generated files defining the set of .o's and the .o .h dependencies
|
||||
-include $(DEP_DIR)/*.d
|
||||
|
||||
# read machine-specific adjustments (%%% should do this via buildtree.make?)
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
include $(MAKEFILES_DIR)/zeroshark.make
|
||||
else
|
||||
include $(MAKEFILES_DIR)/$(BUILDARCH).make
|
||||
endif
|
||||
|
||||
# set VPATH so make knows where to look for source files
|
||||
# Src_Dirs_V is everything in src/share/vm/*, plus the right os/*/vm and cpu/*/vm
|
||||
# The adfiles directory contains ad_<arch>.[ch]pp.
|
||||
# The jvmtifiles directory contains jvmti*.[ch]pp
|
||||
Src_Dirs_V += $(GENERATED)/adfiles $(GENERATED)/jvmtifiles $(GENERATED)/tracefiles
|
||||
VPATH += $(Src_Dirs_V:%=%:)
|
||||
|
||||
# set INCLUDES for C preprocessor.
|
||||
Src_Dirs_I += $(GENERATED)
|
||||
# The order is important for the precompiled headers to work.
|
||||
INCLUDES += $(PRECOMPILED_HEADER_DIR:%=-I%) $(Src_Dirs_I:%=-I%)
|
||||
|
||||
# SYMFLAG is used by jsig.make
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
# always build with debug info when we can create .dSYM/.debuginfo files
|
||||
SYMFLAG = -g
|
||||
else
|
||||
ifeq (${VERSION}, debug)
|
||||
SYMFLAG = -g
|
||||
else
|
||||
SYMFLAG =
|
||||
endif
|
||||
endif
|
||||
|
||||
# The following variables are defined in the generated flags.make file.
|
||||
JDK_VER_DEFS = -DVERSION_MAJOR=$(VERSION_MAJOR) \
|
||||
-DVERSION_MINOR=$(VERSION_MINOR) \
|
||||
-DVERSION_SECURITY=$(VERSION_SECURITY) \
|
||||
-DVERSION_PATCH=$(VERSION_PATCH) \
|
||||
-DVERSION_BUILD=$(VERSION_BUILD)
|
||||
VM_VER_DEFS = -DHOTSPOT_VERSION_STRING="\"$(HOTSPOT_VERSION_STRING)\"" \
|
||||
-DVERSION_STRING="\"$(VERSION_STRING)\"" \
|
||||
-DDEBUG_LEVEL="\"$(DEBUG_LEVEL)\"" \
|
||||
$(JDK_VER_DEFS)
|
||||
HS_LIB_ARCH = -DHOTSPOT_LIB_ARCH=\"$(LIBARCH)\"
|
||||
BUILD_USER = -DHOTSPOT_BUILD_USER="\"$(HOTSPOT_BUILD_USER)\""
|
||||
VM_DISTRO = -DHOTSPOT_VM_DISTRO="\"$(HOTSPOT_VM_DISTRO)\""
|
||||
|
||||
CXXFLAGS = \
|
||||
${SYSDEFS} \
|
||||
${INCLUDES} \
|
||||
${BUILD_USER} \
|
||||
${HS_LIB_ARCH} \
|
||||
${VM_DISTRO}
|
||||
|
||||
# This is VERY important! The version define must only be supplied to vm_version.o
|
||||
# If not, ccache will not re-use the cache at all, since the version string might contain
|
||||
# a time and date.
|
||||
CXXFLAGS/vm_version.o += ${VM_VER_DEFS}
|
||||
|
||||
CXXFLAGS/BYFILE = $(CXXFLAGS/$@)
|
||||
|
||||
# File specific flags
|
||||
CXXFLAGS += $(CXXFLAGS/BYFILE)
|
||||
|
||||
ifdef DEFAULT_LIBPATH
|
||||
CXXFLAGS += -DDEFAULT_LIBPATH="\"$(DEFAULT_LIBPATH)\""
|
||||
endif
|
||||
|
||||
# CFLAGS_WARN holds compiler options to suppress/enable warnings.
|
||||
CFLAGS += $(CFLAGS_WARN/BYFILE)
|
||||
|
||||
# Do not use C++ exception handling
|
||||
CFLAGS += $(CFLAGS/NOEX)
|
||||
|
||||
# Extra flags from gnumake's invocation or environment
|
||||
CFLAGS += $(EXTRA_CFLAGS)
|
||||
LFLAGS += $(EXTRA_CFLAGS)
|
||||
|
||||
# Don't set excutable bit on stack segment
|
||||
# the same could be done by separate execstack command
|
||||
# Darwin is non-executable-stack by default
|
||||
ifneq ($(OS_VENDOR), Darwin)
|
||||
LFLAGS += -Xlinker -z -Xlinker noexecstack
|
||||
endif
|
||||
|
||||
LIBS += -lm
|
||||
|
||||
ifeq ($(USE_CLANG),)
|
||||
LIBS += -pthread
|
||||
endif
|
||||
|
||||
# By default, link the *.o into the library, not the executable.
|
||||
LINK_INTO$(LINK_INTO) = LIBJVM
|
||||
|
||||
JDK_LIBDIR = $(JAVA_HOME)/lib/$(LIBARCH)
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# jvm_db & dtrace
|
||||
include $(MAKEFILES_DIR)/dtrace.make
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# JVM
|
||||
|
||||
JVM = jvm
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
LIBJVM = lib$(JVM).$(LIBRARY_SUFFIX)
|
||||
CFLAGS += -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE
|
||||
|
||||
LIBJVM_DEBUGINFO = lib$(JVM).$(LIBRARY_SUFFIX).dSYM
|
||||
LIBJVM_DIZ = lib$(JVM).diz
|
||||
else
|
||||
LIBJVM = lib$(JVM).so
|
||||
|
||||
LIBJVM_DEBUGINFO = lib$(JVM).debuginfo
|
||||
LIBJVM_DIZ = lib$(JVM).diz
|
||||
endif
|
||||
|
||||
SPECIAL_PATHS:=adlc c1 gc opto shark libadt
|
||||
|
||||
SOURCE_PATHS=\
|
||||
$(shell find $(HS_COMMON_SRC)/share/vm/* -type d \! \
|
||||
\( -name DUMMY $(foreach dir,$(SPECIAL_PATHS),-o -name $(dir)) \))
|
||||
SOURCE_PATHS+=$(HS_COMMON_SRC)/os/$(Platform_os_family)/vm
|
||||
SOURCE_PATHS+=$(HS_COMMON_SRC)/os/posix/vm
|
||||
SOURCE_PATHS+=$(HS_COMMON_SRC)/cpu/$(Platform_arch)/vm
|
||||
SOURCE_PATHS+=$(HS_COMMON_SRC)/os_cpu/$(Platform_os_arch)/vm
|
||||
|
||||
CORE_PATHS=$(foreach path,$(SOURCE_PATHS),$(call altsrc,$(path)) $(path))
|
||||
CORE_PATHS+=$(GENERATED)/jvmtifiles $(GENERATED)/tracefiles
|
||||
|
||||
ifneq ($(INCLUDE_TRACE), false)
|
||||
CORE_PATHS+=$(shell if [ -d $(HS_ALT_SRC)/share/vm/jfr ]; then \
|
||||
find $(HS_ALT_SRC)/share/vm/jfr -type d; \
|
||||
fi)
|
||||
endif
|
||||
|
||||
COMPILER1_PATHS := $(call altsrc,$(HS_COMMON_SRC)/share/vm/c1)
|
||||
COMPILER1_PATHS += $(HS_COMMON_SRC)/share/vm/c1
|
||||
|
||||
COMPILER2_PATHS := $(call altsrc,$(HS_COMMON_SRC)/share/vm/opto)
|
||||
COMPILER2_PATHS += $(call altsrc,$(HS_COMMON_SRC)/share/vm/libadt)
|
||||
COMPILER2_PATHS += $(HS_COMMON_SRC)/share/vm/opto
|
||||
COMPILER2_PATHS += $(HS_COMMON_SRC)/share/vm/libadt
|
||||
COMPILER2_PATHS += $(GENERATED)/adfiles
|
||||
|
||||
SHARK_PATHS := $(GAMMADIR)/src/share/vm/shark
|
||||
|
||||
# Include dirs per type.
|
||||
Src_Dirs/CORE := $(CORE_PATHS)
|
||||
Src_Dirs/COMPILER1 := $(CORE_PATHS) $(COMPILER1_PATHS)
|
||||
Src_Dirs/COMPILER2 := $(CORE_PATHS) $(COMPILER2_PATHS)
|
||||
Src_Dirs/TIERED := $(CORE_PATHS) $(COMPILER1_PATHS) $(COMPILER2_PATHS)
|
||||
Src_Dirs/ZERO := $(CORE_PATHS)
|
||||
Src_Dirs/SHARK := $(CORE_PATHS) $(SHARK_PATHS)
|
||||
Src_Dirs := $(Src_Dirs/$(TYPE))
|
||||
|
||||
COMPILER2_SPECIFIC_FILES := opto libadt bcEscapeAnalyzer.cpp c2_\* runtime_\*
|
||||
COMPILER1_SPECIFIC_FILES := c1_\*
|
||||
SHARK_SPECIFIC_FILES := shark
|
||||
ZERO_SPECIFIC_FILES := zero
|
||||
|
||||
# Always exclude these.
|
||||
Src_Files_EXCLUDE += jsig.c jvmtiEnvRecommended.cpp jvmtiEnvStub.cpp
|
||||
|
||||
# Exclude per type.
|
||||
Src_Files_EXCLUDE/CORE := $(COMPILER1_SPECIFIC_FILES) $(COMPILER2_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES) ciTypeFlow.cpp
|
||||
Src_Files_EXCLUDE/COMPILER1 := $(COMPILER2_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES) ciTypeFlow.cpp
|
||||
Src_Files_EXCLUDE/COMPILER2 := $(COMPILER1_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES)
|
||||
Src_Files_EXCLUDE/TIERED := $(ZERO_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES)
|
||||
Src_Files_EXCLUDE/ZERO := $(COMPILER1_SPECIFIC_FILES) $(COMPILER2_SPECIFIC_FILES) $(SHARK_SPECIFIC_FILES) ciTypeFlow.cpp
|
||||
Src_Files_EXCLUDE/SHARK := $(COMPILER1_SPECIFIC_FILES) $(COMPILER2_SPECIFIC_FILES) $(ZERO_SPECIFIC_FILES)
|
||||
|
||||
Src_Files_EXCLUDE += $(Src_Files_EXCLUDE/$(TYPE))
|
||||
|
||||
# Special handling of arch model.
|
||||
ifeq ($(Platform_arch_model), x86_32)
|
||||
Src_Files_EXCLUDE += \*x86_64\*
|
||||
endif
|
||||
ifeq ($(Platform_arch_model), x86_64)
|
||||
Src_Files_EXCLUDE += \*x86_32\*
|
||||
endif
|
||||
|
||||
# Locate all source files in the given directory, excluding files in Src_Files_EXCLUDE.
|
||||
define findsrc
|
||||
$(notdir $(shell find $(1)/. ! -name . -prune \
|
||||
-a \( -name \*.c -o -name \*.cpp -o -name \*.s \) \
|
||||
-a ! \( -name DUMMY $(addprefix -o -name ,$(Src_Files_EXCLUDE)) \)))
|
||||
endef
|
||||
|
||||
Src_Files := $(foreach e,$(Src_Dirs),$(call findsrc,$(e)))
|
||||
|
||||
Obj_Files = $(sort $(addsuffix .o,$(basename $(Src_Files))))
|
||||
|
||||
JVM_OBJ_FILES = $(Obj_Files)
|
||||
|
||||
vm_version.o: $(filter-out vm_version.o,$(JVM_OBJ_FILES))
|
||||
|
||||
MAPFILE_SHARE := $(GAMMADIR)/make/share/makefiles/mapfile-vers
|
||||
|
||||
MAPFILE_EXT_SRC := $(HS_ALT_MAKE)/share/makefiles/mapfile-ext
|
||||
ifneq ("$(wildcard $(MAPFILE_EXT_SRC))","")
|
||||
MAPFILE_EXT := $(MAPFILE_EXT_SRC)
|
||||
endif
|
||||
|
||||
# For Darwin: add _ prefix and remove trailing ;
|
||||
mapfile_extra: $(MAPFILE_SHARE) $(MAPFILE_EXT)
|
||||
rm -f $@
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
cat $(MAPFILE_SHARE) $(MAPFILE_EXT) | \
|
||||
sed -e 's/#.*//g' -e 's/[ ]*//g' -e 's/;//g' | \
|
||||
awk '{ if ($$0 ~ ".") { print "\t\t_" $$0 } }' \
|
||||
> $@
|
||||
else
|
||||
cat $(MAPFILE_SHARE) $(MAPFILE_EXT) > $@
|
||||
endif
|
||||
|
||||
mapfile : $(MAPFILE) mapfile_extra vm.def
|
||||
rm -f $@
|
||||
awk '{ if ($$0 ~ "INSERT VTABLE SYMBOLS HERE") \
|
||||
{ system ("cat mapfile_extra vm.def"); } \
|
||||
else \
|
||||
{ print $$0 } \
|
||||
}' > $@ < $(MAPFILE)
|
||||
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
EXPORTED_SYMBOLS = libjvm.symbols
|
||||
|
||||
libjvm.symbols : mapfile
|
||||
$(CP) mapfile libjvm.symbols
|
||||
|
||||
else
|
||||
EXPORTED_SYMBOLS =
|
||||
endif
|
||||
|
||||
mapfile_reorder : mapfile $(REORDERFILE)
|
||||
rm -f $@
|
||||
cat $^ > $@
|
||||
|
||||
vm.def: $(Res_Files) $(Obj_Files)
|
||||
sh $(GAMMADIR)/make/bsd/makefiles/build_vm_def.sh *.o > $@
|
||||
|
||||
mapfile_ext:
|
||||
rm -f $@
|
||||
touch $@
|
||||
if [ -f $(HS_ALT_MAKE)/bsd/makefiles/mapfile-ext ]; then \
|
||||
cat $(HS_ALT_MAKE)/bsd/makefiles/mapfile-ext > $@; \
|
||||
fi
|
||||
|
||||
STATIC_CXX = false
|
||||
|
||||
ifeq ($(LINK_INTO),AOUT)
|
||||
LIBJVM.o =
|
||||
LIBJVM_MAPFILE =
|
||||
LIBS_VM = $(LIBS)
|
||||
else
|
||||
LIBJVM.o = $(JVM_OBJ_FILES)
|
||||
LIBJVM_MAPFILE$(LDNOMAP) = mapfile_reorder
|
||||
LFLAGS_VM$(LDNOMAP) += $(MAPFLAG:FILENAME=$(LIBJVM_MAPFILE))
|
||||
LFLAGS_VM += $(SONAMEFLAG:SONAME=$(LIBJVM))
|
||||
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
ifneq ($(STATIC_BUILD),true)
|
||||
LFLAGS_VM += -Xlinker -rpath -Xlinker @loader_path/.
|
||||
LFLAGS_VM += -Xlinker -rpath -Xlinker @loader_path/..
|
||||
LFLAGS_VM += -Xlinker -install_name -Xlinker @rpath/$(@F)
|
||||
endif
|
||||
else
|
||||
LFLAGS_VM += -Wl,-z,defs
|
||||
endif
|
||||
|
||||
# JVM is statically linked with libgcc[_s] and libstdc++; this is needed to
|
||||
# get around library dependency and compatibility issues. Must use gcc not
|
||||
# g++ to link.
|
||||
ifeq ($(STATIC_CXX), true)
|
||||
LFLAGS_VM += $(STATIC_LIBGCC)
|
||||
LIBS_VM += $(STATIC_STDCXX)
|
||||
LINK_VM = $(LINK_LIB.CC)
|
||||
else
|
||||
LINK_VM = $(LINK_LIB.CXX)
|
||||
endif
|
||||
|
||||
LIBS_VM += $(LIBS)
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_ZERO), true)
|
||||
LIBS_VM += $(LIBFFI_LIBS)
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_ZEROSHARK), true)
|
||||
LIBS_VM += $(LIBFFI_LIBS) $(LLVM_LIBS)
|
||||
LFLAGS_VM += $(LLVM_LDFLAGS)
|
||||
endif
|
||||
|
||||
|
||||
# rule for building precompiled header
|
||||
$(PRECOMPILED_HEADER):
|
||||
$(QUIETLY) echo $(LOG_INFO) Generating precompiled header $@
|
||||
$(QUIETLY) mkdir -p $(PRECOMPILED_HEADER_DIR)
|
||||
$(QUIETLY) rm -f $@
|
||||
$(QUIETLY) $(COMPILE.CXX) $(DEPFLAGS) -x c++-header $(PRECOMPILED_HEADER_SRC) -o $@ $(COMPILE_DONE)
|
||||
|
||||
# making the library:
|
||||
|
||||
ifneq ($(JVM_BASE_ADDR),)
|
||||
# By default shared library is linked at base address == 0. Modify the
|
||||
# linker script if JVM prefers a different base location. It can also be
|
||||
# implemented with 'prelink -r'. But 'prelink' is not (yet) available on
|
||||
# our build platform (AS-2.1).
|
||||
LD_SCRIPT = libjvm.so.lds
|
||||
$(LD_SCRIPT): $(LIBJVM_MAPFILE)
|
||||
$(QUIETLY) { \
|
||||
rm -rf $@; \
|
||||
$(LINK_VM) -Wl,--verbose $(LFLAGS_VM) 2>&1 | \
|
||||
sed -e '/^======/,/^======/!d' \
|
||||
-e '/^======/d' \
|
||||
-e 's/0\( + SIZEOF_HEADERS\)/$(JVM_BASE_ADDR)\1/' \
|
||||
> $@; \
|
||||
}
|
||||
LD_SCRIPT_FLAG = -Wl,-T,$(LD_SCRIPT)
|
||||
endif
|
||||
|
||||
$(LIBJVM): $(LIBJVM.o) $(LIBJVM_MAPFILE) $(LD_SCRIPT)
|
||||
ifeq ($(STATIC_BUILD),true)
|
||||
echo Linking static vm...;
|
||||
$(LINK_LIB.CC) $@ $(LIBJVM.o)
|
||||
else
|
||||
$(QUIETLY) { \
|
||||
echo $(LOG_INFO) Linking vm...; \
|
||||
$(LINK_LIB.CXX/PRE_HOOK) \
|
||||
$(LINK_VM) $(LD_SCRIPT_FLAG) \
|
||||
$(LFLAGS_VM) -o $@ $(sort $(LIBJVM.o)) $(LIBS_VM); \
|
||||
$(LINK_LIB.CXX/POST_HOOK) \
|
||||
rm -f $@.1; ln -s $@ $@.1; \
|
||||
}
|
||||
|
||||
endif
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(DSYMUTIL) $@
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(ZIPEXE) -q -r -y $(LIBJVM_DIZ) $(LIBJVM_DEBUGINFO)
|
||||
$(RM) -r $(LIBJVM_DEBUGINFO)
|
||||
endif
|
||||
else
|
||||
$(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJVM_DEBUGINFO)
|
||||
$(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJVM_DEBUGINFO) $@
|
||||
ifeq ($(STRIP_POLICY),all_strip)
|
||||
$(QUIETLY) $(STRIP) $@
|
||||
else
|
||||
ifeq ($(STRIP_POLICY),min_strip)
|
||||
$(QUIETLY) $(STRIP) -g $@
|
||||
# implied else here is no stripping at all
|
||||
endif
|
||||
endif
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
$(ZIPEXE) -q -y $(LIBJVM_DIZ) $(LIBJVM_DEBUGINFO)
|
||||
$(RM) $(LIBJVM_DEBUGINFO)
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
DEST_SUBDIR = $(JDK_LIBDIR)/$(VM_SUBDIR)
|
||||
DEST_JVM = $(DEST_SUBDIR)/$(LIBJVM)
|
||||
DEST_JVM_DEBUGINFO = $(DEST_SUBDIR)/$(LIBJVM_DEBUGINFO)
|
||||
DEST_JVM_DIZ = $(DEST_SUBDIR)/$(LIBJVM_DIZ)
|
||||
|
||||
install_jvm: $(LIBJVM)
|
||||
@echo "Copying $(LIBJVM) to $(DEST_JVM)"
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
$(QUIETLY) test ! -d $(LIBJVM_DEBUGINFO) || \
|
||||
$(CP) -f -r $(LIBJVM_DEBUGINFO) $(DEST_JVM_DEBUGINFO)
|
||||
else
|
||||
$(QUIETLY) test ! -f $(LIBJVM_DEBUGINFO) || \
|
||||
$(CP) -f $(LIBJVM_DEBUGINFO) $(DEST_JVM_DEBUGINFO)
|
||||
endif
|
||||
$(QUIETLY) test ! -f $(LIBJVM_DIZ) || \
|
||||
$(CP) -f $(LIBJVM_DIZ) $(DEST_JVM_DIZ)
|
||||
$(QUIETLY) $(CP) -f $(LIBJVM) $(DEST_JVM) && echo "Done"
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# Other files
|
||||
|
||||
# Signal interposition library
|
||||
include $(MAKEFILES_DIR)/jsig.make
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
ifeq ($(OS_VENDOR), Darwin)
|
||||
# no libjvm_db for macosx
|
||||
build: $(LIBJVM) $(LAUNCHER) $(LIBJSIG) dtraceCheck $(EXPORTED_SYMBOLS)
|
||||
echo "Doing vm.make build:"
|
||||
else
|
||||
build: $(LIBJVM) $(LAUNCHER) $(LIBJSIG) $(LIBJVM_DB) $(EXPORTED_SYMBOLS)
|
||||
endif
|
||||
|
||||
install: install_jvm install_jsigs
|
||||
|
||||
.PHONY: default build install install_jvm
|
@ -1,32 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright 2009 Red Hat, Inc.
|
||||
# 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Setup for Zero (non-Shark) version of VM
|
||||
|
||||
# Select which files to use (in top.make)
|
||||
TYPE = ZERO
|
||||
|
||||
# Install libjvm.so, etc in in server directory.
|
||||
VM_SUBDIR = server
|
@ -1,62 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2003, 2005, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright 2007, 2008 Red Hat, Inc.
|
||||
# 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.
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
#
|
||||
|
||||
# Setup common to Zero (non-Shark) and Shark versions of VM
|
||||
|
||||
# The copied fdlibm routines in sharedRuntimeTrig.o must not be optimized
|
||||
OPT_CFLAGS/sharedRuntimeTrig.o = $(OPT_CFLAGS/NOOPT)
|
||||
# The copied fdlibm routines in sharedRuntimeTrans.o must not be optimized
|
||||
OPT_CFLAGS/sharedRuntimeTrans.o = $(OPT_CFLAGS/NOOPT)
|
||||
|
||||
# Specify that the CPU is little endian, if necessary
|
||||
ifeq ($(ZERO_ENDIANNESS), little)
|
||||
CFLAGS += -DVM_LITTLE_ENDIAN
|
||||
endif
|
||||
|
||||
# Specify that the CPU is 64 bit, if necessary
|
||||
ifeq ($(ARCH_DATA_MODEL), 64)
|
||||
CFLAGS += -D_LP64=1
|
||||
endif
|
||||
|
||||
# Specify the path to the FFI headers
|
||||
ifdef ALT_PACKAGE_PATH
|
||||
PACKAGE_PATH = $(ALT_PACKAGE_PATH)
|
||||
else
|
||||
ifeq ($(OS_VENDOR),Apple)
|
||||
PACKAGE_PATH = /opt/local
|
||||
else
|
||||
ifeq ($(OS_VENDOR),NetBSD)
|
||||
PACKAGE_PATH = /usr/pkg
|
||||
LIBS += -Wl,-R${PACKAGE_PATH}/lib
|
||||
else
|
||||
PACKAGE_PATH = /usr/local
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
CFLAGS += -I$(PACKAGE_PATH)/include
|
||||
LIBS += -L$(PACKAGE_PATH)/lib -lffi
|
||||
|
||||
OPT_CFLAGS/compactingPermGenGen.o = -O1
|
@ -1,15 +0,0 @@
|
||||
os_family = bsd
|
||||
|
||||
arch = x86
|
||||
|
||||
arch_model = x86_64
|
||||
|
||||
os_arch = bsd_x86
|
||||
|
||||
os_arch_model = bsd_x86_64
|
||||
|
||||
lib_arch = amd64
|
||||
|
||||
compiler = gcc
|
||||
|
||||
sysdefs = -D_ALLBSD_SOURCE -D_GNU_SOURCE -DAMD64
|
@ -1,17 +0,0 @@
|
||||
os_family = bsd
|
||||
|
||||
arch = x86
|
||||
|
||||
arch_model = x86_64
|
||||
|
||||
os_arch = bsd_x86
|
||||
|
||||
os_arch_model = bsd_x86_64
|
||||
|
||||
lib_arch = amd64
|
||||
|
||||
compiler = sparcWorks
|
||||
|
||||
gnu_dis_arch = amd64
|
||||
|
||||
sysdefs = -D_ALLBSD_SOURCE -DSPARC_WORKS -D_GNU_SOURCE -DAMD64
|
@ -1,15 +0,0 @@
|
||||
os_family = bsd
|
||||
|
||||
arch = x86
|
||||
|
||||
arch_model = x86_32
|
||||
|
||||
os_arch = bsd_x86
|
||||
|
||||
os_arch_model = bsd_x86_32
|
||||
|
||||
lib_arch = i386
|
||||
|
||||
compiler = gcc
|
||||
|
||||
sysdefs = -D_ALLBSD_SOURCE -D_GNU_SOURCE -DIA32
|
@ -1,17 +0,0 @@
|
||||
os_family = bsd
|
||||
|
||||
arch = x86
|
||||
|
||||
arch_model = x86_32
|
||||
|
||||
os_arch = bsd_x86
|
||||
|
||||
os_arch_model = bsd_x86_32
|
||||
|
||||
lib_arch = i386
|
||||
|
||||
compiler = sparcWorks
|
||||
|
||||
gnu_dis_arch = i386
|
||||
|
||||
sysdefs = -D_ALLBSD_SOURCE -DSPARC_WORKS -D_GNU_SOURCE -DIA32
|
@ -1,15 +0,0 @@
|
||||
os_family = bsd
|
||||
|
||||
arch = ia64
|
||||
|
||||
os_arch = bsd_ia64
|
||||
|
||||
lib_arch = ia64
|
||||
|
||||
compiler = gcc
|
||||
|
||||
gnu_dis_arch = ia64
|
||||
|
||||
sysdefs = -D_ALLBSD_SOURCE -D_GNU_SOURCE -DIA64 -DCC_INTERP
|
||||
|
||||
mark_style = alignment
|
@ -1,15 +0,0 @@
|
||||
os_family = bsd
|
||||
|
||||
arch = sparc
|
||||
|
||||
arch_model = sparc
|
||||
|
||||
os_arch = bsd_sparc
|
||||
|
||||
os_arch_model = bsd_sparc
|
||||
|
||||
lib_arch = sparc
|
||||
|
||||
compiler = gcc
|
||||
|
||||
sysdefs = -D_ALLBSD_SOURCE -D_GNU_SOURCE -DSPARC
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user