提交 13c9f535 编写于 作者: J jcoomes

Merge

...@@ -178,3 +178,4 @@ e8569a473cee7f4955bd9e76a9bdf6c6a07ced27 jdk8-b52 ...@@ -178,3 +178,4 @@ e8569a473cee7f4955bd9e76a9bdf6c6a07ced27 jdk8-b52
70ad0ed1d6cef0e7712690d1bab21e4769708aad jdk8-b54 70ad0ed1d6cef0e7712690d1bab21e4769708aad jdk8-b54
1f3f4b333341873f00da3dee85e4879f0e89c9bb jdk8-b55 1f3f4b333341873f00da3dee85e4879f0e89c9bb jdk8-b55
2e9eeef2909b33c9224a024afddb61ccb0b77f14 jdk8-b56 2e9eeef2909b33c9224a024afddb61ccb0b77f14 jdk8-b56
51594d095a4bcffac4a314bf6e148214501399e0 jdk8-b57
# #
# Copyright (c) 1995, 2011, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 1995, 2012, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
...@@ -29,6 +29,7 @@ ...@@ -29,6 +29,7 @@
# #
BUILDDIR=. BUILDDIR=.
include $(BUILDDIR)/common/Defs.gmk include $(BUILDDIR)/common/Defs.gmk
# #
...@@ -273,6 +274,7 @@ docs:: sanity-docs post-sanity-docs ...@@ -273,6 +274,7 @@ docs:: sanity-docs post-sanity-docs
# Release engineering targets. # Release engineering targets.
# #
include $(BUILDDIR)/common/Release.gmk include $(BUILDDIR)/common/Release.gmk
-include $(CUSTOM_MAKE_DIR)/Release.gmk
# #
# Cscope targets. # Cscope targets.
......
...@@ -159,7 +159,7 @@ $(UNPACK_EXE): $(UNPACK_EXE_FILES_o) updatefiles winres ...@@ -159,7 +159,7 @@ $(UNPACK_EXE): $(UNPACK_EXE_FILES_o) updatefiles winres
$(prep-target) $(prep-target)
$(RM) $(TEMPDIR)/mapfile-vers $(RM) $(TEMPDIR)/mapfile-vers
$(CP) mapfile-vers-unpack200 $(TEMPDIR)/mapfile-vers $(CP) mapfile-vers-unpack200 $(TEMPDIR)/mapfile-vers
$(LINKER) $(LDDFLAGS) $(UNPACK_EXE_FILES_o) $(RES) $(LIBCXX) $(LDOUTPUT)$(TEMPDIR)/unpack200$(EXE_SUFFIX) $(LINKER) $(LDDFLAGS) $(sort $(UNPACK_EXE_FILES_o)) $(RES) $(LIBCXX) $(LDOUTPUT)$(TEMPDIR)/unpack200$(EXE_SUFFIX)
ifdef MT ifdef MT
$(MT) /manifest $(OBJDIR)/unpack200$(EXE_SUFFIX).manifest /outputresource:$(TEMPDIR)/unpack200$(EXE_SUFFIX);#1 $(MT) /manifest $(OBJDIR)/unpack200$(EXE_SUFFIX).manifest /outputresource:$(TEMPDIR)/unpack200$(EXE_SUFFIX);#1
endif endif
......
...@@ -109,18 +109,27 @@ else ...@@ -109,18 +109,27 @@ else
endif endif
endif endif
# We allow for potential specialization of build files. This has to be
# done on a file-by-file, case-by-case basis. Here we define the basic control
# over where custom files are being used. Later we will -include the custom
# Defs.gmk if present. This works best because all Makefiles include defs.gmk.
# In other cases we can either have foo.gmk include custom/foo.gmk, or
# a Makefile can do:
# include foo.gmk
# -include $CUSTOM_MAKE_DIR/foo.gmk
#
# For non-OpenJDK builds the default location is the make/closed repository.
# For OpenJDK builds a real value has to be supplied externally.
ifneq ($(OPENJDK),true)
CUSTOM_MAKE_DIR = $(BUILDDIR)/closed
endif
# #
# Get platform definitions # Get platform definitions
# #
include $(JDK_TOPDIR)/make/common/Defs-$(PLATFORM).gmk include $(JDK_TOPDIR)/make/common/Defs-$(PLATFORM).gmk
#
# SE-Embedded support, if enabled
#
include $(JDK_TOPDIR)/make/common/Defs-embedded.gmk
# #
# Cross-compilation Settings # Cross-compilation Settings
# #
...@@ -611,4 +620,6 @@ define install-import-file ...@@ -611,4 +620,6 @@ define install-import-file
$(install-importonly-file) $(install-importonly-file)
endef endef
-include $(CUSTOM_MAKE_DIR)/Defs.gmk
.PHONY: all build clean clobber .PHONY: all build clean clobber
#
# 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. 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.
#
#
# SE-Embedded Reduced JRE targets
#
ifdef JAVASE_EMBEDDED
reduced-image-jre reduced-headless-image-jre ::
@$(ECHO) ">>>Making "$@" @ `$(DATE)` ..."
# Add the reduced-jre images as pre-reqs. These will be processed last
images:: reduced-image-jre reduced-headless-image-jre
######################################################
# Create the headless rt.jar
######################################################
NOT_HEADLESS_RT_JAR_LIST = $(ABS_TEMPDIR)/not_hl_rt_jar.list
HEADLESS_RT_JAR_FILELIST=$(JARFILELISTS_TEMPDIR)/hl_rt_jar_list
TOTAL_HEADLESS_JAR_FILELIST=$(REORDER_TEMPDIR)/hl_file_list
HEADLESS_CLASSLIST=$(ABS_TEMPDIR)/headless_classlist
# Add the jar file directories that we don't want in the
# headless JRE. If you want to remove most classes in a
# directory, put the directory in the NOT_HEADLESS_RT_JAR_LIST
# and put the individual classes you want to keep in the
# HEADLESS_CLASSLIST file.
$(NOT_HEADLESS_RT_JAR_LIST): $(NOT_RT_JAR_LIST)
$(RM) $(HEADLESS_CLASSLIST)
$(RM) $(NOT_HEADLESS_RT_JAR_LIST)
$(CP) $(NOT_RT_JAR_LIST) $(NOT_HEADLESS_RT_JAR_LIST)
# List all the packages to be excluded
$(ECHO) "sun/awt/motif/" >> $@
$(ECHO) "sun/awt/X11/" >> $@
$(ECHO) "sun/applet/" >> $@
$(ECHO) "sun/java2d/opengl/" >> $@
$(ECHO) "com/sun/java/swing/plaf/" >> $@
# List all the individual classes to be included
$(ECHO) "sun/awt/motif/MFontConfiguration.class" >$(HEADLESS_CLASSLIST)
$(ECHO) "sun/applet/AppContextCreator.class" >>$(HEADLESS_CLASSLIST)
$(ECHO) "sun/applet/AppletAudioClip.class" >>$(HEADLESS_CLASSLIST)
$(ECHO) "sun/java2d/opengl/GLXSurfaceData.class" >>$(HEADLESS_CLASSLIST)
$(ECHO) "sun/java2d/opengl/GLXSurfaceData"\$$"GLXOffScreenSurfaceData.class" >>$(HEADLESS_CLASSLIST)
$(ECHO) "sun/java2d/opengl/GLXVolatileSurfaceManager.class" >>$(HEADLESS_CLASSLIST)
$(ECHO) "sun/java2d/opengl/OGLSurfaceData.class" >>$(HEADLESS_CLASSLIST)
$(TOTAL_HEADLESS_JAR_FILELIST): $(JARREORDER_JARFILE) $(NOT_HEADLESS_RT_JAR_LIST)
$(prep-target)
$(RM) $@.temp
$(CD) $(CLASSBINDIR) ; \
$(BOOT_JAVA_CMD) -jar $(JARREORDER_JARFILE) \
-o $@.temp - $(NOT_HEADLESS_RT_JAR_LIST) .
# Add on the explicitly included class files from the otherwise excluded packages
$(CAT) $(HEADLESS_CLASSLIST) >> $@.temp
$(MV) $@.temp $@
@$(CD) $(CLASSBINDIR); $(java-vm-cleanup)
# Create the headless rt.jar file list & non-class files list
MakeHeadlessJarFileList: $(TOTAL_HEADLESS_JAR_FILELIST) $(JARSPLIT_JARFILE)
@$(RM) $(HEADLESS_RT_JAR_FILELIST) $(RES_JAR_FILELIST)
$(BOOT_JAVA_CMD) -jar $(JARSPLIT_JARFILE) $(TOTAL_HEADLESS_JAR_FILELIST) \
-o $(HEADLESS_RT_JAR_FILELIST) $(RES_JAR_FILELIST)
@$(java-vm-cleanup)
# Create headless rt.jar
HL_RT_JAR=$(ABS_TEMPDIR)/rt-hl-orig.jar
$(HL_RT_JAR): MakeHeadlessJarFileList $(RT_JAR_MANIFEST_FILE)
$(prep-target)
$(CD) $(CLASSBINDIR) ; \
$(BOOT_JAR_CMD) $(CREATE_JAR_OPTS) $(RT_JAR_MANIFEST_FILE) $@ @$(HEADLESS_RT_JAR_FILELIST) \
$(JAR_JFLAGS)
@$(CD) $(CLASSBINDIR); $(java-vm-cleanup)
#
# Produce a reduced Headful JRE for Embedded Devices
#
# The deployment binaries are added during the deployment build process
#
# Binaries that don't get included in reduced jre image bin directory
NOT_REDUCEDJRE_BIN = \
java_vm \
kinit \
klist \
ktab \
orbd \
policytool \
rmid \
rmiregistry \
servertool \
tnameserv \
pack200 \
unpack200
# jars/resources/libs that don't get included in reduced jre image lib directory
NOT_REDUCEDJRE_LIB = \
charsets.jar \
ext/dnsns.jar \
ext/localedata.jar \
$(LIBARCH)/client/classes.jsa \
$(LIBARCH)/libjavaplugin_jni.so \
$(LIBARCH)/libjavaplugin_nscp_gcc29.so \
$(LIBARCH)/libjavaplugin_nscp.so \
$(LIBARCH)/libjavaplugin_oji.so
# JRE docs that don't get included in reduced jre image top directory
NOT_REDUCEDJRE_DOC = \
Welcome.html
reduced-image-jre::
@$(ECHO) Starting to Produce Reduced JRE
@#
@# First make a copy of the full JRE
@#
$(RM) -r $(JRE_REDUCED_IMAGE_DIR)
$(MKDIR) -p $(JRE_REDUCED_IMAGE_DIR)
$(CD) $(JRE_IMAGE_DIR); \
$(TAR) cf - . | ($(CD) $(JRE_REDUCED_IMAGE_DIR); $(TAR) xf - );
@#
@# Remove all of the files that are not needed for the
@# reduced JRE
@#
for l in $(NOT_REDUCEDJRE_BIN) ; do \
$(RM) $(JRE_REDUCED_IMAGE_DIR)/bin/$$l ; \
done
for l in $(NOT_REDUCEDJRE_LIB) ; do \
$(RM) $(JRE_REDUCED_IMAGE_DIR)/lib/$$l ; \
done
for l in $(NOT_REDUCEDJRE_DOC) ; do \
$(RM) $(JRE_REDUCED_IMAGE_DIR)/$$l ; \
done
@# Remove misc. other files
$(RM) -r $(JRE_REDUCED_IMAGE_DIR)/man
$(RM) -f $(JRE_REDUCED_IMAGE_DIR)/CHANGES
@$(ECHO) Done Creating Reduced JRE
#
# Produce a reduced Headless JRE
#
reduced-headless-image-jre:: $(RT_JAR) $(RESOURCES_JAR) $(BUILD_META_INDEX) $(HL_RT_JAR)
@$(ECHO) Starting to Produce Reduced Headless JRE
@#
@# First make a copy of the reduced JRE we just built
@#
$(RM) -r $(JRE_REDUCED_HEADLESS_IMAGE_DIR)
$(MKDIR) -p $(JRE_REDUCED_HEADLESS_IMAGE_DIR)
$(CD) $(JRE_REDUCED_IMAGE_DIR); \
$(TAR) cf - . | ($(CD) $(JRE_REDUCED_HEADLESS_IMAGE_DIR); $(TAR) xf - );
@# Replace the full rt.jar with the headless rt.jar
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/rt.jar
$(CP) $(HL_RT_JAR) $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/rt.jar
@#
@# Remove all of the files that are not needed for the
@# reduced Headless JRE
@#
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/$(LIBARCH)/gtkhelper
$(RM) $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/$(LIBARCH)/libjsoundalsa.so
$(RM) -r $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/audio
$(RM) -fr $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/applet
$(RM) $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/$(LIBARCH)/awt_robot
$(RM) $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/$(LIBARCH)/libawt_xawt.so
$(RM) -r $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/$(LIBARCH)/libsplashscreen.so
@# Remove oblique fonts and reduce font support to LucidaSansRegular only
$(RM) -fr $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/oblique-fonts
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/LucidaBrightDemiBold.ttf
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/LucidaBrightDemiItalic.ttf
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/LucidaBrightItalic.ttf
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/LucidaBrightRegular.ttf
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/LucidaSansDemiBold.ttf
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/LucidaTypewriterBold.ttf
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/LucidaTypewriterRegular.ttf
ifeq ($(PLATFORM), linux)
# put out minimal fonts.dir file for the remaining font
$(RM) -f $(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/fonts.dir
$(ECHO) 6>$(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/fonts.dir
$(ECHO) "LucidaSansRegular.ttf -b&h-lucidasans-medium-r-normal-sans-0-0-0-0-p-0-iso8859-1">>$(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/fonts.dir
$(ECHO) "LucidaSansRegular.ttf -b&h-lucidasans-medium-r-normal-sans-0-0-0-0-p-0-iso8859-2">>$(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/fonts.dir
$(ECHO) "LucidaSansRegular.ttf -b&h-lucidasans-medium-r-normal-sans-0-0-0-0-p-0-iso8859-4">>$(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/fonts.dir
$(ECHO) "LucidaSansRegular.ttf -b&h-lucidasans-medium-r-normal-sans-0-0-0-0-p-0-iso8859-5">>$(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/fonts.dir
$(ECHO) "LucidaSansRegular.ttf -b&h-lucidasans-medium-r-normal-sans-0-0-0-0-p-0-iso8859-7">>$(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/fonts.dir
$(ECHO) "LucidaSansRegular.ttf -b&h-lucidasans-medium-r-normal-sans-0-0-0-0-p-0-iso8859-9">>$(JRE_REDUCED_HEADLESS_IMAGE_DIR)/lib/fonts/fonts.dir
endif # Linux
@#
@# all done with JRE reduced headless image
@#
@$(ECHO) Done Creating Reduced Headless JRE
images-clobber::
$(RM) -r $(JRE_REDUCED_IMAGE_DIR)
$(RM) -r $(JRE_REDUCED_HEADLESS_IMAGE_DIR)
.PHONY: reduced-image-jre reduced-headless-image-jre
endif # JAVASE_EMBEDDED
...@@ -750,10 +750,6 @@ $(RT_JAR): $(RT_JAR_FILELIST) $(RT_JAR_MANIFEST_FILE) ...@@ -750,10 +750,6 @@ $(RT_JAR): $(RT_JAR_FILELIST) $(RT_JAR_MANIFEST_FILE)
BUILDMETAINDEX_JARFILE = $(ABS_BUILDTOOLJARDIR)/buildmetaindex.jar BUILDMETAINDEX_JARFILE = $(ABS_BUILDTOOLJARDIR)/buildmetaindex.jar
# SE-Embedded targets if enabled
include $(JDK_TOPDIR)/make/common/Release-embedded.gmk
###################################################### ######################################################
# JRE Image # JRE Image
###################################################### ######################################################
......
...@@ -190,7 +190,7 @@ ifeq ($(PLATFORM), windows) ...@@ -190,7 +190,7 @@ ifeq ($(PLATFORM), windows)
$(STATIC_LIBRARY): $(FILES_o) $(STATIC_LIBRARY): $(FILES_o)
@$(prep-target) @$(prep-target)
$(LIBEXE) -nologo -out:$@ $(FILES_o) $(LIBEXE) -nologo -out:$@ $(sort $(FILES_o))
library:: $(STATIC_LIBRARY) library:: $(STATIC_LIBRARY)
endif # PLATFORM endif # PLATFORM
...@@ -216,7 +216,7 @@ $(STATIC_LIBRARY_DIR): | $(OBJDIR) ...@@ -216,7 +216,7 @@ $(STATIC_LIBRARY_DIR): | $(OBJDIR)
$(STATIC_LIBRARY): $(STATIC_LIBRARY_DIR) $(STATIC_LIBRARY): $(STATIC_LIBRARY_DIR)
@$(prep-target) @$(prep-target)
$(AR) $(ARFLAGS) $@ $(FILES_o) $(AR) $(ARFLAGS) $@ $(sort $(FILES_o))
library:: $(STATIC_LIBRARY) library:: $(STATIC_LIBRARY)
......
...@@ -44,10 +44,11 @@ BUILD_DEMOS= ...@@ -44,10 +44,11 @@ BUILD_DEMOS=
define SetupAppletDemo define SetupAppletDemo
$$(eval $$(call SetupJavaCompilation,BUILD_DEMO_APPLET_$1,\ $$(eval $$(call SetupJavaCompilation,BUILD_DEMO_APPLET_$1,\
SETUP:=GENERATE_USINGJDKBYTECODE$2,\ SETUP:=GENERATE_USINGJDKBYTECODE,\
SRC:=$(JDK_TOPDIR)/src/$3share/demo/applets/$1,\ SRC:=$(JDK_TOPDIR)/src/$3share/demo/applets/$1,\
BIN:=$(JDK_OUTPUTDIR)/newdemo/applets/$1,\ BIN:=$(JDK_OUTPUTDIR)/demo/applets/$1,\
COPY:=.html .java .xyz .obj .au .gif)) COPY:=.html .java .xyz .obj .au .gif,\
DISABLE_SJAVAC:=$2))
BUILD_DEMOS += $$(BUILD_DEMO_APPLET_$1) BUILD_DEMOS += $$(BUILD_DEMO_APPLET_$1)
endef endef
...@@ -67,11 +68,11 @@ $(eval $(call SetupAppletDemo,SortDemo)) ...@@ -67,11 +68,11 @@ $(eval $(call SetupAppletDemo,SortDemo))
$(eval $(call SetupAppletDemo,SpreadSheet)) $(eval $(call SetupAppletDemo,SpreadSheet))
# Build WireFrame without a server since it # Build WireFrame without a server since it
# has a class Matrix3D that also exists in MoleculeViewer. # has a class Matrix3D that also exists in MoleculeViewer.
$(eval $(call SetupAppletDemo,WireFrame,_NOSERV)) $(eval $(call SetupAppletDemo,WireFrame,true))
ifndef OPENJDK ifndef OPENJDK
$(eval $(call SetupAppletDemo,Animator,,closed/)) $(eval $(call SetupAppletDemo,Animator,,closed/))
$(eval $(call SetupAppletDemo,GraphLayout,_NOSERV,closed/)) $(eval $(call SetupAppletDemo,GraphLayout,true,closed/))
$(eval $(call SetupAppletDemo,JumpingBox,,closed/)) $(eval $(call SetupAppletDemo,JumpingBox,,closed/))
$(eval $(call SetupAppletDemo,TicTacToe,,closed/)) $(eval $(call SetupAppletDemo,TicTacToe,,closed/))
endif endif
...@@ -111,29 +112,30 @@ define SetupDemo ...@@ -111,29 +112,30 @@ define SetupDemo
ifneq ($$($1_JAVA_FILES_EXIST),) ifneq ($$($1_JAVA_FILES_EXIST),)
$$(eval $$(call SetupJavaCompilation,BUILD_DEMO_$1,\ $$(eval $$(call SetupJavaCompilation,BUILD_DEMO_$1,\
SETUP:=GENERATE_USINGJDKBYTECODE$(12),\ SETUP:=GENERATE_USINGJDKBYTECODE,\
ADD_JAVAC_FLAGS:=$3,\ ADD_JAVAC_FLAGS:=$3,\
SRC:=$$($1_MAIN_SRC) $5,\ SRC:=$$($1_MAIN_SRC) $5,\
BIN:=$(JDK_OUTPUTDIR)/newdemoclasses/$2/$1,\ BIN:=$(JDK_OUTPUTDIR)/democlasses/$2/$1,\
COPY:=$(PATTERNS_TO_COPY) $(10),\ COPY:=$(PATTERNS_TO_COPY) $(10),\
JAR:=$(JDK_OUTPUTDIR)/newdemo/$2/$1/$$($1_JARFILE),\ JAR:=$(JDK_OUTPUTDIR)/demo/$2/$1/$$($1_JARFILE),\
JARMAIN:=$4,\ JARMAIN:=$4,\
MANIFEST:=$(JDK_TOPDIR)/make/tools/manifest.mf,\ MANIFEST:=$(JDK_TOPDIR)/make/tools/manifest.mf,\
EXTRA_MANIFEST_ATTR:=$(11),\ EXTRA_MANIFEST_ATTR:=$(11),\
SRCZIP:=$(JDK_OUTPUTDIR)/newdemo/$2/$1/src.zip,\ SRCZIP:=$(JDK_OUTPUTDIR)/demo/$2/$1/src.zip,\
EXCLUDE_FILES:=$9)) EXCLUDE_FILES:=$9,\
DISABLE_SJAVAC:=$(12)))
BUILD_DEMOS += $$(BUILD_DEMO_$1) \ BUILD_DEMOS += $$(BUILD_DEMO_$1) \
$(JDK_OUTPUTDIR)/newdemo/$2/$1/$$($1_JARFILE) \ $(JDK_OUTPUTDIR)/demo/$2/$1/$$($1_JARFILE) \
$(JDK_OUTPUTDIR)/newdemo/$2/$1/src.zip $(JDK_OUTPUTDIR)/demo/$2/$1/src.zip
endif endif
# Copy files. # Copy files.
$1_COPY_TARGETS := $$(patsubst $(JDK_TOPDIR)/src/$6share/demo/$2/$1/%,\ $1_COPY_TARGETS := $$(patsubst $(JDK_TOPDIR)/src/$6share/demo/$2/$1/%,\
$(JDK_OUTPUTDIR)/newdemo/$2/$1/%,\ $(JDK_OUTPUTDIR)/demo/$2/$1/%,\
$$(wildcard $$(addprefix $(JDK_TOPDIR)/src/$6share/demo/$2/$1/,$7))) $$(wildcard $$(addprefix $(JDK_TOPDIR)/src/$6share/demo/$2/$1/,$7)))
ifneq ($7,) ifneq ($7,)
$(JDK_OUTPUTDIR)/newdemo/$2/$1/% : $(JDK_TOPDIR)/src/$6share/demo/$2/$1/% $(JDK_OUTPUTDIR)/demo/$2/$1/% : $(JDK_TOPDIR)/src/$6share/demo/$2/$1/%
$(MKDIR) -p $$(@D) $(MKDIR) -p $$(@D)
$(CP) $$< $$@ $(CP) $$< $$@
$(CHMOD) -f ug+w $$@ $(CHMOD) -f ug+w $$@
...@@ -144,20 +146,20 @@ define SetupDemo ...@@ -144,20 +146,20 @@ define SetupDemo
endef endef
$(eval $(call SetupDemo,CodePointIM,jfc,,CodePointIM,,,*.html)) $(eval $(call SetupDemo,CodePointIM,jfc,,CodePointIM,,,*.html))
$(JDK_OUTPUTDIR)/newdemo/jfc/CodePointIM/_the.services : \ $(JDK_OUTPUTDIR)/demo/jfc/CodePointIM/_the.services : \
$(JDK_OUTPUTDIR)/newdemo/jfc/CodePointIM/CodePointIM.jar \ $(JDK_OUTPUTDIR)/demo/jfc/CodePointIM/CodePointIM.jar \
$(JDK_TOPDIR)/src/share/demo/jfc/CodePointIM/java.awt.im.spi.InputMethodDescriptor $(JDK_TOPDIR)/src/share/demo/jfc/CodePointIM/java.awt.im.spi.InputMethodDescriptor
(cd $(JDK_OUTPUTDIR)/newdemo/jfc/CodePointIM && \ (cd $(JDK_OUTPUTDIR)/demo/jfc/CodePointIM && \
$(MKDIR) -p _the.tmp/META-INF/services && \ $(MKDIR) -p _the.tmp/META-INF/services && \
$(CP) $(JDK_TOPDIR)/src/share/demo/jfc/CodePointIM/java.awt.im.spi.InputMethodDescriptor _the.tmp/META-INF/services && \ $(CP) $(JDK_TOPDIR)/src/share/demo/jfc/CodePointIM/java.awt.im.spi.InputMethodDescriptor _the.tmp/META-INF/services && \
cd _the.tmp && \ cd _the.tmp && \
$(JAR) uf $(JDK_OUTPUTDIR)/newdemo/jfc/CodePointIM/CodePointIM.jar META-INF/services/java.awt.im.spi.InputMethodDescriptor && \ $(JAR) uf $(JDK_OUTPUTDIR)/demo/jfc/CodePointIM/CodePointIM.jar META-INF/services/java.awt.im.spi.InputMethodDescriptor && \
cd META-INF/services && \ cd META-INF/services && \
$(JAR) uf $(JDK_OUTPUTDIR)/newdemo/jfc/CodePointIM/CodePointIM.jar java.awt.im.spi.InputMethodDescriptor) $(JAR) uf $(JDK_OUTPUTDIR)/demo/jfc/CodePointIM/CodePointIM.jar java.awt.im.spi.InputMethodDescriptor)
$(RM) -r $(JDK_OUTPUTDIR)/newdemo/jfc/CodePointIM/_the.tmp $(RM) -r $(JDK_OUTPUTDIR)/demo/jfc/CodePointIM/_the.tmp
$(TOUCH) $@ $(TOUCH) $@
BUILD_DEMOS+=$(JDK_OUTPUTDIR)/newdemo/jfc/CodePointIM/_the.services BUILD_DEMOS+=$(JDK_OUTPUTDIR)/demo/jfc/CodePointIM/_the.services
$(eval $(call SetupDemo,FileChooserDemo,jfc,,FileChooserDemo,,,README*)) $(eval $(call SetupDemo,FileChooserDemo,jfc,,FileChooserDemo,,,README*))
$(eval $(call SetupDemo,Font2DTest,jfc,,Font2DTest,,,*.html *.txt)) $(eval $(call SetupDemo,Font2DTest,jfc,,Font2DTest,,,*.html *.txt))
...@@ -182,12 +184,12 @@ ifndef OPENJDK ...@@ -182,12 +184,12 @@ ifndef OPENJDK
$(eval $(call SetupDemo,Stylepad,jfc,,Stylepad,\ $(eval $(call SetupDemo,Stylepad,jfc,,Stylepad,\
$(JDK_TOPDIR)/src/share/demo/jfc/Notepad,closed/,*.txt,,$(JDK_TOPDIR)/src/share/demo/jfc/Notepad/README.txt)) $(JDK_TOPDIR)/src/share/demo/jfc/Notepad,closed/,*.txt,,$(JDK_TOPDIR)/src/share/demo/jfc/Notepad/README.txt))
$(eval $(call SetupDemo,SwingSet2,jfc,,SwingSet2,,closed/,README* *.html,,,.java COPYRIGHT,\ $(eval $(call SetupDemo,SwingSet2,jfc,,SwingSet2,,closed/,README* *.html,,,.java COPYRIGHT,\
SplashScreen-Image: resources/images/splash.png,_NOSERV)) SplashScreen-Image: resources/images/splash.png,true))
BUILD_DEMOS += $(patsubst $(JDK_TOPDIR)/src/closed/share/demo/nbproject/%,\ BUILD_DEMOS += $(patsubst $(JDK_TOPDIR)/src/closed/share/demo/nbproject/%,\
$(JDK_OUTPUTDIR)/newdemo/nbproject/%,\ $(JDK_OUTPUTDIR)/demo/nbproject/%,\
$(shell $(FIND) $(JDK_TOPDIR)/src/closed/share/demo/nbproject/ -type f)) $(shell $(FIND) $(JDK_TOPDIR)/src/closed/share/demo/nbproject/ -type f))
$(JDK_OUTPUTDIR)/newdemo/nbproject/% : $(JDK_TOPDIR)/src/closed/share/demo/nbproject/% $(JDK_OUTPUTDIR)/demo/nbproject/% : $(JDK_TOPDIR)/src/closed/share/demo/nbproject/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
...@@ -196,7 +198,7 @@ endif ...@@ -196,7 +198,7 @@ endif
################################################################################################## ##################################################################################################
# Why do we install a demo jar into the main jre/lib/ext???????????????? # Why do we install a demo jar into the main jre/lib/ext????????????????
$(JDK_OUTPUTDIR)/lib/ext/zipfs.jar : $(JDK_OUTPUTDIR)/newdemo/nio/zipfs/zipfs.jar $(JDK_OUTPUTDIR)/lib/ext/zipfs.jar : $(JDK_OUTPUTDIR)/demo/nio/zipfs/zipfs.jar
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
...@@ -207,52 +209,74 @@ BUILD_DEMOS += $(JDK_OUTPUTDIR)/lib/ext/zipfs.jar ...@@ -207,52 +209,74 @@ BUILD_DEMOS += $(JDK_OUTPUTDIR)/lib/ext/zipfs.jar
# In the old makefiles, j2dbench was not compiled. # In the old makefiles, j2dbench was not compiled.
#$(eval $(call SetupDemo,J2DBench,java2d,/src,,j2dbench/J2DBench)) #$(eval $(call SetupDemo,J2DBench,java2d,/src,,j2dbench/J2DBench))
# JVMTI demos are a bit strange and share some files, but be careful the
# shared files are just the *.c and *.h files, not the README or sample
# makefiles. So we always exclude the README.txt and sample.makefile.txt
# from the extra sources.
define SetupJVMTIDemo define SetupJVMTIDemo
# Param 1 = Name of the demo # Param 1 = Name of the demo
# Param 2 = add these directories to the includes, default is agent_util # Param 2 = add these directories to the includes, default is agent_util
# Param 3 = extra CFLAGS # Param 3 = extra CFLAGS
# Param 4 = C or C++ (defaults to C) # Param 4 = C or C++ (defaults to C)
# Param 5 = libs for posix # Param 5 = libs for posix
# Param 6 = libs for winapi # Param 6 = libs for windows
# Param 7 = libs for solaris # Param 7 = libs for solaris
BUILD_DEMO_JVMTI_$1_EXTRA_SRC:= $$(wildcard $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/demo/jvmti/$1) \ BUILD_DEMO_JVMTI_$1_EXTRA_SRC:= \
$$(wildcard $$(addprefix $(JDK_TOPDIR)/src/share/demo/jvmti/,$2)) $$(wildcard $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/demo/jvmti/$1) \
$$(wildcard $$(addprefix $(JDK_TOPDIR)/src/share/demo/jvmti/,$2))
BUILD_DEMO_JVMTI_$1_EXTRA_SRC_EXCLUDE:= \
$$(wildcard $$(addprefix $(JDK_TOPDIR)/src/share/demo/jvmti/,$2)/README.txt) \
$$(wildcard $$(addprefix $(JDK_TOPDIR)/src/share/demo/jvmti/,$2)/sample.makefile.txt)
BUILD_DEMO_JVMTI_$1_EXTRA_INC:=$$(addprefix -I,$$(BUILD_DEMO_JVMTI_$1_EXTRA_SRC)) BUILD_DEMO_JVMTI_$1_EXTRA_INC:=$$(addprefix -I,$$(BUILD_DEMO_JVMTI_$1_EXTRA_SRC))
BUILD_DEMO_JVMTI_$1_LANG:=C BUILD_DEMO_JVMTI_$1_LANG:=C
BUILD_DEMO_JVMTI_$1_O_FLAG:=$(C_O_FLAG_NORM)
ifneq (,$4) ifneq (,$4)
BUILD_DEMO_JVMTI_$1_LANG:=$4 BUILD_DEMO_JVMTI_$1_LANG:=$4
endif endif
ifeq (C++,$4) ifeq (C++,$4)
$1_EXTRA_CXX:=$(LIBCXX) $1_EXTRA_CXX:=$(LDFLAGS_CXX_JDK) $(LIBCXX)
BUILD_DEMO_JVMTI_$1_O_FLAG:=$(CXX_O_FLAG_NORM)
endif endif
$1_CXXFLAGS:=$(CXXFLAGS_JDKLIB) $$(BUILD_DEMO_JVMTI_$1_O_FLAG) -I$(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_INC) $3 $1_CXXFLAGS:=$(CXXFLAGS_JDKLIB) -I$(JDK_TOPDIR)/src/share/demo/jvmti/$1 \
$$(BUILD_DEMO_JVMTI_$1_EXTRA_INC) $3 \
$(CXXFLAGS_DEBUG_SYMBOLS)
ifeq ($1-$(OPENJDK_TARGET_CPU_ARCH),waiters-sparc) ifeq ($1-$(OPENJDK_TARGET_CPU_ARCH),waiters-sparc)
$1_FILTER:=-xregs=no%appl $1_FILTER:=-xregs=no%appl
$1_CXXFLAGS:=$$(filter-out $$($1_FILTER),$$($1_CXXFLAGS)) $1_CXXFLAGS:=$$(filter-out $$($1_FILTER),$$($1_CXXFLAGS))
endif endif
# Workaround for CFLAGS_JDKLIB containing ',' on solaris. If this is added as 'CFLAGS' to the
# eval call below, the comma gets expanded too early.
BUILD_DEMO_JVMTI_$1_CFLAGS:=$(CFLAGS_JDKLIB) $(CFLAGS_DEBUG_SYMBOLS) \
-I$(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_INC) $3
# Remove the -incremental:no setting to get .ilk-files like in the old build.
$$(eval $$(call SetupNativeCompilation,BUILD_DEMO_JVMTI_$1,\ $$(eval $$(call SetupNativeCompilation,BUILD_DEMO_JVMTI_$1,\
SRC:=$(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_SRC),\ SRC:=$(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_SRC),\
LANG:=$$(BUILD_DEMO_JVMTI_$1_LANG),\ LANG:=$$(BUILD_DEMO_JVMTI_$1_LANG),\
CFLAGS:=$(CFLAGS_JDKLIB) $$(BUILD_DEMO_JVMTI_$1_O_FLAG) -I$(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_INC) $3,\ OPTIMIZATION:=LOW,\
CXXFLAGS:=$$($1_CXXFLAGS),\ CXXFLAGS:=$$($1_CXXFLAGS),\
LDFLAGS:=$(LDFLAGS_JDKLIB),\ LDFLAGS:=$(filter-out -incremental:no -opt:ref,$(LDFLAGS_JDKLIB)),\
LDFLAGS_macosx:=$(call SET_EXECUTABLE_ORIGIN),\
LDFLAGS_SUFFIX:=$$($1_EXTRA_CXX),\ LDFLAGS_SUFFIX:=$$($1_EXTRA_CXX),\
LDFLAGS_SUFFIX_posix:=$5,\ LDFLAGS_SUFFIX_posix:=$5,\
LDFLAGS_SUFFIX_winapi:=$6,\ LDFLAGS_SUFFIX_windows:=$6,\
LDFLAGS_SUFFIX_solaris:=-lc $7,\ LDFLAGS_SUFFIX_solaris:=$7 -lc,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/newdemoobjs/jvmti/$1,\ LDFLAGS_SUFFIX_linux:=$8,\
OUTPUT_DIR:=$(JDK_OUTPUTDIR)/newdemo/jvmti/$1/lib,\ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$$(RC_FLAGS) \
/D "JDK_FNAME=$1.dll" \
/D "JDK_INTERNAL_NAME=$1" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/demoobjs/jvmti/$1,\
OUTPUT_DIR:=$(JDK_OUTPUTDIR)/demo/jvmti/$1/lib,\
LIBRARY:=$1)) LIBRARY:=$1))
$$(eval $$(call SetupZipArchive,BUILD_DEMO_JVMTI_SRC_$1,\ $$(eval $$(call SetupZipArchive,BUILD_DEMO_JVMTI_SRC_$1,\
SRC:=$(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_SRC),\ SRC:=$(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_SRC),\
ZIP:=$(JDK_OUTPUTDIR)/newdemo/jvmti/$1/src.zip)) EXCLUDE_FILES:=$$(BUILD_DEMO_JVMTI_$1_EXTRA_SRC_EXCLUDE), \
ZIP:=$(JDK_OUTPUTDIR)/demo/jvmti/$1/src.zip))
$(JDK_OUTPUTDIR)/newdemo/jvmti/$1/README.txt : $(JDK_TOPDIR)/src/share/demo/jvmti/$1/README.txt $(JDK_OUTPUTDIR)/demo/jvmti/$1/README.txt : $(JDK_TOPDIR)/src/share/demo/jvmti/$1/README.txt
$(MKDIR) -p $$(@D) $(MKDIR) -p $$(@D)
$(CP) $$< $$@ $(CP) $$< $$@
$(CHMOD) -f ug+w $$@ $(CHMOD) -f ug+w $$@
...@@ -261,29 +285,40 @@ define SetupJVMTIDemo ...@@ -261,29 +285,40 @@ define SetupJVMTIDemo
$$(eval $$(call SetupJavaCompilation,BUILD_DEMO_JVMTI_$1_JAVA,\ $$(eval $$(call SetupJavaCompilation,BUILD_DEMO_JVMTI_$1_JAVA,\
SETUP:=GENERATE_USINGJDKBYTECODE,\ SETUP:=GENERATE_USINGJDKBYTECODE,\
SRC:=$(JDK_TOPDIR)/src/share/demo/jvmti/$1,\ SRC:=$(JDK_TOPDIR)/src/share/demo/jvmti/$1,\
BIN:=$(JDK_OUTPUTDIR)/newdemoclasses/jvmti/$1,\ BIN:=$(JDK_OUTPUTDIR)/democlasses/jvmti/$1,\
COPY:=$(PATTERNS_TO_COPY),\ COPY:=$(PATTERNS_TO_COPY),\
JAR:=$(JDK_OUTPUTDIR)/newdemo/jvmti/$1/$1.jar,\ JAR:=$(JDK_OUTPUTDIR)/demo/jvmti/$1/$1.jar,\
EXTRA_MANIFEST_ATTR:=Main-Class: \n,\ EXTRA_MANIFEST_ATTR:=Main-Class: \n,\
MANIFEST:=$(JDK_TOPDIR)/make/tools/manifest.mf)) MANIFEST:=$(JDK_TOPDIR)/make/tools/manifest.mf))
BUILD_DEMOS += $(JDK_OUTPUTDIR)/newdemo/jvmti/$1/$1.jar BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jvmti/$1/$1.jar
endif endif
BUILD_DEMOS += $$(BUILD_DEMO_JVMTI_$1) \ BUILD_DEMOS += $$(BUILD_DEMO_JVMTI_$1) \
$(JDK_OUTPUTDIR)/newdemo/jvmti/$1/src.zip \ $(JDK_OUTPUTDIR)/demo/jvmti/$1/src.zip \
$(JDK_OUTPUTDIR)/newdemo/jvmti/$1/README.txt $(JDK_OUTPUTDIR)/demo/jvmti/$1/README.txt
ifeq ($(OPENJDK_TARGET_OS),windows)
# These files normally end up in OBJECT_DIR but for demos they
# are supposed to be included in the distro.
$(JDK_OUTPUTDIR)/demo/jvmti/$1/lib/$1.lib: $$(BUILD_DEMO_JVMTI_$1)
$(CP) $(JDK_OUTPUTDIR)/demoobjs/jvmti/$1/$1.lib $$@
$(JDK_OUTPUTDIR)/demo/jvmti/$1/lib/$1.exp: $$(BUILD_DEMO_JVMTI_$1)
$(CP) $(JDK_OUTPUTDIR)/demoobjs/jvmti/$1/$1.exp $$@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jvmti/$1/lib/$1.lib \
$(JDK_OUTPUTDIR)/demo/jvmti/$1/lib/$1.exp
endif
endef endef
$(eval $(call SetupJVMTIDemo,compiledMethodLoad, agent_util)) $(eval $(call SetupJVMTIDemo,compiledMethodLoad, agent_util))
$(eval $(call SetupJVMTIDemo,gctest, agent_util)) $(eval $(call SetupJVMTIDemo,gctest, agent_util))
$(eval $(call SetupJVMTIDemo,heapTracker, agent_util java_crw_demo)) $(eval $(call SetupJVMTIDemo,heapTracker, agent_util java_crw_demo))
$(eval $(call SetupJVMTIDemo,heapViewer, agent_util)) $(eval $(call SetupJVMTIDemo,heapViewer, agent_util))
# hprof contains error messages using __FILE__ macro. These expand to the absolute path
# in the new build system and relative in the old, causing the binaries to differ.
$(eval $(call SetupJVMTIDemo,hprof, java_crw_demo,\ $(eval $(call SetupJVMTIDemo,hprof, java_crw_demo,\
-I$(JDK_TOPDIR)/src/share/npt -I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/npt,C,\ -I$(JDK_TOPDIR)/src/share/npt -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/npt,C,\
-ldl,ws2_32.lib winmm.lib,-lsocket -lnsl)) -ldl,ws2_32.lib winmm.lib,-lsocket -lnsl,-lpthread))
$(eval $(call SetupJVMTIDemo,minst, agent_util java_crw_demo)) $(eval $(call SetupJVMTIDemo,minst, agent_util java_crw_demo))
$(eval $(call SetupJVMTIDemo,mtrace, agent_util java_crw_demo)) $(eval $(call SetupJVMTIDemo,mtrace, agent_util java_crw_demo))
...@@ -298,11 +333,11 @@ JPDA_SOURCES:=$(shell $(FIND) $(JDK_TOPDIR)/src/share/classes/com/sun/tools/exam ...@@ -298,11 +333,11 @@ JPDA_SOURCES:=$(shell $(FIND) $(JDK_TOPDIR)/src/share/classes/com/sun/tools/exam
# The number of files are few enough so that we can use echo safely below to list them. # The number of files are few enough so that we can use echo safely below to list them.
JPDA_FILES:=$(subst $(JDK_TOPDIR)/src/share/classes/,,$(JPDA_SOURCES)) JPDA_FILES:=$(subst $(JDK_TOPDIR)/src/share/classes/,,$(JPDA_SOURCES))
$(JDK_OUTPUTDIR)/newdemo/jpda/src.zip : $(JPDA_SOURCES) $(JDK_OUTPUTDIR)/demo/jpda/src.zip : $(JPDA_SOURCES)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
(cd $(JDK_TOPDIR)/src/share/classes && $(ZIP) -qru $@ com -i "com/sun/tools/example/*") (cd $(JDK_TOPDIR)/src/share/classes && $(ZIP) -qru $@ com -i "com/sun/tools/example/*")
$(JDK_OUTPUTDIR)/newdemo/jpda/examples.jar : $(JPDA_SOURCES) $(JDK_OUTPUTDIR)/demo/jpda/examples.jar : $(JPDA_SOURCES)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $(@D)/_the.sources $(RM) $(@D)/_the.sources
$(call ListPathsSafely,JPDA_FILES,\n, >> $(@D)/_the.sources) $(call ListPathsSafely,JPDA_FILES,\n, >> $(@D)/_the.sources)
...@@ -312,103 +347,104 @@ $(JDK_OUTPUTDIR)/newdemo/jpda/examples.jar : $(JPDA_SOURCES) ...@@ -312,103 +347,104 @@ $(JDK_OUTPUTDIR)/newdemo/jpda/examples.jar : $(JPDA_SOURCES)
(cd $(JDK_TOPDIR)/src/share/classes && $(JAR) cfm $@ $(@D)/_the.manifest @$(@D)/_the.sources) (cd $(JDK_TOPDIR)/src/share/classes && $(JAR) cfm $@ $(@D)/_the.manifest @$(@D)/_the.sources)
(cd $(JDK_TOPDIR)/src/share/classes/com/sun/tools/example && $(JAR) uf $@ README) (cd $(JDK_TOPDIR)/src/share/classes/com/sun/tools/example && $(JAR) uf $@ README)
$(JDK_OUTPUTDIR)/newdemo/jpda/com/sun/tools/example/README : $(JDK_TOPDIR)/src/share/classes/com/sun/tools/example/README $(JDK_OUTPUTDIR)/demo/jpda/com/sun/tools/example/README : $(JDK_TOPDIR)/src/share/classes/com/sun/tools/example/README
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/newdemo/jpda/src.zip $(JDK_OUTPUTDIR)/newdemo/jpda/examples.jar \ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jpda/src.zip $(JDK_OUTPUTDIR)/demo/jpda/examples.jar \
$(JDK_OUTPUTDIR)/newdemo/jpda/com/sun/tools/example/README $(JDK_OUTPUTDIR)/demo/jpda/com/sun/tools/example/README
################################################################################################## ##################################################################################################
$(JDK_OUTPUTDIR)/newdemo/management/index.html : $(JDK_TOPDIR)/src/share/demo/management/index.html $(JDK_OUTPUTDIR)/demo/management/index.html : $(JDK_TOPDIR)/src/share/demo/management/index.html
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
$(JDK_OUTPUTDIR)/newdemo/jvmti/index.html : $(JDK_TOPDIR)/src/share/demo/jvmti/index.html $(JDK_OUTPUTDIR)/demo/jvmti/index.html : $(JDK_TOPDIR)/src/share/demo/jvmti/index.html
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/newdemo/management/index.html \ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/management/index.html \
$(JDK_OUTPUTDIR)/newdemo/jvmti/index.html $(JDK_OUTPUTDIR)/demo/jvmti/index.html
################################################################################################## ##################################################################################################
# The netbeans project files are copied into the demo directory. # The netbeans project files are copied into the demo directory.
BUILD_DEMOS += $(patsubst $(JDK_TOPDIR)/src/share/demo/nbproject/%,\ BUILD_DEMOS += $(patsubst $(JDK_TOPDIR)/src/share/demo/nbproject/%,\
$(JDK_OUTPUTDIR)/newdemo/nbproject/%,\ $(JDK_OUTPUTDIR)/demo/nbproject/%,\
$(shell $(FIND) $(JDK_TOPDIR)/src/share/demo/nbproject/ -type f)) $(shell $(FIND) $(JDK_TOPDIR)/src/share/demo/nbproject/ -type f))
$(JDK_OUTPUTDIR)/newdemo/nbproject/% : $(JDK_TOPDIR)/src/share/demo/nbproject/% $(JDK_OUTPUTDIR)/demo/nbproject/% : $(JDK_TOPDIR)/src/share/demo/nbproject/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
################################################################################################## ##################################################################################################
$(JDK_OUTPUTDIR)/newdemo/README: $(JDK_TOPDIR)/src/share/demo/README $(JDK_OUTPUTDIR)/demo/README: $(JDK_TOPDIR)/src/share/demo/README
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/newdemo/README BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/README
################################################################################################## ##################################################################################################
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
$(JDK_OUTPUTDIR)/newdemoclasses/jni/Poller/% : $(JDK_TOPDIR)/src/solaris/demo/jni/Poller/% $(JDK_OUTPUTDIR)/democlasses/jni/Poller/% : $(JDK_TOPDIR)/src/solaris/demo/jni/Poller/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
$(JDK_OUTPUTDIR)/newdemo/jni/Poller/README.txt : $(JDK_TOPDIR)/src/solaris/demo/jni/Poller/README.txt $(JDK_OUTPUTDIR)/demo/jni/Poller/README.txt : $(JDK_TOPDIR)/src/solaris/demo/jni/Poller/README.txt
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
$(JDK_OUTPUTDIR)/newdemo/jni/Poller/Poller.jar : \ $(JDK_OUTPUTDIR)/demo/jni/Poller/Poller.jar : \
$(JDK_OUTPUTDIR)/newdemoclasses/jni/Poller/README.txt $(JDK_OUTPUTDIR)/newdemoclasses/jni/Poller/Poller.c $(JDK_OUTPUTDIR)/democlasses/jni/Poller/README.txt $(JDK_OUTPUTDIR)/democlasses/jni/Poller/Poller.c
$(eval $(call SetupJavaCompilation,BUILD_DEMO_POLLER_JAR,\ $(eval $(call SetupJavaCompilation,BUILD_DEMO_POLLER_JAR,\
SETUP:=GENERATE_USINGJDKBYTECODE, \ SETUP:=GENERATE_USINGJDKBYTECODE, \
SRC:=$(JDK_TOPDIR)/src/solaris/demo/jni/Poller, \ SRC:=$(JDK_TOPDIR)/src/solaris/demo/jni/Poller, \
BIN:=$(JDK_OUTPUTDIR)/newdemoclasses/jni/Poller, \ BIN:=$(JDK_OUTPUTDIR)/democlasses/jni/Poller, \
HEADERS:=$(JDK_OUTPUTDIR)/newdemoclasses/jni/Poller, \ HEADERS:=$(JDK_OUTPUTDIR)/democlasses/jni/Poller, \
JAR:=$(JDK_OUTPUTDIR)/newdemo/jni/Poller/Poller.jar, \ JAR:=$(JDK_OUTPUTDIR)/demo/jni/Poller/Poller.jar, \
MANIFEST:=$(JDK_TOPDIR)/make/tools/manifest.mf, \ MANIFEST:=$(JDK_TOPDIR)/make/tools/manifest.mf, \
SRCZIP:=$(JDK_OUTPUTDIR)/newdemo/jni/Poller/src.zip, \ SRCZIP:=$(JDK_OUTPUTDIR)/demo/jni/Poller/src.zip, \
COPY := README.txt Poller.c, \ COPY:=README.txt Poller.c, \
JARMAIN := Client)) JARMAIN:=Client))
BUILD_DEMOS += $(JDK_OUTPUTDIR)/newdemo/jni/Poller/Poller.jar $(JDK_OUTPUTDIR)/newdemo/jni/Poller/src.zip \ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jni/Poller/Poller.jar $(JDK_OUTPUTDIR)/demo/jni/Poller/src.zip \
$(JDK_OUTPUTDIR)/newdemo/jni/Poller/README.txt $(JDK_OUTPUTDIR)/demo/jni/Poller/README.txt
$(eval $(call SetupNativeCompilation,BUILD_LIBPOLLER,\ $(eval $(call SetupNativeCompilation,BUILD_LIBPOLLER,\
SRC:=$(JDK_TOPDIR)/src/solaris/demo/jni/Poller, \ SRC:=$(JDK_TOPDIR)/src/solaris/demo/jni/Poller, \
LANG := C, \ LANG:=C,\
CFLAGS:=$(CFLAGS_JDKLIB) $(C_O_FLAG_NORM) $(SHARED_LIBRARY_FLAGS) \ OPTIMIZATION:=LOW,\
-I$(JDK_OUTPUTDIR)/newdemoclasses/jni/Poller, \ CFLAGS:=$(CFLAGS_JDKLIB) $(SHARED_LIBRARY_FLAGS) \
-I$(JDK_OUTPUTDIR)/democlasses/jni/Poller, \
LDFLAGS:=$(LDFLAGS_JDKLIB), \ LDFLAGS:=$(LDFLAGS_JDKLIB), \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/newdemoobjs/jni/Poller,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/demoobjs/jni/Poller,\
OUTPUT_DIR:=$(JDK_OUTPUTDIR)/newdemoobjs, \ OUTPUT_DIR:=$(JDK_OUTPUTDIR)/demoobjs, \
LIBRARY:=Poller)) LIBRARY:=Poller))
# #
# We can only compile native code after jar has been build (since we depend on generated .h files) # We can only compile native code after jar has been build (since we depend on generated .h files)
# #
$(JDK_OUTPUTDIR)/newdemoobjs/jni/Poller/Poller.o : $(JDK_OUTPUTDIR)/newdemo/jni/Poller/Poller.jar $(JDK_OUTPUTDIR)/demoobjs/jni/Poller/Poller.o : $(JDK_OUTPUTDIR)/demo/jni/Poller/Poller.jar
$(JDK_OUTPUTDIR)/newdemo/jni/Poller/lib/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX) : \ $(JDK_OUTPUTDIR)/demo/jni/Poller/lib/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX) : \
$(JDK_OUTPUTDIR)/newdemoobjs/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX) $(JDK_OUTPUTDIR)/demoobjs/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/newdemo/jni/Poller/lib/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX) BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jni/Poller/lib/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX)
endif endif
...@@ -417,20 +453,20 @@ endif ...@@ -417,20 +453,20 @@ endif
ifndef OPENJDK ifndef OPENJDK
DB_DEMO_ZIPFILE := $(shell $(FIND) $(JDK_TOPDIR)/src/closed/share/db -name "*demo*.zip") DB_DEMO_ZIPFILE := $(shell $(FIND) $(JDK_TOPDIR)/src/closed/share/db -name "*demo*.zip")
$(JDK_OUTPUTDIR)/newdemo/_the.db.unzipped: $(DB_DEMO_ZIPFILE) $(JDK_OUTPUTDIR)/demo/_the.db.unzipped: $(DB_DEMO_ZIPFILE)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -rf $(JDK_OUTPUTDIR)/newdemo/db $(JDK_OUTPUTDIR)/newdemo/demo $(RM) -r $(JDK_OUTPUTDIR)/demo/db $(JDK_OUTPUTDIR)/demo/demo
$(CD) $(JDK_OUTPUTDIR)/newdemo && $(UNZIP) -o $< $(CD) $(JDK_OUTPUTDIR)/demo && $(UNZIP) -o $<
$(MV) $(JDK_OUTPUTDIR)/newdemo/demo $(JDK_OUTPUTDIR)/newdemo/db $(MV) $(JDK_OUTPUTDIR)/demo/demo $(JDK_OUTPUTDIR)/demo/db
$(TOUCH) $@ $(TOUCH) $@
# Copy this after the unzip above to avoid race with directory creation and mv command. # Copy this after the unzip above to avoid race with directory creation and mv command.
$(JDK_OUTPUTDIR)/newdemo/db/README-JDK-DEMOS.html: \ $(JDK_OUTPUTDIR)/demo/db/README-JDK-DEMOS.html: \
$(JDK_TOPDIR)/src/closed/share/db/README-JDK-DEMOS.html \ $(JDK_TOPDIR)/src/closed/share/db/README-JDK-DEMOS.html \
| $(JDK_OUTPUTDIR)/newdemo/_the.db.unzipped | $(JDK_OUTPUTDIR)/demo/_the.db.unzipped
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) '$<' '$@' $(CP) '$<' '$@'
BUILD_DEMOS += $(JDK_OUTPUTDIR)/newdemo/_the.db.unzipped $(JDK_OUTPUTDIR)/newdemo/db/README-JDK-DEMOS.html BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/_the.db.unzipped $(JDK_OUTPUTDIR)/demo/db/README-JDK-DEMOS.html
endif endif
################################################################################################## ##################################################################################################
......
...@@ -45,10 +45,6 @@ EXCLUDES += com/sun/pept \ ...@@ -45,10 +45,6 @@ EXCLUDES += com/sun/pept \
com/sun/tools/example/debug/gui \ com/sun/tools/example/debug/gui \
com/oracle/security com/oracle/security
ifeq ($(OPENJDK_TARGET_OS)-$(ARCH_DATA_MODEL),windows-64)
EXCLUDES += sun/security/pkcs11
endif
ifdef OPENJDK ifdef OPENJDK
EXCLUDES+= sun/dc \ EXCLUDES+= sun/dc \
com/sun/jmx/snmp \ com/sun/jmx/snmp \
...@@ -59,6 +55,13 @@ endif ...@@ -59,6 +55,13 @@ endif
ifndef OPENJDK ifndef OPENJDK
# There exists two versions of this file... # There exists two versions of this file...
EXFILES := $(JDK_TOPDIR)/src/share/classes/javax/crypto/JarVerifier.java EXFILES := $(JDK_TOPDIR)/src/share/classes/javax/crypto/JarVerifier.java
ifeq ($(OPENJDK_TARGET_OS),windows)
# This gets built on unix platforms implicitly in the old build even though
# it's excluded in the closed build.
EXCLUDES+=sun/java2d/pisces
endif
endif endif
ifneq ($(OPENJDK_TARGET_OS),solaris) ifneq ($(OPENJDK_TARGET_OS),solaris)
...@@ -90,12 +93,14 @@ ifneq ($(OPENJDK_TARGET_OS),windows) ...@@ -90,12 +93,14 @@ ifneq ($(OPENJDK_TARGET_OS),windows)
# Exclude Window security related files in src/share/classes # Exclude Window security related files in src/share/classes
EXFILES+=NTLoginModule.java \ EXFILES+=NTLoginModule.java \
NTSystem.java NTSystem.java
else
EXFILES+=UnixLoginModule.java \
UnixSystem.java
endif endif
ifeq ($(OPENJDK_TARGET_OS),windows) ifeq ($(OPENJDK_TARGET_OS),windows)
# Don't build GTK L&F on Windows # Don't build GTK L&F on Windows
EXCLUDES+= com/sun/java/swing/plaf/gtk EXCLUDES+=com/sun/java/swing/plaf/gtk
endif endif
ifneq ($(OPENJDK_TARGET_OS),linux) ifneq ($(OPENJDK_TARGET_OS),linux)
...@@ -115,6 +120,9 @@ ifneq ($(OPENJDK_TARGET_OS),macosx) ...@@ -115,6 +120,9 @@ ifneq ($(OPENJDK_TARGET_OS),macosx)
sun/nio/fs/BsdFileSystem.java \ sun/nio/fs/BsdFileSystem.java \
sun/nio/fs/BsdFileSystemProvider.java \ sun/nio/fs/BsdFileSystemProvider.java \
sun/nio/fs/BsdNativeDispatcher.java \ sun/nio/fs/BsdNativeDispatcher.java \
sun/nio/fs/MacOSXFileSystemProvider.java \
sun/nio/fs/MacOSXFileSystem.java \
sun/nio/fs/MacOSXNativeDispatcher.java \
sun/tools/attach/BsdAttachProvider.java \ sun/tools/attach/BsdAttachProvider.java \
sun/tools/attach/BsdVirtualMachine.java sun/tools/attach/BsdVirtualMachine.java
endif endif
...@@ -122,7 +130,7 @@ endif ...@@ -122,7 +130,7 @@ endif
# Exclude BreakIterator classes that are just used in compile process to generate # Exclude BreakIterator classes that are just used in compile process to generate
# data files and shouldn't go in the product # data files and shouldn't go in the product
EXFILES+=sun/text/resources/BreakIteratorRules.java \ EXFILES+=sun/text/resources/BreakIteratorRules.java \
sun/text/resources/BreakIteratorRules_th.java sun/text/resources/BreakIteratorRules_th.java
# TODO: Add BUILD_HEADLESS_ONLY to configure? # TODO: Add BUILD_HEADLESS_ONLY to configure?
ifdef BUILD_HEADLESS_ONLY ifdef BUILD_HEADLESS_ONLY
...@@ -245,7 +253,7 @@ include CopyIntoClasses.gmk ...@@ -245,7 +253,7 @@ include CopyIntoClasses.gmk
ifndef OPENJDK ifndef OPENJDK
CLOSED_SRC_DIRS:=$(JDK_TOPDIR)/src/closed/share/classes \ CLOSED_SRC_DIRS:=$(JDK_TOPDIR)/src/closed/share/classes \
$(JDK_TOPDIR)/src/closed/$(LEGACY_OPENJDK_TARGET_OS_API)/classes $(JDK_TOPDIR)/src/closed/$(OPENJDK_TARGET_OS_API_DIR)/classes
endif endif
MACOSX_SRC_DIRS := MACOSX_SRC_DIRS :=
...@@ -257,7 +265,8 @@ ifeq ($(OPENJDK_TARGET_OS),macosx) ...@@ -257,7 +265,8 @@ ifeq ($(OPENJDK_TARGET_OS),macosx)
$(JDK_TOPDIR)/src/solaris/classes/sun/java2d/BackBufferCapsProvider.java \ $(JDK_TOPDIR)/src/solaris/classes/sun/java2d/BackBufferCapsProvider.java \
$(JDK_TOPDIR)/src/solaris/classes/java/net/DefaultInterface.java \ $(JDK_TOPDIR)/src/solaris/classes/java/net/DefaultInterface.java \
$(JDK_TOPDIR)/src/solaris/classes/java/lang/ClassLoaderHelper.java \ $(JDK_TOPDIR)/src/solaris/classes/java/lang/ClassLoaderHelper.java \
$(JDK_TOPDIR)/src/solaris/classes/sun/util/locale/provider/HostLocaleProviderAdapterImpl.java $(JDK_TOPDIR)/src/solaris/classes/sun/util/locale/provider/HostLocaleProviderAdapterImpl.java \
$(JDK_TOPDIR)/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java
# JObjC.jar contains 1.5 byte-code...so skip it here :-( # JObjC.jar contains 1.5 byte-code...so skip it here :-(
# MACOSX_SRC_DIRS += $(JDK_TOPDIR)/src/macosx/native/jobjc/src # MACOSX_SRC_DIRS += $(JDK_TOPDIR)/src/macosx/native/jobjc/src
...@@ -273,14 +282,21 @@ $(JDK_OUTPUTDIR)/classes/javax/swing/beaninfo/images/%.gif: $(JDK_TOPDIR)/make/t ...@@ -273,14 +282,21 @@ $(JDK_OUTPUTDIR)/classes/javax/swing/beaninfo/images/%.gif: $(JDK_TOPDIR)/make/t
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
# The JDK_USER_DEFINED_FILTER is a poor man's incremental build: by specifying
# JDK_FILTER at the make command line, only a subset of the JDK java files will
# be recompiled. If multiple paths are separated by comma, convert that into a
# space separated list.
JDK_USER_DEFINED_FILTER:=$(strip $(subst $(COMMA),$(SPACE),$(JDK_FILTER)))
$(eval $(call SetupJavaCompilation,BUILD_JDK,\ $(eval $(call SetupJavaCompilation,BUILD_JDK,\
SETUP:=GENERATE_JDKBYTECODE,\ SETUP:=GENERATE_JDKBYTECODE,\
SRC:=$(JDK_TOPDIR)/src/share/classes \ SRC:=$(JDK_TOPDIR)/src/share/classes \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes \
$(MACOSX_SRC_DIRS) \ $(MACOSX_SRC_DIRS) \
$(JDK_OUTPUTDIR)/gensrc \ $(JDK_OUTPUTDIR)/gensrc \
$(JDK_OUTPUTDIR)/gensrc_swing/javax/swing/beaninfo \ $(JDK_OUTPUTDIR)/gensrc_swing/javax/swing/beaninfo \
$(CLOSED_SRC_DIRS),\ $(CLOSED_SRC_DIRS),\
INCLUDES:=$(JDK_USER_DEFINED_FILTER),\
EXCLUDES:=$(EXCLUDES),\ EXCLUDES:=$(EXCLUDES),\
EXCLUDE_FILES:=$(EXFILES),\ EXCLUDE_FILES:=$(EXFILES),\
BIN:=$(JDK_OUTPUTDIR)/classes,\ BIN:=$(JDK_OUTPUTDIR)/classes,\
...@@ -360,13 +376,12 @@ ifeq ($(OPENJDK_TARGET_OS),macosx) ...@@ -360,13 +376,12 @@ ifeq ($(OPENJDK_TARGET_OS),macosx)
$(eval $(call SetupJavaCompiler,GENERATE_15BYTECODE,\ $(eval $(call SetupJavaCompiler,GENERATE_15BYTECODE,\
JAVAC:=$(JAVAC),\ JAVAC:=$(JAVAC),\
FLAGS:=-source 1.5 -target 1.5 -g -bootclasspath $(BOOT_RTJAR) -cp $(JDK_OUTPUTDIR)/../langtools/dist/lib/classes.jar $(DISABLE_WARNINGS),\ FLAGS:=-source 1.5 -target 1.5 -g -bootclasspath $(BOOT_RTJAR) -cp $(JDK_OUTPUTDIR)/../langtools/dist/lib/classes.jar $(DISABLE_WARNINGS),\
SERVER_DIR:=$(JAVAC_SERVERS),\ SERVER_DIR:=$(SJAVAC_SERVER_DIR),\
SERVER_JVM:=$(SERVER_JAVA),\ SERVER_JVM:=$(SJAVAC_SERVER_JAVA)))
MODE:=$(JAVAC_USE_MODE),\
USE_DEPS:=$(JAVAC_USE_DEPS)))
$(eval $(call SetupJavaCompilation,BUILD_JOBJC_JAR,\ $(eval $(call SetupJavaCompilation,BUILD_JOBJC_JAR,\
SETUP:=GENERATE_15BYTECODE,\ SETUP:=GENERATE_15BYTECODE,\
DISABLE_SJAVAC:=true,\
SRC:=$(JDK_TOPDIR)/src/macosx/native/jobjc/src/core/java \ SRC:=$(JDK_TOPDIR)/src/macosx/native/jobjc/src/core/java \
$(JDK_TOPDIR)/src/macosx/native/jobjc/src/runtime-additions/java \ $(JDK_TOPDIR)/src/macosx/native/jobjc/src/runtime-additions/java \
$(JDK_OUTPUTDIR)/gensrc, \ $(JDK_OUTPUTDIR)/gensrc, \
......
# #
# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as # under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this # published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided # particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code. # by Oracle in the LICENSE file that accompanied this code.
# #
# This code is distributed in the hope that it will be useful, but WITHOUT # This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License # 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 # version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code). # accompanied this code).
# #
# You should have received a copy of the GNU General Public License version # 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, # 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
# #
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 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 # or visit www.oracle.com if you need additional information or have any
# questions. # questions.
# #
defalt: all defalt: all
include $(SPEC) include $(SPEC)
include MakeBase.gmk include MakeBase.gmk
include NativeCompilation.gmk include NativeCompilation.gmk
# Setup the java compilers for the JDK build. # Setup the java compilers for the JDK build.
include Setup.gmk include Setup.gmk
# Build tools # Build tools
include Tools.gmk include Tools.gmk
BUILD_LAUNCHERS= BUILD_LAUNCHERS=
define SetupLauncher # When building a legacy overlay image (on solaris 64 bit), the launchers
# TODO: Fix mapfile on solaris. Won't work with ld as linker. # need to be built with a different rpath and a different output dir.
# Parameter 1 is the name of the launcher (java,javac,jar...) ifeq ($(OVERLAY_IMAGES),true)
# Parameter 2 is extra CFLAGS ORIGIN_ROOT:=/../..
# Parameter 3 is extra LDFLAGS OUTPUT_SUBDIR:=$(OPENJDK_TARGET_CPU_ISADIR)
# Parameter 4 is extra LDFLAGS_SUFFIX_posix else
# Parameter 5 is extra LDFLAGS_SUFFIX_winapi ORIGIN_ROOT:=/..
# Parameter 6 is optional Windows JLI library (full path) endif
# Parameter 7 is optional Windows resource (RC) flags
# Parameter 8 is optional Windows version resource file (.rc) ifeq ($(OPENJDK_TARGET_OS), macosx)
# Parameter 9 is different output dir ORIGIN_ARG:=$(call SET_EXECUTABLE_ORIGIN)
# Parameter 10 is FULL DEBUG SYMBOLS (set value to turn OFF, since most(all) seems to have it) else
ORIGIN_ARG:=$(call SET_EXECUTABLE_ORIGIN,$(ORIGIN_ROOT)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/jli) \
$1_WINDOWS_JLI_LIB:=$(JDK_OUTPUTDIR)/objs/libjli/jli.lib $(call SET_EXECUTABLE_ORIGIN,$(ORIGIN_ROOT)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR)/jli)
ifneq ($6,) endif
$1_WINDOWS_JLI_LIB:=$6
endif #
$1_VERSION_INFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc # Applications expect to be able to link against libjawt without invoking
ifneq ($8,) # System.loadLibrary("jawt") first. This was the behaviour described in the
$1_VERSION_INFO_RESOURCE:=$8 # devloper documentation of JAWT and what worked with OpenJDK6.
endif #
ifneq ($(findstring $(OPENJDK_TARGET_OS), linux solaris),)
$1_LDFLAGS := $3 ORIGIN_ARG+=$(call SET_EXECUTABLE_ORIGIN,$(ORIGIN_ROOT)/lib$(OPENJDK_TARGET_CPU_LIBDIR)) \
ifeq ($(OPENJDK_TARGET_OS), macosx) $(call SET_EXECUTABLE_ORIGIN,$(ORIGIN_ROOT)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR))
$1_LDFLAGS += -F/System/Library/Frameworks/JavaVM.framework/Frameworks \ endif
-F/System/Library/Frameworks/ApplicationServices.framework/Frameworks
endif define SetupLauncher
# TODO: Fix mapfile on solaris. Won't work with ld as linker.
$1_LDFLAGS_SUFFIX := # Parameter 1 is the name of the launcher (java,javac,jar...)
ifeq ($(USE_EXTERNAL_LIBZ), true) # Parameter 2 is extra CFLAGS
$1_LDFLAGS_SUFFIX += -lz # Parameter 3 is extra LDFLAGS
endif # Parameter 4 is extra LDFLAGS_SUFFIX_posix
# Parameter 5 is extra LDFLAGS_SUFFIX_windows
ifeq ($(OPENJDK_TARGET_OS), macosx) # Parameter 6 is optional Windows JLI library (full path)
$1_LDFLAGS_SUFFIX += -Wl,-all_load $(JDK_OUTPUTDIR)/objs/libjli_static.a \ # Parameter 7 is optional Windows resource (RC) flags
-framework Cocoa -framework Security -framework ApplicationServices \ # Parameter 8 is optional Windows version resource file (.rc)
-sectcreate __TEXT __info_plist $(JDK_TOPDIR)/src/macosx/lib/Info-cmdline.plist # Parameter 9 is different output dir
endif # Parameter 10 if set, link statically with c runtime on windows.
# Parameter 11 if set, override plist file on macosx.
$1_OUTPUT_DIR_ARG:=$9 $1_WINDOWS_JLI_LIB:=$(JDK_OUTPUTDIR)/objs/libjli/jli.lib
ifeq (,$$($1_OUTPUT_DIR_ARG)) ifneq ($6,)
$1_OUTPUT_DIR_ARG:=$(JDK_OUTPUTDIR)/bin $1_WINDOWS_JLI_LIB:=$6
endif endif
$1_VERSION_INFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc
$1_DEBUG_SYMBOLS:=yes ifneq ($8,)
ifneq (,$(10)) $1_VERSION_INFO_RESOURCE:=$8
$1_DEBUG_SYMBOLS:= endif
endif
$1_LDFLAGS := $3
$1_OPTIMIZATION:= LOW $1_LDFLAGS_SUFFIX :=
ifeq ($(OPENJDK_TARGET_OS), macosx)
# TODO: maybe it's better to move this if-statement out of this function $1_PLIST_FILE:=Info-cmdline.plist
ifeq ($(1),java) ifneq ($(11),)
$1_OPTIMIZATION:=HIGH $1_PLIST_FILE:=$(11)
endif endif
$(call SetupNativeCompilation,BUILD_LAUNCHER_$1,\ $1_LDFLAGS += -Wl,-all_load $(JDK_OUTPUTDIR)/objs/libjli_static.a \
SRC:=$(JDK_TOPDIR)/src/share/bin,\ -framework Cocoa -framework Security -framework ApplicationServices \
INCLUDE_FILES:=main.c,\ -sectcreate __TEXT __info_plist $(JDK_TOPDIR)/src/macosx/lib/$$($1_PLIST_FILE)
LANG:=C,\ $1_LDFLAGS_SUFFIX += -pthread
OPTIMIZATION :=$$($1_OPTIMIZATION), \ endif
CFLAGS:=$(CFLAGS_JDKEXE) \
-I$(JDK_TOPDIR)/src/share/bin \ ifeq ($(USE_EXTERNAL_LIBZ), true)
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/bin \ $1_LDFLAGS_SUFFIX += -lz
-I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS)/bin \ endif
-DFULL_VERSION='"$(FULL_VERSION)"' \
-DJDK_MAJOR_VERSION='"$(JDK_MAJOR_VERSION)"' \ $1_OUTPUT_DIR_ARG:=$9
-DJDK_MINOR_VERSION='"$(JDK_MINOR_VERSION)"' \ ifeq (,$$($1_OUTPUT_DIR_ARG))
-DLIBARCHNAME='"$(ARCH)"' \ $1_OUTPUT_DIR_ARG:=$(JDK_OUTPUTDIR)/bin
-DLAUNCHER_NAME='"java"' \ endif
-DPROGNAME='"$1"' $(DPACKAGEPATH) \
$2,\ # TODO: maybe it's better to move this if-statement out of this function
CFLAGS_linux:=-fPIC,\ ifeq ($1,java)
CFLAGS_solaris:=-KPIC -DHAVE_GETHRTIME,\ $1_OPTIMIZATION_ARG:=HIGH
LDFLAGS:=$(LDFLAGS_JDKEXE) \ $1_LDFLAGS_solaris:=-R$(OPENWIN_HOME)/lib$(OPENJDK_TARGET_CPU_ISADIR)
$(call SET_SHARED_LIBRARY_ORIGIN,../lib/$(LIBARCH)/jli) \ else
$(call SET_SHARED_LIBRARY_ORIGIN,../jre/lib/$(LIBARCH)/jli) \ $1_OPTIMIZATION_ARG:=LOW
$$($1_LDFLAGS),\ endif
MAPFILE := $(JDK_TOPDIR)/makefiles/mapfiles/launchers/mapfile-$(ARCH), \
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKEXE_SUFFIX) $$($1_LDFLAGS_SUFFIX),\ $1_CFLAGS:=$(CFLAGS_JDKEXE)
LDFLAGS_SUFFIX_posix:=$4 -lc,\ ifeq ($(10),true)
LDFLAGS_SUFFIX_winapi:=$$($1_WINDOWS_JLI_LIB) \ $1_CFLAGS:=$(filter-out -MD,$(CFLAGS_JDKEXE))
$(JDK_OUTPUTDIR)/objs/libjava/java.lib advapi32.lib $5,\ endif
LDFLAGS_SUFFIX_solaris := -lthread $(LIBDL), \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/$1_objs,\ $(call SetupNativeCompilation,BUILD_LAUNCHER_$1,\
OUTPUT_DIR:=$$($1_OUTPUT_DIR_ARG),\ SRC:=$(JDK_TOPDIR)/src/share/bin,\
PROGRAM:=$1,\ INCLUDE_FILES:=main.c,\
DEBUG_SYMBOLS:=$$($1_DEBUG_SYMBOLS),\ LANG:=C,\
VERSIONINFO_RESOURCE:=$$($1_VERSION_INFO_RESOURCE),\ OPTIMIZATION:=$$($1_OPTIMIZATION_ARG), \
RC_FLAGS:=$(RC_FLAGS)\ CFLAGS:=$$($1_CFLAGS) \
/D "JDK_FNAME=$1$(EXE_SUFFIX)" \ -I$(JDK_TOPDIR)/src/share/bin \
/D "JDK_INTERNAL_NAME=$1" \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin \
/D "JDK_FTYPE=0x1L" \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS)/bin \
$7,\ -DFULL_VERSION='"$(FULL_VERSION)"' \
MANIFEST:=$(JDK_TOPDIR)/src/windows/resource/java.manifest) -DJDK_MAJOR_VERSION='"$(JDK_MAJOR_VERSION)"' \
-DJDK_MINOR_VERSION='"$(JDK_MINOR_VERSION)"' \
BUILD_LAUNCHERS += $$(BUILD_LAUNCHER_$1) -DLIBARCHNAME='"$(OPENJDK_TARGET_CPU_LEGACY)"' \
-DLAUNCHER_NAME='"$(LAUNCHER_NAME)"' \
ifeq ($(OPENJDK_TARGET_OS),macosx) -DPROGNAME='"$1"' $(DPACKAGEPATH) \
$$(BUILD_LAUNCHER_$1) : $(JDK_OUTPUTDIR)/objs/libjli_static.a $2,\
endif CFLAGS_linux:=-fPIC,\
CFLAGS_solaris:=-KPIC -DHAVE_GETHRTIME,\
ifeq ($(OPENJDK_TARGET_OS),windows) LDFLAGS:=$(LDFLAGS_JDKEXE) \
$$(BUILD_LAUNCHER_$1) : $(JDK_OUTPUTDIR)/objs/libjava/java.lib \ $(ORIGIN_ARG) \
$$($1_WINDOWS_JLI_LIB) $$($1_LDFLAGS),\
endif LDFLAGS_macosx:=$(call SET_SHARED_LIBRARY_NAME,$1),\
endef LDFLAGS_linux:=-lpthread \
$(call SET_SHARED_LIBRARY_NAME,$(LIBRARY_PREFIX)$(SHARED_LIBRARY_SUFFIX)),\
########################################################################################## LDFLAGS_solaris:=$$($1_LDFLAGS_solaris) \
$(call SET_SHARED_LIBRARY_NAME,$(LIBRARY_PREFIX)$(SHARED_LIBRARY_SUFFIX)),\
XLIBS:=$(X_LIBS) -lX11 MAPFILE := $(JDK_TOPDIR)/makefiles/mapfiles/launchers/mapfile-$(OPENJDK_TARGET_CPU), \
ifeq ($(OPENJDK_TARGET_OS),macosx) LDFLAGS_SUFFIX:=$(LDFLAGS_JDKEXE_SUFFIX) $$($1_LDFLAGS_SUFFIX),\
DPACKAGEPATH:=-DPACKAGE_PATH='"$(PACKAGE_PATH)"' LDFLAGS_SUFFIX_posix:=$4,\
XLIBS:= LDFLAGS_SUFFIX_windows:=$$($1_WINDOWS_JLI_LIB) \
endif $(JDK_OUTPUTDIR)/objs/libjava/java.lib advapi32.lib $5,\
LDFLAGS_SUFFIX_linux:=-L$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/jli -ljli $(LIBDL) -lc, \
ifdef OPENJDK LDFLAGS_SUFFIX_solaris:=-L$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/jli -ljli -lthread $(LIBDL) -lc, \
JAVA_RC_FLAGS += -i "$(JDK_TOPDIR)/src/windows/resource/icons" OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/$1_objs$(OUTPUT_SUBDIR),\
else OUTPUT_DIR:=$$($1_OUTPUT_DIR_ARG)$(OUTPUT_SUBDIR),\
JAVA_RC_FLAGS += -i "$(JDK_TOPDIR)/src/closed/windows/native/sun/windows" PROGRAM:=$1,\
endif DEBUG_SYMBOLS:=true,\
VERSIONINFO_RESOURCE:=$$($1_VERSION_INFO_RESOURCE),\
$(eval $(call SetupLauncher,java,\ RC_FLAGS:=$(RC_FLAGS)\
-DEXPAND_CLASSPATH_WILDCARDS,,,user32.lib comctl32.lib,\ /D "JDK_FNAME=$1$(EXE_SUFFIX)" \
$(JDK_OUTPUTDIR)/objs/jli_static.lib,$(JAVA_RC_FLAGS),\ /D "JDK_INTERNAL_NAME=$1" \
$(JDK_TOPDIR)/src/windows/resource/java.rc)) /D "JDK_FTYPE=0x1L" \
$7,\
ifeq ($(OPENJDK_TARGET_OS),windows) MANIFEST:=$(JDK_TOPDIR)/src/windows/resource/java.manifest)
$(eval $(call SetupLauncher,javaw,\
-DEXPAND_CLASSPATH_WILDCARDS,,,user32.lib comctl32.lib,\ BUILD_LAUNCHERS += $$(BUILD_LAUNCHER_$1)
$(JDK_OUTPUTDIR)/objs/jli_static.lib,$(JAVA_RC_FLAGS),\
$(JDK_TOPDIR)/src/windows/resource/java.rc)) ifeq ($(OPENJDK_TARGET_OS),macosx)
endif $$(BUILD_LAUNCHER_$1) : $(JDK_OUTPUTDIR)/objs/libjli_static.a
endif
ifeq ($(OPENJDK_TARGET_OS),solaris)
THREAD_LIB:=-lthread ifeq ($(OPENJDK_TARGET_OS),windows)
endif $$(BUILD_LAUNCHER_$1) : $(JDK_OUTPUTDIR)/objs/libjava/java.lib \
ifeq ($(OPENJDK_TARGET_OS),linux) $$($1_WINDOWS_JLI_LIB)
THREAD_LIB:=-lpthread endif
endif endef
ifndef BUILD_HEADLESS_ONLY ##########################################################################################
$(eval $(call SetupLauncher,appletviewer,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.applet.Main"$(COMMA) }',,\ XLIBS:=$(X_LIBS) -lX11
$(THREAD_LIB) $(XLIBS) -ldl)) ifeq ($(OPENJDK_TARGET_OS),macosx)
endif DPACKAGEPATH:=-DPACKAGE_PATH='"$(PACKAGE_PATH)"'
XLIBS:=
$(eval $(call SetupLauncher,extcheck,\ endif
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.extcheck.Main"$(COMMA) }'))
ifdef OPENJDK
$(eval $(call SetupLauncher,idlj,\ JAVA_RC_FLAGS += -i "$(JDK_TOPDIR)/src/windows/resource/icons"
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.corba.se.idl.toJavaPortable.Compile"$(COMMA) }')) else
JAVA_RC_FLAGS += -i "$(JDK_TOPDIR)/src/closed/windows/native/sun/windows"
$(eval $(call SetupLauncher,jar,\ endif
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jar.Main"$(COMMA) }'))
# On windows, the debuginfo files get the same name as for java.dll. Build
$(eval $(call SetupLauncher,jarsigner,\ # into another dir and copy selectively so debuginfo for java.dll isn't
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.tools.JarSigner"$(COMMA) }')) # overwritten.
$(eval $(call SetupLauncher,java,\
$(eval $(call SetupLauncher,javac,\ -DEXPAND_CLASSPATH_WILDCARDS,,,user32.lib comctl32.lib,\
-DEXPAND_CLASSPATH_WILDCARDS \ $(JDK_OUTPUTDIR)/objs/jli_static.lib,$(JAVA_RC_FLAGS),\
-DNEVER_ACT_AS_SERVER_CLASS_MACHINE \ $(JDK_TOPDIR)/src/windows/resource/java.rc,$(JDK_OUTPUTDIR)/objs/java_objs,true))
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.javac.Main"$(COMMA) }'))
$(JDK_OUTPUTDIR)/bin$(OUTPUT_SUBDIR)/java$(EXE_SUFFIX): $(BUILD_LAUNCHER_java)
$(eval $(call SetupLauncher,javadoc,\ $(MKDIR) -p $(@D)
-DEXPAND_CLASSPATH_WILDCARDS \ $(RM) $@
-DNEVER_ACT_AS_SERVER_CLASS_MACHINE \ $(CP) $(JDK_OUTPUTDIR)/objs/java_objs$(OUTPUT_SUBDIR)/java$(EXE_SUFFIX) $@
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.javadoc.Main"$(COMMA) }'))
BUILD_LAUNCHERS += $(JDK_OUTPUTDIR)/bin$(OUTPUT_SUBDIR)/java$(EXE_SUFFIX)
$(eval $(call SetupLauncher,javah,\
-DEXPAND_CLASSPATH_WILDCARDS \ ifeq ($(OPENJDK_TARGET_OS),windows)
-DNEVER_ACT_AS_SERVER_CLASS_MACHINE \ $(eval $(call SetupLauncher,javaw,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.javah.Main"$(COMMA) }')) -DJAVAW -DEXPAND_CLASSPATH_WILDCARDS,,,user32.lib comctl32.lib,\
$(JDK_OUTPUTDIR)/objs/jli_static.lib,$(JAVA_RC_FLAGS),\
$(eval $(call SetupLauncher,javap,\ $(JDK_TOPDIR)/src/windows/resource/java.rc,,true))
-DEXPAND_CLASSPATH_WILDCARDS \ endif
-DNEVER_ACT_AS_SERVER_CLASS_MACHINE \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.javap.Main"$(COMMA) }'))
ifndef BUILD_HEADLESS_ONLY
BUILD_LAUNCHER_jconsole_CPPFLAGS_windows:=-DJAVAW $(eval $(call SetupLauncher,appletviewer,\
BUILD_LAUNCHER_jconsole_LDFLAGS_windows:=user32.lib -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.applet.Main"$(COMMA) }',,\
$(XLIBS)))
$(eval $(call SetupLauncher,jconsole,\ endif
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "-J-Djconsole.showOutputViewer"$(COMMA) "sun.tools.jconsole.JConsole"$(COMMA) }' \
-DAPP_CLASSPATH='{ "/lib/jconsole.jar"$(COMMA) "/lib/tools.jar"$(COMMA) "/classes" }')) $(eval $(call SetupLauncher,extcheck,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.extcheck.Main"$(COMMA) }'))
$(eval $(call SetupLauncher,jdb,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.example.debug.tty.TTY"$(COMMA) }' \ $(eval $(call SetupLauncher,idlj,\
-DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.corba.se.idl.toJavaPortable.Compile"$(COMMA) }'))
$(eval $(call SetupLauncher,jhat,\ $(eval $(call SetupLauncher,jar,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.hat.Main"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jar.Main"$(COMMA) }'))
$(eval $(call SetupLauncher,jinfo,\ $(eval $(call SetupLauncher,jarsigner,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.tools.JarSigner"$(COMMA) }'))
"-J-Dsun.jvm.hotspot.debugger.useProcDebugger"$(COMMA) \
"-J-Dsun.jvm.hotspot.debugger.useWindbgDebugger"$(COMMA) \ $(eval $(call SetupLauncher,javac,\
"sun.tools.jinfo.JInfo"$(COMMA) }' \ -DEXPAND_CLASSPATH_WILDCARDS \
-DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }')) -DNEVER_ACT_AS_SERVER_CLASS_MACHINE \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.javac.Main"$(COMMA) }'))
$(eval $(call SetupLauncher,jmap,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \ $(eval $(call SetupLauncher,javadoc,\
"-J-Dsun.jvm.hotspot.debugger.useProcDebugger"$(COMMA) \ -DEXPAND_CLASSPATH_WILDCARDS \
"-J-Dsun.jvm.hotspot.debugger.useWindbgDebugger"$(COMMA) \ -DNEVER_ACT_AS_SERVER_CLASS_MACHINE \
"sun.tools.jmap.JMap"$(COMMA) }' \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.javadoc.Main"$(COMMA) }'))
-DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }'))
$(eval $(call SetupLauncher,javah,\
$(eval $(call SetupLauncher,jps,\ -DEXPAND_CLASSPATH_WILDCARDS \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jps.Jps"$(COMMA) }')) -DNEVER_ACT_AS_SERVER_CLASS_MACHINE \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.javah.Main"$(COMMA) }'))
$(eval $(call SetupLauncher,jrunscript,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.script.shell.Main"$(COMMA) }')) $(eval $(call SetupLauncher,javap,\
-DEXPAND_CLASSPATH_WILDCARDS \
$(eval $(call SetupLauncher,jsadebugd,\ -DNEVER_ACT_AS_SERVER_CLASS_MACHINE \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.jvm.hotspot.jdi.SADebugServer"$(COMMA) }' \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.javap.Main"$(COMMA) }'))
-DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }'))
BUILD_LAUNCHER_jconsole_CFLAGS_windows:=-DJAVAW
$(eval $(call SetupLauncher,jstack,\ BUILD_LAUNCHER_jconsole_LDFLAGS_windows:=user32.lib
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \
"-J-Dsun.jvm.hotspot.debugger.useProcDebugger"$(COMMA) \ $(eval $(call SetupLauncher,jconsole,\
"-J-Dsun.jvm.hotspot.debugger.useWindbgDebugger"$(COMMA) \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "-J-Djconsole.showOutputViewer"$(COMMA) "sun.tools.jconsole.JConsole"$(COMMA) }' \
"sun.tools.jstack.JStack"$(COMMA) }' \ -DAPP_CLASSPATH='{ "/lib/jconsole.jar"$(COMMA) "/lib/tools.jar"$(COMMA) "/classes" }'))
-DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }'))
$(eval $(call SetupLauncher,jdb,\
$(eval $(call SetupLauncher,jstat,\ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.example.debug.tty.TTY"$(COMMA) }' \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jstat.Jstat"$(COMMA) }')) -DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }'))
$(eval $(call SetupLauncher,jstatd,\ $(eval $(call SetupLauncher,jhat,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jstatd.Jstatd"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.hat.Main"$(COMMA) }'))
$(eval $(call SetupLauncher,keytool,\ $(eval $(call SetupLauncher,jinfo,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.tools.KeyTool"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \
"-J-Dsun.jvm.hotspot.debugger.useProcDebugger"$(COMMA) \
$(eval $(call SetupLauncher,native2ascii,\ "-J-Dsun.jvm.hotspot.debugger.useWindbgDebugger"$(COMMA) \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.native2ascii.Main"$(COMMA) }')) "sun.tools.jinfo.JInfo"$(COMMA) }' \
-DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }' \
ifndef BUILD_HEADLESS_ONLY ,,,,,,,,,Info-privileged.plist))
$(eval $(call SetupLauncher,policytool,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.tools.policytool.PolicyTool"$(COMMA) }')) $(eval $(call SetupLauncher,jmap,\
endif -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \
"-J-Dsun.jvm.hotspot.debugger.useProcDebugger"$(COMMA) \
$(eval $(call SetupLauncher,rmic,\ "-J-Dsun.jvm.hotspot.debugger.useWindbgDebugger"$(COMMA) \
-DEXPAND_CLASSPATH_WILDCARDS \ "sun.tools.jmap.JMap"$(COMMA) }' \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.rmi.rmic.Main"$(COMMA) }')) -DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }' \
,,,,,,,,,Info-privileged.plist))
$(eval $(call SetupLauncher,schemagen,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.internal.jxc.SchemaGenerator"$(COMMA) }')) $(eval $(call SetupLauncher,jps,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jps.Jps"$(COMMA) }'))
$(eval $(call SetupLauncher,serialver,\
-DEXPAND_CLASSPATH_WILDCARDS \ $(eval $(call SetupLauncher,jrunscript,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.serialver.SerialVer"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.script.shell.Main"$(COMMA) }'))
$(eval $(call SetupLauncher,xjc,\ $(eval $(call SetupLauncher,jsadebugd,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.internal.xjc.Driver"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.jvm.hotspot.jdi.SADebugServer"$(COMMA) }' \
-DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }' \
$(eval $(call SetupLauncher,wsgen,\ ,,,,,,,,,Info-privileged.plist))
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.internal.ws.WsGen"$(COMMA) }'))
$(eval $(call SetupLauncher,jstack,\
$(eval $(call SetupLauncher,wsimport,\ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.internal.ws.WsImport"$(COMMA) }')) "-J-Dsun.jvm.hotspot.debugger.useProcDebugger"$(COMMA) \
"-J-Dsun.jvm.hotspot.debugger.useWindbgDebugger"$(COMMA) \
$(eval $(call SetupLauncher,orbd,\ "sun.tools.jstack.JStack"$(COMMA) }' \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \ -DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }' \
"-J-Dcom.sun.CORBA.activation.DbDir=./orb.db"$(COMMA) \ ,,,,,,,,,Info-privileged.plist))
"-J-Dcom.sun.CORBA.activation.Port=1049"$(COMMA) \
"-J-Dcom.sun.CORBA.POA.ORBServerId=1"$(COMMA) \ $(eval $(call SetupLauncher,jstat,\
"com.sun.corba.se.impl.activation.ORBD"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jstat.Jstat"$(COMMA) }'))
$(eval $(call SetupLauncher,servertool,\ $(eval $(call SetupLauncher,jstatd,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.corba.se.impl.activation.ServerTool"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jstatd.Jstatd"$(COMMA) }'))
$(eval $(call SetupLauncher,tnameserv,\ $(eval $(call SetupLauncher,keytool,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.tools.KeyTool"$(COMMA) }'))
"-J-Dcom.sun.CORBA.activation.DbDir=./orb.db"$(COMMA) \
"-J-Djava.util.logging.LoggingPermission=contol"$(COMMA) \ $(eval $(call SetupLauncher,native2ascii,\
"-J-Dcom.sun.CORBA.POA.ORBServerId=1"$(COMMA) \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.native2ascii.Main"$(COMMA) }'))
"com.sun.corba.se.impl.naming.cosnaming.TransientNameServer"$(COMMA) }'))
ifndef BUILD_HEADLESS_ONLY
$(eval $(call SetupLauncher,pack200,\ $(eval $(call SetupLauncher,policytool,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.java.util.jar.pack.Driver"$(COMMA) "--pack" }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.tools.policytool.PolicyTool"$(COMMA) }',,\
$(XLIBS)))
$(eval $(call SetupLauncher,rmid,\ endif
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.rmi.server.Activation"$(COMMA) }'))
$(eval $(call SetupLauncher,rmic,\
$(eval $(call SetupLauncher,rmiregistry,\ -DEXPAND_CLASSPATH_WILDCARDS \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.rmi.registry.RegistryImpl"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.rmi.rmic.Main"$(COMMA) }'))
$(eval $(call SetupLauncher,jcmd,\ $(eval $(call SetupLauncher,schemagen,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jcmd.JCmd"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.internal.jxc.SchemaGenerator"$(COMMA) }'))
ifeq ($(OPENJDK_TARGET_OS),windows) $(eval $(call SetupLauncher,serialver,\
$(eval $(call SetupLauncher,kinit,\ -DEXPAND_CLASSPATH_WILDCARDS \
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.krb5.internal.tools.Kinit"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.serialver.SerialVer"$(COMMA) }'))
$(eval $(call SetupLauncher,klist,\ $(eval $(call SetupLauncher,xjc,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.krb5.internal.tools.Klist"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.internal.xjc.Driver"$(COMMA) }'))
$(eval $(call SetupLauncher,ktab,\ $(eval $(call SetupLauncher,wsgen,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.krb5.internal.tools.Ktab"$(COMMA) }')) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.internal.ws.WsGen"$(COMMA) }'))
endif
$(eval $(call SetupLauncher,wsimport,\
########################################################################################## -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.internal.ws.WsImport"$(COMMA) }'))
# The order of the object files on the link command line affects the size of the resulting
# binary (at least on linux) which causes the size to differ between old and new build. $(eval $(call SetupLauncher,orbd,\
ifeq ($(USE_EXTERNAL_LIBZ), true) -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \
UNPACKEXE_CFLAGS := -DSYSTEM_ZLIB "-J-Dcom.sun.CORBA.activation.DbDir=./orb.db"$(COMMA) \
UNPACKEXE_ZIPOBJS := -lz "-J-Dcom.sun.CORBA.activation.Port=1049"$(COMMA) \
else "-J-Dcom.sun.CORBA.POA.ORBServerId=1"$(COMMA) \
UNPACKEXE_CFLAGS := -I$(JDK_TOPDIR)/src/share/native/java/util/zip/zlib-1.2.5 "com.sun.corba.se.impl.activation.ORBD"$(COMMA) }'))
UNPACKEXE_ZIPOBJS := $(JDK_OUTPUTDIR)/objs/libzip/zcrc32$(OBJ_SUFFIX) \
$(JDK_OUTPUTDIR)/objs/libzip/deflate$(OBJ_SUFFIX) \ $(eval $(call SetupLauncher,servertool,\
$(JDK_OUTPUTDIR)/objs/libzip/trees$(OBJ_SUFFIX) \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.corba.se.impl.activation.ServerTool"$(COMMA) }'))
$(JDK_OUTPUTDIR)/objs/libzip/zadler32$(OBJ_SUFFIX) \
$(JDK_OUTPUTDIR)/objs/libzip/compress$(OBJ_SUFFIX) \ $(eval $(call SetupLauncher,tnameserv,\
$(JDK_OUTPUTDIR)/objs/libzip/zutil$(OBJ_SUFFIX) \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) \
$(JDK_OUTPUTDIR)/objs/libzip/inflate$(OBJ_SUFFIX) \ "-J-Dcom.sun.CORBA.activation.DbDir=./orb.db"$(COMMA) \
$(JDK_OUTPUTDIR)/objs/libzip/infback$(OBJ_SUFFIX) \ "-J-Djava.util.logging.LoggingPermission=contol"$(COMMA) \
$(JDK_OUTPUTDIR)/objs/libzip/inftrees$(OBJ_SUFFIX) \ "-J-Dcom.sun.CORBA.POA.ORBServerId=1"$(COMMA) \
$(JDK_OUTPUTDIR)/objs/libzip/inffast$(OBJ_SUFFIX) "com.sun.corba.se.impl.naming.cosnaming.TransientNameServer"$(COMMA) }'))
endif $(eval $(call SetupLauncher,pack200,\
-DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.java.util.jar.pack.Driver"$(COMMA) "--pack" }'))
ifeq ($(OPENJDK_TARGET_CPU_ARCH), sparc)
UNPACKEXE_CFLAGS += -xregs=no%appl $(eval $(call SetupLauncher,rmid,\
endif -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.rmi.server.Activation"$(COMMA) }'))
$(eval $(call SetupNativeCompilation,BUILD_UNPACKEXE,\ $(eval $(call SetupLauncher,rmiregistry,\
SRC:=$(JDK_TOPDIR)/src/share/native/com/sun/java/util/jar/pack,\ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.rmi.registry.RegistryImpl"$(COMMA) }'))
EXCLUDE_FILES:=jni.cpp,\
LANG:=C,\ $(eval $(call SetupLauncher,jcmd,\
OPTIMIZATION := LOW, \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.tools.jcmd.JCmd"$(COMMA) }'))
CFLAGS:=$(UNPACKEXE_CFLAGS) $(CXXFLAGS_JDKEXE)\
-DFULL, \ ifeq ($(OPENJDK_TARGET_OS),windows)
CFLAGS_release:=-DPRODUCT,\ $(eval $(call SetupLauncher,kinit,\
CFLAGS_linux:=-fPIC,\ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.krb5.internal.tools.Kinit"$(COMMA) }'))
CFLAGS_solaris := -KPIC, \
CFLAGS_macosx := -fPIC, \ $(eval $(call SetupLauncher,klist,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libunpack/mapfile-vers-unpack200, \ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.krb5.internal.tools.Klist"$(COMMA) }'))
LDFLAGS:=$(LDFLAGS_JDKEXE) \
$(call SET_SHARED_LIBRARY_ORIGIN), \ $(eval $(call SetupLauncher,ktab,\
LDFLAGS_SUFFIX:=$(UNPACKEXE_ZIPOBJS) $(LIBCXX),\ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.security.krb5.internal.tools.Ktab"$(COMMA) }'))
LDFLAGS_SUFFIX_solaris:=-lc,\ endif
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/unpackexe,\
OUTPUT_DIR:=$(JDK_OUTPUTDIR)/bin,\ ##########################################################################################
PROGRAM:=unpack200,\ # The order of the object files on the link command line affects the size of the resulting
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\ # binary (at least on linux) which causes the size to differ between old and new build.
RC_FLAGS:=$(RC_FLAGS)\ ifeq ($(USE_EXTERNAL_LIBZ), true)
/D "JDK_FNAME=unpack200.exe" \ UNPACKEXE_CFLAGS := -DSYSTEM_ZLIB
/D "JDK_INTERNAL_NAME=unpack200" \ UNPACKEXE_ZIPOBJS := -lz
/D "JDK_FTYPE=0x1L",\ else
MANIFEST:=$(JDK_TOPDIR)/src/windows/resource/unpack200_proto.exe.manifest)) UNPACKEXE_CFLAGS := -I$(JDK_TOPDIR)/src/share/native/java/util/zip/zlib-1.2.5
UNPACKEXE_ZIPOBJS := $(JDK_OUTPUTDIR)/objs/libzip/zcrc32$(OBJ_SUFFIX) \
ifneq ($(USE_EXTERNAL_LIBZ), true) $(JDK_OUTPUTDIR)/objs/libzip/deflate$(OBJ_SUFFIX) \
$(JDK_OUTPUTDIR)/objs/libzip/trees$(OBJ_SUFFIX) \
$(BUILD_UNPACKEXE) : $(UNPACKEXE_ZIPOBJS) $(JDK_OUTPUTDIR)/objs/libzip/zadler32$(OBJ_SUFFIX) \
$(JDK_OUTPUTDIR)/objs/libzip/compress$(OBJ_SUFFIX) \
endif $(JDK_OUTPUTDIR)/objs/libzip/zutil$(OBJ_SUFFIX) \
$(JDK_OUTPUTDIR)/objs/libzip/inflate$(OBJ_SUFFIX) \
BUILD_LAUNCHERS += $(BUILD_UNPACKEXE) $(JDK_OUTPUTDIR)/objs/libzip/infback$(OBJ_SUFFIX) \
$(JDK_OUTPUTDIR)/objs/libzip/inftrees$(OBJ_SUFFIX) \
########################################################################################## $(JDK_OUTPUTDIR)/objs/libzip/inffast$(OBJ_SUFFIX)
endif
BUILD_JEXEC :=
BUILD_JEXEC_SRC := ifeq ($(OPENJDK_TARGET_CPU_ARCH), sparc)
BUILD_JEXEC_INC := UNPACKEXE_CFLAGS += -xregs=no%appl
BUILD_JEXEC_DST_DIR := $(JDK_OUTPUTDIR)/lib/$(LIBARCH) endif
# UNPACKEXE_LANG:=C
# UNHANDLED: ifeq ($(OPENJDK_TARGET_OS),solaris)
# - COMPILE_APPROACH = normal UNPACKEXE_LANG:=C++
# endif
# $(eval $(call SetupNativeCompilation,BUILD_UNPACKEXE,\
# jdk/make/java/Makefile SRC:=$(JDK_TOPDIR)/src/share/native/com/sun/java/util/jar/pack,\
# EXCLUDE_FILES:=jni.cpp,\
ifeq ($(OPENJDK_TARGET_OS), solaris) LANG:=$(UNPACKEXE_LANG),\
ifeq ($(ARCH_DATA_MODEL), 32) OPTIMIZATION := LOW, \
BUILD_JEXEC := 1 CFLAGS:=$(UNPACKEXE_CFLAGS) $(CXXFLAGS_JDKEXE)\
endif -DFULL, \
endif CFLAGS_release:=-DPRODUCT,\
CFLAGS_linux:=-fPIC,\
ifeq ($(OPENJDK_TARGET_OS), linux) CFLAGS_solaris := -KPIC, \
BUILD_JEXEC := 1 CFLAGS_macosx := -fPIC, \
endif # OPENJDK_TARGET_OS MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libunpack/mapfile-vers-unpack200, \
LDFLAGS:=$(LDFLAGS_JDKEXE) $(LDFLAGS_CXX_JDK) \
# $(call SET_SHARED_LIBRARY_NAME,$(LIBRARY_PREFIX)unpack$(SHARED_LIBRARY_SUFFIX)) \
# jdk/make/java/jexec/Makefile $(call SET_SHARED_LIBRARY_ORIGIN) \
# $(UNPACKEXE_ZIPOBJS),\
ifeq ($(BUILD_JEXEC), 1) LDFLAGS_linux:=-lc,\
LDFLAGS_SUFFIX:=$(LIBCXX),\
ifeq ($(OPENJDK_TARGET_OS),windows) LDFLAGS_SUFFIX_solaris:=-lc,\
else ifeq ($(OPENJDK_TARGET_OS),macosx) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/unpackexe$(OUTPUT_SUBDIR),\
BUILD_JEXEC_SRC := $(JDK_TOPDIR)/src/macosx/bin OUTPUT_DIR:=$(JDK_OUTPUTDIR)/bin$(OUTPUT_SUBDIR),\
else PROGRAM:=unpack200,\
BUILD_JEXEC_SRC := $(JDK_TOPDIR)/src/solaris/bin VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
endif RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=unpack200.exe" \
ifeq ($(OPENJDK_TARGET_OS), linux) /D "JDK_INTERNAL_NAME=unpack200" \
BUILD_JEXEC_DST_DIR := $(JDK_OUTPUTDIR)/lib /D "JDK_FTYPE=0x1L",\
BUILD_JEXEC_INC += -I$(JDK_TOPDIR)/src/share/bin MANIFEST:=$(JDK_TOPDIR)/src/windows/resource/unpack200_proto.exe.manifest))
endif
endif ifneq ($(USE_EXTERNAL_LIBZ), true)
# $(BUILD_UNPACKEXE) : $(UNPACKEXE_ZIPOBJS)
# Note that the two Makefile's seems to contradict each other,
# and that src/macosx/bin/jexec.c seems unused endif
#
ifneq ($(BUILD_JEXEC_SRC),) BUILD_LAUNCHERS += $(BUILD_UNPACKEXE)
$(eval $(call SetupNativeCompilation,BUILD_JEXEC,\
SRC:=$(BUILD_JEXEC_SRC),\ ##########################################################################################
INCLUDE_FILES:=jexec.c,\
LANG:=C,\
OPTIMIZATION := LOW, \ BUILD_JEXEC :=
CFLAGS:=$(CFLAGS_JDKEXE)\ BUILD_JEXEC_SRC :=
$(BUILD_JEXEC_INC), \ BUILD_JEXEC_INC :=
LDFLAGS:=$(LDFLAGS_JDKEXE), \ BUILD_JEXEC_DST_DIR := $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/jexec_obj,\
OUTPUT_DIR:=$(BUILD_JEXEC_DST_DIR),\ #
PROGRAM:=jexec)) # UNHANDLED:
# - COMPILE_APPROACH = normal
BUILD_LAUNCHERS += $(BUILD_JEXEC) #
endif
#
########################################################################################## # jdk/make/java/Makefile
#
# ifeq ($(OPENJDK_TARGET_OS), solaris)
# The java-rmi.cgi script in bin/ only gets delivered in certain situations ifeq ($(OPENJDK_TARGET_CPU_BITS), 32)
# BUILD_JEXEC := 1
JAVA_RMI_CGI:=$(JDK_OUTPUTDIR)/bin/java-rmi.cgi endif
ifeq ($(OPENJDK_TARGET_OS), linux) endif
BUILD_LAUNCHERS += $(JAVA_RMI_CGI)
endif ifeq ($(OPENJDK_TARGET_OS), linux)
ifeq ($(OPENJDK_TARGET_OS), solaris) BUILD_JEXEC := 1
ifeq ($(ARCH_DATA_MODEL), 32) endif # OPENJDK_TARGET_OS
BUILD_LAUNCHERS += $(JAVA_RMI_CGI)
endif #
endif # jdk/make/java/jexec/Makefile
#
# TODO: ifeq ($(BUILD_JEXEC), 1)
# On windows java-rmi.cgi shouldn't be bundled since Java 1.2, but has been built all
# this time anyway. Since jdk6, it has been built from the wrong source and resulted ifeq ($(OPENJDK_TARGET_OS),windows)
# in a copy of the standard java launcher named "java-rmi.exe" ending up in the final else ifeq ($(OPENJDK_TARGET_OS),macosx)
# images bin dir. This weird behavior is mimicked here in the converted makefiles for BUILD_JEXEC_SRC := $(JDK_TOPDIR)/src/macosx/bin
# now. Should probably just be deleted. else
# http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6512052 BUILD_JEXEC_SRC := $(JDK_TOPDIR)/src/solaris/bin
ifeq ($(OPENJDK_TARGET_OS_API),winapi) endif
$(eval $(call SetupLauncher,java-rmi,\
-DEXPAND_CLASSPATH_WILDCARDS,\ ifeq ($(OPENJDK_TARGET_OS), linux)
$(call SET_SHARED_LIBRARY_MAPFILE,$(JDK_TOPDIR)/makefiles/java/main/java/mapfile-$(ARCH)),\ BUILD_JEXEC_DST_DIR := $(JDK_OUTPUTDIR)/lib
,,,,,$(JDK_OUTPUTDIR)/objs)) BUILD_JEXEC_INC += -I$(JDK_TOPDIR)/src/share/bin
endif
$(JAVA_RMI_CGI): $(BUILD_LAUNCHER_java-rmi) endif
$(MKDIR) -p $(@D)
$(CP) $< $@ #
# Note that the two Makefile's seems to contradict each other,
BUILD_LAUNCHERS += $(JAVA_RMI_CGI) # and that src/macosx/bin/jexec.c seems unused
else #
$(JAVA_RMI_CGI): $(JDK_TOPDIR)/src/solaris/bin/java-rmi.cgi.sh ifneq ($(BUILD_JEXEC_SRC),)
$(MKDIR) -p $(@D) $(eval $(call SetupNativeCompilation,BUILD_JEXEC,\
$(CP) $< $@ SRC:=$(BUILD_JEXEC_SRC),\
$(CHMOD) a+x $@ INCLUDE_FILES:=jexec.c,\
endif LANG:=C,\
OPTIMIZATION := LOW, \
########################################################################################## CFLAGS:=$(CFLAGS_JDKEXE)\
$(BUILD_JEXEC_INC), \
$(BUILD_LAUNCHERS) : $(JDK_TOPDIR)/makefiles/CompileLaunchers.gmk CFLAGS_linux:=-fPIC,\
CFLAGS_solaris:=-KPIC,\
all: $(BUILD_LAUNCHERS) LDFLAGS:=$(LDFLAGS_JDKEXE) \
$(call SET_SHARED_LIBRARY_NAME,$(LIBRARY_PREFIX)$(SHARED_LIBRARY_SUFFIX)), \
.PHONY: all OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/jexec_obj,\
OUTPUT_DIR:=$(BUILD_JEXEC_DST_DIR),\
PROGRAM:=jexec))
BUILD_LAUNCHERS += $(BUILD_JEXEC)
endif
##########################################################################################
#
# The java-rmi.cgi script in bin/ only gets delivered in certain situations
#
JAVA_RMI_CGI:=$(JDK_OUTPUTDIR)/bin$(OUTPUT_SUBDIR)/java-rmi.cgi
ifeq ($(OPENJDK_TARGET_OS), linux)
BUILD_LAUNCHERS += $(JAVA_RMI_CGI)
endif
ifeq ($(OPENJDK_TARGET_OS), solaris)
ifeq ($(OPENJDK_TARGET_CPU_BITS), 32)
BUILD_LAUNCHERS += $(JAVA_RMI_CGI)
endif
endif
# TODO:
# On windows java-rmi.cgi shouldn't be bundled since Java 1.2, but has been built all
# this time anyway. Since jdk6, it has been built from the wrong source and resulted
# in a copy of the standard java launcher named "java-rmi.exe" ending up in the final
# images bin dir. This weird behavior is mimicked here in the converted makefiles for
# now. Should probably just be deleted.
# http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6512052
ifeq ($(OPENJDK_TARGET_OS),windows)
$(eval $(call SetupLauncher,java-rmi,\
-DEXPAND_CLASSPATH_WILDCARDS,\
$(call SET_SHARED_LIBRARY_MAPFILE,$(JDK_TOPDIR)/makefiles/java/main/java/mapfile-$(OPENJDK_TARGET_CPU))))
else
$(JAVA_RMI_CGI): $(JDK_TOPDIR)/src/solaris/bin/java-rmi.cgi.sh
$(MKDIR) -p $(@D)
$(CP) $< $@
$(CHMOD) a+x $@
endif
##########################################################################################
$(BUILD_LAUNCHERS) : $(JDK_TOPDIR)/makefiles/CompileLaunchers.gmk
all: $(BUILD_LAUNCHERS)
.PHONY: all
...@@ -44,13 +44,7 @@ CXXFLAGS_JDKLIB += -I$(JDK_OUTPUTDIR)/gensrc_headers ...@@ -44,13 +44,7 @@ CXXFLAGS_JDKLIB += -I$(JDK_OUTPUTDIR)/gensrc_headers
# Put the libraries here. Different locations for different target apis. # Put the libraries here. Different locations for different target apis.
ifeq ($(OPENJDK_TARGET_OS_API),posix) ifeq ($(OPENJDK_TARGET_OS_API),posix)
ifneq ($(OPENJDK_TARGET_OS),macosx) INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)
INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/lib/$(LIBARCH)
LIBARCHDIR=$(LIBARCH)/
else
INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/lib
LIBARCHDIR=/
endif
else else
INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/bin INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/bin
endif endif
...@@ -63,6 +57,18 @@ WIN_VERIFY_LIB := $(JDK_OUTPUTDIR)/objs/libverify/verify.lib ...@@ -63,6 +57,18 @@ WIN_VERIFY_LIB := $(JDK_OUTPUTDIR)/objs/libverify/verify.lib
WIN_JAVA_LIB := $(JDK_OUTPUTDIR)/objs/libjava/java.lib WIN_JAVA_LIB := $(JDK_OUTPUTDIR)/objs/libjava/java.lib
WIN_AWT_LIB := $(JDK_OUTPUTDIR)/objs/libawt/awt.lib WIN_AWT_LIB := $(JDK_OUTPUTDIR)/objs/libawt/awt.lib
# Use this variable to set DEBUG_SYMBOLS true on windows for all libraries, but
# not on other platforms.
ifeq ($(OPENJDK_TARGET_OS), windows)
WINDOWS_ONLY := true
endif
#
# TODO replace with X_FLAGS / X_LIBS
# and add them to configure
#
OPENWIN_LIB:=$(OPENWIN_HOME)/lib
########################################################################################## ##########################################################################################
BUILD_LIBFDLIBM_OPTIMIZATION:=HIGH BUILD_LIBFDLIBM_OPTIMIZATION:=HIGH
...@@ -80,7 +86,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFDLIBM,\ ...@@ -80,7 +86,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFDLIBM,\
OPTIMIZATION:=$(BUILD_LIBFDLIBM_OPTIMIZATION), \ OPTIMIZATION:=$(BUILD_LIBFDLIBM_OPTIMIZATION), \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/native/java/lang/fdlibm/include,\ -I$(JDK_TOPDIR)/src/share/native/java/lang/fdlibm/include,\
CFLAGS_winapi_debug:=-DLOGGING,\ CFLAGS_windows_debug:=-DLOGGING,\
ARFLAGS:=$(ARFLAGS),\ ARFLAGS:=$(ARFLAGS),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libfdlibm)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libfdlibm))
...@@ -98,7 +104,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFDLIBM,\ ...@@ -98,7 +104,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFDLIBM,\
LANG:=C,\ LANG:=C,\
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/native/java/lang/fdlibm/include,\ -I$(JDK_TOPDIR)/src/share/native/java/lang/fdlibm/include,\
LDFLAGS:=-nostdlib -r,\ LDFLAGS:=-nostdlib -r -arch i386 -arch x86_64,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libfdlibm)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libfdlibm))
$(JDK_OUTPUTDIR)/objs/$(LIBRARY_PREFIX)fdlibm$(STATIC_LIBRARY_SUFFIX) : $(BUILD_LIBFDLIBM) $(JDK_OUTPUTDIR)/objs/$(LIBRARY_PREFIX)fdlibm$(STATIC_LIBRARY_SUFFIX) : $(BUILD_LIBFDLIBM)
...@@ -112,11 +118,18 @@ endif ...@@ -112,11 +118,18 @@ endif
BUILD_LIBVERIFY_SRC:=check_code.c check_format.c BUILD_LIBVERIFY_SRC:=check_code.c check_format.c
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
ifneq ($(ARCH), amd64) ifneq ($(OPENJDK_TARGET_CPU), x86_64)
BUILD_LIBVERIFY_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libverify/reorder-$(ARCH) BUILD_LIBVERIFY_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libverify/reorder-$(OPENJDK_TARGET_CPU)
endif endif
endif endif
LIBVERIFY_OPTIMIZATION:=HIGH
ifneq ($(findstring $(OPENJDK_TARGET_OS),solaris linux),)
ifeq ($(ENABLE_DEBUG_SYMBOLS), yes)
LIBVERIFY_OPTIMIZATION:=LOW
endif
endif
$(eval $(call SetupNativeCompilation,BUILD_LIBVERIFY,\ $(eval $(call SetupNativeCompilation,BUILD_LIBVERIFY,\
LIBRARY:=verify, \ LIBRARY:=verify, \
...@@ -124,13 +137,18 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBVERIFY,\ ...@@ -124,13 +137,18 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBVERIFY,\
SRC:=$(JDK_TOPDIR)/src/share/native/common,\ SRC:=$(JDK_TOPDIR)/src/share/native/common,\
INCLUDE_FILES:=$(BUILD_LIBVERIFY_SRC),\ INCLUDE_FILES:=$(BUILD_LIBVERIFY_SRC),\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=HIGH, \ OPTIMIZATION:=$(LIBVERIFY_OPTIMIZATION), \
CFLAGS:=$(CFLAGS_JDKLIB),\ CFLAGS:=$(CFLAGS_JDKLIB),\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libverify/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libverify/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN), \ $(call SET_SHARED_LIBRARY_ORIGIN), \
LDFLAGS_SUFFIX_posix:=-ljvm -lc,\ LDFLAGS_SUFFIX_posix:=-ljvm -lc,\
LDFLAGS_SUFFIX_windows:=jvm.lib,\ LDFLAGS_SUFFIX_windows:=jvm.lib,\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS) \
/D "JDK_FNAME=verify.dll" \
/D "JDK_INTERNAL_NAME=verify" \
/D "JDK_FTYPE=0x2L",\
REORDER:=$(BUILD_LIBVERIFY_REORDER),\ REORDER:=$(BUILD_LIBVERIFY_REORDER),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libverify,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libverify,\
DEBUG_SYMBOLS:=true)) DEBUG_SYMBOLS:=true))
...@@ -139,40 +157,32 @@ BUILD_LIBRARIES += $(BUILD_LIBVERIFY) ...@@ -139,40 +157,32 @@ BUILD_LIBRARIES += $(BUILD_LIBVERIFY)
########################################################################################## ##########################################################################################
LIBJAVA_SRC_DIRS:=$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/lang \ LIBJAVA_SRC_DIRS:=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/lang \
$(JDK_TOPDIR)/src/share/native/java/lang \ $(JDK_TOPDIR)/src/share/native/java/lang \
$(JDK_TOPDIR)/src/share/native/java/lang/ref \ $(JDK_TOPDIR)/src/share/native/java/lang/ref \
$(JDK_TOPDIR)/src/share/native/java/lang/reflect \ $(JDK_TOPDIR)/src/share/native/java/lang/reflect \
$(JDK_TOPDIR)/src/share/native/java/io \ $(JDK_TOPDIR)/src/share/native/java/io \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/io \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/io \
$(JDK_TOPDIR)/src/share/native/java/nio \ $(JDK_TOPDIR)/src/share/native/java/nio \
$(JDK_TOPDIR)/src/share/native/java/security \ $(JDK_TOPDIR)/src/share/native/java/security \
$(JDK_TOPDIR)/src/share/native/common \ $(JDK_TOPDIR)/src/share/native/common \
$(JDK_TOPDIR)/src/share/native/sun/misc \ $(JDK_TOPDIR)/src/share/native/sun/misc \
$(JDK_TOPDIR)/src/share/native/sun/reflect \ $(JDK_TOPDIR)/src/share/native/sun/reflect \
$(JDK_TOPDIR)/src/share/native/java/sql \
$(JDK_TOPDIR)/src/share/native/java/util \ $(JDK_TOPDIR)/src/share/native/java/util \
$(JDK_TOPDIR)/src/share/native/java/util/concurrent/atomic \ $(JDK_TOPDIR)/src/share/native/java/util/concurrent/atomic \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/common \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/common \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/util \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/util \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/provider \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/provider \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/io $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/io
ifneq ($(OPENJDK_TARGET_OS),macosx)
# LIBJAVA_SRC_DIRS+=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/util/locale/provider
# TODO else
# LIBJAVA_SRC_DIRS+=$(JDK_TOPDIR)/src/macosx/native/sun/util/locale/provider
ARCHPROPNAME:=$(LIBARCH)
ifeq ($(OPENJDK_TARGET_OS)-$(ARCH), solaris-i586)
ARCHPROPNAME:=x86
else ifeq ($(OPENJDK_TARGET_OS)-$(ARCH_DATA_MODEL), windows-32)
ARCHPROPNAME:=x86
else ifeq ($(OPENJDK_TARGET_OS), macosx)
ARCHPROPNAME:=$(ARCH)
endif endif
LIBJAVA_CFLAGS:=$(foreach dir,$(LIBJAVA_SRC_DIRS),-I$(dir)) \ LIBJAVA_CFLAGS:=$(foreach dir,$(LIBJAVA_SRC_DIRS),-I$(dir)) \
-I$(JDK_TOPDIR)/src/share/native/java/lang/fdlibm/include \ -I$(JDK_TOPDIR)/src/share/native/java/lang/fdlibm/include \
-DARCHPROPNAME='"$(ARCHPROPNAME)"' -DARCHPROPNAME='"$(OPENJDK_TARGET_CPU_OSARCH)"'
LIBJAVA_CFLAGS += -DJDK_MAJOR_VERSION='"$(JDK_MAJOR_VERSION)"' \ LIBJAVA_CFLAGS += -DJDK_MAJOR_VERSION='"$(JDK_MAJOR_VERSION)"' \
-DJDK_MINOR_VERSION='"$(JDK_MINOR_VERSION)"' \ -DJDK_MINOR_VERSION='"$(JDK_MINOR_VERSION)"' \
...@@ -208,8 +218,8 @@ else ...@@ -208,8 +218,8 @@ else
endif endif
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
ifneq ($(ARCH), amd64) ifneq ($(OPENJDK_TARGET_CPU), x86_64)
LIBJAVA_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libjava/reorder-$(ARCH) LIBJAVA_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libjava/reorder-$(OPENJDK_TARGET_CPU)
endif endif
endif endif
...@@ -233,11 +243,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJAVA,\ ...@@ -233,11 +243,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJAVA,\
LDFLAGS_SUFFIX_posix:=-ljvm -lverify, \ LDFLAGS_SUFFIX_posix:=-ljvm -lverify, \
LDFLAGS_SUFFIX_solaris:=-lnsl -lsocket -lscf $(LIBDL) $(BUILD_LIBFDLIBM) -lc,\ LDFLAGS_SUFFIX_solaris:=-lnsl -lsocket -lscf $(LIBDL) $(BUILD_LIBFDLIBM) -lc,\
LDFLAGS_SUFFIX_linux:=$(LIBDL) $(BUILD_LIBFDLIBM),\ LDFLAGS_SUFFIX_linux:=$(LIBDL) $(BUILD_LIBFDLIBM),\
LDFLAGS_SUFFIX_macosx:=$(BUILD_LIBFDLIBM) \ LDFLAGS_SUFFIX_macosx:=-L$(JDK_OUTPUTDIR)/objs/ -lfdlibm \
-framework CoreFoundation \ -framework CoreFoundation \
-framework Security -framework SystemConfiguration, \ -framework Security -framework SystemConfiguration, \
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=java.dll" \
/D "JDK_INTERNAL_NAME=java" \
/D "JDK_FTYPE=0x2L",\
REORDER:=$(LIBJAVA_REORDER), \ REORDER:=$(LIBJAVA_REORDER), \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjava)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjava,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBJAVA) BUILD_LIBRARIES += $(BUILD_LIBJAVA)
...@@ -252,20 +268,14 @@ $(BUILD_LIBJAVA) : $(BUILD_LIBFDLIBM) ...@@ -252,20 +268,14 @@ $(BUILD_LIBJAVA) : $(BUILD_LIBFDLIBM)
BUILD_LIBMLIB_SRC:=$(JDK_TOPDIR)/src/share/native/sun/awt/medialib BUILD_LIBMLIB_SRC:=$(JDK_TOPDIR)/src/share/native/sun/awt/medialib
BUILD_LIBMLIB_CFLAGS:=-D__USE_J2D_NAMES -D__MEDIALIB_OLD_NAMES \ BUILD_LIBMLIB_CFLAGS:=-D__USE_J2D_NAMES -D__MEDIALIB_OLD_NAMES \
-I$(BUILD_LIBMLIB_SRC) \ -I$(BUILD_LIBMLIB_SRC) \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/awt/medialib -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt/medialib
BUILD_LIBMLIB_LDLIBS:= BUILD_LIBMLIB_LDLIBS:=
BUILD_LIBMLIB_IMAGE_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libmlib_image/mapfile-vers BUILD_LIBMLIB_IMAGE_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libmlib_image/mapfile-vers
ifneq ($(OPENJDK_TARGET_OS), sparc) BUILD_LIBMLIB_CFLAGS += -DMLIB_NO_LIBSUNMATH
#
# Yes, this will always be true (until someone makes an OS called sparc)
# but this is how it was writtin in old system...keep it like this for now
#
BUILD_LIBMLIB_CFLAGS += -DMLIB_NO_LIBSUNMATH
endif
ifeq ($(ARCH_DATA_MODEL), 64) ifeq ($(OPENJDK_TARGET_CPU_BITS), 64)
BUILD_LIBMLIB_CFLAGS += -DMLIB_OS64BIT BUILD_LIBMLIB_CFLAGS += -DMLIB_OS64BIT
endif endif
...@@ -284,11 +294,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBMLIB_IMAGE,\ ...@@ -284,11 +294,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBMLIB_IMAGE,\
$(BUILD_LIBMLIB_CFLAGS),\ $(BUILD_LIBMLIB_CFLAGS),\
MAPFILE:=$(BUILD_LIBMLIB_IMAGE_MAPFILE), \ MAPFILE:=$(BUILD_LIBMLIB_IMAGE_MAPFILE), \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(BUILD_LIBMLIB_LDLIBS) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=$(BUILD_LIBMLIB_LDLIBS) \
LDFLAGS_SUFFIX_posix:=-lm,\ $(LDFLAGS_JDKLIB_SUFFIX),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libmlib_image)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=mlib_image.dll" \
/D "JDK_INTERNAL_NAME=mlib_image" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libmlib_image,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBMLIB_IMAGE) : $(BUILD_LIBJAVA) $(BUILD_LIBMLIB_IMAGE) : $(BUILD_LIBJAVA)
...@@ -296,15 +311,7 @@ BUILD_LIBRARIES += $(BUILD_LIBMLIB_IMAGE) ...@@ -296,15 +311,7 @@ BUILD_LIBRARIES += $(BUILD_LIBMLIB_IMAGE)
########################################################################################## ##########################################################################################
ifeq ($(OPENJDK_TARGET_OS),solaris) ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH),solaris-sparc)
ifeq ($(ARCH),sparc)
BUILD_LIBMLIB_IMAGE_V:=1
else ifeq ($(ARCH), sparcv9)
BUILD_LIBMLIB_IMAGE_V:=1
endif
endif
ifeq ($(BUILD_LIBMLIB_IMAGE_V), 1)
BUILD_LIBMLIB_IMAGE_V_FILES:=\ BUILD_LIBMLIB_IMAGE_V_FILES:=\
mlib_v_ImageLookUp.c \ mlib_v_ImageLookUp.c \
...@@ -411,7 +418,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBMLIB_IMAGE_V,\ ...@@ -411,7 +418,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBMLIB_IMAGE_V,\
INCLUDE_FILES:=$(BUILD_LIBMLIB_IMAGE_V_FILES),\ INCLUDE_FILES:=$(BUILD_LIBMLIB_IMAGE_V_FILES),\
OPTIMIZATION:=HIGHEST, \ OPTIMIZATION:=HIGHEST, \
CFLAGS:=-xarch=sparcvis \ CFLAGS:=-xarch=sparcvis \
$(JDK_TOPDIR)/src/solaris/native/sun/awt/medialib/vis_$(ARCH_DATA_MODEL).il\ $(JDK_TOPDIR)/src/solaris/native/sun/awt/medialib/vis_$(OPENJDK_TARGET_CPU_BITS).il\
$(BUILD_LIBMLIB_V_CFLAGS) \ $(BUILD_LIBMLIB_V_CFLAGS) \
$(CFLAGS_JDKLIB), \ $(CFLAGS_JDKLIB), \
MAPFILE:=$(BUILD_LIBMLIB_IMAGE_MAPFILE), \ MAPFILE:=$(BUILD_LIBMLIB_IMAGE_MAPFILE), \
...@@ -428,7 +435,7 @@ endif ...@@ -428,7 +435,7 @@ endif
LIBAWT_DIRS:=\ LIBAWT_DIRS:=\
$(JDK_TOPDIR)/src/share/native/sun/awt \ $(JDK_TOPDIR)/src/share/native/sun/awt \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/awt \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt \
$(JDK_TOPDIR)/src/share/native/sun/awt/image \ $(JDK_TOPDIR)/src/share/native/sun/awt/image \
$(JDK_TOPDIR)/src/share/native/sun/awt/image/gif \ $(JDK_TOPDIR)/src/share/native/sun/awt/image/gif \
$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \ $(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \
...@@ -437,17 +444,17 @@ LIBAWT_DIRS:=\ ...@@ -437,17 +444,17 @@ LIBAWT_DIRS:=\
$(JDK_TOPDIR)/src/share/native/sun/awt/debug \ $(JDK_TOPDIR)/src/share/native/sun/awt/debug \
$(JDK_TOPDIR)/src/share/native/sun/awt/utility \ $(JDK_TOPDIR)/src/share/native/sun/awt/utility \
$(JDK_TOPDIR)/src/share/native/sun/java2d \ $(JDK_TOPDIR)/src/share/native/sun/java2d \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d \
$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \ $(JDK_TOPDIR)/src/share/native/sun/java2d/loops \
$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \ $(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \
$(JDK_TOPDIR)/src/share/native/sun/awt/image \ $(JDK_TOPDIR)/src/share/native/sun/awt/image \
$(JDK_TOPDIR)/src/share/native/sun/java2d/opengl \ $(JDK_TOPDIR)/src/share/native/sun/java2d/opengl \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d/opengl \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/opengl \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d/x11 \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/x11 \
$(JDK_TOPDIR)/src/share/native/sun/font \ $(JDK_TOPDIR)/src/share/native/sun/font \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/windows \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/windows \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d/windows \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/windows \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d/d3d $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/d3d
LIBAWT_CFLAGS:=-D__MEDIALIB_OLD_NAMES -D__USE_J2D_NAMES \ LIBAWT_CFLAGS:=-D__MEDIALIB_OLD_NAMES -D__USE_J2D_NAMES \
...@@ -524,11 +531,12 @@ LIBAWT_FILES:=\ ...@@ -524,11 +531,12 @@ LIBAWT_FILES:=\
debug_trace.c \ debug_trace.c \
debug_util.c debug_util.c
ifneq (,$(filter $(OPENJDK_TARGET_OS), solaris linux macosx)) ifneq (,$(filter $(OPENJDK_TARGET_OS), solaris linux))
LIBAWT_FILES += awt_LoadLibrary.c initIDs.c img_colors.c LIBAWT_FILES += awt_LoadLibrary.c initIDs.c img_colors.c
endif endif
ifeq ($(OPENJDK_TARGET_OS),macosx) ifeq ($(OPENJDK_TARGET_OS),macosx)
LIBAWT_FILES += awt_LoadLibrary.c img_colors.c
LIBAWT_DIRS += $(JDK_TOPDIR)/src/macosx/native/com/apple/resources LIBAWT_DIRS += $(JDK_TOPDIR)/src/macosx/native/com/apple/resources
LIBAWT_FILES += awt_LoadLibrary.c MacOSXResourceBundle.m LIBAWT_FILES += awt_LoadLibrary.c MacOSXResourceBundle.m
LIBAWT_CFLAGS += -F/System/Library/Frameworks/JavaVM.framework/Frameworks LIBAWT_CFLAGS += -F/System/Library/Frameworks/JavaVM.framework/Frameworks
...@@ -539,7 +547,7 @@ endif ...@@ -539,7 +547,7 @@ endif
ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH), solaris-sparc) ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH), solaris-sparc)
LIBAWT_CFLAGS += -DMLIB_ADD_SUFF LIBAWT_CFLAGS += -DMLIB_ADD_SUFF
LIBAWT_CFLAGS += -xarch=sparcvis LIBAWT_CFLAGS += -xarch=sparcvis
LIBAWT_CFLAGS += $(JDK_TOPDIR)/src/solaris/native/sun/awt/medialib/vis_$(ARCH_DATA_MODEL).il LIBAWT_CFLAGS += $(JDK_TOPDIR)/src/solaris/native/sun/awt/medialib/vis_$(OPENJDK_TARGET_CPU_BITS).il
LIBAWT_CFLAGS += \ LIBAWT_CFLAGS += \
-I$(JDK_TOPDIR)/src/solaris/native/sun/awt/medialib \ -I$(JDK_TOPDIR)/src/solaris/native/sun/awt/medialib \
-I$(JDK_TOPDIR)/src/solaris/native/sun/java2d/medialib \ -I$(JDK_TOPDIR)/src/solaris/native/sun/java2d/medialib \
...@@ -591,7 +599,7 @@ ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH), solaris-sparc) ...@@ -591,7 +599,7 @@ ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH), solaris-sparc)
vis_XorBlit.c \ vis_XorBlit.c \
mlib_v_ImageCopy_blk.s mlib_v_ImageCopy_blk.s
ifeq ($(OPENJDK_TARGET_CPU_BITS),64) ifeq ($(OPENJDK_TARGET_CPU),sparcv9)
LIBAWT_ASFLAGS=-P -xarch=v9a LIBAWT_ASFLAGS=-P -xarch=v9a
else else
LIBAWT_ASFLAGS=-P -xarch=v8plusa LIBAWT_ASFLAGS=-P -xarch=v8plusa
...@@ -644,8 +652,8 @@ ifeq ($(OPENJDK_TARGET_OS),windows) ...@@ -644,8 +652,8 @@ ifeq ($(OPENJDK_TARGET_OS),windows)
MouseInfo.cpp \ MouseInfo.cpp \
rect.c rect.c
LIBAWT_LANG:=C++ LIBAWT_LANG:=C++
LIBAWT_CFLAGS += $(GX_OPTION) -DUNICODE -D_UNICODE LIBAWT_CFLAGS += -EHsc -DUNICODE -D_UNICODE
ifeq ($(ARCH_DATA_MODEL), 64) ifeq ($(OPENJDK_TARGET_CPU_BITS), 64)
LIBAWT_CFLAGS += -DMLIB_OS64BIT LIBAWT_CFLAGS += -DMLIB_OS64BIT
endif endif
...@@ -686,22 +694,25 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT,\ ...@@ -686,22 +694,25 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT,\
/DELAYLOAD:winspool.drv /DELAYLOAD:imm32.dll \ /DELAYLOAD:winspool.drv /DELAYLOAD:imm32.dll \
/DELAYLOAD:ole32.dll /DELAYLOAD:comdlg32.dll \ /DELAYLOAD:ole32.dll /DELAYLOAD:comdlg32.dll \
/DELAYLOAD:comctl32.dll /DELAYLOAD:shlwapi.dll,\ /DELAYLOAD:comctl32.dll /DELAYLOAD:shlwapi.dll,\
LDFLAGS_macosx:=-lmlib_image \ LDFLAGS_solaris:=-R/usr/dt/lib$(OPENJDK_TARGET_CPU_ISADIR) -R$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR),\
-framework Cocoa \ LDFLAGS_SUFFIX_linux:=-ljvm $(LIBM) $(LIBDL) -ljava,\
-framework OpenGL \ LDFLAGS_SUFFIX_solaris:=-ljvm $(LIBM) $(LIBDL) -ljava,\
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \ LDFLAGS_SUFFIX_macosx:=-lmlib_image -ljvm $(LIBM) \
-framework JavaNativeFoundation \ -framework Cocoa \
-framework JavaRuntimeSupport \ -framework OpenGL \
-framework ApplicationServices \ -F/System/Library/Frameworks/JavaVM.framework/Frameworks \
-framework AudioToolbox,\ -framework JavaNativeFoundation \
LDFLAGS_solaris:=-R/usr/dt/lib$(ISA_DIR) -R$(OPENWIN_LIB)$(ISA_DIR),\ -framework JavaRuntimeSupport \
LDFLAGS_SUFFIX_posix:=-ljvm $(LIBM) -ljava $(LIBDL),\ -framework ApplicationServices \
-framework AudioToolbox \
-ljava,\
VERSIONINFO_RESOURCE:=$(LIBAWT_VERSIONINFO_RESOURCE),\ VERSIONINFO_RESOURCE:=$(LIBAWT_VERSIONINFO_RESOURCE),\
RC_FLAGS:=$(RC_FLAGS) $(LIBAWT_RC_FLAGS) \ RC_FLAGS:=$(RC_FLAGS) $(LIBAWT_RC_FLAGS) \
/D "JDK_FNAME=awt.dll" \ /D "JDK_FNAME=awt.dll" \
/D "JDK_INTERNAL_NAME=awt" \ /D "JDK_INTERNAL_NAME=awt" \
/D "JDK_FTYPE=0x2L",\ /D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libawt)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libawt,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBAWT) : $(BUILD_LIBJAVA) $(BUILD_LIBAWT) : $(BUILD_LIBJAVA)
...@@ -728,25 +739,25 @@ LIBAWT_XAWT_DIRS:=\ ...@@ -728,25 +739,25 @@ LIBAWT_XAWT_DIRS:=\
$(JDK_TOPDIR)/src/share/native/sun/awt/debug \ $(JDK_TOPDIR)/src/share/native/sun/awt/debug \
$(JDK_TOPDIR)/src/share/native/sun/awt/utility \ $(JDK_TOPDIR)/src/share/native/sun/awt/utility \
$(JDK_TOPDIR)/src/share/native/sun/font \ $(JDK_TOPDIR)/src/share/native/sun/font \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/font \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/font \
$(JDK_TOPDIR)/src/share/native/sun/java2d/opengl \ $(JDK_TOPDIR)/src/share/native/sun/java2d/opengl \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/awt \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d/opengl \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/opengl \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d/x11 \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/x11 \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/xawt \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/xawt \
LIBAWT_XAWT_CFLAGS:=-DXAWT -DXAWT_HACK \ LIBAWT_XAWT_CFLAGS:=-DXAWT -DXAWT_HACK \
-DX11_PATH=\"$(X11_PATH)\" -DPACKAGE_PATH=\"$(PACKAGE_PATH)\" \ -DX11_PATH=\"$(X11_PATH)\" -DPACKAGE_PATH=\"$(PACKAGE_PATH)\" \
$(CUPS_CFLAGS) \ $(CUPS_CFLAGS) \
$(foreach dir,$(LIBAWT_XAWT_DIRS),-I$(dir)) \ $(foreach dir,$(LIBAWT_XAWT_DIRS),-I$(dir)) \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/image \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/image \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/jdga -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/jdga
ifeq ($(OPENJDK_TARGET_OS),solaris) ifeq ($(OPENJDK_TARGET_OS),solaris)
LIBAWT_XAWT_CFLAGS += -DFUNCPROTO=15 LIBAWT_XAWT_CFLAGS += -DFUNCPROTO=15
...@@ -816,13 +827,15 @@ LIBAWT_XAWT_FILES:=\ ...@@ -816,13 +827,15 @@ LIBAWT_XAWT_FILES:=\
LIBAWT_XAWT_LDFLAGS_SUFFIX:=$(LIBM) -lawt -lXext -lX11 -lXrender $(LIBDL) -lXtst -lXi -ljava -ljvm -lc LIBAWT_XAWT_LDFLAGS_SUFFIX:=$(LIBM) -lawt -lXext -lX11 -lXrender $(LIBDL) -lXtst -lXi -ljava -ljvm -lc
ifeq ($(OPENJDK_TARGET_OS), linux) ifeq ($(OPENJDK_TARGET_OS), linux)
LIBAWT_XAWT_LDFLAGS_SUFFIX += -lpthread # To match old build, add this to LDFLAGS instead of suffix.
LIBAWT_XAWT_LDFLAGS += -lpthread
endif endif
ifeq ($(OPENJDK_TARGET_OS), macosx) ifeq ($(OPENJDK_TARGET_OS), macosx)
LIBAWT_XAWT_LDFLAGS_SUFFIX += -lpthread LIBAWT_XAWT_LDFLAGS_SUFFIX += -lpthread
endif endif
# On macosx, the shared library origin is set twice for this lib.
$(eval $(call SetupNativeCompilation,BUILD_LIBAWT_XAWT,\ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT_XAWT,\
LIBRARY:=awt_xawt,\ LIBRARY:=awt_xawt,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
...@@ -834,12 +847,26 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT_XAWT,\ ...@@ -834,12 +847,26 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT_XAWT,\
$(X_CFLAGS),\ $(X_CFLAGS),\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libawt_xawt/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libawt_xawt/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN) \ $(X_LIBS) $(LIBAWT_XAWT_LDFLAGS),\
$(X_LIBS),\ LDFLAGS_linux:=$(call SET_SHARED_LIBRARY_ORIGIN) \
LDFLAGS_solaris:=-L$(OPENWIN_HOME)/sfw/lib$(ISA_DIR) -L$(OPENWIN_HOME)/lib$(ISA_DIR) \ $(call SET_SHARED_LIBRARY_ORIGIN,/..),\
-R$(OPENWIN_HOME)/sfw/lib$(ISA_DIR) -R$(OPENWIN_HOME)/lib$(ISA_DIR) \ LDFLAGS_solaris:=-L$(OPENWIN_HOME)/sfw/lib$(OPENJDK_TARGET_CPU_ISADIR) \
-R/usr/dt/lib$(ISA_DIR),\ -L$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) \
-R$(OPENWIN_HOME)/sfw/lib$(OPENJDK_TARGET_CPU_ISADIR) \
-R$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) \
-R/usr/dt/lib$(OPENJDK_TARGET_CPU_ISADIR) \
$(call SET_SHARED_LIBRARY_ORIGIN) \
$(call SET_SHARED_LIBRARY_ORIGIN,/..),\
LDFLAGS_macosx:=$(call SET_SHARED_LIBRARY_ORIGIN) \
$(call SET_SHARED_LIBRARY_ORIGIN). \
$(call SET_SHARED_LIBRARY_ORIGIN) \
$(call SET_SHARED_LIBRARY_ORIGIN).,\
LDFLAGS_SUFFIX:=$(LIBAWT_XAWT_LDFLAGS_SUFFIX),\ LDFLAGS_SUFFIX:=$(LIBAWT_XAWT_LDFLAGS_SUFFIX),\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=xawt.dll" \
/D "JDK_INTERNAL_NAME=xawt" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libawt_xawt)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libawt_xawt))
$(BUILD_LIBAWT_XAWT) : $(BUILD_LIBJAVA) $(BUILD_LIBAWT_XAWT) : $(BUILD_LIBJAVA)
...@@ -885,8 +912,8 @@ endif ...@@ -885,8 +912,8 @@ endif
BUILD_LIBZIP_REORDER:= BUILD_LIBZIP_REORDER:=
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
ifneq ($(ARCH), amd64) ifneq ($(OPENJDK_TARGET_CPU), x86_64)
BUILD_LIBZIP_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libzip/reorder-$(ARCH) BUILD_LIBZIP_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libzip/reorder-$(OPENJDK_TARGET_CPU)
endif endif
endif endif
...@@ -905,17 +932,26 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBZIP,\ ...@@ -905,17 +932,26 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBZIP,\
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
$(LIBZ_INCLUDE) \ $(LIBZ_INCLUDE) \
-I$(JDK_TOPDIR)/src/share/native/java/io \ -I$(JDK_TOPDIR)/src/share/native/java/io \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/io,\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/io,\
CFLAGS_posix:=$(BUILD_LIBZIP_MMAP) -UDEBUG,\ CFLAGS_posix:=$(BUILD_LIBZIP_MMAP) -UDEBUG,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libzip/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libzip/mapfile-vers, \
REORDER:=$(BUILD_LIBZIP_REORDER), \ REORDER:=$(BUILD_LIBZIP_REORDER), \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN) \
$(EXPORT_ZIP_FUNCS), \ $(EXPORT_ZIP_FUNCS), \
LDFLAGS_winapi:=-export:ZIP_Open -export:ZIP_Close -export:ZIP_FindEntry \ LDFLAGS_windows:=-export:ZIP_Open -export:ZIP_Close -export:ZIP_FindEntry \
-export:ZIP_ReadEntry -export:ZIP_GetNextEntry jvm.lib \ -export:ZIP_ReadEntry -export:ZIP_GetNextEntry jvm.lib \
$(WIN_JAVA_LIB),\ $(WIN_JAVA_LIB),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) $(LIBZ),\ LDFLAGS_SUFFIX_linux:=-ljvm -ljava $(LIBZ),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libzip)) LDFLAGS_SUFFIX_solaris:=-ljvm -ljava $(LIBZ),\
LDFLAGS_SUFFIX_macosx:=$(LIBZ) -ljava -ljvm,\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=zip.dll" \
/D "JDK_INTERNAL_NAME=zip" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libzip,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBZIP) : $(BUILD_LIBJAVA) $(BUILD_LIBZIP) : $(BUILD_LIBJAVA)
...@@ -934,24 +970,24 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBUNPACK,\ ...@@ -934,24 +970,24 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBUNPACK,\
-DNO_ZLIB -DUNPACK_JNI -DFULL,\ -DNO_ZLIB -DUNPACK_JNI -DFULL,\
CFLAGS_release:=-DPRODUCT,\ CFLAGS_release:=-DPRODUCT,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libunpack/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libunpack/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB)\ LDFLAGS:=$(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_winapi:=-map:$(JDK_OUTPUTDIR)/objs/unpack.map /debug \ LDFLAGS_windows:=-map:$(JDK_OUTPUTDIR)/objs/unpack.map /debug \
jvm.lib $(WIN_JAVA_LIB),\ jvm.lib $(WIN_JAVA_LIB),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX_posix:=-ljvm $(LIBCXX) -ljava -lc,\
LDFLAGS_SUFFIX_posix:=$(LIBCXX),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libunpack,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libunpack,\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\ RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=unpack.dll" \ /D "JDK_FNAME=unpack.dll" \
/D "JDK_INTERNAL_NAME=unpack" \ /D "JDK_INTERNAL_NAME=unpack" \
/D "JDK_FTYPE=0x2L")) /D "JDK_FTYPE=0x2L",\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBUNPACK) : $(BUILD_LIBJAVA) $(BUILD_LIBUNPACK) : $(BUILD_LIBJAVA)
BUILD_LIBRARIES += $(BUILD_LIBUNPACK) BUILD_LIBRARIES += $(BUILD_LIBUNPACK)
ifeq ($(OPENJDK_TARGET_OS_API),winapi) ifeq ($(OPENJDK_TARGET_OS),windows)
$(INSTALL_LIBRARIES_HERE)/$(LIBRARY_PREFIX)unpack.map: $(BUILD_LIBUNPACK) $(INSTALL_LIBRARIES_HERE)/$(LIBRARY_PREFIX)unpack.map: $(BUILD_LIBUNPACK)
$(ECHO) Copying $(@F) $(ECHO) Copying $(@F)
$(CP) $(patsubst %$(SHARED_LIBRARY_SUFFIX),%.map,$<) $@ $(CP) $(patsubst %$(SHARED_LIBRARY_SUFFIX),%.map,$<) $@
...@@ -977,16 +1013,21 @@ endif ...@@ -977,16 +1013,21 @@ endif
$(eval $(call SetupNativeCompilation,BUILD_LIBATTACH,\ $(eval $(call SetupNativeCompilation,BUILD_LIBATTACH,\
LIBRARY:=attach, \ LIBRARY:=attach, \
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/tools/attach,\ SRC:=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/tools/attach,\
EXCLUDE_FILES:=$(LIBATTACH_EXCLUDE_FILES),\ EXCLUDE_FILES:=$(LIBATTACH_EXCLUDE_FILES),\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB),\ CFLAGS:=$(CFLAGS_JDKLIB),\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libattach/mapfile-$(OPENJDK_TARGET_OS), \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libattach/mapfile-$(OPENJDK_TARGET_OS), \
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS) \
/D "JDK_FNAME=attach.dll" \
/D "JDK_INTERNAL_NAME=attach" \
/D "JDK_FTYPE=0x2L",\
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_solaris:=-ldoor,\ LDFLAGS_solaris:=-ldoor,\
LDFLAGS_winapi:=psapi.lib advapi32.lib $(WIN_JAVA_LIB) jvm.lib,\ LDFLAGS_windows:=psapi.lib advapi32.lib $(WIN_JAVA_LIB) jvm.lib,\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libattach,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libattach,\
DEBUG_SYMBOLS:=true)) DEBUG_SYMBOLS:=true))
...@@ -1001,21 +1042,26 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBDT_SOCKET,\ ...@@ -1001,21 +1042,26 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBDT_SOCKET,\
LIBRARY:=dt_socket,\ LIBRARY:=dt_socket,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/transport/socket \ SRC:=$(JDK_TOPDIR)/src/share/transport/socket \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/transport/socket,\ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/transport/socket,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) -DUSE_MMAP \ CFLAGS:=$(CFLAGS_JDKLIB) -DUSE_MMAP \
-I$(INCLUDEDIR) -I$(JDK_OUTPUTDIR)/include/$(OPENJDK_TARGET_OS) \ -I$(INCLUDEDIR) -I$(JDK_OUTPUTDIR)/include/$(OPENJDK_TARGET_OS) \
-I$(JDK_TOPDIR)/src/share/transport/socket \ -I$(JDK_TOPDIR)/src/share/transport/socket \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/transport/socket \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/transport/socket \
-I$(JDK_TOPDIR)/src/share/back/export \ -I$(JDK_TOPDIR)/src/share/back/export \
-I$(JDK_TOPDIR)/src/share/back,\ -I$(JDK_TOPDIR)/src/share/back,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libdt_socket/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libdt_socket/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB), \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
LDFLAGS_SUFFIX_linux:=$(LDFLAGS_JDKLIB_SUFFIX) -lpthread,\ $(call SET_SHARED_LIBRARY_ORIGIN), \
LDFLAGS_SUFFIX_linux:=-lpthread,\
LDFLAGS_SUFFIX_solaris:=-lnsl -lsocket,\ LDFLAGS_SUFFIX_solaris:=-lnsl -lsocket,\
LDFLAGS_SUFFIX_winapi:=$(LDFLAGS_JDKLIB_SUFFIX) -export:jdwpTransport_OnLoad ws2_32.lib,\ LDFLAGS_SUFFIX_windows:=$(LDFLAGS_JDKLIB_SUFFIX) -export:jdwpTransport_OnLoad ws2_32.lib,\
LDFLAGS_SUFFIX:=,\ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=dt_socket.dll" \
/D "JDK_INTERNAL_NAME=dt_socket" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libdt_socket,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libdt_socket,\
DEBUG_SYMBOLS:=true)) DEBUG_SYMBOLS:=true))
...@@ -1025,55 +1071,66 @@ BUILD_LIBRARIES += $(BUILD_LIBDT_SOCKET) ...@@ -1025,55 +1071,66 @@ BUILD_LIBRARIES += $(BUILD_LIBDT_SOCKET)
########################################################################################## ##########################################################################################
ifeq ($(OPENJDK_TARGET_OS_API),winapi) ifeq ($(OPENJDK_TARGET_OS),windows)
$(eval $(call SetupNativeCompilation,BUILD_LIBDT_SHMEM,\ $(eval $(call SetupNativeCompilation,BUILD_LIBDT_SHMEM,\
LIBRARY:=dt_shmem,\ LIBRARY:=dt_shmem,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/native/com/sun/tools/jdi \ SRC:=$(JDK_TOPDIR)/src/share/native/com/sun/tools/jdi \
$(JDK_TOPDIR)/src/share/transport/shmem \ $(JDK_TOPDIR)/src/share/transport/shmem \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/transport/shmem,\ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/transport/shmem,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) -DUSE_MMAP\ CFLAGS:=$(CFLAGS_JDKLIB) -DUSE_MMAP\
-I$(INCLUDEDIR) -I$(JDK_OUTPUTDIR)/include/$(OPENJDK_TARGET_OS) \ -I$(INCLUDEDIR) -I$(JDK_OUTPUTDIR)/include/$(OPENJDK_TARGET_OS) \
-I$(JDK_TOPDIR)/src/share/transport/shmem \ -I$(JDK_TOPDIR)/src/share/transport/shmem \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/transport/shmem \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/transport/shmem \
-I$(JDK_TOPDIR)/src/share/back/export, \ -I$(JDK_TOPDIR)/src/share/back/export, \
LDFLAGS:=$(LDFLAGS_JDKLIB),\ LDFLAGS:=$(LDFLAGS_JDKLIB),\
LDFLAGS_winapi:=-export:jdwpTransport_OnLoad,\ LDFLAGS_windows:=-export:jdwpTransport_OnLoad,\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libdt_shmem)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=dt_shmem.dll" \
/D "JDK_INTERNAL_NAME=dt_shmem" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libdt_shmem,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBDT_SHMEM) BUILD_LIBRARIES += $(BUILD_LIBDT_SHMEM)
endif # OPENJDK_TARGET_OS endif # OPENJDK_TARGET_OS
########################################################################################## ##########################################################################################
# JDWP_LOGGING causes log messages to be compiled into the library. These reference the # JDWP_LOGGING causes log messages to be compiled into the library.
# __FILE__ macro which here expands to the absolute path of the file while the old build
# system used a relative path. This causes the binaries to differ in size.
$(eval $(call SetupNativeCompilation,BUILD_LIBJDWP,\ $(eval $(call SetupNativeCompilation,BUILD_LIBJDWP,\
LIBRARY:=jdwp, \ LIBRARY:=jdwp, \
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/back $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/back,\ SRC:=$(JDK_TOPDIR)/src/share/back $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/back,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) -DJDWP_LOGGING\ CFLAGS:=$(CFLAGS_JDKLIB) -DJDWP_LOGGING\
-I$(JDK_TOPDIR)/src/share/transport/export \ -I$(JDK_TOPDIR)/src/share/transport/export \
-I$(JDK_TOPDIR)/src/share/back/export \ -I$(JDK_TOPDIR)/src/share/back/export \
-I$(JDK_TOPDIR)/src/share/npt \ -I$(JDK_TOPDIR)/src/share/npt \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/npt \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/npt \
-I$(JDK_TOPDIR)/src/share/back \ -I$(JDK_TOPDIR)/src/share/back \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/back \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/back \
-I$(JDK_OUTPUTDIR)/gensrc_jdwp_headers,\ -I$(JDK_OUTPUTDIR)/gensrc_jdwp_headers,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjdwp/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjdwp/mapfile-vers, \
LDFLAGS:=$(filter-out -ljava,$(LDFLAGS_JDKLIB)), \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
LDFLAGS_SUFFIX_linux:=$(LDFLAGS_JDKLIB_SUFFIX) $(LIBDL),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX_linux:=$(LIBDL),\
LDFLAGS_SUFFIX_solaris:=$(LIBDL),\ LDFLAGS_SUFFIX_solaris:=$(LIBDL),\
LDFLAGS_SUFFIX_windows:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX_windows:=$(LDFLAGS_JDKLIB_SUFFIX),\
LDFLAGS_SUFFIX:=,\ LDFLAGS_SUFFIX:=,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjdwp)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=jdwp.dll" \
/D "JDK_INTERNAL_NAME=jdwp" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjdwp,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBJDWP) : $(BUILD_LIBJAVA) $(BUILD_LIBJDWP) : $(BUILD_LIBJAVA)
...@@ -1097,19 +1154,24 @@ endif ...@@ -1097,19 +1154,24 @@ endif
$(eval $(call SetupNativeCompilation,BUILD_LIBJAAS,\ $(eval $(call SetupNativeCompilation,BUILD_LIBJAAS,\
LIBRARY:=$(LIBJAAS_NAME),\ LIBRARY:=$(LIBJAAS_NAME),\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/com/sun/security/auth/module,\ SRC:=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/com/sun/security/auth/module,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB),\ CFLAGS:=$(CFLAGS_JDKLIB),\
MAPFILE:=$(LIBJAAS_MAPFILE),\ MAPFILE:=$(LIBJAAS_MAPFILE),\
LDFLAGS:=$(filter-out -ljava,$(LDFLAGS_JDKLIB)) \ LDFLAGS:=$(filter-out -ljava,$(LDFLAGS_JDKLIB)) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_winapi:=netapi32.lib user32.lib mpr.lib advapi32.lib,\ LDFLAGS_windows:=netapi32.lib user32.lib mpr.lib advapi32.lib,\
LDFLAGS_SUFFIX_linux:=$(LDFLAGS_JDKLIB_SUFFIX),\
LDFLAGS_SUFFIX_windows:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX_windows:=$(LDFLAGS_JDKLIB_SUFFIX),\
LDFLAGS_SUFFIX:=,\ LDFLAGS_SUFFIX:=,\
EXCLUDE_FILES:=$(LIBJAAS_EXCLUDE_FILES),\ EXCLUDE_FILES:=$(LIBJAAS_EXCLUDE_FILES),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjaas)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS) \
/D "JDK_FNAME=$(LIBJAAS_NAME).dll" \
/D "JDK_INTERNAL_NAME=$(LIBJAAS_NAME)" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjaas,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBJAAS) : $(BUILD_LIBJAVA) $(BUILD_LIBJAAS) : $(BUILD_LIBJAVA)
...@@ -1121,7 +1183,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSDT,\ ...@@ -1121,7 +1183,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSDT,\
LIBRARY:=jsdt,\ LIBRARY:=jsdt,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/native/sun/tracing/dtrace\ SRC:=$(JDK_TOPDIR)/src/share/native/sun/tracing/dtrace\
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/tracing/dtrace,\ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/tracing/dtrace,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB)\ CFLAGS:=$(CFLAGS_JDKLIB)\
...@@ -1129,12 +1191,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSDT,\ ...@@ -1129,12 +1191,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSDT,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjsdt/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjsdt/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX_linux:=$(LDFLAGS_JDKLIB_SUFFIX) $(LIBDL),\ LDFLAGS_SUFFIX_linux:=$(LIBDL),\
LDFLAGS_SUFFIX_winapi:=$(LDFLAGS_JDKLIB_SUFFIX) $(LIBDL),\ LDFLAGS_SUFFIX_windows:=$(LDFLAGS_JDKLIB_SUFFIX) $(LIBDL),\
LDFLAGS_SUFFIX_macosx:= $(LIBDL),\ LDFLAGS_SUFFIX_macosx:= $(LIBDL),\
LDFLAGS_SUFFIX:=,\ LDFLAGS_SUFFIX:=,\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=jsdt.dll" \
/D "JDK_INTERNAL_NAME=jsdt" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjsdt, \ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjsdt, \
DEBUG_SYMBOLS:= yes)) DEBUG_SYMBOLS:=true))
$(BUILD_LIBJSDT) : $(BUILD_LIBJAVA) $(BUILD_LIBJSDT) : $(BUILD_LIBJAVA)
...@@ -1163,14 +1230,20 @@ ifdef OPENJDK ...@@ -1163,14 +1230,20 @@ ifdef OPENJDK
-I$(JDK_TOPDIR)/src/share/native/sun/java2d \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/debug,\ -I$(JDK_TOPDIR)/src/share/native/sun/awt/debug,\
CFLAGS_solaris:=-xc99=no_lib,\ CFLAGS_solaris:=-xc99=no_lib,\
CFLAGS_winapi:=-DCMS_IS_WINDOWS_,\ CFLAGS_windows:=-DCMS_IS_WINDOWS_,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/liblcms/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/liblcms/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB), \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
LDFLAGS_solaris:=/usr/lib$(ISA_DIR)/libm.so.2,\ $(call SET_SHARED_LIBRARY_ORIGIN), \
LDFLAGS_winapi:=$(WIN_AWT_LIB) $(WIN_JAVA_LIB),\ LDFLAGS_solaris:=/usr/lib$(OPENJDK_TARGET_CPU_ISADIR)/libm.so.2,\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_windows:=$(WIN_AWT_LIB) $(WIN_JAVA_LIB),\
LDFLAGS_SUFFIX_posix:=-lawt,\ LDFLAGS_SUFFIX_solaris:=-lawt -ljava -ljvm,\
LDFLAGS_SUFFIX_linux:=-lm,\ LDFLAGS_SUFFIX_macosx:=$(LIBM) -lawt -ljava -ljvm,\
LDFLAGS_SUFFIX_linux:=-lm -lawt -ljava -ljvm,\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=lcms.dll" \
/D "JDK_INTERNAL_NAME=lcms" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/liblcms)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/liblcms))
BUILD_LIBRARIES += $(BUILD_LIBLCMS) BUILD_LIBRARIES += $(BUILD_LIBLCMS)
...@@ -1190,8 +1263,8 @@ endif ...@@ -1190,8 +1263,8 @@ endif
BUILD_LIBJPEG_REORDER:= BUILD_LIBJPEG_REORDER:=
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
ifneq ($(ARCH), amd64) ifneq ($(OPENJDK_TARGET_CPU), x86_64)
BUILD_LIBJPEG_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libjpeg/reorder-$(ARCH) BUILD_LIBJPEG_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libjpeg/reorder-$(OPENJDK_TARGET_CPU)
endif endif
endif endif
...@@ -1223,11 +1296,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJPEG,\ ...@@ -1223,11 +1296,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJPEG,\
MAPFILE:=$(BUILD_LIBJPEG_MAPFILE), \ MAPFILE:=$(BUILD_LIBJPEG_MAPFILE), \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_linux:=$(LIBDL),\ LDFLAGS_windows:=$(WIN_JAVA_LIB) jvm.lib,\
LDFLAGS_winapi:=$(WIN_JAVA_LIB) jvm.lib,\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=jpeg.dll" \
/D "JDK_INTERNAL_NAME=jpeg" \
/D "JDK_FTYPE=0x2L",\
REORDER:=$(BUILD_LIBJPEG_REORDER),\ REORDER:=$(BUILD_LIBJPEG_REORDER),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjpeg)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjpeg,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBJPEG) : $(BUILD_LIBJAVA) $(BUILD_LIBJPEG) : $(BUILD_LIBJAVA)
...@@ -1263,11 +1341,11 @@ BUILD_LIBFONTMANAGER_CFLAGS_COMMON:=\ ...@@ -1263,11 +1341,11 @@ BUILD_LIBFONTMANAGER_CFLAGS_COMMON:=\
-I$(JDK_TOPDIR)/src/share/native/sun/font \ -I$(JDK_TOPDIR)/src/share/native/sun/font \
-I$(JDK_TOPDIR)/src/share/native/sun/font/layout \ -I$(JDK_TOPDIR)/src/share/native/sun/font/layout \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/awt \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d -I$(JDK_TOPDIR)/src/share/native/sun/java2d
# Turn off aliasing with GCC for ExtensionSubtables.cpp # Turn off aliasing with GCC for ExtensionSubtables.cpp
...@@ -1279,25 +1357,30 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFONTMANAGER,\ ...@@ -1279,25 +1357,30 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFONTMANAGER,\
LIBRARY:=fontmanager, \ LIBRARY:=fontmanager, \
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/native/sun/font\ SRC:=$(JDK_TOPDIR)/src/share/native/sun/font\
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/font,\ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/font,\
EXCLUDE_FILES:=$(LIBFONTMANAGER_EXCLUDE_FILES) \ EXCLUDE_FILES:=$(LIBFONTMANAGER_EXCLUDE_FILES) \
AccelGlyphCache.c,\ AccelGlyphCache.c,\
LANG:=C++,\ LANG:=C++,\
CFLAGS:=$(CFLAGS_JDKLIB) $(BUILD_LIBFONTMANAGER_CFLAGS_COMMON),\ CFLAGS:=$(CFLAGS_JDKLIB) $(BUILD_LIBFONTMANAGER_CFLAGS_COMMON),\
CXXFLAGS:=$(CXXFLAGS_JDKLIB) $(BUILD_LIBFONTMANAGER_CFLAGS_COMMON),\ CXXFLAGS:=$(CXXFLAGS_JDKLIB) $(BUILD_LIBFONTMANAGER_CFLAGS_COMMON),\
OPTIMIZATION:=$(LIBFONTMANAGER_OPTIMIZATION), \ OPTIMIZATION:=$(LIBFONTMANAGER_OPTIMIZATION), \
CFLAGS_windows= -I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/windows \ CFLAGS_windows= -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/windows \
-DCC_NOEX, \ -DCC_NOEX, \
MAPFILE:=$(BUILD_LIBFONTMANAGER_MAPFILE), \ MAPFILE:=$(BUILD_LIBFONTMANAGER_MAPFILE), \
LDFLAGS:=$(subst -Xlinker -z -Xlinker defs,,$(LDFLAGS_JDKLIB)) \ LDFLAGS:=$(subst -Xlinker -z -Xlinker defs,,$(LDFLAGS_JDKLIB)) $(LDFLAGS_CXX_JDK) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_windows:=advapi32.lib user32.lib gdi32.lib $(WIN_AWT_LIB) $(WIN_JAVA_LIB),\ LDFLAGS_windows:=advapi32.lib user32.lib gdi32.lib $(WIN_AWT_LIB) $(WIN_JAVA_LIB),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) \ LDFLAGS_SUFFIX:=$(BUILD_LIBFONTMANAGER_FONTLIB),\
$(BUILD_LIBFONTMANAGER_FONTLIB),\ LDFLAGS_SUFFIX_linux:=-lawt $(LIBM) $(LIBCXX) -ljava -ljvm -lc,\
LDFLAGS_SUFFIX_linux:=-lawt $(LIBM) $(LIBCXX),\ LDFLAGS_SUFFIX_solaris:=-lawt -lawt_xawt -lc $(LIBM) $(LIBCXX) -ljava -ljvm,\
LDFLAGS_SUFFIX_solaris:=-lawt -lawt_xawt -lc $(LIBM) $(LIBCXX),\ LDFLAGS_SUFFIX_macosx:=-lawt $(LIBM) $(LIBCXX) -undefined dynamic_lookup -ljava -ljvm,\
LDFLAGS_SUFFIX_macosx:=-lawt $(LIBM) $(LIBCXX) -undefined dynamic_lookup,\ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libfontmanager)) RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=fontmanager.dll" \
/D "JDK_INTERNAL_NAME=fontmanager" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libfontmanager,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBFONTMANAGER) : $(BUILD_LIBAWT) $(BUILD_LIBFONTMANAGER) : $(BUILD_LIBAWT)
...@@ -1323,10 +1406,10 @@ ifndef OPENJDK ...@@ -1323,10 +1406,10 @@ ifndef OPENJDK
-I$(JDK_TOPDIR)/src/closed/share/native/sun/font/t2k \ -I$(JDK_TOPDIR)/src/closed/share/native/sun/font/t2k \
-I$(JDK_TOPDIR)/src/closed/share/native/sun/font \ -I$(JDK_TOPDIR)/src/closed/share/native/sun/font \
-I$(JDK_TOPDIR)/src/share/share/native/sun/font \ -I$(JDK_TOPDIR)/src/share/share/native/sun/font \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/font \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/font \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d -I$(JDK_TOPDIR)/src/share/native/sun/java2d
$(eval $(call SetupNativeCompilation,BUILD_LIBT2K,\ $(eval $(call SetupNativeCompilation,BUILD_LIBT2K,\
...@@ -1343,15 +1426,18 @@ ifndef OPENJDK ...@@ -1343,15 +1426,18 @@ ifndef OPENJDK
CFLAGS_windows=-DCC_NOEX, \ CFLAGS_windows=-DCC_NOEX, \
CXXFLAGS_windows=-DCC_NOEX, \ CXXFLAGS_windows=-DCC_NOEX, \
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libt2k/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libt2k/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_windows:=user32.lib $(JDK_OUTPUTDIR)/objs/libfontmanager/fontmanager.lib,\ LDFLAGS_windows:=user32.lib $(JDK_OUTPUTDIR)/objs/libfontmanager/fontmanager.lib,\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX_posix:=$(LIBM) $(LIBCXX) -lfontmanager -ljava -ljvm -lc,\
LDFLAGS_SUFFIX_macosx:=$(LIBCXX) $(LIBM) -lfontmanager,\ LDFLAGS_SUFFIX_solaris:=-lawt -lawt_xawt,\
LDFLAGS_SUFFIX_linux:=$(LIBCXX) $(LIBM) -lfontmanager,\ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
LDFLAGS_SUFFIX_solaris:=$(LIBCXX) $(LIBM) -lfontmanager -lawt \ RC_FLAGS:=$(RC_FLAGS)\
-lawt_xawt,\ /D "JDK_FNAME=t2k.dll" \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libt2k)) /D "JDK_INTERNAL_NAME=t2k" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libt2k,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
# t2k is linked against fontmanager # t2k is linked against fontmanager
$(BUILD_LIBT2K) : $(BUILD_LIBFONTMANAGER) $(BUILD_LIBT2K) : $(BUILD_LIBFONTMANAGER)
...@@ -1361,40 +1447,40 @@ endif ...@@ -1361,40 +1447,40 @@ endif
########################################################################################## ##########################################################################################
#
# TODO replace with X_FLAGS / X_LIBS
# and add them to configure
#
OPENWIN_LIB:=$(OPENWIN_HOME)/lib
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
ifeq ($(ARCH_DATA_MODEL), 32) ifeq ($(OPENJDK_TARGET_CPU), x86)
KERNEL32_LIB:=kernel32.lib KERNEL32_LIB:=kernel32.lib
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBJAWT,\ $(eval $(call SetupNativeCompilation,BUILD_LIBJAWT,\
LIBRARY:=jawt, \ LIBRARY:=jawt, \
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/windows,\ SRC:=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/windows,\
INCLUDE_FILES:=jawt.cpp,\ INCLUDE_FILES:=jawt.cpp,\
LANG:=C++,\ LANG:=C++,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CXXFLAGS_JDKLIB) \ CFLAGS:=$(CXXFLAGS_JDKLIB) \
-EHsc -DUNICODE -D_UNICODE \ -EHsc -DUNICODE -D_UNICODE \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/windows \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/windows \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d/windows, \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/windows, \
LDFLAGS:=$(LDFLAGS_JDKLIB) $(KERNEL32_LIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) $(KERNEL32_LIB) $(LDFLAGS_CXX_JDK) \
advapi32.lib $(WIN_AWT_LIB),\ advapi32.lib $(WIN_AWT_LIB),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjawt)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=jawt.dll" \
/D "JDK_INTERNAL_NAME=jawt" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjawt,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBJAWT) : $(BUILD_LIBAWT) $(BUILD_LIBJAWT) : $(BUILD_LIBAWT)
$(JDK_OUTPUTDIR)/lib/$(LIBRARY_PREFIX)jawt$(STATIC_LIBRARY_SUFFIX): $(BUILD_LIBJAWT) $(JDK_OUTPUTDIR)/lib/$(LIBRARY_PREFIX)jawt$(STATIC_LIBRARY_SUFFIX): $(BUILD_LIBJAWT)
$(ECHO) Copying $(@F) $(ECHO) Copying $(@F)
$(CP) $< $@ $(CP) $(JDK_OUTPUTDIR)/objs/libjawt/$(LIBRARY_PREFIX)jawt$(STATIC_LIBRARY_SUFFIX) $@
BUILD_LIBRARIES += $(JDK_OUTPUTDIR)/lib/$(LIBRARY_PREFIX)jawt$(STATIC_LIBRARY_SUFFIX) BUILD_LIBRARIES += $(JDK_OUTPUTDIR)/lib/$(LIBRARY_PREFIX)jawt$(STATIC_LIBRARY_SUFFIX)
...@@ -1421,7 +1507,7 @@ else # OPENJDK_TARGET_OS not windows ...@@ -1421,7 +1507,7 @@ else # OPENJDK_TARGET_OS not windows
$(eval $(call SetupNativeCompilation,BUILD_LIBJAWT,\ $(eval $(call SetupNativeCompilation,BUILD_LIBJAWT,\
LIBRARY:=jawt, \ LIBRARY:=jawt, \
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/awt \ SRC:=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt \
$(JDK_TOPDIR)/src/macosx/native/sun/awt,\ $(JDK_TOPDIR)/src/macosx/native/sun/awt,\
INCLUDE_FILES:=$(JAWT_FILES),\ INCLUDE_FILES:=$(JAWT_FILES),\
LANG:=C,\ LANG:=C,\
...@@ -1432,10 +1518,11 @@ else # OPENJDK_TARGET_OS not windows ...@@ -1432,10 +1518,11 @@ else # OPENJDK_TARGET_OS not windows
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjawt/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjawt/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_solaris:=-L$(OPENWIN_HOME)/sfw/lib$(ISA_DIR) -L$(OPENWIN_LIB)$(ISA_DIR),\ LDFLAGS_solaris:=-L$(OPENWIN_HOME)/sfw/lib$(OPENJDK_TARGET_CPU_ISADIR) -L$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) $(JAWT_LIBS),\ LDFLAGS_SUFFIX_linux:=$(JAWT_LIBS) $(LDFLAGS_JDKLIB_SUFFIX),\
LDFLAGS_SUFFIX_solaris:=-lXrender,\ LDFLAGS_SUFFIX_solaris:=$(JAWT_LIBS) $(LDFLAGS_JDKLIB_SUFFIX) -lXrender,\
LDFLAGS_SUFFIX_macosx:=-framework Cocoa, \ LDFLAGS_SUFFIX_macosx:=-Xlinker -rpath -Xlinker @loader_path $(JAWT_LIBS) \
-framework Cocoa $(LDFLAGS_JDKLIB_SUFFIX),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjawt)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjawt))
ifndef BUILD_HEADLESS_ONLY ifndef BUILD_HEADLESS_ONLY
...@@ -1494,7 +1581,13 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJDBCODBC,\ ...@@ -1494,7 +1581,13 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJDBCODBC,\
LDFLAGS:=$(LIBJDBCODBC_LDFLAGS) \ LDFLAGS:=$(LIBJDBCODBC_LDFLAGS) \
$(call SET_SHARED_LIBRARY_ORIGIN) $(LIBJDBCODBC_LIBS),\ $(call SET_SHARED_LIBRARY_ORIGIN) $(LIBJDBCODBC_LIBS),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) $(LIBJDBCODBC_SONAME),\ LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) $(LIBJDBCODBC_SONAME),\
OBJECT_DIR:=$(LIBJDBCODBC_DIR))) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=JdbcOdbc.dll" \
/D "JDK_INTERNAL_NAME=JdbcOdbc" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(LIBJDBCODBC_DIR),\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBJDBCODBC) : $(BUILD_LIBJAVA) $(BUILD_LIBJDBCODBC) : $(BUILD_LIBJAVA)
...@@ -1538,11 +1631,11 @@ endif ...@@ -1538,11 +1631,11 @@ endif
########################################################################################## ##########################################################################################
BUILD_LIBINSTRUMENT_SRC :=$(JDK_TOPDIR)/src/share/instrument \ LIBINSTRUMENT_SRC :=$(JDK_TOPDIR)/src/share/instrument \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/io \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/io \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/instrument $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/instrument
BUILD_LIBINSTRUMENT_FILES :=\ LIBINSTRUMENT_FILES :=\
EncodingSupport.c \ EncodingSupport.c \
EncodingSupport_md.c \ EncodingSupport_md.c \
FileSystemSupport_md.c \ FileSystemSupport_md.c \
...@@ -1557,50 +1650,54 @@ BUILD_LIBINSTRUMENT_FILES :=\ ...@@ -1557,50 +1650,54 @@ BUILD_LIBINSTRUMENT_FILES :=\
Utilities.c \ Utilities.c \
canonicalize_md.c canonicalize_md.c
BUILD_LIBINSTRUMENT_DIR :=$(JDK_OUTPUTDIR)/objs/libinstrument LIBINSTRUMENT_DIR :=$(JDK_OUTPUTDIR)/objs/libinstrument
BUILD_LIBINSTRUMENT_CFLAGS:=-I$(JDK_TOPDIR)/src/share/instrument \ LIBINSTRUMENT_CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/instrument \ -I$(JDK_TOPDIR)/src/share/instrument \
-I$(JDK_TOPDIR)/src/share/bin -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/instrument \
-I$(JDK_TOPDIR)/src/share/bin
BUILD_LIBINSTRUMENT_LDFLAGS:= LIBINSTRUMENT_LDFLAGS:=
BUILD_LIBINSTRUMENT_LDFLAGS_SUFFIX:= LIBINSTRUMENT_LDFLAGS_SUFFIX:=
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
BUILD_LIBINSTRUMENT_LDFLAGS += $(JDK_OUTPUTDIR)/objs/jli_static.lib $(WIN_JAVA_LIB) \ LIBINSTRUMENT_LDFLAGS += $(JDK_OUTPUTDIR)/objs/jli_static.lib $(WIN_JAVA_LIB) \
-export:Agent_OnAttach -export:Agent_OnAttach advapi32.lib
# equivalent of strcasecmp is stricmp on Windows # Statically link the C runtime so that there are not dependencies on modules
BUILD_LIBINSTRUMENT_CFLAGS += -Dstrcasecmp=stricmp # not on the search patch when invoked from the Windows system directory
else ifneq (,$(findstring $(OPENJDK_TARGET_OS), macosx)) # (or elsewhere).
ifneq ($(ARCH), universal) LIBINSTRUMENT_CFLAGS := $(filter-out -MD,$(LIBINSTRUMENT_CFLAGS))
BUILD_LIBINSTRUMENT_LDFLAGS += -Wl,-all_load # equivalent of strcasecmp is stricmp on Windows
endif LIBINSTRUMENT_CFLAGS += -Dstrcasecmp=stricmp
BUILD_LIBINSTRUMENT_LDFLAGS += $(JDK_OUTPUTDIR)/objs/libjli_static.a
BUILD_LIBINSTRUMENT_LDFLAGS += -liconv
BUILD_LIBINSTRUMENT_LDFLAGS += -framework Cocoa -framework Security -framework ApplicationServices
BUILD_LIBINSTRUMENT_LDFLAGS += $(LIBZ)
else
BUILD_LIBINSTRUMENT_LDFLAGS += -L $(INSTALL_LIBRARIES_HERE)/jli
BUILD_LIBINSTRUMENT_LDFLAGS_SUFFIX += -ljli $(LIBDL)
endif endif
$(eval $(call SetupNativeCompilation,BUILD_LIBINSTRUMENT,\ $(eval $(call SetupNativeCompilation,BUILD_LIBINSTRUMENT,\
LIBRARY:=instrument, \ LIBRARY:=instrument, \
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(BUILD_LIBINSTRUMENT_SRC),\ SRC:=$(LIBINSTRUMENT_SRC),\
INCLUDE_FILES:=$(BUILD_LIBINSTRUMENT_FILES),\ INCLUDE_FILES:=$(LIBINSTRUMENT_FILES),\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(LIBINSTRUMENT_CFLAGS),\
$(BUILD_LIBINSTRUMENT_CFLAGS),\
CFLAGS_debug:=-DJPLIS_LOGGING,\ CFLAGS_debug:=-DJPLIS_LOGGING,\
CFLAGS_release:=-DNO_JPLIS_LOGGING,\ CFLAGS_release:=-DNO_JPLIS_LOGGING,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libinstrument/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libinstrument/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) $(call SET_SHARED_LIBRARY_ORIGIN)\ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN,jli) \ $(call SET_SHARED_LIBRARY_ORIGIN) \
$(BUILD_LIBINSTRUMENT_LDFLAGS),\ $(LIBINSTRUMENT_LDFLAGS),\
LDFLAGS_SUFFIX:=$(LIBZ) $(BUILD_LIBINSTRUMENT_LDFLAGS_SUFFIX),\ LDFLAGS_linux:=$(call SET_SHARED_LIBRARY_ORIGIN,/jli),\
OBJECT_DIR:=$(BUILD_LIBINSTRUMENT_DIR),\ LDFLAGS_solaris:= $(call SET_SHARED_LIBRARY_ORIGIN,/jli),\
LDFLAGS_macosx:=-Xlinker -all_load $(JDK_OUTPUTDIR)/objs/libjli_static.a \
-framework Cocoa -framework Security -framework ApplicationServices,\
LDFLAGS_SUFFIX:=$(LIBINSTRUMENT_LDFLAGS_SUFFIX),\
LDFLAGS_SUFFIX_macosx:=-liconv $(LIBZ),\
LDFLAGS_SUFFIX_solaris:=$(LIBZ) -L $(INSTALL_LIBRARIES_HERE)/jli -ljli $(LIBDL),\
LDFLAGS_SUFFIX_linux:=$(LIBZ) -L $(INSTALL_LIBRARIES_HERE)/jli -ljli $(LIBDL),\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=instrument.dll" \
/D "JDK_INTERNAL_NAME=instrument" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(LIBINSTRUMENT_DIR),\
DEBUG_SYMBOLS:=true)) DEBUG_SYMBOLS:=true))
ifneq (,$(findstring $(OPENJDK_TARGET_OS), macosx windows)) ifneq (,$(findstring $(OPENJDK_TARGET_OS), macosx windows))
...@@ -1615,8 +1712,8 @@ BUILD_LIBRARIES += $(BUILD_LIBINSTRUMENT) ...@@ -1615,8 +1712,8 @@ BUILD_LIBRARIES += $(BUILD_LIBINSTRUMENT)
########################################################################################## ##########################################################################################
BUILD_LIBMANAGEMENT_SRC:=$(JDK_TOPDIR)/src/share/native/sun/management \ BUILD_LIBMANAGEMENT_SRC:=$(JDK_TOPDIR)/src/share/native/sun/management \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/management \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/management \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/com/sun/management $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/com/sun/management
BUILD_LIBMANAGEMENT_EXCLUDES:= BUILD_LIBMANAGEMENT_EXCLUDES:=
...@@ -1640,6 +1737,12 @@ ifneq ($(OPENJDK_TARGET_OS),macosx) ...@@ -1640,6 +1737,12 @@ ifneq ($(OPENJDK_TARGET_OS),macosx)
BUILD_LIBMANAGEMENT_EXCLUDES += MacosxOperatingSystem.c BUILD_LIBMANAGEMENT_EXCLUDES += MacosxOperatingSystem.c
endif endif
LIBMANAGEMENT_OPTIMIZATION:=HIGH
ifneq ($(findstring $(OPENJDK_TARGET_OS),solaris linux),)
ifeq ($(ENABLE_DEBUG_SYMBOLS), yes)
LIBMANAGEMENT_OPTIMIZATION:=LOW
endif
endif
$(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT,\ $(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT,\
LIBRARY:=management,\ LIBRARY:=management,\
...@@ -1647,7 +1750,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT,\ ...@@ -1647,7 +1750,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT,\
SRC:=$(BUILD_LIBMANAGEMENT_SRC),\ SRC:=$(BUILD_LIBMANAGEMENT_SRC),\
EXCLUDE_FILES:=$(BUILD_LIBMANAGEMENT_EXCLUDES),\ EXCLUDE_FILES:=$(BUILD_LIBMANAGEMENT_EXCLUDES),\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=HIGH, \ OPTIMIZATION:=$(LIBMANAGEMENT_OPTIMIZATION), \
CFLAGS:=$(CFLAGS_JDKLIB) $(BUILD_LIBMANAGEMENT_CFLAGS),\ CFLAGS:=$(CFLAGS_JDKLIB) $(BUILD_LIBMANAGEMENT_CFLAGS),\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libmanagement/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libmanagement/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
...@@ -1655,6 +1758,11 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT,\ ...@@ -1655,6 +1758,11 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBMANAGEMENT,\
LDFLAGS_windows:=$(WIN_JAVA_LIB) jvm.lib advapi32.lib psapi.lib,\ LDFLAGS_windows:=$(WIN_JAVA_LIB) jvm.lib advapi32.lib psapi.lib,\
LDFLAGS_solaris:=-lkstat,\ LDFLAGS_solaris:=-lkstat,\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=management.dll" \
/D "JDK_INTERNAL_NAME=management" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libmanagement,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libmanagement,\
DEBUG_SYMBOLS:=true)) DEBUG_SYMBOLS:=true))
...@@ -1664,10 +1772,10 @@ BUILD_LIBRARIES += $(BUILD_LIBMANAGEMENT) ...@@ -1664,10 +1772,10 @@ BUILD_LIBRARIES += $(BUILD_LIBMANAGEMENT)
########################################################################################## ##########################################################################################
BUILD_LIBHPROF_SRC:=$(JDK_TOPDIR)/src/share/demo/jvmti/hprof $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/demo/jvmti/hprof BUILD_LIBHPROF_SRC:=$(JDK_TOPDIR)/src/share/demo/jvmti/hprof $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/demo/jvmti/hprof
BUILD_LIBHPROF_CFLAGS:=-I$(JDK_TOPDIR)/src/share/demo/jvmti/hprof \ BUILD_LIBHPROF_CFLAGS:=-I$(JDK_TOPDIR)/src/share/demo/jvmti/hprof \
-I$(JDK_TOPDIR)/src/share/npt \ -I$(JDK_TOPDIR)/src/share/npt \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/npt \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/npt \
-I$(JDK_TOPDIR)/src/share/demo/jvmti/java_crw_demo -I$(JDK_TOPDIR)/src/share/demo/jvmti/java_crw_demo
BUILD_LIBHPROF_LDFLAGS:= BUILD_LIBHPROF_LDFLAGS:=
...@@ -1676,6 +1784,13 @@ ifeq ($(OPENJDK_TARGET_OS),solaris) ...@@ -1676,6 +1784,13 @@ ifeq ($(OPENJDK_TARGET_OS),solaris)
BUILD_LIBHPROF_LDFLAGS += -lsocket -lnsl BUILD_LIBHPROF_LDFLAGS += -lsocket -lnsl
endif endif
LIBHPROF_OPTIMIZATION:=HIGHEST
ifneq ($(findstring $(OPENJDK_TARGET_OS),solaris linux),)
ifeq ($(ENABLE_DEBUG_SYMBOLS), yes)
LIBHPROF_OPTIMIZATION:=LOW
endif
endif
ifneq ($(OPENJDK_TARGET_OS),windows) ifneq ($(OPENJDK_TARGET_OS),windows)
BUILD_LIBHPROF_LDFLAGS += $(LIBDL) BUILD_LIBHPROF_LDFLAGS += $(LIBDL)
endif endif
...@@ -1685,7 +1800,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBHPROF,\ ...@@ -1685,7 +1800,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBHPROF,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(BUILD_LIBHPROF_SRC),\ SRC:=$(BUILD_LIBHPROF_SRC),\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=HIGHEST, \ OPTIMIZATION:=$(LIBHPROF_OPTIMIZATION), \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
$(BUILD_LIBHPROF_CFLAGS),\ $(BUILD_LIBHPROF_CFLAGS),\
CFLAGS_debug:=-DHPROF_LOGGING,\ CFLAGS_debug:=-DHPROF_LOGGING,\
...@@ -1694,6 +1809,11 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBHPROF,\ ...@@ -1694,6 +1809,11 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBHPROF,\
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_windows:=wsock32.lib winmm.lib advapi32.lib,\ LDFLAGS_windows:=wsock32.lib winmm.lib advapi32.lib,\
LDFLAGS_SUFFIX:=$(BUILD_LIBHPROF_LDFLAGS),\ LDFLAGS_SUFFIX:=$(BUILD_LIBHPROF_LDFLAGS),\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=hprof.dll" \
/D "JDK_INTERNAL_NAME=hprof" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libhprof_jvmti,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libhprof_jvmti,\
DEBUG_SYMBOLS:=true)) DEBUG_SYMBOLS:=true))
...@@ -1712,7 +1832,11 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJAVA_CRW_DEMO,\ ...@@ -1712,7 +1832,11 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJAVA_CRW_DEMO,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjava_crw_demo/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjava_crw_demo/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=,\ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=java_crw_demo.dll" \
/D "JDK_INTERNAL_NAME=java_crw_demo" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjava_crw_demo,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjava_crw_demo,\
DEBUG_SYMBOLS:=true)) DEBUG_SYMBOLS:=true))
...@@ -1723,17 +1847,22 @@ BUILD_LIBRARIES += $(BUILD_LIBJAVA_CRW_DEMO) ...@@ -1723,17 +1847,22 @@ BUILD_LIBRARIES += $(BUILD_LIBJAVA_CRW_DEMO)
$(eval $(call SetupNativeCompilation,BUILD_LIBNPT,\ $(eval $(call SetupNativeCompilation,BUILD_LIBNPT,\
LIBRARY:=npt, \ LIBRARY:=npt, \
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/npt $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/npt,\ SRC:=$(JDK_TOPDIR)/src/share/npt $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/npt,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/npt \ -I$(JDK_TOPDIR)/src/share/npt \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/npt,\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/npt,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnpt/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnpt/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_macosx:=-liconv,\ LDFLAGS_macosx:=-liconv,\
LDFLAGS_SUFFIX_windows:=-export:nptInitialize -export:nptTerminate,\ LDFLAGS_SUFFIX_windows:=-export:nptInitialize -export:nptTerminate,\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=npt.dll" \
/D "JDK_INTERNAL_NAME=npt" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libnpt,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libnpt,\
DEBUG_SYMBOLS:=true)) DEBUG_SYMBOLS:=true))
...@@ -1742,11 +1871,11 @@ BUILD_LIBRARIES += $(BUILD_LIBNPT) ...@@ -1742,11 +1871,11 @@ BUILD_LIBRARIES += $(BUILD_LIBNPT)
########################################################################################## ##########################################################################################
LIBNET_SRC_DIRS:=$(JDK_TOPDIR)/src/share/native/java/net \ LIBNET_SRC_DIRS:=$(JDK_TOPDIR)/src/share/native/java/net \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/net \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/net \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/net/dns \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/net/dns \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/net/www/protocol/http/ntlm \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/net/www/protocol/http/ntlm \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/net/sdp \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/net/sdp \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/net/spi $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/net/spi
LIBNET_CFLAGS:=$(foreach dir,$(LIBNET_SRC_DIRS),-I$(dir)) LIBNET_CFLAGS:=$(foreach dir,$(LIBNET_SRC_DIRS),-I$(dir))
...@@ -1767,8 +1896,6 @@ else ...@@ -1767,8 +1896,6 @@ else
NTLMAuthSequence.c NetworkInterface_winXP.c NTLMAuthSequence.c NetworkInterface_winXP.c
endif endif
LIBNET_LDFLAGS_SUFFIX:=
$(eval $(call SetupNativeCompilation,BUILD_LIBNET,\ $(eval $(call SetupNativeCompilation,BUILD_LIBNET,\
LIBRARY:=net,\ LIBRARY:=net,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
...@@ -1781,13 +1908,19 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBNET,\ ...@@ -1781,13 +1908,19 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBNET,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnet/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnet/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) $(LIBNET_LDFLAGS_SUFFIX),\ LDFLAGS_SUFFIX_macosx:=-ljvm -ljava,\
LDFLAGS_SUFFIX_solaris:=-lnsl -lsocket $(LIBDL) ,\ LDFLAGS_SUFFIX_solaris:=-ljvm -ljava -lnsl -lsocket $(LIBDL) ,\
LDFLAGS_SUFFIX_linux:=$(LIBDL) -lpthread ,\ LDFLAGS_SUFFIX_linux:=$(LIBDL) -ljvm -lpthread -ljava,\
LDFLAGS_SUFFIX_windows:=ws2_32.lib $(JVMLIB) secur32.lib iphlpapi.lib \ LDFLAGS_SUFFIX_windows:=ws2_32.lib $(JVMLIB) secur32.lib iphlpapi.lib \
delayimp.lib $(WIN_JAVA_LIB) jvm.lib advapi32.lib \ delayimp.lib $(WIN_JAVA_LIB) jvm.lib advapi32.lib \
/DELAYLOAD:secur32.dll /DELAYLOAD:iphlpapi.dll, \ /DELAYLOAD:secur32.dll /DELAYLOAD:iphlpapi.dll, \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libnet)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=net.dll" \
/D "JDK_INTERNAL_NAME=net" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libnet,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBNET) : $(BUILD_LIBJAVA) $(BUILD_LIBNET) : $(BUILD_LIBJAVA)
...@@ -1801,7 +1934,7 @@ $(JDK_OUTPUTDIR)/lib/net.properties: $(JDK_TOPDIR)/src/share/lib/net.properties ...@@ -1801,7 +1934,7 @@ $(JDK_OUTPUTDIR)/lib/net.properties: $(JDK_TOPDIR)/src/share/lib/net.properties
COPY_FILES += $(JDK_OUTPUTDIR)/lib/net.properties COPY_FILES += $(JDK_OUTPUTDIR)/lib/net.properties
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
$(JDK_OUTPUTDIR)/lib/sdp/sdp.conf.template : $(JDK_TOPDIR)/src/${LEGACY_OPENJDK_TARGET_OS_API}/lib/sdp/sdp.conf.template $(JDK_OUTPUTDIR)/lib/sdp/sdp.conf.template : $(JDK_TOPDIR)/src/${OPENJDK_TARGET_OS_API_DIR}/lib/sdp/sdp.conf.template
$(ECHO) Copying $(@F) $(ECHO) Copying $(@F)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
...@@ -1812,15 +1945,15 @@ endif ...@@ -1812,15 +1945,15 @@ endif
########################################################################################## ##########################################################################################
BUILD_LIBNIO_SRC:=\ BUILD_LIBNIO_SRC:=\
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/nio \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/nio \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/nio/ch \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/nio/ch \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/nio/fs $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/nio/fs
BUILD_LIBNIO_CFLAGS:=\ BUILD_LIBNIO_CFLAGS:=\
-I$(JDK_TOPDIR)/src/share/native/sun/nio/ch \ -I$(JDK_TOPDIR)/src/share/native/sun/nio/ch \
-I$(JDK_TOPDIR)/src/share/native/java/io \ -I$(JDK_TOPDIR)/src/share/native/java/io \
-I$(JDK_TOPDIR)/src/share/native/java/net \ -I$(JDK_TOPDIR)/src/share/native/java/net \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/net -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/net
BUILD_LIBNIO_FILES:=\ BUILD_LIBNIO_FILES:=\
DatagramChannelImpl.c \ DatagramChannelImpl.c \
...@@ -1847,14 +1980,14 @@ ifeq ($(OPENJDK_TARGET_OS), windows) ...@@ -1847,14 +1980,14 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
endif endif
ifeq ($(OPENJDK_TARGET_OS), linux) ifeq ($(OPENJDK_TARGET_OS), linux)
BUILD_LIBNIO_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnio/mapfile-linux BUILD_LIBNIO_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnio/mapfile-$(OPENJDK_TARGET_OS)
BUILD_LIBNIO_FILES += \ BUILD_LIBNIO_FILES += \
EPoll.c \ EPoll.c \
EPollArrayWrapper.c \ EPollArrayWrapper.c \
EPollPort.c \ EPollPort.c \
InheritedChannel.c \ InheritedChannel.c \
NativeThread.c \ NativeThread.c \
PollArrayWrapper.c \ PollArrayWrapper.c \
UnixAsynchronousServerSocketChannelImpl.c \ UnixAsynchronousServerSocketChannelImpl.c \
UnixAsynchronousSocketChannelImpl.c \ UnixAsynchronousSocketChannelImpl.c \
GnomeFileTypeDetector.c \ GnomeFileTypeDetector.c \
...@@ -1865,7 +1998,7 @@ ifeq ($(OPENJDK_TARGET_OS), linux) ...@@ -1865,7 +1998,7 @@ ifeq ($(OPENJDK_TARGET_OS), linux)
endif endif
ifeq ($(OPENJDK_TARGET_OS), macosx) ifeq ($(OPENJDK_TARGET_OS), macosx)
BUILD_LIBNIO_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnio/mapfile-bsd BUILD_LIBNIO_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnio/mapfile-$(OPENJDK_TARGET_OS)
BUILD_LIBNIO_SRC += $(JDK_TOPDIR)/src/macosx/native/sun/nio/ch BUILD_LIBNIO_SRC += $(JDK_TOPDIR)/src/macosx/native/sun/nio/ch
BUILD_LIBNIO_FILES += \ BUILD_LIBNIO_FILES += \
InheritedChannel.c \ InheritedChannel.c \
...@@ -1873,8 +2006,8 @@ ifeq ($(OPENJDK_TARGET_OS), macosx) ...@@ -1873,8 +2006,8 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
PollArrayWrapper.c \ PollArrayWrapper.c \
UnixAsynchronousServerSocketChannelImpl.c \ UnixAsynchronousServerSocketChannelImpl.c \
UnixAsynchronousSocketChannelImpl.c \ UnixAsynchronousSocketChannelImpl.c \
GnomeFileTypeDetector.c \
BsdNativeDispatcher.c \ BsdNativeDispatcher.c \
MacOSXNativeDispatcher.c \
UnixCopyFile.c \ UnixCopyFile.c \
UnixNativeDispatcher.c \ UnixNativeDispatcher.c \
KQueue.c \ KQueue.c \
...@@ -1883,7 +2016,7 @@ ifeq ($(OPENJDK_TARGET_OS), macosx) ...@@ -1883,7 +2016,7 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
endif endif
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
BUILD_LIBNIO_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnio/mapfile-solaris BUILD_LIBNIO_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libnio/mapfile-$(OPENJDK_TARGET_OS)
BUILD_LIBNIO_FILES += \ BUILD_LIBNIO_FILES += \
DevPollArrayWrapper.c \ DevPollArrayWrapper.c \
InheritedChannel.c \ InheritedChannel.c \
...@@ -1912,17 +2045,22 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBNIO,\ ...@@ -1912,17 +2045,22 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBNIO,\
LDFLAGS:=$(LDFLAGS_JDKLIB) $(BUILD_LIBNIO_LDFLAGS) \ LDFLAGS:=$(LDFLAGS_JDKLIB) $(BUILD_LIBNIO_LDFLAGS) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX_linux:=-ljava -lnet -lpthread $(LIBDL),\ LDFLAGS_SUFFIX_linux:=-ljava -lnet -lpthread $(LIBDL),\
LDFLAGS_SUFFIX_solaris:=$(LDFLAGS_JDKLIB_SUFFIX) \ LDFLAGS_SUFFIX_solaris:=-ljvm -lsocket -lposix4 $(LIBDL) \
$(JVMLIB) -lsocket -lposix4 $(LIBDL) -lsendfile \ -lsendfile -ljava -lnet -lc,\
-ljava -lnet,\
LDFLAGS_SUFFIX_windows:=$(LDFLAGS_JDKLIB_SUFFIX) \ LDFLAGS_SUFFIX_windows:=$(LDFLAGS_JDKLIB_SUFFIX) \
$(WIN_JAVA_LIB) $(JDK_OUTPUTDIR)/objs/libnet/net.lib \ $(WIN_JAVA_LIB) $(JDK_OUTPUTDIR)/objs/libnet/net.lib \
advapi32.lib jvm.lib ws2_32.lib\ advapi32.lib jvm.lib ws2_32.lib\
$(JDK_OUTPUTDIR)/objs/libjava/io_util.obj \ $(JDK_OUTPUTDIR)/objs/libjava/io_util.obj \
$(JDK_OUTPUTDIR)/objs/libjava/FileDescriptor_md.obj ,\ $(JDK_OUTPUTDIR)/objs/libjava/FileDescriptor_md.obj ,\
LDFLAGS_SUFFIX_macosx:=-ljava -lnet -pthread,\ LDFLAGS_SUFFIX_macosx:=-ljava -lnet -pthread -framework CoreFoundation,\
LDFLAGS_SUFFIX:=,\ LDFLAGS_SUFFIX:=,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libnio)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=nio.dll" \
/D "JDK_INTERNAL_NAME=nio" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libnio,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBNIO) BUILD_LIBRARIES += $(BUILD_LIBNIO)
...@@ -1942,23 +2080,23 @@ ifeq ($(OPENJDK_TARGET_OS_API),posix) ...@@ -1942,23 +2080,23 @@ ifeq ($(OPENJDK_TARGET_OS_API),posix)
$(eval $(call SetupNativeCompilation,BUILD_LIBSCTP,\ $(eval $(call SetupNativeCompilation,BUILD_LIBSCTP,\
LIBRARY:=sctp,\ LIBRARY:=sctp,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/nio/ch/sctp,\ SRC:=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/nio/ch/sctp,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB)\ CFLAGS:=$(CFLAGS_JDKLIB)\
-I$(JDK_TOPDIR)/src/share/native/sun/nio/ch \ -I$(JDK_TOPDIR)/src/share/native/sun/nio/ch \
-I$(JDK_TOPDIR)/src/share/native/sun/nio/ch/sctp \ -I$(JDK_TOPDIR)/src/share/native/sun/nio/ch/sctp \
-I$(JDK_TOPDIR)/src/share/native/java/net \ -I$(JDK_TOPDIR)/src/share/native/java/net \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/nio/ch \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/nio/ch \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/java/net,\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/java/net,\
CFLAGS_linux:=$(SCTP_WERROR),\ CFLAGS_linux:=$(SCTP_WERROR),\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsctp/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsctp/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX_linux:=$(LIBDL) -lpthread,\ LDFLAGS_SUFFIX_linux:=-lpthread $(LIBDL) -ljava -ljvm,\
LDFLAGS_SUFFIX_posix:=-lnio -lnet,\ LDFLAGS_SUFFIX_posix:=-lnio -lnet,\
LDFLAGS_SUFFIX_solaris:=-lsocket,\ LDFLAGS_SUFFIX_solaris:=-lsocket -ljava -ljvm,\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX_macosx:=-ljava -ljvm,\
INCLUDE_FILES:=SctpNet.c SctpChannelImpl.c SctpServerChannelImpl.c,\ INCLUDE_FILES:=SctpNet.c SctpChannelImpl.c SctpServerChannelImpl.c,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsctp)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsctp))
...@@ -1970,8 +2108,8 @@ endif ...@@ -1970,8 +2108,8 @@ endif
########################################################################################## ##########################################################################################
BUILD_LIBJLI_SRC_DIRS:=$(JDK_TOPDIR)/src/share/bin $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/bin BUILD_LIBJLI_SRC_DIRS:=$(JDK_TOPDIR)/src/share/bin $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin
BUILD_LIBJLI_CFLAGS:=$(foreach dir,$(BUILD_LIBJLI_SRC_DIRS),-I$(dir)) LIBJLI_CFLAGS:=$(CFLAGS_JDKLIB) $(foreach dir,$(BUILD_LIBJLI_SRC_DIRS),-I$(dir))
BUILD_LIBJLI_FILES:=\ BUILD_LIBJLI_FILES:=\
java.c \ java.c \
...@@ -1983,16 +2121,16 @@ BUILD_LIBJLI_FILES:=\ ...@@ -1983,16 +2121,16 @@ BUILD_LIBJLI_FILES:=\
ifeq ($(JVM_VARIANT_ZERO), true) ifeq ($(JVM_VARIANT_ZERO), true)
ERGO_FAMILY:=zero ERGO_FAMILY:=zero
else # !ZERO_BUILD else
ifneq (,$(findstring $(ARCH), amd64 x86_64)) ifeq ($(OPENJDK_TARGET_CPU_ARCH), x86)
ERGO_FAMILY:=i586 ERGO_FAMILY:=i586
else # !X86 FAMILY else
ERGO_FAMILY:=$(ARCH) ERGO_FAMILY:=$(OPENJDK_TARGET_CPU_ARCH)
endif #ARCH_FAMILY endif
endif # ZERO_BUILD endif
ifeq ($(OPENJDK_TARGET_OS), macosx) ifeq ($(OPENJDK_TARGET_OS), macosx)
BUILD_LIBJLI_CFLAGS += -I$(JDK_TOPDIR)/src/macosx/bin LIBJLI_CFLAGS += -I$(JDK_TOPDIR)/src/macosx/bin
BUILD_LIBJLI_SRC_DIRS += $(JDK_TOPDIR)/src/macosx/bin BUILD_LIBJLI_SRC_DIRS += $(JDK_TOPDIR)/src/macosx/bin
BUILD_LIBJLI_FILES += java_md_common.c java_md_macosx.c BUILD_LIBJLI_FILES += java_md_common.c java_md_macosx.c
...@@ -2001,7 +2139,10 @@ ifeq ($(OPENJDK_TARGET_OS), macosx) ...@@ -2001,7 +2139,10 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
endif endif
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
BUILD_LIBJLI_FILES += java_md.c BUILD_LIBJLI_FILES += java_md.c \
cmdtoargs.c
# Staticically link with c runtime on windows.
LIBJLI_CFLAGS:=$(filter-out -MD,$(LIBJLI_CFLAGS))
else ifneq ($(OPENJDK_TARGET_OS), macosx) else ifneq ($(OPENJDK_TARGET_OS), macosx)
BUILD_LIBJLI_FILES += java_md_common.c BUILD_LIBJLI_FILES += java_md_common.c
...@@ -2011,36 +2152,23 @@ else ifneq ($(OPENJDK_TARGET_OS), macosx) ...@@ -2011,36 +2152,23 @@ else ifneq ($(OPENJDK_TARGET_OS), macosx)
# if the architecture specific ergo file exists then # if the architecture specific ergo file exists then
# use it, else use the generic definitions from ergo.c # use it, else use the generic definitions from ergo.c
ifneq ($(wildcard $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/bin/$(ERGO_ARCH_FILE)),) ifneq ($(wildcard $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin/$(ERGO_ARCH_FILE)),)
BUILD_LIBJLI_FILES += $(ERGO_ARCH_FILE) BUILD_LIBJLI_FILES += $(ERGO_ARCH_FILE)
else # !ERGO_ARCH_FILE else # !ERGO_ARCH_FILE
BUILD_LIBJLI_CFLAGS += -DUSE_GENERIC_ERGO LIBJLI_CFLAGS += -DUSE_GENERIC_ERGO
endif # ERGO_ARCH_FILE endif # ERGO_ARCH_FILE
endif #WINDOWS endif #WINDOWS
# Names of arch directories # Append defines depending on target platform
ifneq ($(OPENJDK_TARGET_OS), macosx) LIBJLI_CFLAGS += $(OPENJDK_TARGET_CPU_JLI_CFLAGS)
BUILD_LIBJLI_CFLAGS += -DLIBARCHNAME='"$(LIBARCH)"'
else
BUILD_LIBJLI_CFLAGS += -DLIBARCHNAME='"$(ARCH)"'
endif
ifeq ($(OPENJDK_TARGET_OS), solaris)
ifeq ($(OPENJDK_TARGET_CPU_ARCH), sparc)
BUILD_LIBJLI_CFLAGS += -DLIBARCH32NAME='"sparc"'
BUILD_LIBJLI_CFLAGS += -DLIBARCH64NAME='"sparcv9"'
else
BUILD_LIBJLI_CFLAGS += -DLIBARCH32NAME='"i386"'
BUILD_LIBJLI_CFLAGS += -DLIBARCH64NAME='"amd64"'
endif
endif # OPENJDK_TARGET_OS
ifeq ($(OPENJDK_TARGET_OS), macosx) ifeq ($(OPENJDK_TARGET_OS), macosx)
BUILD_LIBJLI_CFLAGS += -DPACKAGE_PATH=\"$(PACKAGE_PATH)\" LIBJLI_CFLAGS += -DPACKAGE_PATH=\"$(PACKAGE_PATH)\"
endif endif
ifneq ($(USE_EXTERNAL_LIBZ),true) ifneq ($(USE_EXTERNAL_LIBZ),true)
BUILD_LIBJLI_SRC_DIRS += $(JDK_TOPDIR)/src/share/native/java/util/zip/zlib-1.2.5 BUILD_LIBJLI_SRC_DIRS += $(JDK_TOPDIR)/src/share/native/java/util/zip/zlib-1.2.5
BUILD_LIBJLI_CFLAGS += $(LIBZ_INCLUDE) LIBJLI_CFLAGS += $(LIBZ_INCLUDE)
BUILD_LIBJLI_FILES += \ BUILD_LIBJLI_FILES += \
inflate.c \ inflate.c \
inftrees.c \ inftrees.c \
...@@ -2063,13 +2191,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJLI,\ ...@@ -2063,13 +2191,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJLI,\
INCLUDE_FILES:=$(BUILD_LIBJLI_FILES),\ INCLUDE_FILES:=$(BUILD_LIBJLI_FILES),\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=HIGH, \ OPTIMIZATION:=HIGH, \
CFLAGS:=$(CFLAGS_JDKLIB) $(BUILD_LIBJLI_CFLAGS),\ CFLAGS:=$(LIBJLI_CFLAGS),\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjli/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjli/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(LIBZ),\ LDFLAGS_linux:=$(call SET_SHARED_LIBRARY_ORIGIN,/..),\
LDFLAGS_SUFFIX_posix:=$(LIBDL) -lc,\ LDFLAGS_solaris:=$(call SET_SHARED_LIBRARY_ORIGIN,/..),\
LDFLAGS_SUFFIX_linux:=-lpthread,\ LDFLAGS_macosx:=-framework Cocoa -framework Security -framework ApplicationServices,\
LDFLAGS_SUFFIX_solaris:=$(LIBZ) $(LIBDL) -lc,\
LDFLAGS_SUFFIX_linux:=$(LIBZ) $(LIBDL) -lc -lpthread,\
LDFLAGS_SUFFIX_macosx:=$(LIBZ),\
LDFLAGS_SUFFIX_windows:=\ LDFLAGS_SUFFIX_windows:=\
-export:JLI_Launch \ -export:JLI_Launch \
-export:JLI_ManifestIterate \ -export:JLI_ManifestIterate \
...@@ -2078,11 +2209,20 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJLI,\ ...@@ -2078,11 +2209,20 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJLI,\
-export:JLI_ReportErrorMessageSys \ -export:JLI_ReportErrorMessageSys \
-export:JLI_ReportMessage \ -export:JLI_ReportMessage \
-export:JLI_ReportExceptionDescription \ -export:JLI_ReportExceptionDescription \
-export:JLI_MemAlloc \
-export:JLI_CmdToArgs \
-export:JLI_GetStdArgc \
-export:JLI_GetStdArgs \
advapi32.lib \ advapi32.lib \
comctl32.lib \ comctl32.lib \
user32.lib,\ user32.lib,\
LDFLAGS_SUFFIX_macosx:=-framework Cocoa -framework Security -framework ApplicationServices, \ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjli)) RC_FLAGS:=$(RC_FLAGS) \
/D "JDK_FNAME=jli.dll" \
/D "JDK_INTERNAL_NAME=jli" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjli,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBJLI) BUILD_LIBRARIES += $(BUILD_LIBJLI)
...@@ -2097,7 +2237,7 @@ ifeq ($(OPENJDK_TARGET_OS), windows) ...@@ -2097,7 +2237,7 @@ ifeq ($(OPENJDK_TARGET_OS), windows)
INCLUDE_FILES:=$(BUILD_LIBJLI_FILES),\ INCLUDE_FILES:=$(BUILD_LIBJLI_FILES),\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=HIGH, \ OPTIMIZATION:=HIGH, \
CFLAGS:=$(CFLAGS_JDKLIB) $(STATIC_LIBRARY_FLAGS) $(BUILD_LIBJLI_CFLAGS),\ CFLAGS:=$(STATIC_LIBRARY_FLAGS) $(LIBJLI_CFLAGS),\
ARFLAGS:=$(ARFLAGS),\ ARFLAGS:=$(ARFLAGS),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjli_static)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjli_static))
...@@ -2115,7 +2255,7 @@ else ifeq ($(OPENJDK_TARGET_OS),macosx) ...@@ -2115,7 +2255,7 @@ else ifeq ($(OPENJDK_TARGET_OS),macosx)
INCLUDE_FILES:=$(BUILD_LIBJLI_FILES),\ INCLUDE_FILES:=$(BUILD_LIBJLI_FILES),\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=HIGH, \ OPTIMIZATION:=HIGH, \
CFLAGS:=$(CFLAGS_JDKLIB) $(BUILD_LIBJLI_CFLAGS),\ CFLAGS:=$(CFLAGS_JDKLIB) $(LIBJLI_CFLAGS),\
LDFLAGS:=-nostdlib -r,\ LDFLAGS:=-nostdlib -r,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjli_static)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjli_static))
...@@ -2140,7 +2280,13 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJFR,\ ...@@ -2140,7 +2280,13 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJFR,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjfr/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjfr/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjfr)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=jfr.dll" \
/D "JDK_INTERNAL_NAME=jfr" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjfr,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBJFR) BUILD_LIBRARIES += $(BUILD_LIBJFR)
...@@ -2180,11 +2326,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBKCMS,\ ...@@ -2180,11 +2326,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBKCMS,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libkcms/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libkcms/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX_linux:=-lpthread,\ LDFLAGS_SUFFIX_linux:=-lc -lpthread,\
LDFLAGS_SUFFIX_windows:=$(WIN_JAVA_LIB) advapi32.lib user32.lib version.lib, \ LDFLAGS_SUFFIX_windows:=$(WIN_JAVA_LIB) advapi32.lib user32.lib version.lib, \
LDFLAGS_SUFFIX:=-lm $(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=-lm $(LDFLAGS_JDKLIB_SUFFIX),\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/closed/share/native/sun/java2d/cmm/kcms/cmm.rc,\ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/closed/share/native/sun/java2d/cmm/kcms/cmm.rc,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libkcms)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/closed/share/native/sun/java2d/cmm/kcms/cmm.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=kcms.dll" \
/D "JDK_INTERNAL_NAME=kcms" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libkcms,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBKCMS) : $(BUILD_LIBJAVA) $(BUILD_LIBKCMS) : $(BUILD_LIBJAVA)
...@@ -2196,12 +2348,12 @@ endif ...@@ -2196,12 +2348,12 @@ endif
ifndef OPENJDK ifndef OPENJDK
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
ifneq ($(ARCH), amd64) ifneq ($(OPENJDK_TARGET_CPU), x86_64)
ifeq ($(shell if test "$(OS_VERSION_MAJOR)" -eq 5 -a "$(OS_VERSION_MINOR)" -le 10; then $(ECHO) ok; fi), ok) ifeq ($(shell if test "$(OS_VERSION_MAJOR)" -eq 5 -a "$(OS_VERSION_MINOR)" -le 10; then $(ECHO) ok; fi), ok)
SUNWJDGA_MAPFILE:= SUNWJDGA_MAPFILE:=
ifneq (,$(findstring $(ARCH),sparc)) ifeq ($(OPENJDK_TARGET_CPU_ARCH), sparc)
SUNWJDGA_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjdga/mapfile-vers SUNWJDGA_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjdga/mapfile-vers
endif endif
...@@ -2213,12 +2365,12 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBSUNWJDGA, \ ...@@ -2213,12 +2365,12 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBSUNWJDGA, \
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/javavm/export \ -I$(JDK_TOPDIR)/src/share/javavm/export \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/javavm/export \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/javavm/export \
-I$(OPENWIN_HOME)/include, \ -I$(OPENWIN_HOME)/include, \
MAPFILE:=$(SUNWJDGA_MAPFILE), \ MAPFILE:=$(SUNWJDGA_MAPFILE), \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN), \ $(call SET_SHARED_LIBRARY_ORIGIN), \
LDFLAGS_SUFFIX:=-L$(OPENWIN_LIB)$(ISA_DIR) -R$(OPENWIN_LIB)$(ISA_DIR) -ldga -lX11 $(LIBDL) -lc, \ LDFLAGS_SUFFIX:=-L$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) -R$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) -ldga -lX11 $(LIBDL) -lc, \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsunwjdga)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsunwjdga))
BUILD_LIBRARIES += $(BUILD_LIBSUNWJDGA) BUILD_LIBRARIES += $(BUILD_LIBSUNWJDGA)
...@@ -2245,13 +2397,13 @@ LIBAWT_HEADLESS_CFLAGS:=-DHEADLESS=true \ ...@@ -2245,13 +2397,13 @@ LIBAWT_HEADLESS_CFLAGS:=-DHEADLESS=true \
$(CUPS_CFLAGS) \ $(CUPS_CFLAGS) \
$(X_CFLAGS) \ $(X_CFLAGS) \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/java2d \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d/loops \
-I$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \ -I$(JDK_TOPDIR)/src/share/native/sun/java2d/pipe \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/image \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/image \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/jdga \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/jdga \
$(foreach dir,$(LIBAWT_HEADLESS_DIRS),-I$(dir)) $(foreach dir,$(LIBAWT_HEADLESS_DIRS),-I$(dir))
LIBAWT_HEADLESS_FILES:=\ LIBAWT_HEADLESS_FILES:=\
...@@ -2282,12 +2434,10 @@ LIBAWT_HEADLESS_FILES:=\ ...@@ -2282,12 +2434,10 @@ LIBAWT_HEADLESS_FILES:=\
AccelGlyphCache.c \ AccelGlyphCache.c \
CUPSfuncs.c CUPSfuncs.c
LIBAWT_HEADLESS_LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) -lawt -lm
LIBAWT_HEADLESS_REORDER:= LIBAWT_HEADLESS_REORDER:=
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
ifneq ($(ARCH), amd64) ifneq ($(OPENJDK_TARGET_CPU), x86_64)
LIBAWT_HEADLESS_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libawt_headless/reorder-$(ARCH) LIBAWT_HEADLESS_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libawt_headless/reorder-$(OPENJDK_TARGET_CPU)
endif endif
endif endif
...@@ -2302,11 +2452,15 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT_HEADLESS,\ ...@@ -2302,11 +2452,15 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT_HEADLESS,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libawt_headless/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libawt_headless/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_linux:=$(call SET_SHARED_LIBRARY_ORIGIN,/..),\
LDFLAGS_solaris:=$(call SET_SHARED_LIBRARY_ORIGIN,/..) \
-R/usr/dt/lib$(OPENJDK_TARGET_CPU_ISADIR) \
-R$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR),\
LDFLAGS_macosx:=$(call SET_SHARED_LIBRARY_ORIGIN).,\
REORDER:=$(LIBAWT_HEADLESS_REORDER), \ REORDER:=$(LIBAWT_HEADLESS_REORDER), \
LDFLAGS_SUFFIX:=$(LIBAWT_HEADLESS_LDFLAGS_SUFFIX),\ LDFLAGS_SUFFIX_linux:=-ljvm -lawt -lm $(LIBDL) -ljava,\
LDFLAGS_SUFFIX_posix:=$(LIBDL),\ LDFLAGS_SUFFIX_solaris:=$(LIBDL) -ljvm -lawt -lm -ljava $(LIBCXX), \
LDFLAGS_SUFFIX_macosx:=$(LIBCXX), \ LDFLAGS_SUFFIX_macosx:=-ljvm $(LIBCXX) -lawt $(LIBDL) -ljava, \
LDFLAGS_SUFFIX_solaris:=$(LIBCXX), \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libawt_headless)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libawt_headless))
$(BUILD_LIBAWT_HEADLESS) : $(BUILD_LIBAWT) $(BUILD_LIBAWT_HEADLESS) : $(BUILD_LIBAWT)
...@@ -2324,7 +2478,7 @@ LIBSPLASHSCREEN_DIRS:=\ ...@@ -2324,7 +2478,7 @@ LIBSPLASHSCREEN_DIRS:=\
$(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg \ $(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg \
$(JDK_TOPDIR)/src/share/native/sun/awt/libpng \ $(JDK_TOPDIR)/src/share/native/sun/awt/libpng \
$(JDK_TOPDIR)/src/share/native/sun/awt/splashscreen \ $(JDK_TOPDIR)/src/share/native/sun/awt/splashscreen \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/awt/splashscreen $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt/splashscreen
LIBSPLASHSCREEN_CFLAGS:=-DSPLASHSCREEN -DPNG_NO_MMX_CODE \ LIBSPLASHSCREEN_CFLAGS:=-DSPLASHSCREEN -DPNG_NO_MMX_CODE \
$(foreach dir,$(LIBSPLASHSCREEN_DIRS),-I$(dir)) $(foreach dir,$(LIBSPLASHSCREEN_DIRS),-I$(dir))
...@@ -2458,7 +2612,7 @@ ifeq ($(OPENJDK_TARGET_OS), macosx) ...@@ -2458,7 +2612,7 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \ -F/System/Library/Frameworks/JavaVM.framework/Frameworks \
-framework JavaNativeFoundation -framework JavaNativeFoundation
else ifneq ($(OPENJDK_TARGET_OS), windows) else ifneq ($(OPENJDK_TARGET_OS), windows)
LIBSPLASHSCREEN_LDFLAGS_SUFFIX += -L$(OPENWIN_LIB)$(ISA_DIR) -lX11 -lXext $(LIBM) -lpthread LIBSPLASHSCREEN_LDFLAGS_SUFFIX += -L$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) -lX11 -lXext $(LIBM) -lpthread
else # OPENJDK_TARGET_OS else # OPENJDK_TARGET_OS
LIBSPLASHSCREEN_LDFLAGS_SUFFIX += kernel32.lib user32.lib gdi32.lib delayimp.lib /DELAYLOAD:user32.dll LIBSPLASHSCREEN_LDFLAGS_SUFFIX += kernel32.lib user32.lib gdi32.lib delayimp.lib /DELAYLOAD:user32.dll
endif # OPENJDK_TARGET_OS endif # OPENJDK_TARGET_OS
...@@ -2474,9 +2628,14 @@ $(eval $(call SetupNativeCompilation,LIBSPLASHSCREEN,\ ...@@ -2474,9 +2628,14 @@ $(eval $(call SetupNativeCompilation,LIBSPLASHSCREEN,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsplashscreen/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsplashscreen/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX_linux:=$(LIBDL), \
LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ),\ LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsplashscreen)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=splashscreen.dll" \
/D "JDK_INTERNAL_NAME=splashscreen" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsplashscreen,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(LIBSPLASHSCREEN) BUILD_LIBRARIES += $(LIBSPLASHSCREEN)
...@@ -2508,11 +2667,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBDCPR,\ ...@@ -2508,11 +2667,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBDCPR,\
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
$(LIBDCPR_CFLAGS), \ $(LIBDCPR_CFLAGS), \
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libdcpr/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libdcpr/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) $(LIBM)\ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=$(LIBM) $(LDFLAGS_JDKLIB_SUFFIX),\
LDFLAGS_SUFFIX_posix:=-lm,\ LDFLAGS_SUFFIX_posix:=-lm,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libdcpr)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=dcpr.dll" \
/D "JDK_INTERNAL_NAME=dcpr" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libdcpr,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBDCPR) : $(BUILD_LIBJAVA) $(BUILD_LIBDCPR) : $(BUILD_LIBJAVA)
...@@ -2526,20 +2691,26 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJ2PCSC,\ ...@@ -2526,20 +2691,26 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJ2PCSC,\
LIBRARY:=j2pcsc,\ LIBRARY:=j2pcsc,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/native/sun/security/smartcardio \ SRC:=$(JDK_TOPDIR)/src/share/native/sun/security/smartcardio \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/smartcardio,\ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/smartcardio,\
LANG:=C,\ LANG:=C,\
CFLAGS_posix:=-D__sun_jdk,\ CFLAGS_posix:=-D__sun_jdk,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/native/sun/security/smartcardio \ -I$(JDK_TOPDIR)/src/share/native/sun/security/smartcardio \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/smartcardio\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/smartcardio\
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/smartcardio/MUSCLE,\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/smartcardio/MUSCLE,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libj2pcsc/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libj2pcsc/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX_posix:=$(LIBDL), \ LDFLAGS_SUFFIX_posix:=$(LIBDL), \
LDFLAGS_SUFFIX_windows:=winscard.lib,\ LDFLAGS_SUFFIX_windows:=winscard.lib,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libj2pcsc)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=j2pcsc.dll" \
/D "JDK_INTERNAL_NAME=j2pcsc" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libj2pcsc,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBJ2PCSC) BUILD_LIBRARIES += $(BUILD_LIBJ2PCSC)
...@@ -2550,12 +2721,12 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJ2GSS,\ ...@@ -2550,12 +2721,12 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJ2GSS,\
LIBRARY:=j2gss,\ LIBRARY:=j2gss,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/native/sun/security/jgss/wrapper \ SRC:=$(JDK_TOPDIR)/src/share/native/sun/security/jgss/wrapper \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/jgss/wrapper,\ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/jgss/wrapper,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/native/sun/security/jgss/wrapper \ -I$(JDK_TOPDIR)/src/share/native/sun/security/jgss/wrapper \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/jgss/wrapper,\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/jgss/wrapper,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libj2gss/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libj2gss/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
...@@ -2571,7 +2742,7 @@ BUILD_LIBKRB5_NAME:= ...@@ -2571,7 +2742,7 @@ BUILD_LIBKRB5_NAME:=
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
BUILD_LIBKRB5_NAME:=w2k_lsa_auth BUILD_LIBKRB5_NAME:=w2k_lsa_auth
BUILD_LIBKRB5_FILES:=NativeCreds.c WindowsDirectory.c BUILD_LIBKRB5_FILES:=NativeCreds.c WindowsDirectory.c
BUILD_LIBKRB5_SRC:=$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/krb5 BUILD_LIBKRB5_SRC:=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/krb5
BUILD_LIBKRB5_LIBS:=Secur32.lib netapi32.lib \ BUILD_LIBKRB5_LIBS:=Secur32.lib netapi32.lib \
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib \ kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib \
advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib \ advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib \
...@@ -2593,11 +2764,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBKRB5,\ ...@@ -2593,11 +2764,17 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBKRB5,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/native/sun/security/krb5 \ -I$(JDK_TOPDIR)/src/share/native/sun/security/krb5 \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/krb5 ,\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/krb5 ,\
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(BUILD_LIBKRB5_LIBS) ,\ LDFLAGS_SUFFIX:=$(BUILD_LIBKRB5_LIBS) ,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libkrb5)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=$(BUILD_LIBKRB5_NAME).dll" \
/D "JDK_INTERNAL_NAME=$(BUILD_LIBKRB5_NAME)" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libkrb5,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBKRB5) BUILD_LIBRARIES += $(BUILD_LIBKRB5)
endif endif
...@@ -2610,46 +2787,56 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBSUNMSCAPI,\ ...@@ -2610,46 +2787,56 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBSUNMSCAPI,\
LIBRARY:=sunmscapi,\ LIBRARY:=sunmscapi,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/native/sun/security/mscapi \ SRC:=$(JDK_TOPDIR)/src/share/native/sun/security/mscapi \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/mscapi,\ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/mscapi,\
INCLUDE_FILES:=security.cpp, \ INCLUDE_FILES:=security.cpp, \
LANG:=C++,\ LANG:=C++,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/native/sun/security/mscapi \ -I$(JDK_TOPDIR)/src/share/native/sun/security/mscapi \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/mscapi ,\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/mscapi ,\
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=Crypt32.Lib advapi32.lib,\ LDFLAGS_SUFFIX:=Crypt32.Lib advapi32.lib,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsunmscapi)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=sunmscapi.dll" \
/D "JDK_INTERNAL_NAME=sunmscapi" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsunmscapi,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBSUNMSCAPI) BUILD_LIBRARIES += $(BUILD_LIBSUNMSCAPI)
endif endif
########################################################################################## ##########################################################################################
ifneq ($(OPENJDK_TARGET_OS)-$(ARCH_DATA_MODEL), windows-64)
$(eval $(call SetupNativeCompilation,BUILD_LIBJ2PKCS11,\ $(eval $(call SetupNativeCompilation,BUILD_LIBJ2PKCS11,\
LIBRARY:=j2pkcs11,\ LIBRARY:=j2pkcs11,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
SRC:=$(JDK_TOPDIR)/src/share/native/sun/security/pkcs11 \ SRC:=$(JDK_TOPDIR)/src/share/native/sun/security/pkcs11 \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/pkcs11 \ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/pkcs11 \
$(JDK_TOPDIR)/src/share/native/sun/security/pkcs11/wrapper \ $(JDK_TOPDIR)/src/share/native/sun/security/pkcs11/wrapper \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/pkcs11/wrapper,\ $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/pkcs11/wrapper,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/share/native/sun/security/pkcs11 \ -I$(JDK_TOPDIR)/src/share/native/sun/security/pkcs11 \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/pkcs11 \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/pkcs11 \
-I$(JDK_TOPDIR)/src/share/native/sun/security/pkcs11/wrapper \ -I$(JDK_TOPDIR)/src/share/native/sun/security/pkcs11/wrapper \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/security/pkcs11/wrapper,\ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/security/pkcs11/wrapper,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libj2pkcs11/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libj2pkcs11/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX_posix:=$(LIBDL), \ LDFLAGS_SUFFIX_posix:=$(LIBDL), \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libj2pkcs11)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=j2pkcs11.dll" \
/D "JDK_INTERNAL_NAME=j2pkcs11" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libj2pkcs11,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBJ2PKCS11) BUILD_LIBRARIES += $(BUILD_LIBJ2PKCS11)
endif
########################################################################################## ##########################################################################################
...@@ -2685,11 +2872,18 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBSUNEC,\ ...@@ -2685,11 +2872,18 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBSUNEC,\
CXXFLAGS:=$(filter-out $(ECC_JNI_SOLSPARC_FILTER), $(CXXFLAGS_JDKLIB)) \ CXXFLAGS:=$(filter-out $(ECC_JNI_SOLSPARC_FILTER), $(CXXFLAGS_JDKLIB)) \
$(BUILD_LIBSUNEC_FLAGS),\ $(BUILD_LIBSUNEC_FLAGS),\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsunec/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsunec/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK),\
$(call SET_SHARED_LIBRARY_ORIGIN),\ LDFLAGS_macosx:=$(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(LIBCXX),\ LDFLAGS_SUFFIX:=$(LIBCXX),\
LDFLAGS_SUFFIX_linux:=-lc ,\
LDFLAGS_SUFFIX_solaris:=-lc ,\ LDFLAGS_SUFFIX_solaris:=-lc ,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsunec)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=sunec.dll" \
/D "JDK_INTERNAL_NAME=sunec" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libsunec,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
BUILD_LIBRARIES += $(BUILD_LIBSUNEC) BUILD_LIBRARIES += $(BUILD_LIBSUNEC)
endif endif
...@@ -2698,7 +2892,7 @@ endif ...@@ -2698,7 +2892,7 @@ endif
LIBJSOUND_SRC_DIRS:=\ LIBJSOUND_SRC_DIRS:=\
$(JDK_TOPDIR)/src/share/native/com/sun/media/sound \ $(JDK_TOPDIR)/src/share/native/com/sun/media/sound \
$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/com/sun/media/sound $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/com/sun/media/sound
LIBJSOUND_SRC_FILES:=Utilities.c Platform.c LIBJSOUND_SRC_FILES:=Utilities.c Platform.c
...@@ -2781,29 +2975,29 @@ endif # OPENJDK_TARGET_OS solaris ...@@ -2781,29 +2975,29 @@ endif # OPENJDK_TARGET_OS solaris
ifeq ($(JVM_VARIANT_ZERO), true) ifeq ($(JVM_VARIANT_ZERO), true)
LIBJSOUND_CFLAGS += -DX_ARCH=X_ZERO LIBJSOUND_CFLAGS += -DX_ARCH=X_ZERO
else else
ifeq ($(ARCH), i586) ifeq ($(OPENJDK_TARGET_CPU), x86)
LIBJSOUND_CFLAGS += -DX_ARCH=X_I586 LIBJSOUND_CFLAGS += -DX_ARCH=X_I586
endif # ARCH i586 endif
ifeq ($(ARCH), sparc) ifeq ($(OPENJDK_TARGET_CPU), sparc)
LIBJSOUND_CFLAGS += -DX_ARCH=X_SPARC LIBJSOUND_CFLAGS += -DX_ARCH=X_SPARC
endif # ARCH sparc endif
ifeq ($(ARCH), sparcv9) ifeq ($(OPENJDK_TARGET_CPU), sparcv9)
LIBJSOUND_CFLAGS += -DX_ARCH=X_SPARCV9 LIBJSOUND_CFLAGS += -DX_ARCH=X_SPARCV9
endif # ARCH sparcv9 endif
ifeq ($(ARCH), amd64) ifeq ($(OPENJDK_TARGET_CPU), x86_64)
LIBJSOUND_CFLAGS += -DX_ARCH=X_AMD64 LIBJSOUND_CFLAGS += -DX_ARCH=X_AMD64
endif # ARCH amd64 endif
ifeq ($(ARCH), arm) ifeq ($(OPENJDK_TARGET_CPU), arm)
LIBJSOUND_CFLAGS += -DX_ARCH=X_ARM LIBJSOUND_CFLAGS += -DX_ARCH=X_ARM
endif # ARCH arm endif
ifeq ($(ARCH), ppc) ifeq ($(OPENJDK_TARGET_CPU), ppc)
LIBJSOUND_CFLAGS += -DX_ARCH=X_PPC LIBJSOUND_CFLAGS += -DX_ARCH=X_PPC
endif # ARCH ppc endif
endif endif
LIBJSOUND_CFLAGS += -DEXTRA_SOUND_JNI_LIBS='"$(EXTRA_SOUND_JNI_LIBS)"' LIBJSOUND_CFLAGS += -DEXTRA_SOUND_JNI_LIBS='"$(EXTRA_SOUND_JNI_LIBS)"'
...@@ -2815,18 +3009,25 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSOUND,\ ...@@ -2815,18 +3009,25 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSOUND,\
INCLUDE_FILES:=$(LIBJSOUND_SRC_FILES),\ INCLUDE_FILES:=$(LIBJSOUND_SRC_FILES),\
LANG:=$(LIBJSOUND_LANG),\ LANG:=$(LIBJSOUND_LANG),\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(CFLAGS_JDKLIB) $(LIBJSOUND_CFLAGS), \ CFLAGS:=$(CFLAGS_JDKLIB) \
$(LIBJSOUND_CFLAGS), \
CXXFLAGS:=$(CXXFLAGS_JDKLIB) $(LIBJSOUND_CFLAGS), \ CXXFLAGS:=$(CXXFLAGS_JDKLIB) $(LIBJSOUND_CFLAGS), \
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjsound/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjsound/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB)\ LDFLAGS:=$(LDFLAGS_JDKLIB)\
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_macosx:=-framework CoreAudio -framework CoreFoundation \
-framework CoreServices -framework AudioUnit $(LIBCXX) \
-framework CoreMIDI -framework AudioToolbox,\
LDFLAGS_windows:=$(WIN_JAVA_LIB) advapi32.lib winmm.lib,\ LDFLAGS_windows:=$(WIN_JAVA_LIB) advapi32.lib winmm.lib,\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\ LDFLAGS_SUFFIX:=-ljava -ljvm,\
LDFLAGS_SUFFIX_solaris:=-lc ,\ LDFLAGS_SUFFIX_solaris:=-lc ,\
LDFLAGS_SUFFIX_macosx:=-framework CoreAudio -framework CoreFoundation \ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
-framework CoreServices -framework AudioUnit $(LIBCXX) \ RC_FLAGS:=$(RC_FLAGS)\
-framework CoreMIDI -framework AudioToolbox ,\ /D "JDK_FNAME=jsound.dll" \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjsound)) /D "JDK_INTERNAL_NAME=jsound" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjsound,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBJSOUND) : $(BUILD_LIBJAVA) $(BUILD_LIBJSOUND) : $(BUILD_LIBJAVA)
...@@ -2860,7 +3061,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSOUNDALSA,\ ...@@ -2860,7 +3061,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSOUNDALSA,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjsoundalsa/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjsoundalsa/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB)\ LDFLAGS:=$(LDFLAGS_JDKLIB)\
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) -lasound,\ LDFLAGS_SUFFIX:=-lasound -ljava -ljvm,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjsoundalsa)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjsoundalsa))
$(BUILD_LIBJSOUNDALSA) : $(BUILD_LIBJAVA) $(BUILD_LIBJSOUNDALSA) : $(BUILD_LIBJAVA)
...@@ -2884,10 +3085,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSOUNDDS,\ ...@@ -2884,10 +3085,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJSOUNDDS,\
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
$(LIBJSOUND_CFLAGS) \ $(LIBJSOUND_CFLAGS) \
-DUSE_DAUDIO=TRUE, \ -DUSE_DAUDIO=TRUE, \
LDFLAGS:=$(LDFLAGS_JDKLIB)\ LDFLAGS:=$(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) dsound.lib winmm.lib user32.lib ole32.lib,\ LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) dsound.lib winmm.lib user32.lib ole32.lib,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjsoundds)) VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\
/D "JDK_FNAME=jsoundds.dll" \
/D "JDK_INTERNAL_NAME=jsoundds" \
/D "JDK_FTYPE=0x2L",\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjsoundds,\
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
$(BUILD_LIBJSOUNDDS) : $(BUILD_LIBJAVA) $(BUILD_LIBJSOUNDDS) : $(BUILD_LIBJAVA)
...@@ -2909,8 +3116,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJ2UCRYPTO,\ ...@@ -2909,8 +3116,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJ2UCRYPTO,\
CFLAGS:=$(CFLAGS_JDKLIB) \ CFLAGS:=$(CFLAGS_JDKLIB) \
-I$(JDK_TOPDIR)/src/closed/solaris/native/com/oracle/security/ucrypto ,\ -I$(JDK_TOPDIR)/src/closed/solaris/native/com/oracle/security/ucrypto ,\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libj2ucrypto/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libj2ucrypto/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB)\ LDFLAGS:=$(LDFLAGS_JDKLIB),\
$(call SET_SHARED_LIBRARY_ORIGIN), \
LDFLAGS_SUFFIX:=$(LIBDL),\ LDFLAGS_SUFFIX:=$(LIBDL),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libj2ucrypto)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libj2ucrypto))
...@@ -2944,11 +3150,11 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAPPLESCRIPTENGINE,\ ...@@ -2944,11 +3150,11 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAPPLESCRIPTENGINE,\
-F/System/Library/Frameworks/ApplicationServices.framework/Frameworks, \ -F/System/Library/Frameworks/ApplicationServices.framework/Frameworks, \
LDFLAGS:=$(LDFLAGS_JDKLIB)\ LDFLAGS:=$(LDFLAGS_JDKLIB)\
$(call SET_SHARED_LIBRARY_ORIGIN), \ $(call SET_SHARED_LIBRARY_ORIGIN), \
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) \ LDFLAGS_SUFFIX:=-framework Cocoa \
-framework Cocoa \ -framework Carbon \
-framework Carbon \ -F/System/Library/Frameworks/JavaVM.framework/Frameworks \
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \ -framework JavaNativeFoundation \
-framework JavaNativeFoundation, \ $(LDFLAGS_JDKLIB_SUFFIX),\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libAppleScriptEngine)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libAppleScriptEngine))
$(BUILD_LIBAPPLESCRIPTENGINE) : $(BUILD_LIBJAVA) $(BUILD_LIBAPPLESCRIPTENGINE) : $(BUILD_LIBJAVA)
...@@ -3161,20 +3367,19 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT_LWAWT,\ ...@@ -3161,20 +3367,19 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBAWT_LWAWT,\
-F/System/Library/Frameworks/ApplicationServices.framework/Frameworks,\ -F/System/Library/Frameworks/ApplicationServices.framework/Frameworks,\
LDFLAGS:=$(LDFLAGS_JDKLIB)\ LDFLAGS:=$(LDFLAGS_JDKLIB)\
$(call SET_SHARED_LIBRARY_ORIGIN), \ $(call SET_SHARED_LIBRARY_ORIGIN), \
LDFLAGS_SUFFIX_macosx:=\ LDFLAGS_SUFFIX_macosx:=-lawt -lmlib_image -losxapp -ljvm $(LIBM) \
-lawt -lmlib_image -losxapp $(LDFLAGS_JDKLIB_SUFFIX) $(LIBM) \ -framework Accelerate \
-framework Accelerate \ -framework ApplicationServices \
-framework ApplicationServices \ -framework AudioToolbox \
-framework AudioToolbox \ -framework Carbon \
-framework Carbon \ -framework Cocoa \
-framework Cocoa \ -framework Security \
-framework Security \ -framework ExceptionHandling \
-framework ExceptionHandling \ -F/System/Library/Frameworks/JavaVM.framework/Frameworks \
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \ -framework JavaNativeFoundation \
-framework JavaNativeFoundation \ -framework JavaRuntimeSupport \
-framework JavaRuntimeSupport \ -framework OpenGL \
-framework OpenGL \ -framework QuartzCore -ljava,\
-framework QuartzCore ,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libawt_lwawt)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libawt_lwawt))
BUILD_LIBRARIES += $(BUILD_LIBAWT_LWAWT) BUILD_LIBRARIES += $(BUILD_LIBAWT_LWAWT)
...@@ -3216,16 +3421,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBOSXUI,\ ...@@ -3216,16 +3421,16 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBOSXUI,\
-I$(JDK_TOPDIR)/src/macosx/native/sun/awt \ -I$(JDK_TOPDIR)/src/macosx/native/sun/awt \
-F/System/Library/Frameworks/JavaVM.framework/Frameworks, \ -F/System/Library/Frameworks/JavaVM.framework/Frameworks, \
LDFLAGS:=$(LDFLAGS_JDKLIB)\ LDFLAGS:=$(LDFLAGS_JDKLIB)\
$(call SET_SHARED_LIBRARY_ORIGIN), \ $(call SET_SHARED_LIBRARY_ORIGIN) \
LDFLAGS_SUFFIX_macosx:=\ -Xlinker -rpath -Xlinker @loader_path,\
$(LDFLAGS_JDKLIB_SUFFIX) \ LDFLAGS_SUFFIX_macosx:=-lawt -losxapp -lawt_lwawt \
-lawt -losxapp -lawt_lwawt \ -framework Cocoa \
-framework Cocoa \ -framework Carbon \
-framework Carbon \ -framework ApplicationServices \
-framework ApplicationServices \ -F/System/Library/Frameworks/JavaVM.framework/Frameworks \
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \ -framework JavaNativeFoundation \
-framework JavaNativeFoundation \ -framework JavaRuntimeSupport \
-framework JavaRuntimeSupport, \ -ljava -ljvm,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libosxui)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libosxui))
BUILD_LIBRARIES += $(BUILD_LIBOSXUI) BUILD_LIBRARIES += $(BUILD_LIBOSXUI)
...@@ -3244,9 +3449,33 @@ endif ...@@ -3244,9 +3449,33 @@ endif
ifeq ($(OPENJDK_TARGET_OS), macosx) ifeq ($(OPENJDK_TARGET_OS), macosx)
$(eval $(call SetupNativeCompilation,BUILD_LIBJOBJC,\ # Ugly hack to mimic behaviour in old build where this is built as an xcode project.
SET_SHARED_LIBRARY_NAME=-Xlinker -install_name -Xlinker /usr/local/lib/libJObjC.dylib
$(eval $(call SetupNativeCompilation,BUILD_LIBJOBJC32,\
LIBRARY:=JObjC,\ LIBRARY:=JObjC,\
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\ OUTPUT_DIR:=$(JDK_OUTPUTDIR)/objs/libjobjc32,\
SRC:=$(JDK_TOPDIR)/src/macosx/native/jobjc/src/core/native \
$(JDK_TOPDIR)/src/macosx/native/jobjc/src/runtime-additions/native ,\
LANG:=C,\
OPTIMIZATION:=LOW, \
CFLAGS:=-fpascal-strings \
-fobjc-gc \
-gdwarf-2 \
$(CFLAGS_JDKLIB) \
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \
-m32,\
LDFLAGS:=$(LDFLAGS_JDKLIB)\
-m32, \
LDFLAGS_SUFFIX:=-framework Foundation -framework JavaVM \
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \
-framework JavaNativeFoundation \
-lffi, \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjobjc32))
$(eval $(call SetupNativeCompilation,BUILD_LIBJOBJC64,\
LIBRARY:=JObjC,\
OUTPUT_DIR:=$(JDK_OUTPUTDIR)/objs/libjobjc64,\
SRC:=$(JDK_TOPDIR)/src/macosx/native/jobjc/src/core/native \ SRC:=$(JDK_TOPDIR)/src/macosx/native/jobjc/src/core/native \
$(JDK_TOPDIR)/src/macosx/native/jobjc/src/runtime-additions/native ,\ $(JDK_TOPDIR)/src/macosx/native/jobjc/src/runtime-additions/native ,\
LANG:=C,\ LANG:=C,\
...@@ -3266,9 +3495,12 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJOBJC,\ ...@@ -3266,9 +3495,12 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBJOBJC,\
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \ -F/System/Library/Frameworks/JavaVM.framework/Frameworks \
-framework JavaNativeFoundation \ -framework JavaNativeFoundation \
-lffi, \ -lffi, \
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjobjc)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjobjc64))
$(INSTALL_LIBRARIES_HERE)/$(LIBRARY_PREFIX)JObjC$(SHARED_LIBRARY_SUFFIX): $(BUILD_LIBJOBJC32) $(BUILD_LIBJOBJC64)
$(LIPO) -create -output $@ $(BUILD_LIBJOBJC32) $(BUILD_LIBJOBJC64)
BUILD_LIBRARIES += $(BUILD_LIBJOBJC) BUILD_LIBRARIES += $(INSTALL_LIBRARIES_HERE)/$(LIBRARY_PREFIX)JObjC$(SHARED_LIBRARY_SUFFIX)
endif endif
......
...@@ -47,12 +47,12 @@ H_TARGET_FILES =$(INCLUDEDIR)/jdwpTransport.h \ ...@@ -47,12 +47,12 @@ H_TARGET_FILES =$(INCLUDEDIR)/jdwpTransport.h \
$(INCLUDEDIR)/%.h: $(JDK_TOPDIR)/src/share/javavm/export/%.h $(INCLUDEDIR)/%.h: $(JDK_TOPDIR)/src/share/javavm/export/%.h
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(OPENJDK_TARGET_OS_INCLUDE)/%.h: $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/javavm/export/%.h $(OPENJDK_TARGET_OS_INCLUDE)/%.h: $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/javavm/export/%.h
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES = $(H_TARGET_FILES) COPY_FILES = $(H_TARGET_FILES)
...@@ -64,7 +64,7 @@ SERVICETAG_LIBDIR = $(LIBDIR)/servicetag ...@@ -64,7 +64,7 @@ SERVICETAG_LIBDIR = $(LIBDIR)/servicetag
$(SERVICETAG_LIBDIR)/jdk_header.png: $(JDK_TOPDIR)/src/share/classes/com/sun/servicetag/resources/jdk_header.png $(SERVICETAG_LIBDIR)/jdk_header.png: $(JDK_TOPDIR)/src/share/classes/com/sun/servicetag/resources/jdk_header.png
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(CHMOD) 444 $@ $(CHMOD) 444 $@
...@@ -79,20 +79,20 @@ MGMT_TARGET_FILES = $(subst $(MGMT_LIB_SRC),$(MGMT_LIBDIR),$(MGMT_SRC_FILES)) ...@@ -79,20 +79,20 @@ MGMT_TARGET_FILES = $(subst $(MGMT_LIB_SRC),$(MGMT_LIBDIR),$(MGMT_SRC_FILES))
$(MGMT_LIBDIR)/management.properties: $(MGMT_LIB_SRC)/management.properties $(MGMT_LIBDIR)/management.properties: $(MGMT_LIB_SRC)/management.properties
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(CHMOD) 644 $@ $(CHMOD) 644 $@
# this file has different permissions...don't know why... # this file has different permissions...don't know why...
$(MGMT_LIBDIR)/jmxremote.access: $(MGMT_LIB_SRC)/jmxremote.access $(MGMT_LIBDIR)/jmxremote.access: $(MGMT_LIB_SRC)/jmxremote.access
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(CHMOD) 644 $@ $(CHMOD) 644 $@
$(MGMT_LIBDIR)/%: $(MGMT_LIB_SRC)/% $(MGMT_LIBDIR)/%: $(MGMT_LIB_SRC)/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(CHMOD) 444 $@ $(CHMOD) 444 $@
...@@ -104,7 +104,7 @@ LOGGING_LIB_SRC = $(JDK_TOPDIR)/src/share/lib ...@@ -104,7 +104,7 @@ LOGGING_LIB_SRC = $(JDK_TOPDIR)/src/share/lib
$(LIBDIR)/logging.properties: $(LOGGING_LIB_SRC)/logging.properties $(LIBDIR)/logging.properties: $(LOGGING_LIB_SRC)/logging.properties
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(LIBDIR)/logging.properties COPY_FILES += $(LIBDIR)/logging.properties
...@@ -119,7 +119,7 @@ PSFONTPROPFILE_TARGET_FILES = $(subst $(PSFONTPROPFILE_SRC_DIR),$(LIBDIR),$(PSFO ...@@ -119,7 +119,7 @@ PSFONTPROPFILE_TARGET_FILES = $(subst $(PSFONTPROPFILE_SRC_DIR),$(LIBDIR),$(PSFO
$(LIBDIR)/%: $(PSFONTPROPFILE_SRC_DIR)/% $(LIBDIR)/%: $(PSFONTPROPFILE_SRC_DIR)/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(PSFONTPROPFILE_TARGET_FILES) COPY_FILES += $(PSFONTPROPFILE_TARGET_FILES)
...@@ -129,24 +129,24 @@ COPY_FILES += $(PSFONTPROPFILE_TARGET_FILES) ...@@ -129,24 +129,24 @@ COPY_FILES += $(PSFONTPROPFILE_TARGET_FILES)
# Copy flavormap.properties, cursor.properties and cursors gif files to LIBDIR # Copy flavormap.properties, cursor.properties and cursors gif files to LIBDIR
# #
ifneq ($(OPENJDK_TARGET_OS), macosx) ifneq ($(OPENJDK_TARGET_OS), macosx)
OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/lib OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib
else else
OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/macosx/lib OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/macosx/lib
endif endif
$(LIBDIR)/flavormap.properties: $(OPENJDK_TARGET_OS_LIB_SRC)/flavormap.properties $(LIBDIR)/flavormap.properties: $(OPENJDK_TARGET_OS_LIB_SRC)/flavormap.properties
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(LIBDIR)/flavormap.properties COPY_FILES += $(LIBDIR)/flavormap.properties
CURSORS_DEST_DIR = $(LIBDIR)/images/cursors CURSORS_DEST_DIR = $(LIBDIR)/images/cursors
CURSORS_OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/lib/images/cursors CURSORS_OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib/images/cursors
$(CURSORS_DEST_DIR)/cursors.properties: $(CURSORS_OPENJDK_TARGET_OS_LIB_SRC)/cursors.properties $(CURSORS_DEST_DIR)/cursors.properties: $(CURSORS_OPENJDK_TARGET_OS_LIB_SRC)/cursors.properties
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(CURSORS_DEST_DIR)/cursors.properties COPY_FILES += $(CURSORS_DEST_DIR)/cursors.properties
...@@ -161,18 +161,18 @@ CURSORS_TARGET_FILES = $(subst $(CURSORS_LIB_SRC),$(CURSORS_DEST_DIR),$(CURSORS ...@@ -161,18 +161,18 @@ CURSORS_TARGET_FILES = $(subst $(CURSORS_LIB_SRC),$(CURSORS_DEST_DIR),$(CURSORS
$(CURSORS_DEST_DIR)/%: $(CURSORS_LIB_SRC)/% $(CURSORS_DEST_DIR)/%: $(CURSORS_LIB_SRC)/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(CURSORS_TARGET_FILES) COPY_FILES += $(CURSORS_TARGET_FILES)
########################################################################################## ##########################################################################################
CONTENT_TYPES_SRC=$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/lib CONTENT_TYPES_SRC=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib
$(LIBDIR)/content-types.properties: $(CONTENT_TYPES_SRC)/content-types.properties $(LIBDIR)/content-types.properties: $(CONTENT_TYPES_SRC)/content-types.properties
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(LIBDIR)/content-types.properties COPY_FILES += $(LIBDIR)/content-types.properties
...@@ -183,7 +183,7 @@ CALENDARS_SRC := $(JDK_TOPDIR)/src/share/lib ...@@ -183,7 +183,7 @@ CALENDARS_SRC := $(JDK_TOPDIR)/src/share/lib
$(LIBDIR)/calendars.properties: $(CALENDARS_SRC)/calendars.properties $(LIBDIR)/calendars.properties: $(CALENDARS_SRC)/calendars.properties
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(LIBDIR)/calendars.properties COPY_FILES += $(LIBDIR)/calendars.properties
...@@ -192,11 +192,11 @@ COPY_FILES += $(LIBDIR)/calendars.properties ...@@ -192,11 +192,11 @@ COPY_FILES += $(LIBDIR)/calendars.properties
ifeq ($(OPENJDK_TARGET_OS),windows) ifeq ($(OPENJDK_TARGET_OS),windows)
TZMAPPINGS_SRC := $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/lib TZMAPPINGS_SRC := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib
$(LIBDIR)/tzmappings: $(TZMAPPINGS_SRC)/tzmappings $(LIBDIR)/tzmappings: $(TZMAPPINGS_SRC)/tzmappings
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(LIBDIR)/tzmappings COPY_FILES += $(LIBDIR)/tzmappings
...@@ -218,7 +218,7 @@ ICCPROFILE_TARGET_FILES:=$(subst $(ICCPROFILE_SRC_DIR),$(ICCPROFILE_DEST_DIR),$( ...@@ -218,7 +218,7 @@ ICCPROFILE_TARGET_FILES:=$(subst $(ICCPROFILE_SRC_DIR),$(ICCPROFILE_DEST_DIR),$(
$(ICCPROFILE_DEST_DIR)%.pf: $(ICCPROFILE_SRC_DIR)%.pf $(ICCPROFILE_DEST_DIR)%.pf: $(ICCPROFILE_SRC_DIR)%.pf
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(CHMOD) 444 $@ $(CHMOD) 444 $@
...@@ -248,7 +248,7 @@ ifdef OPENJDK ...@@ -248,7 +248,7 @@ ifdef OPENJDK
FREETYPE_LIB = $(JDK_OUTPUTDIR)/bin/$(call SHARED_LIBRARY,freetype) FREETYPE_LIB = $(JDK_OUTPUTDIR)/bin/$(call SHARED_LIBRARY,freetype)
else else
ifeq ($(USING_SYSTEM_FT_LIB), false) ifeq ($(USING_SYSTEM_FT_LIB), false)
FREETYPE_LIB = $(JDK_OUTPUTDIR)/lib/$(LIBARCH)/$(call SHARED_LIBRARY,freetype).6 FREETYPE_LIB = $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/$(call SHARED_LIBRARY,freetype).6
endif endif
endif endif
...@@ -269,7 +269,7 @@ ifeq ($(OPENJDK_TARGET_OS),windows) ...@@ -269,7 +269,7 @@ ifeq ($(OPENJDK_TARGET_OS),windows)
MSVCRNN_TARGET := $(JDK_OUTPUTDIR)/bin/$(notdir $(MSVCRNN_DLL)) MSVCRNN_TARGET := $(JDK_OUTPUTDIR)/bin/$(notdir $(MSVCRNN_DLL))
$(MSVCRNN_TARGET): $(MSVCRNN_DLL) $(MSVCRNN_TARGET): $(MSVCRNN_DLL)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(MSVCRNN_TARGET) COPY_FILES += $(MSVCRNN_TARGET)
...@@ -281,7 +281,7 @@ HPROF_SRC=$(JDK_TOPDIR)/src/share/demo/jvmti/hprof/jvm.hprof.txt ...@@ -281,7 +281,7 @@ HPROF_SRC=$(JDK_TOPDIR)/src/share/demo/jvmti/hprof/jvm.hprof.txt
$(LIBDIR)/jvm.hprof.txt : $(HPROF_SRC) $(LIBDIR)/jvm.hprof.txt : $(HPROF_SRC)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(LIBDIR)/jvm.hprof.txt COPY_FILES += $(LIBDIR)/jvm.hprof.txt
...@@ -292,26 +292,21 @@ COPY_FILES += $(LIBDIR)/jvm.hprof.txt ...@@ -292,26 +292,21 @@ COPY_FILES += $(LIBDIR)/jvm.hprof.txt
# How to install jvm.cfg. # How to install jvm.cfg.
# #
ifeq ($(JVM_VARIANT_ZERO), true) ifeq ($(JVM_VARIANT_ZERO), true)
JVMCFG_ARCH := zero JVMCFG_ARCH := zero
else else
JVMCFG_ARCH := $(ARCH) JVMCFG_ARCH := $(OPENJDK_TARGET_CPU_LEGACY)
endif endif
ifeq ($(OPENJDK_TARGET_OS),macosx) ifeq ($(OPENJDK_TARGET_OS),macosx)
ifeq ($(JVMCFG_ARCH),amd64)
JVMCFG_ARCH := x86_64
endif
JVMCFG_SRC := $(JDK_TOPDIR)/src/macosx/bin/$(JVMCFG_ARCH)/jvm.cfg JVMCFG_SRC := $(JDK_TOPDIR)/src/macosx/bin/$(JVMCFG_ARCH)/jvm.cfg
JVMCFG_DIR := $(JDK_OUTPUTDIR)/lib
else else
JVMCFG_SRC := $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/bin/$(JVMCFG_ARCH)/jvm.cfg JVMCFG_SRC := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin/$(JVMCFG_ARCH)/jvm.cfg
JVMCFG_DIR := $(JDK_OUTPUTDIR)/lib/$(LIBARCH)
endif endif
JVMCFG_DIR := $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)
JVMCFG := $(JVMCFG_DIR)/jvm.cfg JVMCFG := $(JVMCFG_DIR)/jvm.cfg
ifeq ($(ARCH_DATA_MODEL),32) ifeq ($(OPENJDK_TARGET_CPU_BITS),32)
# On 32 bit machines, we can have client and/or server libjvms installed. # On 32 bit machines, we can have client and/or server libjvms installed.
# Since the currently committed jvm.cfg expects clientANDserver, we need # Since the currently committed jvm.cfg expects clientANDserver, we need
# to patch the jvm.cfg when we have built only a client or only a server. # to patch the jvm.cfg when we have built only a client or only a server.
...@@ -320,7 +315,7 @@ ifeq ($(ARCH_DATA_MODEL),32) ...@@ -320,7 +315,7 @@ ifeq ($(ARCH_DATA_MODEL),32)
# Create a patched jvm.cfg to use -client by default and alias -server to -client. # Create a patched jvm.cfg to use -client by default and alias -server to -client.
$(JVMCFG): $(JVMCFG):
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $(JVMCFG) $(RM) $(JVMCFG)
$(PRINTF) "-client KNOWN\n">$(JVMCFG) $(PRINTF) "-client KNOWN\n">$(JVMCFG)
$(PRINTF) "-server IGNORE\n">>$(JVMCFG) $(PRINTF) "-server IGNORE\n">>$(JVMCFG)
$(PRINTF) "-hotspot ALIASED_TO -client\n">>$(JVMCFG) $(PRINTF) "-hotspot ALIASED_TO -client\n">>$(JVMCFG)
...@@ -334,7 +329,7 @@ ifeq ($(ARCH_DATA_MODEL),32) ...@@ -334,7 +329,7 @@ ifeq ($(ARCH_DATA_MODEL),32)
$(JVMCFG): $(JVMCFG):
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $(JVMCFG) $(RM) $(JVMCFG)
$(PRINTF) "-server KNOWN\n">$(JVMCFG) $(PRINTF) "-server KNOWN\n">$(JVMCFG)
$(PRINTF) "-client IGNORE\n">>$(JVMCFG) $(PRINTF) "-client IGNORE\n">>$(JVMCFG)
$(PRINTF) "-hotspot IGNORE\n">>$(JVMCFG) $(PRINTF) "-hotspot IGNORE\n">>$(JVMCFG)
...@@ -345,7 +340,7 @@ ifeq ($(ARCH_DATA_MODEL),32) ...@@ -345,7 +340,7 @@ ifeq ($(ARCH_DATA_MODEL),32)
# Use the default jvm.cfg for this 32 bit setup. # Use the default jvm.cfg for this 32 bit setup.
$(JVMCFG): $(JVMCFG_SRC) $(JVMCFG): $(JVMCFG_SRC)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
endif endif
endif endif
...@@ -353,7 +348,7 @@ else ...@@ -353,7 +348,7 @@ else
# Use the default jvm.cfg for this 64 bit setup. # Use the default jvm.cfg for this 64 bit setup.
$(JVMCFG): $(JVMCFG_SRC) $(JVMCFG): $(JVMCFG_SRC)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
endif endif
...@@ -378,7 +373,7 @@ endif ...@@ -378,7 +373,7 @@ endif
$(PROPS_DST): $(PROPS_SRC) $(PROPS_DST): $(PROPS_SRC)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(PROPS_DST) COPY_FILES += $(PROPS_DST)
...@@ -390,7 +385,7 @@ POLICY_DST := $(JDK_OUTPUTDIR)/lib/security/java.policy ...@@ -390,7 +385,7 @@ POLICY_DST := $(JDK_OUTPUTDIR)/lib/security/java.policy
$(POLICY_DST): $(POLICY_SRC) $(POLICY_DST): $(POLICY_SRC)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(POLICY_DST) COPY_FILES += $(POLICY_DST)
...@@ -402,7 +397,7 @@ CACERTS_DST := $(JDK_OUTPUTDIR)/lib/security/cacerts ...@@ -402,7 +397,7 @@ CACERTS_DST := $(JDK_OUTPUTDIR)/lib/security/cacerts
$(CACERTS_DST): $(CACERTS_SRC) $(CACERTS_DST): $(CACERTS_SRC)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(CACERTS_DST) COPY_FILES += $(CACERTS_DST)
...@@ -419,14 +414,14 @@ TRUSTEDLIBS_DST := $(JDK_OUTPUTDIR)/lib/security/trusted.libraries ...@@ -419,14 +414,14 @@ TRUSTEDLIBS_DST := $(JDK_OUTPUTDIR)/lib/security/trusted.libraries
$(BLACKLIST_DST): $(BLACKLIST_SRC) $(BLACKLIST_DST): $(BLACKLIST_SRC)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(BLACKLIST_DST) COPY_FILES += $(BLACKLIST_DST)
$(TRUSTEDLIBS_DST): $(TRUSTEDLIBS_SRC) $(TRUSTEDLIBS_DST): $(TRUSTEDLIBS_SRC)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(TRUSTEDLIBS_DST) COPY_FILES += $(TRUSTEDLIBS_DST)
...@@ -462,7 +457,11 @@ $(SHARED_FONTS_DST_DIR)/fonts.dir : $(JDK_TOPDIR)/src/solaris/classes/sun/awt/mo ...@@ -462,7 +457,11 @@ $(SHARED_FONTS_DST_DIR)/fonts.dir : $(JDK_TOPDIR)/src/solaris/classes/sun/awt/mo
$(RM) $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(SHARED_FONTS_DST) $(SHARED_FONTS_DST_DIR)/fonts.dir COPY_FILES += $(SHARED_FONTS_DST)
ifneq ($(OPENJDK_TARGET_OS), windows)
COPY_FILES += $(SHARED_FONTS_DST_DIR)/fonts.dir
endif
ifeq ($(OPENJDK_TARGET_OS), linux) ifeq ($(OPENJDK_TARGET_OS), linux)
...@@ -537,21 +536,21 @@ _DGALIBS_i586 = # no i586 library yet ...@@ -537,21 +536,21 @@ _DGALIBS_i586 = # no i586 library yet
_DGALIBS_amd64 = # no amd64 library yet _DGALIBS_amd64 = # no amd64 library yet
DGALIBS = $(_DGALIBS_$(ARCH):%=$(JDK_OUTPUTDIR)/lib/$(LIBARCH)/%) DGALIBS = $(_DGALIBS_$(OPENJDK_TARGET_CPU_LEGACY):%=$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/%)
$(JDK_OUTPUTDIR)/lib/$(LIBARCH)/libxinerama.so: $(JDK_TOPDIR)/src/closed/solaris/lib/$(ARCH)/libxinerama.so $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libxinerama.so: $(JDK_TOPDIR)/src/closed/solaris/lib/$(OPENJDK_TARGET_CPU_LEGACY)/libxinerama.so
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(CHMOD) 755 $@ $(CHMOD) 755 $@
$(JDK_OUTPUTDIR)/lib/$(LIBARCH)/libjdgaSUNW%.so: $(JDK_TOPDIR)/src/closed/solaris/lib/$(ARCH)/libjdgaSUNW%.so $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNW%.so: $(JDK_TOPDIR)/src/closed/solaris/lib/$(OPENJDK_TARGET_CPU_LEGACY)/libjdgaSUNW%.so
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(CHMOD) 755 $@ $(CHMOD) 755 $@
$(JDK_OUTPUTDIR)/lib/$(LIBARCH)/libjdgaSUNWafb.so: $(JDK_OUTPUTDIR)/lib/$(LIBARCH)/libjdgaSUNWffb.so $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNWafb.so: $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNWffb.so
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(LN) -s $< $@ $(LN) -s $< $@
......
...@@ -174,11 +174,11 @@ COPY_FILES += \ ...@@ -174,11 +174,11 @@ COPY_FILES += \
$(shell $(MKDIR) -p $(JDK_OUTPUTDIR)/classes/META-INF/services) $(shell $(MKDIR) -p $(JDK_OUTPUTDIR)/classes/META-INF/services)
# Find all META-INF/services/* files # Find all META-INF/services/* files
ALL_META-INF_DIRS_share:=$(shell $(FIND) $(JDK_TOPDIR)/src/share/classes -type d -a -name META-INF) ALL_META-INF_DIRS_share:=$(shell $(FIND) $(JDK_TOPDIR)/src/share/classes -type d -a -name META-INF)
ALL_META-INF_DIRS_targetapi:=$(shell $(FIND) $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes -type d -a -name META-INF) ALL_META-INF_DIRS_targetapi:=$(shell $(FIND) $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes -type d -a -name META-INF)
# Platform specific overrides shared # Platform specific overrides shared
ifneq ($(ALL_META-INF_DIRS_targetapi),) ifneq ($(ALL_META-INF_DIRS_targetapi),)
ALL_META-INF_DIRS:=$(ALL_META-INF_DIRS_targetapi) \ ALL_META-INF_DIRS:=$(ALL_META-INF_DIRS_targetapi) \
$(filter-out %$(patsubst $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes%,%,$(ALL_META-INF_DIRS_targetapi)),\ $(filter-out %$(patsubst $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes%,%,$(ALL_META-INF_DIRS_targetapi)),\
$(ALL_META-INF_DIRS_share)) $(ALL_META-INF_DIRS_share))
else else
ALL_META-INF_DIRS:=$(ALL_META-INF_DIRS_share) ALL_META-INF_DIRS:=$(ALL_META-INF_DIRS_share)
...@@ -216,9 +216,9 @@ OUT_SERVICES_FILES:=$(addprefix $(JDK_OUTPUTDIR)/classes/META-INF/services/,\ ...@@ -216,9 +216,9 @@ OUT_SERVICES_FILES:=$(addprefix $(JDK_OUTPUTDIR)/classes/META-INF/services/,\
$(shell $(PRINTF) "$(SRC_SERVICES_FILES)\n" | $(SED) -e 's|/[^ ]*/META-INF/services/||g')) $(shell $(PRINTF) "$(SRC_SERVICES_FILES)\n" | $(SED) -e 's|/[^ ]*/META-INF/services/||g'))
OUT_SERVICES_FILES_COLON:=$(addsuffix :,$(OUT_SERVICES_FILES)) OUT_SERVICES_FILES_COLON:=$(addsuffix :,$(OUT_SERVICES_FILES))
# Exception handling for print services with no META-INF directory # Exception handling for print services with no META-INF directory
SRC_SERVICES_FILES_PRINT = $(wildcard $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes/sun/print/services/*) SRC_SERVICES_FILES_PRINT = $(wildcard $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes/sun/print/services/*)
OUT_SERVICES_FILES_PRINT = $(addprefix $(JDK_OUTPUTDIR)/classes/META-INF/services/,\ OUT_SERVICES_FILES_PRINT = $(addprefix $(JDK_OUTPUTDIR)/classes/META-INF/services/,\
$(patsubst $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes/sun/print/services/%,%,\ $(patsubst $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes/sun/print/services/%,%,\
$(SRC_SERVICES_FILES_PRINT))) $(SRC_SERVICES_FILES_PRINT)))
OUT_SERVICES_FILES_PRINT_COLON = $(addsuffix :,$(OUT_SERVICES_FILES_PRINT)) OUT_SERVICES_FILES_PRINT_COLON = $(addsuffix :,$(OUT_SERVICES_FILES_PRINT))
RULES_SERVICES_PRINT = $(join $(OUT_SERVICES_FILES_PRINT_COLON),$(SRC_SERVICES_FILES_PRINT)) RULES_SERVICES_PRINT = $(join $(OUT_SERVICES_FILES_PRINT_COLON),$(SRC_SERVICES_FILES_PRINT))
...@@ -257,23 +257,10 @@ JAVAX_SOUND_SRC_FILES := \ ...@@ -257,23 +257,10 @@ JAVAX_SOUND_SRC_FILES := \
javax.sound.midi.spi.SoundbankReader \ javax.sound.midi.spi.SoundbankReader \
javax.sound.sampled.spi.AudioFileReader \ javax.sound.sampled.spi.AudioFileReader \
javax.sound.sampled.spi.AudioFileWriter \ javax.sound.sampled.spi.AudioFileWriter \
javax.sound.sampled.spi.FormatConversionProvider javax.sound.sampled.spi.FormatConversionProvider \
javax.sound.sampled.spi.MixerProvider
COPY_EXTRA += $(foreach F,$(notdir $(JAVAX_SOUND_SRC_FILES)),$(JDK_OUTPUTDIR)/classes/META-INF/services/${F})
COPY_EXTRA += $(addprefix $(JDK_OUTPUTDIR)/classes/META-INF/services/,$(JAVAX_SOUND_SRC_FILES))
ifeq ($(OPENJDK_TARGET_OS)-$(ARCH),windows-ia64)
JAVAX_SOUND_SRC_FILES += windows-ia64/javax.sound.sampled.spi.MixerProvider
COPY_EXTRA += $(JDK_OUTPUTDIR)/classes/META-INF/services/javax.sound.sampled.spi.MixerProvider
else ifeq ($(OPENJDK_TARGET_OS),windows)
JAVAX_SOUND_SRC_FILES += windows-i586/javax.sound.sampled.spi.MixerProvider
COPY_EXTRA += $(JDK_OUTPUTDIR)/classes/META-INF/services/javax.sound.sampled.spi.MixerProvider
else ifeq ($(OPENJDK_TARGET_OS)-$(ARCH),linux-i586)
JAVAX_SOUND_SRC_FILES += linux-i586/javax.sound.sampled.spi.MixerProvider
COPY_EXTRA += $(JDK_OUTPUTDIR)/classes/META-INF/services/javax.sound.sampled.spi.MixerProvider
else
JAVAX_SOUND_SRC_FILES += javax.sound.sampled.spi.MixerProvider
COPY_EXTRA += $(JDK_OUTPUTDIR)/classes/META-INF/services/javax.sound.sampled.spi.MixerProvider
endif
JAVAX_SOUND_RULES := $(foreach F,$(JAVAX_SOUND_SRC_FILES),$(JDK_OUTPUTDIR)/classes/META-INF/services/$(notdir $F):$(JAVAX_SOUND_SRC)/$F) JAVAX_SOUND_RULES := $(foreach F,$(JAVAX_SOUND_SRC_FILES),$(JDK_OUTPUTDIR)/classes/META-INF/services/$(notdir $F):$(JAVAX_SOUND_SRC)/$F)
......
...@@ -54,17 +54,17 @@ endif ...@@ -54,17 +54,17 @@ endif
$(SAMPLE_TARGET_DIR)/dtrace/%: $(SAMPLE_SOLARIS_SOURCE_DIR)/dtrace/% $(SAMPLE_TARGET_DIR)/dtrace/%: $(SAMPLE_SOLARIS_SOURCE_DIR)/dtrace/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(SAMPLE_TARGET_DIR)/webservices/%: $(SAMPLE_CLOSED_SOURCE_DIR)/webservices/% $(SAMPLE_TARGET_DIR)/webservices/%: $(SAMPLE_CLOSED_SOURCE_DIR)/webservices/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
$(SAMPLE_TARGET_DIR)/%: $(SAMPLE_SOURCE_DIR)/% $(SAMPLE_TARGET_DIR)/%: $(SAMPLE_SOURCE_DIR)/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
COPY_FILES += $(SAMPLE_TARGET) COPY_FILES += $(SAMPLE_TARGET)
......
...@@ -151,10 +151,12 @@ RT_JAR_EXCLUDES := \ ...@@ -151,10 +151,12 @@ RT_JAR_EXCLUDES := \
sun/security/ec/ECDSASignature\$$$$SHA384.class \ sun/security/ec/ECDSASignature\$$$$SHA384.class \
sun/security/ec/ECDSASignature\$$$$SHA512.class \ sun/security/ec/ECDSASignature\$$$$SHA512.class \
sun/security/ec/ECDSASignature.class \ sun/security/ec/ECDSASignature.class \
sun/security/ec/ECKeyFactory.class \
sun/security/ec/ECKeyPairGenerator.class \ sun/security/ec/ECKeyPairGenerator.class \
sun/security/ec/SunEC\$$$$1.class \ sun/security/ec/SunEC\$$$$1.class \
sun/security/ec/SunEC.class \ sun/security/ec/SunEC.class \
sun/security/ec/SunECEntries.class \ sun/security/ec/SunECEntries.class \
sun/security/mscapi \
sun/security/pkcs11 \ sun/security/pkcs11 \
com/sun/net/ssl/internal/ssl \ com/sun/net/ssl/internal/ssl \
javax/crypto \ javax/crypto \
...@@ -260,50 +262,64 @@ endif ...@@ -260,50 +262,64 @@ endif
# Find all files in the classes dir to use as dependencies. This could be more fine granular. # Find all files in the classes dir to use as dependencies. This could be more fine granular.
ALL_FILES_IN_CLASSES := $(shell $(FIND) $(JDK_OUTPUTDIR)/classes -type f \ ALL_FILES_IN_CLASSES := $(shell $(FIND) $(JDK_OUTPUTDIR)/classes -type f \
| $(GREP) -v -e '/_the\.*' -e '^_the\.*') | $(GREP) -v -e '/_the\.*' -e '^_the\.*' -e 'javac_state')
RT_JAR_MANIFEST_FILE := $(JDK_OUTPUTDIR)/lib/_the.rt.jar_manifest RT_JAR_MANIFEST_FILE := $(JDK_OUTPUTDIR)/lib/_the.rt.jar_manifest
RESOURCE_JAR_MANIFEST_FILE := $(JDK_OUTPUTDIR)/lib/_the.resources.jar_manifest RESOURCE_JAR_MANIFEST_FILE := $(JDK_OUTPUTDIR)/lib/_the.resources.jar_manifest
$(RT_JAR_MANIFEST_FILE): $(MAINMANIFEST) $(BEANMANIFEST) $(RT_JAR_MANIFEST_FILE): $(MAINMANIFEST) $(BEANMANIFEST)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$(SED) -e "s#@@RELEASE@@#$(RELEASE)#" \ $(SED) -e "s#@@RELEASE@@#$(RELEASE)#" \
-e "s#@@COMPANY_NAME@@#$(COMPANY_NAME)#" \ -e "s#@@COMPANY_NAME@@#$(COMPANY_NAME)#" \
$(MAINMANIFEST) >> $@ $(MAINMANIFEST) >> $@.tmp
$(ECHO) >> $@ $(ECHO) >> $@.tmp
$(CAT) $(BEANMANIFEST) >> $@ $(CAT) $(BEANMANIFEST) >> $@.tmp
$(MV) $@.tmp $@
$(RESOURCE_JAR_MANIFEST_FILE): $(MAINMANIFEST) $(RESOURCE_JAR_MANIFEST_FILE): $(MAINMANIFEST)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$(SED) -e "s#@@RELEASE@@#$(RELEASE)#" \ $(SED) -e "s#@@RELEASE@@#$(RELEASE)#" \
-e "s#@@COMPANY_NAME@@#$(COMPANY_NAME)#" \ -e "s#@@COMPANY_NAME@@#$(COMPANY_NAME)#" \
$(MAINMANIFEST) >> $@ $(MAINMANIFEST) >> $@.tmp
$(MV) $@.tmp $@
$(JDK_OUTPUTDIR)/lib/_the.jars.exclude: $(MAKEFILE) $(JDK_OUTPUTDIR)/lib/_the.jars.exclude: $(MAKEFILE)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(call ListPathsSafely,RT_JAR_EXCLUDES,\n, >> $@) $(RM) $@ $@.tmp
$(call ListPathsSafely,RT_JAR_EXCLUDES,\n, >> $@.tmp)
$(MV) $@.tmp $@
$(JDK_OUTPUTDIR)/lib/classlist : $(JDK_TOPDIR)/make/tools/sharing/classlist.$(OPENJDK_TARGET_OS) \ $(JDK_OUTPUTDIR)/lib/classlist : $(JDK_TOPDIR)/make/tools/sharing/classlist.$(OPENJDK_TARGET_OS) \
$(MAKEFILE) $(MAKEFILE)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) -f $@.temp $(RM) $@ $@.tmp
$(TOOL_ADDJSUM) $< $@.temp $(TOOL_ADDJSUM) $< $@.tmp
$(MV) $@.temp $@ $(MV) $@.tmp $@
$(JDK_OUTPUTDIR)/lib/_the.jars.contents: $(BUILD_TOOLS) $(JDK_OUTPUTDIR)/lib/_the.jars.exclude \ $(JDK_OUTPUTDIR)/lib/_the.jars.contents: $(BUILD_TOOLS) $(JDK_OUTPUTDIR)/lib/_the.jars.exclude \
$(ALL_FILES_IN_CLASSES) $(JDK_OUTPUTDIR)/lib/classlist $(ALL_FILES_IN_CLASSES) $(JDK_OUTPUTDIR)/lib/classlist
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@.temp $(RM) $@ $@.tmp
($(CD) $(JDK_OUTPUTDIR)/classes && \ ($(CD) $(JDK_OUTPUTDIR)/classes && \
$(TOOL_JARREORDER) \ $(TOOL_JARREORDER) \
-o $@.temp $(JDK_OUTPUTDIR)/lib/classlist $(JDK_OUTPUTDIR)/lib/_the.jars.exclude . ) -o $@.tmp $(JDK_OUTPUTDIR)/lib/classlist $(JDK_OUTPUTDIR)/lib/_the.jars.exclude . )
$(MV) $@.temp $@ $(MV) $@.tmp $@
$(JDK_OUTPUTDIR)/lib/_the.rt.jar.contents: $(JDK_OUTPUTDIR)/lib/_the.jars.contents $(JDK_OUTPUTDIR)/lib/_the.rt.jar.contents: $(JDK_OUTPUTDIR)/lib/_the.jars.contents
$(GREP) -e '\.class$$' $(JDK_OUTPUTDIR)/lib/_the.jars.contents > $@ $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$(GREP) -e '\.class$$' $(JDK_OUTPUTDIR)/lib/_the.jars.contents > $@.tmp
$(MV) $@.tmp $@
$(JDK_OUTPUTDIR)/lib/_the.resources.jar.contents: $(JDK_OUTPUTDIR)/lib/_the.jars.contents $(JDK_OUTPUTDIR)/lib/_the.resources.jar.contents: $(JDK_OUTPUTDIR)/lib/_the.jars.contents
$(GREP) -v -e '\.class$$' -e '/_the\.*' -e '^_the\.*' $(JDK_OUTPUTDIR)/lib/_the.jars.contents > $@ $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$(GREP) -v -e '\.class$$' \
-e '/_the\.*' -e '^_the\.*' -e '\\_the\.*' -e 'javac_state' \
$(JDK_OUTPUTDIR)/lib/_the.jars.contents > $@.tmp
$(MV) $@.tmp $@
RT_JAR_CREATE_OPTIONS := c0fm RT_JAR_CREATE_OPTIONS := c0fm
ifeq ($(COMPRESS_JARS), true) ifeq ($(COMPRESS_JARS), true)
...@@ -312,16 +328,22 @@ endif ...@@ -312,16 +328,22 @@ endif
$(JDK_OUTPUTDIR)/lib/rt.jar: $(JDK_OUTPUTDIR)/lib/_the.rt.jar.contents $(RT_JAR_MANIFEST_FILE) $(JDK_OUTPUTDIR)/lib/rt.jar: $(JDK_OUTPUTDIR)/lib/_the.rt.jar.contents $(RT_JAR_MANIFEST_FILE)
$(ECHO) Creating rt.jar $(ECHO) Creating rt.jar
$(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$(CD) $(JDK_OUTPUTDIR)/classes && \ $(CD) $(JDK_OUTPUTDIR)/classes && \
$(JAR) $(RT_JAR_CREATE_OPTIONS) $@ $(RT_JAR_MANIFEST_FILE) \ $(JAR) $(RT_JAR_CREATE_OPTIONS) $@.tmp $(RT_JAR_MANIFEST_FILE) \
@$(JDK_OUTPUTDIR)/lib/_the.rt.jar.contents @$(JDK_OUTPUTDIR)/lib/_the.rt.jar.contents
$(MV) $@.tmp $@
$(JDK_OUTPUTDIR)/lib/resources.jar: $(JDK_OUTPUTDIR)/lib/_the.resources.jar.contents \ $(JDK_OUTPUTDIR)/lib/resources.jar: $(JDK_OUTPUTDIR)/lib/_the.resources.jar.contents \
$(RESOURCE_JAR_MANIFEST_FILE) $(RESOURCE_JAR_MANIFEST_FILE)
$(ECHO) Creating resources.jar $(ECHO) Creating resources.jar
$(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$(CD) $(JDK_OUTPUTDIR)/classes && \ $(CD) $(JDK_OUTPUTDIR)/classes && \
$(JAR) $(RT_JAR_CREATE_OPTIONS) $@ $(RESOURCE_JAR_MANIFEST_FILE) \ $(JAR) $(RT_JAR_CREATE_OPTIONS) $@.tmp $(RESOURCE_JAR_MANIFEST_FILE) \
@$(JDK_OUTPUTDIR)/lib/_the.resources.jar.contents @$(JDK_OUTPUTDIR)/lib/_the.resources.jar.contents
$(MV) $@.tmp $@
JARS+=$(JDK_OUTPUTDIR)/lib/rt.jar $(JDK_OUTPUTDIR)/lib/resources.jar JARS+=$(JDK_OUTPUTDIR)/lib/rt.jar $(JDK_OUTPUTDIR)/lib/resources.jar
...@@ -385,32 +407,31 @@ JARS+=$(JDK_OUTPUTDIR)/lib/jsse.jar ...@@ -385,32 +407,31 @@ JARS+=$(JDK_OUTPUTDIR)/lib/jsse.jar
########################################################################################## ##########################################################################################
ifneq ($(OPENJDK_TARGET_OS)-$(ARCH_DATA_MODEL),windows-64) SUNPKCS11_JAR_DST := $(JDK_OUTPUTDIR)/lib/ext/sunpkcs11.jar
SUNPKCS11_JAR_DST := $(JDK_OUTPUTDIR)/lib/ext/sunpkcs11.jar
ifndef OPENJDK ifndef OPENJDK
SUNPKCS11_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/pkcs11/sunpkcs11.jar
$(SUNPKCS11_JAR_DST) : $(SUNPKCS11_JAR_SRC) SUNPKCS11_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/pkcs11/sunpkcs11.jar
@$(ECHO) "\n>>>Installing prebuilt SunPKCS11 provider..."
$(RM) $@
$(CP) $< $@
else $(SUNPKCS11_JAR_DST) : $(SUNPKCS11_JAR_SRC)
@$(ECHO) "\n>>>Installing prebuilt SunPKCS11 provider..."
$(MKDIR) -p $(@D)
$(RM) $@
$(CP) $< $@
$(eval $(call SetupArchive,BUILD_SUNPKCS11_JAR,$(SUNPKCS11_JAR_DEPS),\ else
SRCS:=$(JDK_OUTPUTDIR)/classes, \
SUFFIXES:=.class,\
INCLUDES:=sun/security/pkcs11,\
JAR:=$(SUNPKCS11_JAR_DST), \
SKIP_METAINF := true))
endif $(eval $(call SetupArchive,BUILD_SUNPKCS11_JAR,$(SUNPKCS11_JAR_DEPS),\
SRCS:=$(JDK_OUTPUTDIR)/classes, \
SUFFIXES:=.class,\
INCLUDES:=sun/security/pkcs11,\
JAR:=$(SUNPKCS11_JAR_DST), \
SKIP_METAINF := true))
JARS += $(SUNPKCS11_JAR_DST)
endif endif
JARS += $(SUNPKCS11_JAR_DST)
########################################################################################## ##########################################################################################
SUNEC_JAR_DST := $(JDK_OUTPUTDIR)/lib/ext/sunec.jar SUNEC_JAR_DST := $(JDK_OUTPUTDIR)/lib/ext/sunec.jar
...@@ -421,6 +442,7 @@ SUNEC_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/ec/sunec.jar ...@@ -421,6 +442,7 @@ SUNEC_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/ec/sunec.jar
$(SUNEC_JAR_DST) : $(SUNEC_JAR_SRC) $(SUNEC_JAR_DST) : $(SUNEC_JAR_SRC)
@$(ECHO) "\n>>>Installing prebuilt SunEC provider..." @$(ECHO) "\n>>>Installing prebuilt SunEC provider..."
$(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
...@@ -430,12 +452,6 @@ $(eval $(call SetupArchive,BUILD_SUNEC_JAR,,\ ...@@ -430,12 +452,6 @@ $(eval $(call SetupArchive,BUILD_SUNEC_JAR,,\
SRCS:=$(JDK_OUTPUTDIR)/classes, \ SRCS:=$(JDK_OUTPUTDIR)/classes, \
SUFFIXES:=.class,\ SUFFIXES:=.class,\
INCLUDES:=sun/security/ec,\ INCLUDES:=sun/security/ec,\
EXCLUDE_FILES := sun/security/ec/ECKeyFactory.class \
sun/security/ec/ECParameters.class \
sun/security/ec/ECPrivateKeyImpl.class \
sun/security/ec/ECPublicKeyImpl.class \
sun/security/ec/NamedCurve.class \
sun/security/ec/ECKeyFactory*,\
JAR:=$(SUNEC_JAR_DST), \ JAR:=$(SUNEC_JAR_DST), \
SKIP_METAINF := true)) SKIP_METAINF := true))
...@@ -465,6 +481,7 @@ ifndef OPENJDK ...@@ -465,6 +481,7 @@ ifndef OPENJDK
$(SUNJCE_PROVIDER_JAR_DST) : $(SUNJCE_PROVIDER_JAR_SRC) $(SUNJCE_PROVIDER_JAR_DST) : $(SUNJCE_PROVIDER_JAR_SRC)
@$(ECHO) "\n>>>Installing prebuilt SunJCE provider..." @$(ECHO) "\n>>>Installing prebuilt SunJCE provider..."
$(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
else else
...@@ -489,6 +506,7 @@ JCE_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/jce/jce.jar ...@@ -489,6 +506,7 @@ JCE_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/jce/jce.jar
$(JCE_JAR_DST) : $(JCE_JAR_SRC) $(JCE_JAR_DST) : $(JCE_JAR_SRC)
@$(ECHO) "\n>>>Installing prebuilt jce.jar..." @$(ECHO) "\n>>>Installing prebuilt jce.jar..."
$(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
...@@ -520,6 +538,7 @@ US_EXPORT_POLICY_JAR_TMP := $(JDK_OUTPUTDIR)/US_export_policy_jar.tmp ...@@ -520,6 +538,7 @@ US_EXPORT_POLICY_JAR_TMP := $(JDK_OUTPUTDIR)/US_export_policy_jar.tmp
$(US_EXPORT_POLICY_JAR_TMP)/% : $(US_EXPORT_POLICY_JAR_SRC_DIR)/% $(US_EXPORT_POLICY_JAR_TMP)/% : $(US_EXPORT_POLICY_JAR_SRC_DIR)/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(CP) $< $@ $(CP) $< $@
US_EXPORT_POLICY_JAR_DEPS := $(US_EXPORT_POLICY_JAR_TMP)/default_US_export.policy US_EXPORT_POLICY_JAR_DEPS := $(US_EXPORT_POLICY_JAR_TMP)/default_US_export.policy
...@@ -552,6 +571,7 @@ LOCAL_POLICY_JAR_DEPS := $(LOCAL_POLICY_JAR_TMP)/exempt_local.policy $(LOCAL_POL ...@@ -552,6 +571,7 @@ LOCAL_POLICY_JAR_DEPS := $(LOCAL_POLICY_JAR_TMP)/exempt_local.policy $(LOCAL_POL
$(LOCAL_POLICY_JAR_TMP)/% : $(LOCAL_POLICY_JAR_SRC_DIR)/% $(LOCAL_POLICY_JAR_TMP)/% : $(LOCAL_POLICY_JAR_SRC_DIR)/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(CP) $< $@ $(CP) $< $@
$(eval $(call SetupArchive,BUILD_LOCAL_POLICY_JAR,$(LOCAL_POLICY_JAR_DEPS),\ $(eval $(call SetupArchive,BUILD_LOCAL_POLICY_JAR,$(LOCAL_POLICY_JAR_DEPS),\
...@@ -576,6 +596,7 @@ SUNMSCAPI_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/mscapi/sunmscapi.jar ...@@ -576,6 +596,7 @@ SUNMSCAPI_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/mscapi/sunmscapi.jar
$(SUNMSCAPI_JAR_DST) : $(SUNMSCAPI_JAR_SRC) $(SUNMSCAPI_JAR_DST) : $(SUNMSCAPI_JAR_SRC)
@$(ECHO) "\n>>>Installing prebuilt SunMSCAPI provider..." @$(ECHO) "\n>>>Installing prebuilt SunMSCAPI provider..."
$(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
...@@ -586,9 +607,9 @@ $(eval $(call SetupArchive,BUILD_SUNMSCAPI_JAR,$(SUNMSCAPI_JAR_DEPS),\ ...@@ -586,9 +607,9 @@ $(eval $(call SetupArchive,BUILD_SUNMSCAPI_JAR,$(SUNMSCAPI_JAR_DEPS),\
SUFFIXES:=.class,\ SUFFIXES:=.class,\
INCLUDES:= sun/security/mscapi,\ INCLUDES:= sun/security/mscapi,\
JAR:=$(SUNMSCAPI_JAR_DST), \ JAR:=$(SUNMSCAPI_JAR_DST), \
MANIFEST := $(JDK_TOPDIR)/make/tools/manifest.mf, \ MANIFEST:=$(JDK_TOPDIR)/make/tools/manifest.mf, \
EXTRA_MANIFEST_ATTR := Extension-Name: javax.crypto\nImplementation-Vendor-Id: com.sun, \ EXTRA_MANIFEST_ATTR:=Extension-Name: javax.crypto\nImplementation-Vendor-Id: com.sun, \
SKIP_METAINF := true)) SKIP_METAINF:=true))
endif endif
JARS += $(SUNMSCAPI_JAR_DST) JARS += $(SUNMSCAPI_JAR_DST)
...@@ -605,6 +626,7 @@ UCRYPTO_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/ucrypto/ucrypto.jar ...@@ -605,6 +626,7 @@ UCRYPTO_JAR_SRC := $(JDK_TOPDIR)/make/closed/tools/crypto/ucrypto/ucrypto.jar
$(UCRYPTO_JAR_DST) : $(UCRYPTO_JAR_SRC) $(UCRYPTO_JAR_DST) : $(UCRYPTO_JAR_SRC)
@$(ECHO) "\n>>>Installing prebuilt OracleUcrypto provider..." @$(ECHO) "\n>>>Installing prebuilt OracleUcrypto provider..."
$(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(CP) $< $@ $(CP) $< $@
...@@ -711,8 +733,8 @@ JARS+=$(JDK_OUTPUTDIR)/lib/tools.jar ...@@ -711,8 +733,8 @@ JARS+=$(JDK_OUTPUTDIR)/lib/tools.jar
########################################################################################## ##########################################################################################
include $(JDK_TOPDIR)/makefiles/docs/CORE_PKGS.gmk include javadoc/CORE_PKGS.gmk
include $(JDK_TOPDIR)/makefiles/docs/NON_CORE_PKGS.gmk include javadoc/NON_CORE_PKGS.gmk
# The compiler should not issue a "Proprietary" warning when compiling # The compiler should not issue a "Proprietary" warning when compiling
# classes in the com.sun.java.swing.plaf packages, since we've always # classes in the com.sun.java.swing.plaf packages, since we've always
...@@ -740,7 +762,7 @@ EXPORTED_PRIVATE_PKGS = com.sun.servicetag \ ...@@ -740,7 +762,7 @@ EXPORTED_PRIVATE_PKGS = com.sun.servicetag \
com.oracle.nio com.oracle.nio
$(IMAGES_OUTPUTDIR)/symbols/_the.symbols: $(JDK_OUTPUTDIR)/lib/rt.jar $(IMAGES_OUTPUTDIR)/symbols/_the.symbols: $(JDK_OUTPUTDIR)/lib/rt.jar
$(RM) -rf $(IMAGES_OUTPUTDIR)/symbols/META-INF/sym $(RM) -r $(IMAGES_OUTPUTDIR)/symbols/META-INF/sym
$(MKDIR) -p $(IMAGES_OUTPUTDIR)/symbols/META-INF/sym $(MKDIR) -p $(IMAGES_OUTPUTDIR)/symbols/META-INF/sym
$(JAVA) \ $(JAVA) \
-Xbootclasspath/a:$(JDK_OUTPUTDIR)/classes \ -Xbootclasspath/a:$(JDK_OUTPUTDIR)/classes \
...@@ -808,9 +830,10 @@ SRC_ZIP_INCLUDES = \ ...@@ -808,9 +830,10 @@ SRC_ZIP_INCLUDES = \
org/ietf \ org/ietf \
org/omg \ org/omg \
org/w3c/dom \ org/w3c/dom \
org/xml/sax org/xml/sax \
sunw
SRC_ZIP_SRCS = $(JDK_TOPDIR)/src/share/classes $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes SRC_ZIP_SRCS = $(JDK_TOPDIR)/src/share/classes $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes
SRC_ZIP_SRCS += $(JDK_OUTPUTDIR)/gensrc SRC_ZIP_SRCS += $(JDK_OUTPUTDIR)/gensrc
SRC_ZIP_SRCS += $(JDK_OUTPUTDIR)/impsrc SRC_ZIP_SRCS += $(JDK_OUTPUTDIR)/impsrc
SRC_ZIP_SRCS += $(JDK_OUTPUTDIR)/gendocsrc_rmic SRC_ZIP_SRCS += $(JDK_OUTPUTDIR)/gendocsrc_rmic
...@@ -821,17 +844,19 @@ endif ...@@ -821,17 +844,19 @@ endif
# Need to copy launcher src files into desired directory structure # Need to copy launcher src files into desired directory structure
# before zipping the sources. # before zipping the sources.
LAUNCHER_SRC_FILES := $(wildcard $(JDK_TOPDIR)/src/share/bin/*) \ LAUNCHER_SRC_FILES := $(wildcard $(JDK_TOPDIR)/src/share/bin/*) \
$(wildcard $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/bin/java_md*) $(wildcard $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin/java_md*)
LAUNCHER_ZIP_SRC := $(patsubst $(JDK_TOPDIR)/src/share/bin/%,$(IMAGES_OUTPUTDIR)/src/launcher/%,\ LAUNCHER_ZIP_SRC := $(patsubst $(JDK_TOPDIR)/src/share/bin/%,$(IMAGES_OUTPUTDIR)/src/launcher/%,\
$(patsubst $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/bin/%,$(IMAGES_OUTPUTDIR)/src/launcher/%,\ $(patsubst $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin/%,$(IMAGES_OUTPUTDIR)/src/launcher/%,\
$(LAUNCHER_SRC_FILES))) $(LAUNCHER_SRC_FILES)))
$(IMAGES_OUTPUTDIR)/src/launcher/%: $(JDK_TOPDIR)/src/share/bin/% $(IMAGES_OUTPUTDIR)/src/launcher/%: $(JDK_TOPDIR)/src/share/bin/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(CP) $< $@ $(CP) $< $@
$(IMAGES_OUTPUTDIR)/src/launcher/%: $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/bin/% $(IMAGES_OUTPUTDIR)/src/launcher/%: $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin/%
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(CP) $< $@ $(CP) $< $@
$(IMAGES_OUTPUTDIR)/src.zip: $(LAUNCHER_ZIP_SRC) $(IMAGES_OUTPUTDIR)/src.zip: $(LAUNCHER_ZIP_SRC)
...@@ -849,6 +874,10 @@ JARS+=$(IMAGES_OUTPUTDIR)/src.zip ...@@ -849,6 +874,10 @@ JARS+=$(IMAGES_OUTPUTDIR)/src.zip
########################################################################################## ##########################################################################################
-include $(CUSTOM_MAKE_DIR)/CreateJars.gmk
##########################################################################################
all: $(JARS) all: $(JARS)
.PHONY: default all .PHONY: default all
...@@ -48,10 +48,12 @@ BREAK_ITERATOR_CLASSES = $(BREAK_ITERATOR_DIR)/classes ...@@ -48,10 +48,12 @@ BREAK_ITERATOR_CLASSES = $(BREAK_ITERATOR_DIR)/classes
# two files in that directory and not get anything implicit from # two files in that directory and not get anything implicit from
# surrounding directories which aren't jdk 6 compatible. # surrounding directories which aren't jdk 6 compatible.
# Because we are targeting jdk 6, but the surrounding source code is jdk 7. Ugh. # Because we are targeting jdk 6, but the surrounding source code is jdk 7. Ugh.
# These two files should be moved out to a build tool! # These two files should be moved out to a build tool! We have to disable
# sjavac here as well.
$(eval $(call SetupJavaCompilation,BUILD_BREAKITERATOR,\ $(eval $(call SetupJavaCompilation,BUILD_BREAKITERATOR,\
SETUP:=GENERATE_OLDBYTECODE,\ SETUP:=GENERATE_OLDBYTECODE,\
SRC:=$(TEXT_SRCDIR),\ SRC:=$(TEXT_SRCDIR),\
DISABLE_SJAVAC:=true,\
JAVAC_SOURCE_PATH_UGLY_OVERRIDE:=$(TEXT_SRCDIR)/$(TEXT_PKG),\ JAVAC_SOURCE_PATH_UGLY_OVERRIDE:=$(TEXT_SRCDIR)/$(TEXT_PKG),\
INCLUDES:=$(TEXT_PKG),\ INCLUDES:=$(TEXT_PKG),\
INCLUDE_FILES:=$(TEXT_SOURCES),\ INCLUDE_FILES:=$(TEXT_SOURCES),\
...@@ -70,23 +72,23 @@ BIFILES = $(DATA_PKG_DIR)/CharacterBreakIteratorData \ ...@@ -70,23 +72,23 @@ BIFILES = $(DATA_PKG_DIR)/CharacterBreakIteratorData \
BIFILES_TH = $(DATA_PKG_DIR)/th/WordBreakIteratorData_th \ BIFILES_TH = $(DATA_PKG_DIR)/th/WordBreakIteratorData_th \
$(DATA_PKG_DIR)/th/LineBreakIteratorData_th $(DATA_PKG_DIR)/th/LineBreakIteratorData_th
$(BIFILES): $(BREAK_ITERATOR_DIR)/_the.bifiles $(BIFILES): $(DATA_PKG_DIR)/_the.bifiles
$(BREAK_ITERATOR_DIR)/_the.bifiles: JAVA_FLAGS += -Xbootclasspath/p:$(BREAK_ITERATOR_CLASSES) $(DATA_PKG_DIR)/_the.bifiles: JAVA_FLAGS += -Xbootclasspath/p:$(BREAK_ITERATOR_CLASSES)
$(BREAK_ITERATOR_DIR)/_the.bifiles: $(BUILD_TOOLS) $(UNICODEDATA) $(BUILD_BREAKITERATOR) $(DATA_PKG_DIR)/_the.bifiles: $(BUILD_TOOLS) $(UNICODEDATA) $(BUILD_BREAKITERATOR)
$(ECHO) "Generating BreakIteratorData" $(ECHO) "Generating BreakIteratorData"
$(MKDIR) -p $(DATA_PKG_DIR) $(MKDIR) -p $(DATA_PKG_DIR)
$(RM) -f $(BIFILES) $(RM) $(BIFILES)
$(TOOL_GENERATEBREAKITERATORDATA) \ $(TOOL_GENERATEBREAKITERATORDATA) \
-o $(DATA_PKG_DIR) \ -o $(DATA_PKG_DIR) \
-spec $(UNICODEDATA) -spec $(UNICODEDATA)
$(TOUCH) $@ $(TOUCH) $@
$(BIFILES_TH): $(BREAK_ITERATOR_DIR)/_the.bifiles_th $(BIFILES_TH): $(DATA_PKG_DIR)/_the.bifiles_th
$(BREAK_ITERATOR_DIR)/_the.bifiles_th: JAVA_FLAGS += -Xbootclasspath/p:$(BREAK_ITERATOR_CLASSES) $(DATA_PKG_DIR)/_the.bifiles_th: JAVA_FLAGS += -Xbootclasspath/p:$(BREAK_ITERATOR_CLASSES)
$(BREAK_ITERATOR_DIR)/_the.bifiles_th: $(BUILD_TOOLS) $(UNICODEDATA) $(BUILD_BREAKITERATOR) $(DATA_PKG_DIR)/_the.bifiles_th: $(BUILD_TOOLS) $(UNICODEDATA) $(BUILD_BREAKITERATOR)
$(ECHO) "Generating BreakIteratorData_th" $(ECHO) "Generating BreakIteratorData_th"
$(MKDIR) -p $(DATA_PKG_DIR)/th $(MKDIR) -p $(DATA_PKG_DIR)/th
$(RM) -f $(BIFILES_TH) $(RM) $(BIFILES_TH)
$(TOOL_GENERATEBREAKITERATORDATA) \ $(TOOL_GENERATEBREAKITERATORDATA) \
-o $(DATA_PKG_DIR) \ -o $(DATA_PKG_DIR) \
-spec $(UNICODEDATA) \ -spec $(UNICODEDATA) \
......
...@@ -26,53 +26,61 @@ ...@@ -26,53 +26,61 @@
GENDATA_FONT_CONFIG_DST := $(JDK_OUTPUTDIR)/lib GENDATA_FONT_CONFIG_DST := $(JDK_OUTPUTDIR)/lib
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
GENDATA_FONT_CONFIG_SRC_DIR := $(JDK_TOPDIR)/src/windows/classes/sun/awt/windows GENDATA_FONT_CONFIG_SRC_DIR := $(JDK_TOPDIR)/src/windows/classes/sun/awt/windows
GENDATA_FONT_CONFIG_SRC_FILES := fontconfig.properties GENDATA_FONT_CONFIG_SRC_FILES := fontconfig.properties
GENDATA_FONT_CONFIG_SRC_PREFIX := GENDATA_FONT_CONFIG_SRC_PREFIX :=
endif endif
ifeq ($(OPENJDK_TARGET_OS), linux) ifeq ($(OPENJDK_TARGET_OS), linux)
GENDATA_FONT_CONFIG_SRC_PREFIX := linux. GENDATA_FONT_CONFIG_SRC_PREFIX := linux.
ifdef OPENJDK ifdef OPENJDK
GENDATA_FONT_CONFIG_SRC_DIR := $(JDK_TOPDIR)/src/solaris/classes/sun/awt/fontconfigs GENDATA_FONT_CONFIG_SRC_DIR := \
GENDATA_FONT_CONFIG_SRC_FILES := \ $(JDK_TOPDIR)/src/solaris/classes/sun/awt/fontconfigs
GENDATA_FONT_CONFIG_SRC_FILES := \
fontconfig.properties \ fontconfig.properties \
fontconfig.SuSE.properties \ fontconfig.SuSE.properties \
fontconfig.Ubuntu.properties \ fontconfig.Ubuntu.properties \
fontconfig.Fedora.properties fontconfig.Fedora.properties
else else
GENDATA_FONT_CONFIG_SRC_DIR := $(JDK_TOPDIR)/src/closed/solaris/classes/sun/awt/fontconfigs GENDATA_FONT_CONFIG_SRC_DIR := \
GENDATA_FONT_CONFIG_SRC_FILES := \ $(JDK_TOPDIR)/src/closed/solaris/classes/sun/awt/fontconfigs
GENDATA_FONT_CONFIG_SRC_FILES := \
fontconfig.properties \ fontconfig.properties \
fontconfig.RedHat.5.properties \ fontconfig.RedHat.5.properties \
fontconfig.RedHat.6.properties \ fontconfig.RedHat.6.properties \
fontconfig.Turbo.properties \ fontconfig.Turbo.properties \
fontconfig.SuSE.10.properties \ fontconfig.SuSE.10.properties \
fontconfig.SuSE.11.properties fontconfig.SuSE.11.properties
endif endif
endif endif
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
GENDATA_FONT_CONFIG_SRC_DIR := $(JDK_TOPDIR)/src/solaris/classes/sun/awt/fontconfigs GENDATA_FONT_CONFIG_SRC_DIR := \
GENDATA_FONT_CONFIG_SRC_FILES := fontconfig.properties $(JDK_TOPDIR)/src/solaris/classes/sun/awt/fontconfigs
GENDATA_FONT_CONFIG_SRC_PREFIX := solaris. GENDATA_FONT_CONFIG_SRC_FILES := fontconfig.properties
GENDATA_FONT_CONFIG_SRC_PREFIX := solaris.
endif endif
ifeq ($(OPENJDK_TARGET_OS), macosx) ifeq ($(OPENJDK_TARGET_OS), macosx)
GENDATA_FONT_CONFIG_SRC_DIR := $(JDK_TOPDIR)/src/macosx/classes/sun/awt/fontconfigs GENDATA_FONT_CONFIG_SRC_DIR := \
GENDATA_FONT_CONFIG_SRC_FILES := fontconfig.properties $(JDK_TOPDIR)/src/macosx/classes/sun/awt/fontconfigs
GENDATA_FONT_CONFIG_SRC_PREFIX := macosx. GENDATA_FONT_CONFIG_SRC_FILES := fontconfig.properties
endif # OPENJDK_TARGET_OS GENDATA_FONT_CONFIG_SRC_PREFIX := macosx.
endif
### ###
$(GENDATA_FONT_CONFIG_DST)/%.src : $(GENDATA_FONT_CONFIG_SRC_DIR)/$(GENDATA_FONT_CONFIG_SRC_PREFIX)% $(GENDATA_FONT_CONFIG_DST)/%.src : \
$(GENDATA_FONT_CONFIG_SRC_DIR)/$(GENDATA_FONT_CONFIG_SRC_PREFIX)%
$(RM) $@
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CP) $< $@ $(CP) $< $@
$(CHMOD) 644 $@ $(CHMOD) 644 $@
$(GENDATA_FONT_CONFIG_DST)/%.bfc : $(GENDATA_FONT_CONFIG_SRC_DIR)/$(GENDATA_FONT_CONFIG_SRC_PREFIX)%.properties $(GENDATA_FONT_CONFIG_DST)/%.bfc : \
$(GENDATA_FONT_CONFIG_SRC_DIR)/$(GENDATA_FONT_CONFIG_SRC_PREFIX)%.properties
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(TOOL_COMPILEFONTCONFIG) $< $@ $(TOOL_COMPILEFONTCONFIG) $< $@
$(CHMOD) 444 $@ $(CHMOD) 444 $@
...@@ -84,3 +92,4 @@ GENDATA_BFONT_CONFIGS := $(GENDATA_FONT_CONFIG_SRC_FILES:%.properties=$(GENDATA_ ...@@ -84,3 +92,4 @@ GENDATA_BFONT_CONFIGS := $(GENDATA_FONT_CONFIG_SRC_FILES:%.properties=$(GENDATA_
GENDATA_FONT_CONFIG := $(GENDATA_FONT_CONFIGS) $(GENDATA_BFONT_CONFIGS) GENDATA_FONT_CONFIG := $(GENDATA_FONT_CONFIGS) $(GENDATA_BFONT_CONFIGS)
### ###
...@@ -46,9 +46,9 @@ TZFILES := \ ...@@ -46,9 +46,9 @@ TZFILES := \
GENDATA_TIMEZONE_MAPFILE:=ZoneInfoMappings GENDATA_TIMEZONE_MAPFILE:=ZoneInfoMappings
$(GENDATA_TIMEZONE_DST)/$(GENDATA_TIMEZONE_MAPFILE) : $(TZFILES) $(GENDATA_TIMEZONE_DST)/$(GENDATA_TIMEZONE_MAPFILE) : $(TZFILES)
$(RM) -rf $(GENDATA_TIMEZONE_TMP) $(RM) -r $(GENDATA_TIMEZONE_TMP)
$(MKDIR) -p $(GENDATA_TIMEZONE_TMP) $(MKDIR) -p $(GENDATA_TIMEZONE_TMP)
$(RM) -rf $(GENDATA_TIMEZONE_DST) $(RM) -r $(GENDATA_TIMEZONE_DST)
$(MKDIR) -p $(GENDATA_TIMEZONE_DST) $(MKDIR) -p $(GENDATA_TIMEZONE_DST)
$(TOOL_JAVAZIC) -V "$(GENDATA_TIMEZONE_VERSION)" -d $(GENDATA_TIMEZONE_TMP) $(TZFILES) $(TOOL_JAVAZIC) -V "$(GENDATA_TIMEZONE_VERSION)" -d $(GENDATA_TIMEZONE_TMP) $(TZFILES)
$(CP) -r $(GENDATA_TIMEZONE_TMP)/* $(GENDATA_TIMEZONE_DST)/ $(CP) -r $(GENDATA_TIMEZONE_TMP)/* $(GENDATA_TIMEZONE_DST)/
......
...@@ -31,7 +31,7 @@ include RMICompilation.gmk ...@@ -31,7 +31,7 @@ include RMICompilation.gmk
# To ensure the latest stub generator files are picked up from corba repo # To ensure the latest stub generator files are picked up from corba repo
# when available, we need to run with latest rmic version available. # when available, we need to run with latest rmic version available.
ifeq ($(CROSS_COMPILE_ARCH),) ifneq ($(COMPILE_TYPE),cross)
RMIC := $(UNCYGDRIVE) $(JDK_OUTPUTDIR)/bin/rmic RMIC := $(UNCYGDRIVE) $(JDK_OUTPUTDIR)/bin/rmic
endif endif
......
...@@ -67,8 +67,8 @@ GENDATA_CURDATA := $(JDK_OUTPUTDIR)/lib/currency.data ...@@ -67,8 +67,8 @@ GENDATA_CURDATA := $(JDK_OUTPUTDIR)/lib/currency.data
$(GENDATA_CURDATA): $(JDK_TOPDIR)/src/share/classes/java/util/CurrencyData.properties $(BUILD_TOOLS) $(GENDATA_CURDATA): $(JDK_TOPDIR)/src/share/classes/java/util/CurrencyData.properties $(BUILD_TOOLS)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(TOOL_GENERATECURRENCYDATA) -o $@.temp < $< $(TOOL_GENERATECURRENCYDATA) -o $@.tmp < $<
$(MV) $@.temp $@ $(MV) $@.tmp $@
$(CHMOD) 444 $@ $(CHMOD) 444 $@
GENDATA += $(GENDATA_CURDATA) GENDATA += $(GENDATA_CURDATA)
...@@ -77,6 +77,9 @@ GENDATA += $(GENDATA_CURDATA) ...@@ -77,6 +77,9 @@ GENDATA += $(GENDATA_CURDATA)
$(GENDATA) : $(BUILD_TOOLS) $(GENDATA) : $(BUILD_TOOLS)
all: $(GENDATA) $(JDK_OUTPUTDIR)/classes/_the.gendata : $(GENDATA)
$(TOUCH) $@
all: $(JDK_OUTPUTDIR)/classes/_the.gendata
.PHONY: all .PHONY: all
...@@ -226,7 +226,7 @@ define SetupGenBuffer ...@@ -226,7 +226,7 @@ define SetupGenBuffer
endif endif
$$($1_DST) : $$($1_DEP) $(GENSRC_BUFFER_DST)/_the.dir $$($1_DST) : $$($1_DEP) $(GENSRC_BUFFER_DST)/_the.dir
$(TOOL_SPP) < $$($1_SRC) > $$($1_OUT).temp \ $(TOOL_SPP) < $$($1_SRC) > $$($1_OUT).tmp \
-K$$($1_type) \ -K$$($1_type) \
-K$$($1_category) \ -K$$($1_category) \
-Dtype=$$($1_type) \ -Dtype=$$($1_type) \
...@@ -248,19 +248,19 @@ $$($1_DST) : $$($1_DEP) $(GENSRC_BUFFER_DST)/_the.dir ...@@ -248,19 +248,19 @@ $$($1_DST) : $$($1_DEP) $(GENSRC_BUFFER_DST)/_the.dir
-Da=$$($1_a) \ -Da=$$($1_a) \
-DA=$$($1_A) \ -DA=$$($1_A) \
-Kbo$$($1_BO) -Kbo$$($1_BO)
$(MV) $$($1_OUT).temp $$($1_OUT) $(MV) $$($1_OUT).tmp $$($1_OUT)
# Do the extra bin thing # Do the extra bin thing
ifeq ($$($1_BIN),1) ifeq ($$($1_BIN),1)
$(SED) -e '/#BIN/,$$$$d' < $$($1_OUT) > $$($1_DST).temp $(SED) -e '/#BIN/,$$$$d' < $$($1_OUT) > $$($1_DST).tmp
$(RM) $$($1_OUT) $(RM) $$($1_OUT)
$$($1_char_CMD) < $$($1_SRC_BIN) >> $$($1_DST).temp $$($1_char_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
$$($1_short_CMD) < $$($1_SRC_BIN) >> $$($1_DST).temp $$($1_short_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
$$($1_int_CMD) < $$($1_SRC_BIN) >> $$($1_DST).temp $$($1_int_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
$$($1_long_CMD) < $$($1_SRC_BIN) >> $$($1_DST).temp $$($1_long_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
$$($1_float_CMD) < $$($1_SRC_BIN) >> $$($1_DST).temp $$($1_float_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
$$($1_double_CMD) < $$($1_SRC_BIN) >> $$($1_DST).temp $$($1_double_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
$(PRINTF) "}\n" >> $$($1_DST).temp $(PRINTF) "}\n" >> $$($1_DST).tmp
mv $$($1_DST).temp $$($1_DST) mv $$($1_DST).tmp $$($1_DST)
endif endif
GENSRC_BUFFER += $$($1_DST) GENSRC_BUFFER += $$($1_DST)
......
...@@ -36,8 +36,8 @@ GENSRC_CHARSETCODER_TEMPLATE := $(GENSRC_CHARSETCODER_SRC)/charset/Charset-X-Cod ...@@ -36,8 +36,8 @@ GENSRC_CHARSETCODER_TEMPLATE := $(GENSRC_CHARSETCODER_SRC)/charset/Charset-X-Cod
$(GENSRC_CHARSETCODER_DST)/CharsetDecoder.java : $(GENSRC_CHARSETCODER_TEMPLATE) $(GENSRC_CHARSETCODER_DST)/CharsetDecoder.java : $(GENSRC_CHARSETCODER_TEMPLATE)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
-$(RM) $@.temp -$(RM) $@.tmp
$(TOOL_SPP) < $< >$@.temp \ $(TOOL_SPP) < $< >$@.tmp \
-Kdecoder \ -Kdecoder \
-DA='A' \ -DA='A' \
-Da='a' \ -Da='a' \
...@@ -63,7 +63,7 @@ $(GENSRC_CHARSETCODER_DST)/CharsetDecoder.java : $(GENSRC_CHARSETCODER_TEMPLATE) ...@@ -63,7 +63,7 @@ $(GENSRC_CHARSETCODER_DST)/CharsetDecoder.java : $(GENSRC_CHARSETCODER_TEMPLATE)
-DnotLegal='not legal for this charset' \ -DnotLegal='not legal for this charset' \
-Dotypes-per-itype='chars-per-byte' \ -Dotypes-per-itype='chars-per-byte' \
-DoutSequence='Unicode character' -DoutSequence='Unicode character'
$(MV) $@.temp $@ $(MV) $@.tmp $@
GENSRC_CHARSETCODER += $(GENSRC_CHARSETCODER_DST)/CharsetDecoder.java GENSRC_CHARSETCODER += $(GENSRC_CHARSETCODER_DST)/CharsetDecoder.java
...@@ -71,8 +71,8 @@ GENSRC_CHARSETCODER += $(GENSRC_CHARSETCODER_DST)/CharsetDecoder.java ...@@ -71,8 +71,8 @@ GENSRC_CHARSETCODER += $(GENSRC_CHARSETCODER_DST)/CharsetDecoder.java
$(GENSRC_CHARSETCODER_DST)/CharsetEncoder.java : $(GENSRC_CHARSETCODER_TEMPLATE) $(GENSRC_CHARSETCODER_DST)/CharsetEncoder.java : $(GENSRC_CHARSETCODER_TEMPLATE)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
-$(RM) $@.temp -$(RM) $@.tmp
$(TOOL_SPP) < $< >$@.temp \ $(TOOL_SPP) < $< >$@.tmp \
-Kencoder \ -Kencoder \
-DA='An' \ -DA='An' \
-Da='an' \ -Da='an' \
...@@ -98,7 +98,7 @@ $(GENSRC_CHARSETCODER_DST)/CharsetEncoder.java : $(GENSRC_CHARSETCODER_TEMPLATE) ...@@ -98,7 +98,7 @@ $(GENSRC_CHARSETCODER_DST)/CharsetEncoder.java : $(GENSRC_CHARSETCODER_TEMPLATE)
-DnotLegal='not a legal sixteen-bit Unicode sequence' \ -DnotLegal='not a legal sixteen-bit Unicode sequence' \
-Dotypes-per-itype='bytes-per-char' \ -Dotypes-per-itype='bytes-per-char' \
-DoutSequence='byte sequence in the given charset' -DoutSequence='byte sequence in the given charset'
$(MV) $@.temp $@ $(MV) $@.tmp $@
GENSRC_CHARSETCODER += $(GENSRC_CHARSETCODER_DST)/CharsetEncoder.java GENSRC_CHARSETCODER += $(GENSRC_CHARSETCODER_DST)/CharsetEncoder.java
......
...@@ -29,7 +29,7 @@ GENSRC_ICONS_TMP := $(JDK_OUTPUTDIR)/gensrc_icons ...@@ -29,7 +29,7 @@ GENSRC_ICONS_TMP := $(JDK_OUTPUTDIR)/gensrc_icons
GENSRC_ICONS_DST := $(GENSRC_ICONS_TMP)/sun/awt/X11 GENSRC_ICONS_DST := $(GENSRC_ICONS_TMP)/sun/awt/X11
ifdef OPENJDK ifdef OPENJDK
ICONS_PATH_PREFIX := $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API) ICONS_PATH_PREFIX := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)
else else
ICONS_PATH_PREFIX := $(JDK_TOPDIR)/src/closed/solaris ICONS_PATH_PREFIX := $(JDK_TOPDIR)/src/closed/solaris
endif endif
...@@ -41,7 +41,7 @@ GENSRC_ICONS_SRC += \ ...@@ -41,7 +41,7 @@ GENSRC_ICONS_SRC += \
$(ICONS_PATH_PREFIX)/classes/sun/awt/X11/java-icon48.png $(ICONS_PATH_PREFIX)/classes/sun/awt/X11/java-icon48.png
ICONPATH := $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes/sun/awt/X11 ICONPATH := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes/sun/awt/X11
GENSRC_ICONS_SRC += \ GENSRC_ICONS_SRC += \
$(ICONPATH)/security-icon-bw16.png \ $(ICONPATH)/security-icon-bw16.png \
...@@ -85,10 +85,7 @@ $$($1_TARGET32) : $2/$1 $(GENSRC_ICONS_TMP)/_the.dir ...@@ -85,10 +85,7 @@ $$($1_TARGET32) : $2/$1 $(GENSRC_ICONS_TMP)/_the.dir
$(ECHO) "package sun.awt.X11;" > $$@.tmp $(ECHO) "package sun.awt.X11;" > $$@.tmp
$(ECHO) "public class $$($1_NAME32) {" >> $$@.tmp $(ECHO) "public class $$($1_NAME32) {" >> $$@.tmp
$(ECHO) "public static int[] $$($1_SHORTNAME) = { " >> $$@.tmp $(ECHO) "public static int[] $$($1_SHORTNAME) = { " >> $$@.tmp
# TODO FIX FIX FIX
ifneq ($(OPENJDK_TARGET_OS),macosx)
$(CAT) $$< | $(TOOL_TOBIN) >> $$@.tmp $(CAT) $$< | $(TOOL_TOBIN) >> $$@.tmp
endif
$(ECHO) "}; }" >> $$@.tmp $(ECHO) "}; }" >> $$@.tmp
$(MV) $$@.tmp $$@ $(MV) $$@.tmp $$@
...@@ -99,10 +96,7 @@ $$($1_TARGET64) : $2/$1 $(GENSRC_ICONS_TMP)/_the.dir ...@@ -99,10 +96,7 @@ $$($1_TARGET64) : $2/$1 $(GENSRC_ICONS_TMP)/_the.dir
$(ECHO) "package sun.awt.X11;" > $$@.tmp $(ECHO) "package sun.awt.X11;" > $$@.tmp
$(ECHO) "public class $$($1_NAME64) {" >> $$@.tmp $(ECHO) "public class $$($1_NAME64) {" >> $$@.tmp
$(ECHO) "public static long[] $$($1_SHORTNAME) = { " >> $$@.tmp $(ECHO) "public static long[] $$($1_SHORTNAME) = { " >> $$@.tmp
# TODO FIX FIX FIX
ifneq ($(OPENJDK_TARGET_OS),macosx)
$(CAT) $$< | $(TOOL_TOBIN) >> $$@.tmp $(CAT) $$< | $(TOOL_TOBIN) >> $$@.tmp
endif
$(ECHO) "}; }" >> $$@.tmp $(ECHO) "}; }" >> $$@.tmp
$(MV) $$@.tmp $$@ $(MV) $$@.tmp $$@
......
...@@ -31,8 +31,17 @@ $(JDK_OUTPUTDIR)/gensrc_jdwp_headers/JDWPCommands.h : $(JDK_TOPDIR)/makefiles/jp ...@@ -31,8 +31,17 @@ $(JDK_OUTPUTDIR)/gensrc_jdwp_headers/JDWPCommands.h : $(JDK_TOPDIR)/makefiles/jp
$(JDK_OUTPUTDIR)/gensrc_jdwp/com/sun/tools/jdi/JDWP.java : $(JDK_TOPDIR)/makefiles/jpda/jdwp/jdwp.spec $(JDK_OUTPUTDIR)/gensrc_jdwp/com/sun/tools/jdi/JDWP.java : $(JDK_TOPDIR)/makefiles/jpda/jdwp/jdwp.spec
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(MKDIR) -p $(JDK_OUTPUTDIR)/gensrc_jdwp_headers $(MKDIR) -p $(JDK_OUTPUTDIR)/gensrc_jdwp_headers
$(RM) $@ $(JDK_OUTPUTDIR)/gensrc_jdwp_headers/JDWPCommands.h
$(ECHO) Creating JDWP.java and JDWPCommands.h from jdwp.spec $(ECHO) Creating JDWP.java and JDWPCommands.h from jdwp.spec
$(TOOL_JDWPGEN) $< -jdi $@ -include $(JDK_OUTPUTDIR)/gensrc_jdwp_headers/JDWPCommands.h $(TOOL_JDWPGEN) $< -jdi $@ -include $(JDK_OUTPUTDIR)/gensrc_jdwp_headers/JDWPCommands.h
$(JDK_OUTPUTDIR)/gensrc_jdwp_doc/jdwp-protocol.html : $(JDK_TOPDIR)/makefiles/jpda/jdwp/jdwp.spec
$(MKDIR) -p $(@D)
$(RM) $@
$(ECHO) Creating $(@F) from jdwp.spec
$(TOOL_JDWPGEN) $< -doc $@
GENSRC_JDWP:= $(JDK_OUTPUTDIR)/gensrc_jdwp/com/sun/tools/jdi/JDWP.java \ GENSRC_JDWP:= $(JDK_OUTPUTDIR)/gensrc_jdwp/com/sun/tools/jdi/JDWP.java \
$(JDK_OUTPUTDIR)/gensrc_jdwp_headers/JDWPCommands.h $(JDK_OUTPUTDIR)/gensrc_jdwp_headers/JDWPCommands.h \
$(JDK_OUTPUTDIR)/gensrc_jdwp_doc/jdwp-protocol.html
...@@ -38,43 +38,71 @@ JOBJC_DST := $(JDK_OUTPUTDIR)/gensrc_jobjc/src ...@@ -38,43 +38,71 @@ JOBJC_DST := $(JDK_OUTPUTDIR)/gensrc_jobjc/src
# #
$(eval $(call SetupJavaCompilation,BUILD_JOBJC_PRIMITIVE_CODER,\ $(eval $(call SetupJavaCompilation,BUILD_JOBJC_PRIMITIVE_CODER,\
SETUP:=GENERATE_OLDBYTECODE,\ SETUP:=GENERATE_OLDBYTECODE,\
DISABLE_SJAVAC:=true,\
INCLUDES:=core/java \ INCLUDES:=core/java \
com/apple,\ com/apple,\
HEADERS :=$(JOBJC_DST)/jni_headers/core ,\ HEADERS:=$(JOBJC_DST)/jni_headers/core ,\
SRC:=$(JOBJC_SRC)/src \ SRC:=$(JOBJC_SRC)/src \
$(JOBJC_SRC)/src/generator/java, \ $(JOBJC_SRC)/src/generator/java, \
BIN:=$(JOBJC_TMP)/bin)) BIN:=$(JOBJC_TMP)/bin))
GENSRC_JOBJC += $(JOBJC_TMP)/bin/_the.batch GENSRC_JOBJC += $(BUILD_JOBJC_PRIMITIVE_CODER)
# #
# Generate bridge support # Generate bridge support for select frameworks
# #
BRIDGESUPPORT := $(addprefix $(JOBJC_TMP)/bridge/,$(addsuffix Full.bridgesupport,$(JOBJC_FRAMEWORKS))) BRIDGESUPPORT := $(addprefix $(JOBJC_TMP)/bridge/,$(addsuffix Full.bridgesupport,$(JOBJC_FRAMEWORKS)))
$(JOBJC_TMP)/bridge/%Full.bridgesupport : $(FRAMEWORKS_DIR)/%.framework/Headers/*.h #
$(MKDIR) -p $(@D) # Define macro for rules to create bridge support
if [ -f $(FRAMEWORKS_DIR)/$*.framework/Resources/BridgeSupport/$(@F) ]; then \ # Not sure why, but if the system has this framework bridge support,
cp $(FRAMEWORKS_DIR)/$*.framework/Resources/BridgeSupport/$(@F) $@ ;\ # we appear to copy that, otherwise we run GBM which can be very slow.
else \ #
$(GBM) -F complete --framework $* -o $@ ; \ define CreateBridgeSupport # Framework
fi $(RM) $@ $@.tmp
$(MKDIR) -p $(@D)
if [ -f $(FRAMEWORKS_DIR)/$1.framework/Resources/BridgeSupport/$(@F) ]; then \
$(CP) $(FRAMEWORKS_DIR)/$1.framework/Resources/BridgeSupport/$(@F) $@.tmp ;\
else \
$(GBM) -F complete --framework $1 -o $@.tmp ; \
fi
$(MV) $@.tmp $@
endef
#
# Currently 3 frameworks, avoid pattern rule due to the names being conflicting
#
$(JOBJC_TMP)/bridge/FoundationFull.bridgesupport : \
$(wildcard $(FRAMEWORKS_DIR)/Foundation.framework/Headers/*.h)
$(call CreateBridgeSupport,Foundation)
$(JOBJC_TMP)/bridge/CoreFoundationFull.bridgesupport : \
$(wildcard $(FRAMEWORKS_DIR)/CoreFoundation.framework/Headers/*.h)
$(call CreateBridgeSupport,CoreFoundation)
$(JOBJC_TMP)/bridge/AppKitFull.bridgesupport : \
$(wildcard $(FRAMEWORKS_DIR)/AppKit.framework/Headers/*.h)
$(call CreateBridgeSupport,AppKit)
# #
# Find Xbootclasspath # Find Xbootclasspath, for some reason, this involves firing up Java just
# so we can get the boot classpath, so we can remove anything in that
# classpath that ends with "JObjC.jar", and emit the new bootclasspath.
# #
$(JOBJC_TMP)/_the.generator_bootclasspath : $(JOBJC_TMP)/bin/_the.batch $(JOBJC_TMP)/_the.generator_bootclasspath : $(BUILD_JOBJC_PRIMITIVE_CODER)
$(RM) $@
$(JAVA) -cp $(JOBJC_TMP)/bin com.apple.internal.jobjc.generator.BootClassPathMinus JObjC.jar > $@.tmp $(JAVA) -cp $(JOBJC_TMP)/bin com.apple.internal.jobjc.generator.BootClassPathMinus JObjC.jar > $@.tmp
$(MV) $@.tmp $@ $(MV) $@.tmp $@
# #
# Run generator # Run generator
# Now we use bootclasspath to run java again, with the bridge support to
# generate more source.
# Note the use of the | (order-only) on the BRIDGESUPPORT, should serialize
# them just in case GBM run in parallel has issues.
# #
TOOL_JOBJC := $(JAVA) -cp $(JOBJC_TMP)/bin -ea com.apple.internal.jobjc.generator.Generator $(JOBJC_TMP)/_the.generator : $(JOBJC_TMP)/_the.generator_bootclasspath | $(BRIDGESUPPORT)
$(RM) $@
$(JOBJC_TMP)/_the.generator : $(JOBJC_TMP)/bin/_the.batch $(JOBJC_TMP)/_the.generator_bootclasspath $(BRIDGESUPPORT)
$(JAVA) -d64 -Xbootclasspath:`$(CAT) $(JOBJC_TMP)/_the.generator_bootclasspath` -cp $(JOBJC_TMP)/bin -ea com.apple.internal.jobjc.generator.Generator dst=$(JOBJC_DST) frameworks=$(JOBJC_TMP)/bridge $(JAVA) -d64 -Xbootclasspath:`$(CAT) $(JOBJC_TMP)/_the.generator_bootclasspath` -cp $(JOBJC_TMP)/bin -ea com.apple.internal.jobjc.generator.Generator dst=$(JOBJC_DST) frameworks=$(JOBJC_TMP)/bridge
$(TOUCH) $@ $(TOUCH) $@
GENSRC_JOBJC += $(JOBJC_TMP)/_the.generator GENSRC_JOBJC += $(JOBJC_TMP)/_the.generator
...@@ -31,12 +31,14 @@ ...@@ -31,12 +31,14 @@
$(JDK_OUTPUTDIR)/gensrc_misc/sun/misc/Version.java: \ $(JDK_OUTPUTDIR)/gensrc_misc/sun/misc/Version.java: \
$(JDK_TOPDIR)/src/share/classes/sun/misc/Version.java.template $(JDK_TOPDIR)/src/share/classes/sun/misc/Version.java.template
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$(ECHO) Generating sun/misc/Version.java $(ECHO) Generating sun/misc/Version.java
$(SED) -e 's/@@launcher_name@@/$(LAUNCHER_NAME)/g' \ $(SED) -e 's/@@launcher_name@@/$(LAUNCHER_NAME)/g' \
-e 's/@@java_version@@/$(RELEASE)/g' \ -e 's/@@java_version@@/$(RELEASE)/g' \
-e 's/@@java_runtime_version@@/$(FULL_VERSION)/g' \ -e 's/@@java_runtime_version@@/$(FULL_VERSION)/g' \
-e 's/@@java_runtime_name@@/$(RUNTIME_NAME)/g' \ -e 's/@@java_runtime_name@@/$(RUNTIME_NAME)/g' \
$< > $@ $< > $@.tmp
$(MV) $@.tmp $@
GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/misc/Version.java GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/misc/Version.java
...@@ -46,8 +48,10 @@ GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/misc/Version.java ...@@ -46,8 +48,10 @@ GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/misc/Version.java
$(JDK_OUTPUTDIR)/gensrc_misc/sun/tools/jconsole/Version.java: \ $(JDK_OUTPUTDIR)/gensrc_misc/sun/tools/jconsole/Version.java: \
$(JDK_TOPDIR)/src/share/classes/sun/tools/jconsole/Version.java.template $(JDK_TOPDIR)/src/share/classes/sun/tools/jconsole/Version.java.template
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$(ECHO) Generating sun/tools/jconsole/Version.java $(ECHO) Generating sun/tools/jconsole/Version.java
$(SED) -e 's/@@jconsole_version@@/$(FULL_VERSION)/g' $< > $@ $(SED) -e 's/@@jconsole_version@@/$(FULL_VERSION)/g' $< > $@.tmp
$(MV) $@.tmp $@
GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/tools/jconsole/Version.java GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/tools/jconsole/Version.java
...@@ -80,12 +84,14 @@ ifneq ($(OPENJDK_TARGET_OS), macosx) ...@@ -80,12 +84,14 @@ ifneq ($(OPENJDK_TARGET_OS), macosx)
$(JDK_OUTPUTDIR)/gensrc_c/libjdbcodbc/dummyodbc1.c : $(JDK_OUTPUTDIR)/gensrc_c/libjdbcodbc/dummyodbc1.c :
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(ECHO) Creating $@ $(ECHO) Creating $@
$(PRINTF) "void dummyOdbc(void){}\n" > $@ $(PRINTF) "void dummyOdbc(void){}\n" > $@
$(ECHO) Created $@ $(ECHO) Created $@
$(JDK_OUTPUTDIR)/gensrc_c/libjdbcodbc/dummyodbc2.c : $(JDK_OUTPUTDIR)/gensrc_c/libjdbcodbc/dummyodbc2.c :
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(ECHO) Creating $@ $(ECHO) Creating $@
$(PRINTF) "void dummyOdbc(void){}\n" > $@ $(PRINTF) "void dummyOdbc(void){}\n" > $@
$(ECHO) Created $@ $(ECHO) Created $@
...@@ -110,21 +116,27 @@ $(eval $(call SetupNativeCompilation,BUILD_GENSRC_SOR_EXE,\ ...@@ -110,21 +116,27 @@ $(eval $(call SetupNativeCompilation,BUILD_GENSRC_SOR_EXE,\
SRC:=$(GENSRC_SOR_SRC),\ SRC:=$(GENSRC_SOR_SRC),\
INCLUDE_FILES:=$(GENSRC_SOR_SRC_FILE),\ INCLUDE_FILES:=$(GENSRC_SOR_SRC_FILE),\
LANG:=C,\ LANG:=C,\
CC:=$(HOST_CC),\ CC:=$(BUILD_CC),\
LDEXE:=$(HOST_LD),\ LDEXE:=$(BUILD_LD),\
OBJECT_DIR:=$(GENSRC_SOR_BIN),\ OBJECT_DIR:=$(GENSRC_SOR_BIN),\
OUTPUT_DIR:=$(GENSRC_SOR_BIN),\ OUTPUT_DIR:=$(GENSRC_SOR_BIN),\
PROGRAM:=genSocketOptionRegistry)) PROGRAM:=genSocketOptionRegistry))
ifneq ($(JAVASE_EMBEDDED), true) ifneq ($(wildcard $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/ch/SocketOptionRegistry-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java),)
HAS_SOCKET_OPTION_REGISTRY:=true
endif
ifneq ($(HAS_SOCKET_OTION_REGISTRY),true)
$(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/ch/SocketOptionRegistry.java : $(BUILD_GENSRC_SOR_EXE) $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/ch/SocketOptionRegistry.java : $(BUILD_GENSRC_SOR_EXE)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
NAWK="$(NAWK)" SH="$(SH)" $(SH) -e $(JDK_TOPDIR)/makefiles/scripts/addNotices.sh "$(SOR_COPYRIGHT_YEARS)" > $@.tmp NAWK="$(NAWK)" SH="$(SH)" $(SH) -e $(JDK_TOPDIR)/makefiles/scripts/addNotices.sh "$(SOR_COPYRIGHT_YEARS)" > $@.tmp
$(BUILD_GENSRC_SOR_EXE) >> $@.tmp $(BUILD_GENSRC_SOR_EXE) >> $@.tmp
$(MV) $@.tmp $@ $(MV) $@.tmp $@
else else
$(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/ch/SocketOptionRegistry.java : $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/ch/SocketOptionRegistry-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/ch/SocketOptionRegistry.java : $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/ch/SocketOptionRegistry-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(CP) $< $@ $(CP) $< $@
endif endif
...@@ -134,7 +146,7 @@ ifneq ($(OPENJDK_TARGET_OS),windows) ...@@ -134,7 +146,7 @@ ifneq ($(OPENJDK_TARGET_OS),windows)
GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/UnixConstants.java GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/UnixConstants.java
GENSRC_UC_SRC := $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/nio/fs GENSRC_UC_SRC := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/nio/fs
GENSRC_UC_SRC_FILE := genUnixConstants.c GENSRC_UC_SRC_FILE := genUnixConstants.c
GENSRC_UC_BIN := $(JDK_OUTPUTDIR)/gensrc_misc/genUnixConstants GENSRC_UC_BIN := $(JDK_OUTPUTDIR)/gensrc_misc/genUnixConstants
...@@ -145,21 +157,27 @@ $(eval $(call SetupNativeCompilation,BUILD_GENSRC_UC_EXE,\ ...@@ -145,21 +157,27 @@ $(eval $(call SetupNativeCompilation,BUILD_GENSRC_UC_EXE,\
SRC:=$(GENSRC_UC_SRC),\ SRC:=$(GENSRC_UC_SRC),\
INCLUDE_FILES:=$(GENSRC_UC_SRC_FILE),\ INCLUDE_FILES:=$(GENSRC_UC_SRC_FILE),\
LANG:=C,\ LANG:=C,\
CC:=$(HOST_CC),\ CC:=$(BUILD_CC),\
LDEXE:=$(HOST_CC),\ LDEXE:=$(BUILD_CC),\
OBJECT_DIR:=$(GENSRC_UC_BIN),\ OBJECT_DIR:=$(GENSRC_UC_BIN),\
OUTPUT_DIR:=$(GENSRC_UC_BIN),\ OUTPUT_DIR:=$(GENSRC_UC_BIN),\
PROGRAM:=genUnixConstants)) PROGRAM:=genUnixConstants))
ifneq ($(JAVASE_EMBEDDED), true) ifneq ($(wildcard $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/fs/UnixConstants-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java),)
HAS_UNIX_CONSTANTS:=true
endif
ifneq ($(HAS_UNIX_CONSTANTS),true)
$(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/UnixConstants.java : $(BUILD_GENSRC_UC_EXE) $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/UnixConstants.java : $(BUILD_GENSRC_UC_EXE)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
NAWK="$(NAWK)" SH="$(SH)" $(SH) -e $(JDK_TOPDIR)/makefiles/scripts/addNotices.sh "$(UC_COPYRIGHT_YEARS)" > $@.tmp NAWK="$(NAWK)" SH="$(SH)" $(SH) -e $(JDK_TOPDIR)/makefiles/scripts/addNotices.sh "$(UC_COPYRIGHT_YEARS)" > $@.tmp
$(BUILD_GENSRC_UC_EXE) >> $@.tmp $(BUILD_GENSRC_UC_EXE) >> $@.tmp
$(MV) $@.tmp $@ $(MV) $@.tmp $@
else else
$(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/UnixConstants.java : $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/fs/UnixConstants-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/UnixConstants.java : $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/fs/UnixConstants-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@
$(CP) $< $@ $(CP) $< $@
endif endif
...@@ -171,7 +189,7 @@ ifeq ($(OPENJDK_TARGET_OS),solaris) ...@@ -171,7 +189,7 @@ ifeq ($(OPENJDK_TARGET_OS),solaris)
GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/SolarisConstants.java GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/SolarisConstants.java
GENSRC_SOL_SRC := $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/sun/nio/fs GENSRC_SOL_SRC := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/nio/fs
GENSRC_SOL_SRC_FILE := genSolarisConstants.c GENSRC_SOL_SRC_FILE := genSolarisConstants.c
GENSRC_SOL_BIN := $(JDK_OUTPUTDIR)/gensrc_misc/genSolarisConstants GENSRC_SOL_BIN := $(JDK_OUTPUTDIR)/gensrc_misc/genSolarisConstants
...@@ -182,14 +200,15 @@ $(eval $(call SetupNativeCompilation,BUILD_GENSRC_SOL_EXE,\ ...@@ -182,14 +200,15 @@ $(eval $(call SetupNativeCompilation,BUILD_GENSRC_SOL_EXE,\
SRC:=$(GENSRC_SOL_SRC),\ SRC:=$(GENSRC_SOL_SRC),\
INCLUDE_FILES:=$(GENSRC_SOL_SRC_FILE),\ INCLUDE_FILES:=$(GENSRC_SOL_SRC_FILE),\
LANG:=C,\ LANG:=C,\
CC:=$(HOST_CC),\ CC:=$(BUILD_CC),\
LDEXE:=$(HOST_CC),\ LDEXE:=$(BUILD_CC),\
OBJECT_DIR:=$(GENSRC_SOL_BIN),\ OBJECT_DIR:=$(GENSRC_SOL_BIN),\
OUTPUT_DIR:=$(GENSRC_SOL_BIN),\ OUTPUT_DIR:=$(GENSRC_SOL_BIN),\
PROGRAM:=genSolarisConstants)) PROGRAM:=genSolarisConstants))
$(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/SolarisConstants.java : $(BUILD_GENSRC_SOL_EXE) $(JDK_OUTPUTDIR)/gensrc_misc/sun/nio/fs/SolarisConstants.java : $(BUILD_GENSRC_SOL_EXE)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
NAWK="$(NAWK)" SH="$(SH)" $(SH) -e $(JDK_TOPDIR)/makefiles/scripts/addNotices.sh "$(SOL_COPYRIGHT_YEARS)" > $@.tmp NAWK="$(NAWK)" SH="$(SH)" $(SH) -e $(JDK_TOPDIR)/makefiles/scripts/addNotices.sh "$(SOL_COPYRIGHT_YEARS)" > $@.tmp
$(BUILD_GENSRC_SOL_EXE) >> $@.tmp $(BUILD_GENSRC_SOL_EXE) >> $@.tmp
$(MV) $@.tmp $@ $(MV) $@.tmp $@
......
...@@ -46,8 +46,9 @@ define add_properties_to_compile ...@@ -46,8 +46,9 @@ define add_properties_to_compile
# Strip away prefix and suffix, # Strip away prefix and suffix,
# leaving for example: sun/util/resources/CurrencyNames_sv # leaving for example: sun/util/resources/CurrencyNames_sv
$1_PROPPATHS:=$$(patsubst $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes/%.properties,%,\ $1_PROPPATHS:=$$(patsubst $(JDK_TOPDIR)/src/windows/classes/%.properties,%,\
$$(patsubst $(JDK_TOPDIR)/src/share/classes/%.properties,%,$2)) $$(patsubst $(JDK_TOPDIR)/src/macosx/classes/%.properties,%,\
$$(patsubst $(JDK_TOPDIR)/src/share/classes/%.properties,%,$2)))
# Apply optional name transformation, example: hz_TW -> hz_HK # Apply optional name transformation, example: hz_TW -> hz_HK
$(if $4,$1_PROPPATHS:=$$(patsubst $4,$5,$$($1_PROPPATHS))) $(if $4,$1_PROPPATHS:=$$(patsubst $4,$5,$$($1_PROPPATHS)))
...@@ -75,7 +76,7 @@ define add_properties_to_clean ...@@ -75,7 +76,7 @@ define add_properties_to_clean
# Strip away prefix and suffix, # Strip away prefix and suffix,
# leaving for example: sun/util/resources/CurrencyNames_sv # leaving for example: sun/util/resources/CurrencyNames_sv
$1_PROPPATHS:=$$(patsubst $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes/%.properties,%,\ $1_PROPPATHS:=$$(patsubst $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes/%.properties,%,\
$$(patsubst $(JDK_TOPDIR)/src/share/classes/%.properties,%,$2)) $$(patsubst $(JDK_TOPDIR)/src/share/classes/%.properties,%,$2))
# Apply optional name transformation, example: hz_TW -> hz_HK # Apply optional name transformation, example: hz_TW -> hz_HK
...@@ -113,6 +114,13 @@ endef ...@@ -113,6 +114,13 @@ endef
# Some packages have properties that need to be converted to java source files. # Some packages have properties that need to be converted to java source files.
#com/apple/laf/resources
ifeq ($(OPENJDK_TARGET_OS),macosx)
$(eval $(call add_properties_to_compile,COM_APPLE_LAF,\
$(shell find $(JDK_TOPDIR)/src/macosx/classes/com/apple/laf/resources -name "*.properties"),\
ListResourceBundle))
endif
#com/sun/accessibility/internal/resources #com/sun/accessibility/internal/resources
$(eval $(call add_properties_to_compile,COM_SUN_ACCESSIBILITY,\ $(eval $(call add_properties_to_compile,COM_SUN_ACCESSIBILITY,\
$(shell find $(JDK_TOPDIR)/src/share/classes/com/sun/accessibility/internal/resources -name "*.properties"),\ $(shell find $(JDK_TOPDIR)/src/share/classes/com/sun/accessibility/internal/resources -name "*.properties"),\
...@@ -210,6 +218,16 @@ $(eval $(call add_properties_to_compile,SUN_AWT,\ ...@@ -210,6 +218,16 @@ $(eval $(call add_properties_to_compile,SUN_AWT,\
$(eval $(call add_properties_to_compile,SUN_AWT_HK,\ $(eval $(call add_properties_to_compile,SUN_AWT_HK,\
$(shell find $(JDK_TOPDIR)/src/share/classes/sun/awt/resources -name "*.properties"),\ $(shell find $(JDK_TOPDIR)/src/share/classes/sun/awt/resources -name "*.properties"),\
ListResourceBundle,%zh_TW,%zh_HK)) ListResourceBundle,%zh_TW,%zh_HK))
#sun/awt/windows/
ifeq ($(OPENJDK_TARGET_OS),windows)
$(eval $(call add_properties_to_compile,SUN_AWT,\
$(shell find $(JDK_TOPDIR)/src/windows/classes/sun/awt/windows -name "awtLocalization*.properties"),\
ListResourceBundle))
$(eval $(call add_properties_to_compile,SUN_AWT_HK,\
$(shell find $(JDK_TOPDIR)/src/windows/classes/sun/awt/windows -name "awtLocalization*.properties"),\
ListResourceBundle,%zh_TW,%zh_HK))
endif
#sun/launcher/resources #sun/launcher/resources
$(eval $(call add_properties_to_compile,SUN_LAUNCHER,\ $(eval $(call add_properties_to_compile,SUN_LAUNCHER,\
$(shell find $(JDK_TOPDIR)/src/share/classes/sun/launcher/resources -name "*.properties"),\ $(shell find $(JDK_TOPDIR)/src/share/classes/sun/launcher/resources -name "*.properties"),\
...@@ -286,7 +304,7 @@ $(eval $(call add_properties_to_compile,SUN_UTIL,\ ...@@ -286,7 +304,7 @@ $(eval $(call add_properties_to_compile,SUN_UTIL,\
# Now setup the rule for the generation of the resource bundles. # Now setup the rule for the generation of the resource bundles.
$(JDK_OUTPUTDIR)/gensrc_properties/_the.compiled_properties : $(ALL_COMPILED_PROPSOURCES) $(BUILD_TOOLS) $(JDK_OUTPUTDIR)/gensrc_properties/_the.compiled_properties : $(ALL_COMPILED_PROPSOURCES) $(BUILD_TOOLS)
$(RM) -rf $(JDK_OUTPUTDIR)/gensrc_properties/* $(RM) -r $(JDK_OUTPUTDIR)/gensrc_properties/*
# Generate all output directories in advance since the build tool does not do that... # Generate all output directories in advance since the build tool does not do that...
$(MKDIR) -p $(sort $(dir $(ALL_COMPILED_PROPJAVAS))) $(MKDIR) -p $(sort $(dir $(ALL_COMPILED_PROPJAVAS)))
$(ECHO) Compiling $(words $(ALL_COMPILED_PROPSOURCES)) properties into resource bundles $(ECHO) Compiling $(words $(ALL_COMPILED_PROPSOURCES)) properties into resource bundles
...@@ -297,7 +315,7 @@ $(JDK_OUTPUTDIR)/gensrc_properties/_the.compiled_properties : $(ALL_COMPILED_PRO ...@@ -297,7 +315,7 @@ $(JDK_OUTPUTDIR)/gensrc_properties/_the.compiled_properties : $(ALL_COMPILED_PRO
# Now setup the rule for the generation of the cleaned properties. # Now setup the rule for the generation of the cleaned properties.
# FIXME: We currently don't handle removed properties incrementally. # FIXME: We currently don't handle removed properties incrementally.
$(JDK_OUTPUTDIR)/classes/_the.cleaned_properties : $(ALL_CLEANED_PROPSOURCES) $(BUILD_TOOLS) $(JDK_OUTPUTDIR)/classes/_the.cleaned_properties : $(ALL_CLEANED_PROPSOURCES) $(BUILD_TOOLS)
$(RM) -f $(JDK_OUTPUTDIR)/classes/_the.cleaned_properties.cmdline $(RM) $(JDK_OUTPUTDIR)/classes/_the.cleaned_properties.cmdline
# Generate all output directories in advance since the build tool does not do that... # Generate all output directories in advance since the build tool does not do that...
$(MKDIR) -p $(sort $(dir $(ALL_CLEANED_PROPOUTPUT))) $(MKDIR) -p $(sort $(dir $(ALL_CLEANED_PROPOUTPUT)))
$(ECHO) Copying and cleaning $(words $(ALL_CLEANED_PROPSOURCES)) properties $(ECHO) Copying and cleaning $(words $(ALL_CLEANED_PROPSOURCES)) properties
......
...@@ -23,36 +23,33 @@ ...@@ -23,36 +23,33 @@
# questions. # questions.
# #
# This file is responsible for extracting the x11 native struct offsets to
# the xawt Java library. This is done by compiling and running a native
# binary, which dumps output to a text file. The offsets differ on 32 and 64
# bit systems, so care must be taken here.
# Note: Some of the more complex logic here is most likely not needed anymore.
GENSRC_X11WRAPPERS := GENSRC_X11WRAPPERS :=
GENSRC_X11WRAPPERS_TMP := $(JDK_OUTPUTDIR)/gensrc_x11wrappers GENSRC_X11WRAPPERS_TMP := $(JDK_OUTPUTDIR)/gensrc_x11wrappers
GENSRC_SIZER_SRC := $(JDK_TOPDIR)/src/solaris/classes/sun/awt/X11/generator GENSRC_SIZER_SRC := $(JDK_TOPDIR)/src/solaris/classes/sun/awt/X11/generator
GENSRC_SIZES := # Normal case is to generate version according to target bits
GENSRC_SIZES := sizes.$(OPENJDK_TARGET_CPU_BITS)
ifeq ($(OPENJDK_TARGET_OS)-$(LIBARCH), solaris-i386) ifeq ($(OPENJDK_TARGET_CPU_BITS), 64)
GENSRC_SIZES := sizes.32 sizes.64 ifneq ($(OPENJDK_TARGET_OS), linux)
else ifeq ($(OPENJDK_TARGET_OS), solaris) # On all 64-bit systems except Linux, generate both 32 and 64 bit versions
isalist:=$(shell isainfo)
ifneq (,$(findstring sparcv9, $(isalist)))
# On sparcv9 we generate both 32 and 64-bit sizers in spite of ARCH_DATA_MODEL.
GENSRC_SIZES := sizes.32 sizes.64 GENSRC_SIZES := sizes.32 sizes.64
endif
else else
ifneq (,$(findstring amd64, $(isalist))) ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU), solaris-x86)
# On amd64 we generate both 32 and 64-bit sizers in spite of ARCH_DATA_MODEL. # As a special case, solaris on x86 (32-bit) also generates the 64-bit version
GENSRC_SIZES := sizes.32 sizes.64
else # !sparcv9 : includes (32-bit) sparc, i586
GENSRC_SIZES := sizes.32
endif # amd64
endif # sparcv9
else # !solaris
ifeq ($(OPENJDK_TARGET_OS), macosx)
GENSRC_SIZES := sizes.32 sizes.64 GENSRC_SIZES := sizes.32 sizes.64
else # !macosx endif
GENSRC_SIZES := sizes.$(ARCH_DATA_MODEL) endif
endif # !macosx
endif # solaris
########################################################################################## ##########################################################################################
...@@ -62,40 +59,44 @@ $(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.%.c : $(GENSRC_SIZER_SRC)/xlibtypes.txt ...@@ -62,40 +59,44 @@ $(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.%.c : $(GENSRC_SIZER_SRC)/xlibtypes.txt
$(TOOL_WRAPPERGENERATOR) $(@D) $< "sizer" $* $(TOOL_WRAPPERGENERATOR) $(@D) $< "sizer" $*
$(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.%.exe : $(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.%.c $(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.%.exe : $(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.%.c
(cd $(@D) && $(HOST_CC) -m$* -o $@ $< \ $(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
(cd $(@D) && $(BUILD_CC) -m$* -o $@.tmp $< \
-I$(JDK_OUTPUTDIR)/include \ -I$(JDK_OUTPUTDIR)/include \
-I$(JDK_TOPDIR)/src/share/javavm/export \ -I$(JDK_TOPDIR)/src/share/javavm/export \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/javavm/export \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/javavm/export \
-I$(JDK_TOPDIR)//src/share/native/common \ -I$(JDK_TOPDIR)//src/share/native/common \
-I$(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/native/common \ -I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/common \
-I$(JDK_TOPDIR)/src/solaris/native/sun/awt \ -I$(JDK_TOPDIR)/src/solaris/native/sun/awt \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \ -I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \
-I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils -lc) -I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils -lc)
ifeq ($(OPENJDK_TARGET_OS)-$(LIBARCH), solaris-i386)
$(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.32 : $(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.32.exe
$< > $@.tmp
$(MV) $@.tmp $@ $(MV) $@.tmp $@
$(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.64 : $(JDK_TOPDIR)/src/$(LEGACY_OPENJDK_TARGET_OS_API)/classes/sun/awt/X11/generator/sizes.64-$(OPENJDK_TARGET_OS)-$(LIBARCH) # Run the generated sizer binary to create the sizes text file
$(MKDIR) -p $(@D)
$(CP) $< $@
else
$(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.% : $(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.%.exe $(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.% : $(GENSRC_X11WRAPPERS_TMP)/sizer/sizer.%.exe
$(MKDIR) -p $(@D)
$(RM) $@ $@.tmp
$< > $@.tmp $< > $@.tmp
$(MV) $@.tmp $@ $(MV) $@.tmp $@
ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU), solaris-x86)
# On solaris-x86 we also need to create the 64-bit version, but we can't run a 64-bit binary
# As a workaround, copy this from a pre-generated file.
$(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.64 : $(JDK_TOPDIR)/src/solaris/classes/sun/awt/X11/generator/sizes.64-solaris-i386
$(MKDIR) -p $(@D)
$(RM) $@
$(CP) $< $@
endif endif
$(GENSRC_X11WRAPPERS_TMP)/classes/_the.classes : $(foreach S,$(GENSRC_SIZES),$(GENSRC_X11WRAPPERS_TMP)/sizer/$(S)) $(GENSRC_X11WRAPPERS_TMP)/classes/_the.classes : $(foreach S,$(GENSRC_SIZES),$(GENSRC_X11WRAPPERS_TMP)/sizer/$(S))
$(RM) $@
$(MKDIR) -p $(@D)/sun/awt/X11 $(MKDIR) -p $(@D)/sun/awt/X11
$(RM) $(@D)/sun/awt/X11/* $(RM) $(@D)/sun/awt/X11/*
$(TOOL_WRAPPERGENERATOR) $(@D)/sun/awt/X11 $(GENSRC_SIZER_SRC)/xlibtypes.txt "gen" $(GENSRC_X11WRAPPERS_TMP)/sizer/sizes $(TOOL_WRAPPERGENERATOR) $(@D)/sun/awt/X11 $(GENSRC_SIZER_SRC)/xlibtypes.txt "gen" $(GENSRC_X11WRAPPERS_TMP)/sizer/sizes
ifeq ($(OPENJDK_TARGET_OS)-$(LIBARCH), solaris-amd64) ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU), solaris-x86_64)
$(ECHO) COMPARING $(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.64 and $(GENSRC_SIZER_SRC)/sizes.64-$(OPENJDK_TARGET_OS)-i386 # On solaris-x86_64, as a safety measure, compare the generated file with the checked-in version
$(DIFF) $(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.64 $(GENSRC_SIZER_SRC)/sizes.64-$(OPENJDK_TARGET_OS)-i386 $(ECHO) COMPARING $(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.64 and $(GENSRC_SIZER_SRC)/sizes.64-solaris-i386
$(DIFF) $(GENSRC_X11WRAPPERS_TMP)/sizer/sizes.64 $(GENSRC_SIZER_SRC)/sizes.64-solaris-i386
endif endif
$(TOUCH) $@ $(TOUCH) $@
......
...@@ -32,11 +32,21 @@ default: images ...@@ -32,11 +32,21 @@ default: images
include Tools.gmk include Tools.gmk
images: jre-image jdk-image # Note: This double-colon rule is intentional, to support
# custom make file integration.
images:: jre-image jdk-image
overlay-images: jre-overlay-image jdk-overlay-image
-include $(CUSTOM_MAKE_DIR)/Images.gmk
ifeq ($(OPENJDK_TARGET_OS),solaris) ifeq ($(OPENJDK_TARGET_OS),solaris)
# On Solaris, if the target is a symlink and exists, cp won't overwrite.
define install-file define install-file
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) '$@'
$(CP) -f -r -P '$<' '$(@D)' $(CP) -f -r -P '$<' '$(@D)'
endef endef
else ifeq ($(OPENJDK_TARGET_OS),macosx) else ifeq ($(OPENJDK_TARGET_OS),macosx)
...@@ -51,11 +61,34 @@ define install-file ...@@ -51,11 +61,34 @@ define install-file
endef endef
endif endif
# Processing license files from source area to image area
# These will be modified to have the platform specific EOL chars.
define process-doc-file
$(ECHO) Processing $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(MKDIR) -p $(@D)
$(RM) $@
$(SED) 's/$$//g' $< > $@
$(CHMOD) 444 $@
endef
JDK_IMAGE_DIR:=$(IMAGES_OUTPUTDIR)/j2sdk-image
JRE_IMAGE_DIR:=$(IMAGES_OUTPUTDIR)/j2re-image
JDK_OVERLAY_IMAGE_DIR:=$(IMAGES_OUTPUTDIR)/j2sdk-overlay-image
JRE_OVERLAY_IMAGE_DIR:=$(IMAGES_OUTPUTDIR)/j2re-overlay-image
################################################################################ ################################################################################
# #
# JRE and JDK build rules # JRE and JDK build rules
# #
################################################################################ ################################################################################
#
# Variable prefixes explained:
# JRE_ refers to files in the j2re-image.
# JDK_ refers to files in the j2sdk-image outside of the jre subdir.
# JDKJRE_ refers to files in the j2sdk-image inside the jre subdir.
#
################################################################################ ################################################################################
# /bin dir # /bin dir
...@@ -72,6 +105,19 @@ $(JDK_IMAGE_DIR)/jre/bin/%: $(JDK_OUTPUTDIR)/bin/% ...@@ -72,6 +105,19 @@ $(JDK_IMAGE_DIR)/jre/bin/%: $(JDK_OUTPUTDIR)/bin/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(install-file) $(install-file)
# Overaly image targets
$(JRE_OVERLAY_IMAGE_DIR)/bin/%: $(JDK_OUTPUTDIR)/bin/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(install-file)
$(JDK_OVERLAY_IMAGE_DIR)/bin/%: $(JDK_OUTPUTDIR)/bin/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(install-file)
$(JDK_OVERLAY_IMAGE_DIR)/jre/bin/%: $(JDK_OUTPUTDIR)/bin/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(install-file)
NOT_JRE_BIN_FILES := \ NOT_JRE_BIN_FILES := \
appletviewer$(EXE_SUFFIX) \ appletviewer$(EXE_SUFFIX) \
extcheck$(EXE_SUFFIX) \ extcheck$(EXE_SUFFIX) \
...@@ -107,26 +153,54 @@ NOT_JRE_BIN_FILES := \ ...@@ -107,26 +153,54 @@ NOT_JRE_BIN_FILES := \
WINDOWS_JDK_BIN_FILES = \ WINDOWS_JDK_BIN_FILES = \
$(EXE_SUFFIX) \ $(EXE_SUFFIX) \
$(LIB_PREFIX)jli$(SHARED_LIBRARY_SUFFIX) \ $(LIBRARY_PREFIX)jli$(SHARED_LIBRARY_SUFFIX) \
$(MSVCRNN_DLL) $(notdir $(MSVCRNN_DLL))
WINDOWS_JDKJRE_BIN_FILES := \
$(LIBRARY_PREFIX)attach$(SHARED_LIBRARY_SUFFIX) \
$(SALIB_NAME)
# Find all files in bin dir # Find all files in bin dir
ALL_BIN_LIST := $(shell $(FIND) $(JDK_OUTPUTDIR)/bin -type f) ALL_BIN_LIST := $(shell $(FIND) $(JDK_OUTPUTDIR)/bin -type f)
# For unknown reason the debuginfo files for binaries are not put into images # For unknown reason the debuginfo files for executables are not put into images
# e.g filter them out # e.g filter them out
ALL_BIN_LIST := $(filter-out %.debuginfo %.diz, $(ALL_BIN_LIST)) ifneq ($(OPENJDK_TARGET_OS),windows)
ALL_BIN_LIST := $(filter-out %.debuginfo %.diz, $(ALL_BIN_LIST))
else
# On windows, the libraries are in the bin dir, only filter out debuginfo files
# for executables. "java" is both a library and executable.
ALL_BIN_EXEC_FILES := $(filter-out java.exe,$(notdir $(shell $(FIND) $(JDK_OUTPUTDIR)/bin -type f -name "*.exe")))
ALL_BIN_DEBUG_FILTER := $(addprefix %,$(patsubst %.exe,%.debuginfo,$(ALL_BIN_EXEC_FILES)) \
$(patsubst %.exe,%.diz,$(ALL_BIN_EXEC_FILES))) %.pdb
ALL_BIN_LIST := $(filter-out $(ALL_BIN_DEBUG_FILTER),$(ALL_BIN_LIST))
endif
ifeq ($(OPENJDK_TARGET_OS),windows) ifeq ($(OPENJDK_TARGET_OS),windows)
JDK_BIN_LIST := $(filter $(addprefix %,$(WINDOWS_JDK_BIN_FILES)), $(ALL_BIN_LIST)) JDK_BIN_LIST := $(filter $(addprefix %,$(WINDOWS_JDK_BIN_FILES)), $(ALL_BIN_LIST))
else else
JDK_BIN_LIST := $(ALL_BIN_LIST) JDK_BIN_LIST := $(ALL_BIN_LIST)
endif endif
JRE_BIN_LIST := $(filter-out $(addprefix %,$(NOT_JRE_BIN_FILES)), $(ALL_BIN_LIST)) JDKJRE_BIN_LIST := $(filter-out $(addprefix %,$(NOT_JRE_BIN_FILES)), $(ALL_BIN_LIST))
JRE_BIN_LIST := $(filter-out $(addprefix %,$(WINDOWS_JDKJRE_BIN_FILES)), $(JDKJRE_BIN_LIST))
ifneq ($(OPENJDK_TARGET_CPU_ISADIR),)
OVERLAY_FILTER := $(JDK_OUTPUTDIR)/bin$(OPENJDK_TARGET_CPU_ISADIR)%
endif
JRE_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JRE_IMAGE_DIR)/%, \
$(filter-out $(OVERLAY_FILTER),$(JRE_BIN_LIST)))
JDK_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_IMAGE_DIR)/%, \
$(filter-out $(OVERLAY_FILTER),$(JDK_BIN_LIST)))
JDKJRE_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_IMAGE_DIR)/jre/%, \
$(filter-out $(OVERLAY_FILTER),$(JDKJRE_BIN_LIST)))
JRE_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JRE_IMAGE_DIR)/%, $(JRE_BIN_LIST)) JRE_OVERLAY_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JRE_OVERLAY_IMAGE_DIR)/%, \
JDK_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_IMAGE_DIR)/%, $(JDK_BIN_LIST)) $(filter $(OVERLAY_FILTER),$(JRE_BIN_LIST)))
JDKJRE_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_IMAGE_DIR)/jre/%, $(JRE_BIN_LIST)) JDK_OVERLAY_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_OVERLAY_IMAGE_DIR)/%, \
$(filter $(OVERLAY_FILTER),$(JDK_BIN_LIST)))
JDKJRE_OVERLAY_BIN_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_OVERLAY_IMAGE_DIR)/jre/%, \
$(filter $(OVERLAY_FILTER),$(JDKJRE_BIN_LIST)))
################################################################################ ################################################################################
# /lib dir # /lib dir
...@@ -143,9 +217,24 @@ $(JDK_IMAGE_DIR)/jre/lib/%: $(JDK_OUTPUTDIR)/lib/% ...@@ -143,9 +217,24 @@ $(JDK_IMAGE_DIR)/jre/lib/%: $(JDK_OUTPUTDIR)/lib/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(install-file) $(install-file)
JDKJRE_LIB_FILES := \ # Overlay image targets
$(LIB_PREFIX)attach$(SHARED_LIBRARY_SUFFIX) \ $(JRE_OVERLAY_IMAGE_DIR)/lib/%: $(JDK_OUTPUTDIR)/lib/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(install-file)
$(JDK_OVERLAY_IMAGE_DIR)/lib/%: $(JDK_OUTPUTDIR)/lib/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(install-file)
$(JDK_OVERLAY_IMAGE_DIR)/jre/lib/%: $(JDK_OUTPUTDIR)/lib/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(install-file)
ifneq ($(OPENJDK_TARGET_OS), macosx)
JDKJRE_LIB_FILES := \
$(LIBRARY_PREFIX)attach$(SHARED_LIBRARY_SUFFIX) \
$(SALIB_NAME) $(SALIB_NAME)
endif
NOT_JRE_LIB_FILES := \ NOT_JRE_LIB_FILES := \
tools.jar \ tools.jar \
...@@ -156,12 +245,16 @@ NOT_JRE_LIB_FILES := \ ...@@ -156,12 +245,16 @@ NOT_JRE_LIB_FILES := \
ir.idl \ ir.idl \
ct.sym ct.sym
ifeq ($(OPENJDK_TARGET_OS), windows)
NOT_JRE_LIB_FILES += jawt.lib jvm.lib
endif
JDK_LIB_FILES := $(NOT_JRE_LIB_FILES) JDK_LIB_FILES := $(NOT_JRE_LIB_FILES)
ifeq ($(OPENJDK_TARGET_OS), linux) ifeq ($(OPENJDK_TARGET_OS), linux)
JDK_LIB_FILES += jexec JDK_LIB_FILES += jexec
endif endif
ALL_LIB_LIST := $(shell $(FIND) $(JDK_OUTPUTDIR)/lib \( -type f -o -type l \) ! -name "_the*") ALL_LIB_LIST := $(shell $(FIND) $(JDK_OUTPUTDIR)/lib \( -type f -o -type l \) -a ! \( -name "_the*" -o -name "javac_state " \) )
JRE_LIB_LIST := $(filter-out $(addprefix %,$(NOT_JRE_LIB_FILES) $(JDKJRE_LIB_FILES)),$(ALL_LIB_LIST)) JRE_LIB_LIST := $(filter-out $(addprefix %,$(NOT_JRE_LIB_FILES) $(JDKJRE_LIB_FILES)),$(ALL_LIB_LIST))
JDKJRE_LIB_LIST := $(filter-out $(addprefix %,$(NOT_JRE_LIB_FILES)),$(ALL_LIB_LIST)) JDKJRE_LIB_LIST := $(filter-out $(addprefix %,$(NOT_JRE_LIB_FILES)),$(ALL_LIB_LIST))
JDK_LIB_LIST := $(filter $(addprefix %,$(JDK_LIB_FILES)),$(ALL_LIB_LIST)) JDK_LIB_LIST := $(filter $(addprefix %,$(JDK_LIB_FILES)),$(ALL_LIB_LIST))
...@@ -170,6 +263,13 @@ JRE_LIB_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JRE_IMAGE_DIR)/%,$(JRE_LIB_LI ...@@ -170,6 +263,13 @@ JRE_LIB_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JRE_IMAGE_DIR)/%,$(JRE_LIB_LI
JDK_LIB_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_IMAGE_DIR)/%,$(JDK_LIB_LIST)) JDK_LIB_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_IMAGE_DIR)/%,$(JDK_LIB_LIST))
JDKJRE_LIB_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_IMAGE_DIR)/jre/%,$(JDKJRE_LIB_LIST)) JDKJRE_LIB_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/%,$(JDK_IMAGE_DIR)/jre/%,$(JDKJRE_LIB_LIST))
JRE_OVERLAY_LIB_TARGETS := $(subst $(JRE_IMAGE_DIR),$(JRE_OVERLAY_IMAGE_DIR),\
$(filter $(JRE_IMAGE_DIR)/lib$(OPENJDK_TARGET_CPU_ISADIR)/%,$(JRE_LIB_TARGETS)))
JDK_OVERLAY_LIB_TARGETS := $(subst $(JDK_IMAGE_DIR),$(JDK_OVERLAY_IMAGE_DIR),\
$(filter $(JDK_IMAGE_DIR)/lib$(OPENJDK_TARGET_CPU_ISADIR)/%,$(JDK_LIB_TARGETS)))
JDKJRE_OVERLAY_LIB_TARGETS := $(subst $(JDK_IMAGE_DIR),$(JDK_OVERLAY_IMAGE_DIR),\
$(filter $(JDK_IMAGE_DIR)/jre/lib$(OPENJDK_TARGET_CPU_ISADIR)/%,$(JDKJRE_LIB_TARGETS)))
# CTE plugin security change require new empty directory lib/applet # CTE plugin security change require new empty directory lib/applet
$(JRE_IMAGE_DIR)/lib/applet: $(JRE_IMAGE_DIR)/lib/applet:
$(ECHO) Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
...@@ -179,19 +279,20 @@ $(JDK_IMAGE_DIR)/jre/lib/applet: ...@@ -179,19 +279,20 @@ $(JDK_IMAGE_DIR)/jre/lib/applet:
$(ECHO) Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(MKDIR) -p $@ $(MKDIR) -p $@
# In the old build, JObjC.jar is not part of the meta-index
$(JRE_IMAGE_DIR)/lib/meta-index: $(JRE_LIB_TARGETS) $(JRE_IMAGE_DIR)/lib/meta-index: $(JRE_LIB_TARGETS)
$(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(CD) $(@D) && $(TOOL_BUILDMETAINDEX) -o meta-index *.jar $(CD) $(@D) && $(TOOL_BUILDMETAINDEX) -o meta-index `$(LS) *.jar | $(SED) 's/JObjC\.jar//g'`
$(JDK_IMAGE_DIR)/jre/lib/meta-index: $(JDKJRE_LIB_TARGETS) $(JDK_IMAGE_DIR)/jre/lib/meta-index: $(JDKJRE_LIB_TARGETS)
$(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(CD) $(@D) && $(TOOL_BUILDMETAINDEX) -o meta-index *.jar $(CD) $(@D) && $(TOOL_BUILDMETAINDEX) -o meta-index `$(LS) *.jar | $(SED) 's/JObjC\.jar//g'`
$(JRE_IMAGE_DIR)/lib/ext/meta-index: $(JRE_LIB_TARGETS) $(JRE_IMAGE_DIR)/lib/ext/meta-index: $(JRE_LIB_TARGETS)
$(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(CD) $(@D) && $(TOOL_BUILDMETAINDEX) -o meta-index *.jar $(CD) $(@D) && $(TOOL_BUILDMETAINDEX) -o meta-index *.jar
$(JDK_IMAGE_DIR)/jre/lib/ext/meta-index: $(JRE_LIB_TARGETS) $(JDK_IMAGE_DIR)/jre/lib/ext/meta-index: $(JDKJRE_LIB_TARGETS)
$(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(CD) $(@D) && $(TOOL_BUILDMETAINDEX) -o meta-index *.jar $(CD) $(@D) && $(TOOL_BUILDMETAINDEX) -o meta-index *.jar
...@@ -378,12 +479,12 @@ endif ...@@ -378,12 +479,12 @@ endif
# /demo dir # /demo dir
ifndef NO_DEMOS ifndef NO_DEMOS
# FIXME: newdemo/applets/GraphLayout/GraphPanel$2.class is sometimes not copied. # FIXME: demo/applets/GraphLayout/GraphPanel$2.class is sometimes not copied.
# The db demo contains an empty dir that needs to be copied. The other # The db demo contains an empty dir that needs to be copied. The other
# directories will always trigger the rule for recompile since # directories will always trigger the rule for recompile since
# _the.list_of_packages files are touched. # _the.list_of_packages files are touched.
$(JDK_IMAGE_DIR)/demo/%: $(JDK_OUTPUTDIR)/newdemo/% $(JDK_IMAGE_DIR)/demo/%: $(JDK_OUTPUTDIR)/demo/%
if [ ! -d "$@" ]; then \ if [ ! -d "$@" ]; then \
$(ECHO) Copying '$(patsubst $(OUTPUT_ROOT)/%,%,$@)'; \ $(ECHO) Copying '$(patsubst $(OUTPUT_ROOT)/%,%,$@)'; \
$(MKDIR) -p $(@D); \ $(MKDIR) -p $(@D); \
...@@ -391,8 +492,25 @@ ifndef NO_DEMOS ...@@ -391,8 +492,25 @@ ifndef NO_DEMOS
fi fi
# Find all files including directories # Find all files including directories
JDK_DEMO_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/newdemo/%,$(JDK_IMAGE_DIR)/demo/%,\ JDK_DEMO_TARGETS := $(patsubst $(JDK_OUTPUTDIR)/demo/%,$(JDK_IMAGE_DIR)/demo/%,\
$(shell $(FIND) $(JDK_OUTPUTDIR)/newdemo ! -name "_the.*")) $(shell $(FIND) $(JDK_OUTPUTDIR)/demo ! \( -name "_the*" -o -name "javac_state" \) ))
# Param 1 is source file
define CreateOverlayDemoRule
$1_TARGET:=$$(subst $(JDK_OUTPUTDIR),$(JDK_OVERLAY_IMAGE_DIR),\
$$(dir $1)$(OPENJDK_TARGET_CPU_ISADIR)/$$(notdir $1))
$$($1_TARGET): $1
$(ECHO) Copying '$$(patsubst $(OUTPUT_ROOT)/%,%,$$@)'
$(MKDIR) -p $$(@D)
$(RM) $$@
$(CP) -f '$$<' '$$@'
JDK_OVERLAY_DEMO_TARGETS += $$($1_TARGET)
endef
JDK_OVERLAY_DEMO_SOURCES := $(shell $(FIND) $(JDK_OUTPUTDIR)/demo -name "*$(SHARED_LIBRARY_SUFFIX)")
$(foreach lib,$(JDK_OVERLAY_DEMO_SOURCES),$(eval $(call CreateOverlayDemoRule,$(lib))))
endif endif
...@@ -471,50 +589,47 @@ JDKJRE_DOC_TARGETS := $(addprefix $(JDK_IMAGE_DIR)/jre/,$(JRE_DOC_FILES)) ...@@ -471,50 +589,47 @@ JDKJRE_DOC_TARGETS := $(addprefix $(JDK_IMAGE_DIR)/jre/,$(JRE_DOC_FILES))
JDK_DOC_TARGETS := $(addprefix $(JDK_IMAGE_DIR)/,$(JDK_DOC_FILES)) JDK_DOC_TARGETS := $(addprefix $(JDK_IMAGE_DIR)/,$(JDK_DOC_FILES))
$(JRE_IMAGE_DIR)/%: $(JRE_DOC_LOCATION)/% $(JRE_IMAGE_DIR)/%: $(JRE_DOC_LOCATION)/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(process-doc-file)
$(install-file)
$(CHMOD) 444 $(@)
$(JDK_IMAGE_DIR)/jre/%: $(JRE_DOC_LOCATION)/% $(JDK_IMAGE_DIR)/jre/%: $(JRE_DOC_LOCATION)/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(process-doc-file)
$(install-file)
$(CHMOD) 444 $(@)
$(JRE_IMAGE_DIR)/README.txt: $(JRE_DOC_LOCATION)/README $(JRE_IMAGE_DIR)/README.txt: $(JRE_DOC_LOCATION)/README
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(process-doc-file)
$(MKDIR) -p $(@D)
$(CP) $< $@
$(CHMOD) 444 $(@)
$(JDK_IMAGE_DIR)/jre/README.txt: $(JRE_DOC_LOCATION)/README $(JDK_IMAGE_DIR)/jre/README.txt: $(JRE_DOC_LOCATION)/README
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(process-doc-file)
$(MKDIR) -p $(@D)
$(CP) $< $@
$(CHMOD) 444 $(@)
$(JDK_IMAGE_DIR)/%: $(JDK_DOC_LOCATION)/% $(JDK_IMAGE_DIR)/%: $(JDK_DOC_LOCATION)/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(process-doc-file)
$(install-file)
$(CHMOD) 444 $(@)
$(JDK_IMAGE_DIR)/demo/%: $(JDK_DOC_LOCATION)/% $(JDK_IMAGE_DIR)/demo/%: $(JDK_DOC_LOCATION)/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(process-doc-file)
$(install-file)
$(CHMOD) 444 $(@)
$(JDK_IMAGE_DIR)/sample/%: $(JDK_DOC_LOCATION)/% $(JDK_IMAGE_DIR)/sample/%: $(JDK_DOC_LOCATION)/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(process-doc-file)
$(install-file)
$(CHMOD) 444 $(@)
JRE_INFO_FILE := $(JRE_IMAGE_DIR)/release JRE_INFO_FILE := $(JRE_IMAGE_DIR)/release
JDK_INFO_FILE := $(JDK_IMAGE_DIR)/release JDK_INFO_FILE := $(JDK_IMAGE_DIR)/release
JRE_OVERLAY_INFO_FILE := $(JRE_OVERLAY_IMAGE_DIR)/release
JDK_OVERLAY_INFO_FILE := $(JDK_OVERLAY_IMAGE_DIR)/release
# Common way to emit a line into the release or info file # Common way to emit a line into the release or info file
define info-file-item # name value define info-file-item # name value
$(PRINTF) '%s="%s"\n' $1 $2 >> $@ $(PRINTF) '%s="%s"\n' $1 $2 >> $@
endef endef
define create-info-file
$(MKDIR) -p $(@D)
$(RM) $@
$(call info-file-item, "JAVA_VERSION", "$(JDK_VERSION)")
$(call info-file-item, "OS_NAME", "$(REQUIRED_OS_NAME)")
$(call info-file-item, "OS_VERSION", "$(REQUIRED_OS_VERSION)")
$(call info-file-item, "OS_ARCH", "$(OPENJDK_TARGET_CPU_LEGACY)")
$(call info-file-item, "SOURCE", "$(ALL_SOURCE_TIPS)")
endef
ALL_SOURCE_TIPS = $(shell \ ALL_SOURCE_TIPS = $(shell \
if [ -f $(OUTPUT_ROOT)/source_tips ] ; then \ if [ -f $(OUTPUT_ROOT)/source_tips ] ; then \
$(CAT) $(OUTPUT_ROOT)/source_tips ; \ $(CAT) $(OUTPUT_ROOT)/source_tips ; \
...@@ -522,23 +637,19 @@ ALL_SOURCE_TIPS = $(shell \ ...@@ -522,23 +637,19 @@ ALL_SOURCE_TIPS = $(shell \
$(JRE_INFO_FILE): $(OUTPUT_ROOT)/spec.gmk $(OUTPUT_ROOT)/source_tips $(JRE_INFO_FILE): $(OUTPUT_ROOT)/spec.gmk $(OUTPUT_ROOT)/source_tips
$(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(MKDIR) -p $(@D) $(call create-info-file)
$(RM) $@
$(call info-file-item, "JAVA_VERSION", "$(JDK_VERSION)")
$(call info-file-item, "OS_NAME", "$(REQUIRED_OS_NAME)")
$(call info-file-item, "OS_VERSION", "$(REQUIRED_OS_VERSION)")
$(call info-file-item, "OS_ARCH", "$(ARCH)")
$(call info-file-item, "SOURCE", "$(ALL_SOURCE_TIPS)")
$(JDK_INFO_FILE): $(OUTPUT_ROOT)/spec.gmk $(OUTPUT_ROOT)/source_tips $(JDK_INFO_FILE): $(OUTPUT_ROOT)/spec.gmk $(OUTPUT_ROOT)/source_tips
$(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(MKDIR) -p $(@D) $(call create-info-file)
$(RM) $@
$(call info-file-item, "JAVA_VERSION", "$(JDK_VERSION)") $(JRE_OVERLAY_INFO_FILE): $(OUTPUT_ROOT)/spec.gmk $(OUTPUT_ROOT)/source_tips
$(call info-file-item, "OS_NAME", "$(REQUIRED_OS_NAME)") $(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(call info-file-item, "OS_VERSION", "$(REQUIRED_OS_VERSION)") $(call create-info-file)
$(call info-file-item, "OS_ARCH", "$(ARCH)")
$(call info-file-item, "SOURCE", "$(ALL_SOURCE_TIPS)") $(JDK_OVERLAY_INFO_FILE): $(OUTPUT_ROOT)/spec.gmk $(OUTPUT_ROOT)/source_tips
$(ECHO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
$(call create-info-file)
$(JDK_IMAGE_DIR)/src.zip: $(IMAGES_OUTPUTDIR)/src.zip $(JDK_IMAGE_DIR)/src.zip: $(IMAGES_OUTPUTDIR)/src.zip
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@)
...@@ -549,51 +660,75 @@ $(JDK_IMAGE_DIR)/src.zip: $(IMAGES_OUTPUTDIR)/src.zip ...@@ -549,51 +660,75 @@ $(JDK_IMAGE_DIR)/src.zip: $(IMAGES_OUTPUTDIR)/src.zip
ifneq ($(POST_STRIP_CMD),) ifneq ($(POST_STRIP_CMD),)
ifeq ($(OPENJDK_TARGET_OS), windows) ifeq ($(OPENJDK_TARGET_OS), windows)
EXEC_LIST:=$(shell $(FIND) $(JDK_OUTPUTDIR)/bin -type f -name \*.exe \ EXEC_LIST_BIN:=$(shell $(FIND) $(JDK_OUTPUTDIR)/bin -type f -name \*.exe \
-o -name \*.dll | $(EGREP) -v -i "$(MSVCRNN_DLL)") -o -name \*.dll | $(EGREP) -v -i "$(MSVCRNN_DLL)")
else else
# Find all executables in JDK_OUTPUTDIR since they exist when this makefile is parsed # Find all executables in JDK_OUTPUTDIR since they exist when this makefile is parsed
EXEC_LIST:=$(shell $(FIND) $(JDK_OUTPUTDIR)/lib -type f -name \*$(SHARED_LIBRARY_SUFFIX) && \ EXEC_LIST_BIN:=$(shell $(FILE) `$(FIND) $(JDK_OUTPUTDIR)/bin -type f -name \*$(EXE_SUFFIX)` \
$(FILE) `$(FIND) $(JDK_OUTPUTDIR)/bin -type f -name \*$(EXE_SUFFIX)` \
| $(EGREP) 'ELF' | $(CUT) -d':' -f1) | $(EGREP) 'ELF' | $(CUT) -d':' -f1)
# On mac, the old build searches for static libraries for stripping instead of shared.
# Not clear if it's intentional.
ifneq ($(OPENJDK_TARGET_OS), macosx)
EXEC_LIST_LIB:=$(shell $(FIND) $(JDK_OUTPUTDIR)/lib -type f -name \*$(SHARED_LIBRARY_SUFFIX))
endif
endif endif
# Filter out the overlay specific bin files
EXEC_LIST:=$(filter-out $(OVERLAY_FILTER),$(EXEC_LIST_BIN)) $(EXEC_LIST_LIB)
EXEC_LIST_OVERLAY:=$(filter $(OVERLAY_FILTER),$(EXEC_LIST_BIN)) $(EXEC_LIST_LIB)
# Filter out non JRE files and convert to unique touch files to depend on # Filter out non JRE files and convert to unique touch files to depend on
JRE_EXEC_TOUCH_LIST:=$(patsubst $(JDK_OUTPUTDIR)/%,$(IMAGES_OUTPUTDIR)/_strip_jre/%.stripped,\ JRE_STRIP_LIST:=$(patsubst $(JDK_OUTPUTDIR)/%,$(IMAGES_OUTPUTDIR)/_strip_jre/%.stripped,\
$(filter-out $(addprefix %,$(NOT_JRE_BIN_FILES) $(NOT_JRE_LIB_FILES)), $(EXEC_LIST))) $(filter-out $(addprefix %,$(NOT_JRE_BIN_FILES) $(NOT_JRE_LIB_FILES) $(JDKJRE_LIB_FILES)),\
$(EXEC_LIST)))
JDK_JRE_EXEC_TOUCH_LIST:=$(patsubst $(JDK_OUTPUTDIR)/%, \ JDKJRE_STRIP_LIST:=$(patsubst $(JDK_OUTPUTDIR)/%, \
$(IMAGES_OUTPUTDIR)/_strip_jdk/jre/%.stripped, \ $(IMAGES_OUTPUTDIR)/_strip_jdk/jre/%.stripped, \
$(filter-out $(addprefix %,$(NOT_JRE_BIN_FILES) $(NOT_JRE_LIB_FILES)), $(EXEC_LIST))) $(filter-out $(addprefix %,$(NOT_JRE_BIN_FILES) $(NOT_JRE_LIB_FILES)), $(EXEC_LIST)))
JDK_BIN_EXEC_TOUCH_LIST := $(patsubst $(JDK_OUTPUTDIR)/%, \ JDK_BIN_STRIP_LIST:=$(patsubst $(JDK_OUTPUTDIR)/%, \
$(IMAGES_OUTPUTDIR)/_strip_jdk/%.stripped, \ $(IMAGES_OUTPUTDIR)/_strip_jdk/%.stripped, \
$(filter-out $(JDK_OUTPUTDIR)/lib/%, $(EXEC_LIST))) $(filter-out $(JDK_OUTPUTDIR)/lib/%, $(EXEC_LIST)))
# Setup a rule for stripping files based on touch files # Do the same for overlay image
$(IMAGES_OUTPUTDIR)/_strip_jre/%.stripped: $(JRE_IMAGE_DIR)/% JRE_OVERLAY_STRIP_LIST:=$(patsubst $(JDK_OUTPUTDIR)/%,$(IMAGES_OUTPUTDIR)/_strip_jre_overlay/%.stripped,\
$(ECHO) Stripping $(patsubst $(OUTPUT_ROOT)/%,%,$<) $(filter-out $(addprefix %,$(NOT_JRE_BIN_FILES) $(NOT_JRE_LIB_FILES) $(JDKJRE_LIB_FILES)),\
$(CHMOD) u+w $< $(EXEC_LIST_OVERLAY)))
$(POST_STRIP_CMD) $<
$(CHMOD) go-w $< JDKJRE_OVERLAY_STRIP_LIST:=$(patsubst $(JDK_OUTPUTDIR)/%, \
$(MKDIR) -p $(@D) $(IMAGES_OUTPUTDIR)/_strip_jdk_overlay/jre/%.stripped, \
$(TOUCH) $@ $(filter-out $(addprefix %,$(NOT_JRE_BIN_FILES) $(NOT_JRE_LIB_FILES)), $(EXEC_LIST_OVERLAY)))
$(IMAGES_OUTPUTDIR)/_strip_jdk/bin/%.stripped: $(JDK_IMAGE_DIR)/bin/% JDK_OVERLAY_BIN_STRIP_LIST:=$(patsubst $(JDK_OUTPUTDIR)/%, \
$(IMAGES_OUTPUTDIR)/_strip_jdk_overlay/%.stripped, \
$(filter-out $(JDK_OUTPUTDIR)/lib/%, $(EXEC_LIST_OVERLAY)))
define mcs-file
$(if $(POST_MCS_CMD),$(POST_MCS_CMD) $<)
endef
define strip-file
$(ECHO) Stripping $(patsubst $(OUTPUT_ROOT)/%,%,$<) $(ECHO) Stripping $(patsubst $(OUTPUT_ROOT)/%,%,$<)
$(CHMOD) u+w $< $(CHMOD) u+w $<
$(POST_STRIP_CMD) $< $(POST_STRIP_CMD) $<
$(call mcs-file)
$(CHMOD) go-w $< $(CHMOD) go-w $<
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(TOUCH) $@ $(TOUCH) $@
endef
# Setup a rule for stripping files based on touch files # Setup a rule for stripping files based on touch files
$(IMAGES_OUTPUTDIR)/_strip_jdk/jre/%.stripped: $(JDK_IMAGE_DIR)/jre/% $(IMAGES_OUTPUTDIR)/_strip_jre/%.stripped: $(JRE_IMAGE_DIR)/%
$(ECHO) Stripping $(patsubst $(OUTPUT_ROOT)/%,%,$<) $(call strip-file)
$(CHMOD) u+w $<
$(POST_STRIP_CMD) $< $(IMAGES_OUTPUTDIR)/_strip_jdk/%.stripped: $(JDK_IMAGE_DIR)/%
$(CHMOD) go-w $< $(call strip-file)
$(MKDIR) -p $(@D)
$(TOUCH) $@ $(IMAGES_OUTPUTDIR)/_strip_jre_overlay/%.stripped: $(JRE_OVERLAY_IMAGE_DIR)/%
$(call strip-file)
$(IMAGES_OUTPUTDIR)/_strip_jdk_overlay/%.stripped: $(JDK_OVERLAY_IMAGE_DIR)/%
$(call strip-file)
endif endif
...@@ -602,7 +737,7 @@ endif ...@@ -602,7 +737,7 @@ endif
jre-image: $(JRE_BIN_TARGETS) $(JRE_LIB_TARGETS) $(JRE_IMAGE_DIR)/lib/applet \ jre-image: $(JRE_BIN_TARGETS) $(JRE_LIB_TARGETS) $(JRE_IMAGE_DIR)/lib/applet \
$(JRE_IMAGE_DIR)/lib/meta-index $(JRE_IMAGE_DIR)/lib/ext/meta-index \ $(JRE_IMAGE_DIR)/lib/meta-index $(JRE_IMAGE_DIR)/lib/ext/meta-index \
$(JRE_MAN_PAGE_LIST) $(JRE_DOC_TARGETS) $(JRE_INFO_FILE) $(JRE_EXEC_TOUCH_LIST) $(JRE_MAN_PAGE_LIST) $(JRE_DOC_TARGETS) $(JRE_INFO_FILE) $(JRE_STRIP_LIST)
jdk-image: $(JDK_BIN_TARGETS) $(JDKJRE_BIN_TARGETS) \ jdk-image: $(JDK_BIN_TARGETS) $(JDKJRE_BIN_TARGETS) \
$(JDK_LIB_TARGETS) $(JDKJRE_LIB_TARGETS) \ $(JDK_LIB_TARGETS) $(JDKJRE_LIB_TARGETS) \
...@@ -612,9 +747,17 @@ jdk-image: $(JDK_BIN_TARGETS) $(JDKJRE_BIN_TARGETS) \ ...@@ -612,9 +747,17 @@ jdk-image: $(JDK_BIN_TARGETS) $(JDKJRE_BIN_TARGETS) \
$(JDK_MAN_PAGE_LIST) $(JDK_SAMPLE_TARGETS) \ $(JDK_MAN_PAGE_LIST) $(JDK_SAMPLE_TARGETS) \
$(JDK_DB_TARGETS) $(JDK_INCLUDE_TARGETS) \ $(JDK_DB_TARGETS) $(JDK_INCLUDE_TARGETS) \
$(JDKJRE_DOC_TARGETS) $(JDK_DOC_TARGETS) \ $(JDKJRE_DOC_TARGETS) $(JDK_DOC_TARGETS) \
$(JDK_INFO_FILE) $(JDK_JRE_EXEC_TOUCH_LIST) $(JDK_BIN_EXEC_TOUCH_LIST) \ $(JDK_INFO_FILE) $(JDKJRE_STRIP_LIST) $(JDK_BIN_STRIP_LIST) \
$(JDK_IMAGE_DIR)/src.zip $(JDK_IMAGE_DIR)/src.zip
jre-overlay-image: $(JRE_OVERLAY_BIN_TARGETS) $(JRE_OVERLAY_LIB_TARGETS) \
$(JRE_OVERLAY_INFO_FILE) $(JRE_OVERLAY_STRIP_LIST)
jdk-overlay-image: $(JDK_OVERLAY_BIN_TARGETS) $(JDKJRE_OVERLAY_BIN_TARGETS) \
$(JDK_OVERLAY_LIB_TARGETS) $(JDKJRE_OVERLAY_LIB_TARGETS) \
$(JDK_OVERLAY_DEMO_TARGETS) $(JDK_OVERLAY_INFO_FILE) \
$(JDKJRE_OVERLAY_STRIP_LIST) $(JDK_OVERLAY_BIN_STRIP_LIST)
################################################################################ ################################################################################
.PHONY: default images jre-image jdk-image .PHONY: default images jre-image jdk-image
...@@ -41,12 +41,8 @@ IMPORT_BINARIES := CORBA ...@@ -41,12 +41,8 @@ IMPORT_BINARIES := CORBA
# Put the libraries here. Different locations for different target apis. # Put the libraries here. Different locations for different target apis.
ifeq ($(OPENJDK_TARGET_OS_API),posix) ifeq ($(OPENJDK_TARGET_OS_API),posix)
ifneq ($(OPENJDK_TARGET_OS),macosx) INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)
INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/lib/$(LIBARCH) HOTSPOT_LIB_DIR:=$(HOTSPOT_DIST)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR)
else
INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/lib
endif
HOTSPOT_LIB_DIR:=$(HOTSPOT_DIST)/jre/lib/$(LIBARCH)
else else
INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/bin INSTALL_LIBRARIES_HERE:=$(JDK_OUTPUTDIR)/bin
HOTSPOT_LIB_DIR:=$(HOTSPOT_DIST)/jre/bin HOTSPOT_LIB_DIR:=$(HOTSPOT_DIST)/jre/bin
...@@ -65,6 +61,7 @@ IMPORT_TARGET_CLASSES += $(JDK_OUTPUTDIR)/classes/_the.$1.classes.imported ...@@ -65,6 +61,7 @@ IMPORT_TARGET_CLASSES += $(JDK_OUTPUTDIR)/classes/_the.$1.classes.imported
$(JDK_OUTPUTDIR)/classes/_the.$1.classes.imported : $$($1_DIST)/lib/classes.jar $$($1_CLASSES_DEP) $(JDK_OUTPUTDIR)/classes/_the.$1.classes.imported : $$($1_DIST)/lib/classes.jar $$($1_CLASSES_DEP)
$(ECHO) Importing $1 classes.jar $(ECHO) Importing $1 classes.jar
$(MKDIR) -p $$(@D) $(MKDIR) -p $$(@D)
$(RM) $$@ $$@.tmp
($(CD) $$(@D) && $(JAR) xvf $$< > $$@.tmp) ($(CD) $$(@D) && $(JAR) xvf $$< > $$@.tmp)
$(MV) $$@.tmp $$@ $(MV) $$@.tmp $$@
endef endef
...@@ -76,6 +73,7 @@ IMPORT_TARGET_SOURCES += $(JDK_OUTPUTDIR)/impsrc/_the.$1.src.imported ...@@ -76,6 +73,7 @@ IMPORT_TARGET_SOURCES += $(JDK_OUTPUTDIR)/impsrc/_the.$1.src.imported
$(JDK_OUTPUTDIR)/impsrc/_the.$1.src.imported : $$($1_DIST)/lib/src.zip $$($1_SOURCES_DEP) $(JDK_OUTPUTDIR)/impsrc/_the.$1.src.imported : $$($1_DIST)/lib/src.zip $$($1_SOURCES_DEP)
$(ECHO) Importing $1 src.zip $(ECHO) Importing $1 src.zip
$(MKDIR) -p $$(@D) $(MKDIR) -p $$(@D)
$(RM) $$@ $$@.tmp
($(CD) $$(@D) && $(JAR) xvf $$< > $$@.tmp) ($(CD) $$(@D) && $(JAR) xvf $$< > $$@.tmp)
$(MV) $$@.tmp $$@ $(MV) $$@.tmp $$@
endef endef
...@@ -87,6 +85,7 @@ IMPORT_TARGET_BINARIES += $(JDK_OUTPUTDIR)/_the.$1.binaries.imported ...@@ -87,6 +85,7 @@ IMPORT_TARGET_BINARIES += $(JDK_OUTPUTDIR)/_the.$1.binaries.imported
$(JDK_OUTPUTDIR)/_the.$1.binaries.imported : $$($1_DIST)/lib/bin.zip $$($1_BINARIES_DEP) $(JDK_OUTPUTDIR)/_the.$1.binaries.imported : $$($1_DIST)/lib/bin.zip $$($1_BINARIES_DEP)
$(ECHO) Importing $1 bin.zip $(ECHO) Importing $1 bin.zip
$(MKDIR) -p $$(@D) $(MKDIR) -p $$(@D)
$(RM) $$@ $$@.tmp
($(CD) $$(@D) && $(JAR) xvf $$< > $$@.tmp) ($(CD) $$(@D) && $(JAR) xvf $$< > $$@.tmp)
$(MV) $$@.tmp $$@ $(MV) $$@.tmp $$@
endef endef
...@@ -103,23 +102,26 @@ IMPORT_TARGET_FILES += $(IMPORT_TARGET_CLASSES) $(IMPORT_TARGET_SOURCES) $(IMPOR ...@@ -103,23 +102,26 @@ IMPORT_TARGET_FILES += $(IMPORT_TARGET_CLASSES) $(IMPORT_TARGET_SOURCES) $(IMPOR
ifeq ($(OPENJDK_TARGET_OS),solaris) ifeq ($(OPENJDK_TARGET_OS),solaris)
define do-install-file define do-install-file
$(MKDIR) -p $$(@D) $(MKDIR) -p '$$(@D)'
$(RM) '$$@'
$(CP) -r -P '$$<' '$$(@D)' $(CP) -r -P '$$<' '$$(@D)'
endef endef
else ifeq ($(OPENJDK_TARGET_OS),macosx) else ifeq ($(OPENJDK_TARGET_OS),macosx)
define do-install-file define do-install-file
$(MKDIR) -p $$(@D) $(MKDIR) -p '$$(@D)'
$(RM) '$$@'
$(CP) -pRP '$$<' '$$@' $(CP) -pRP '$$<' '$$@'
endef endef
else else
define do-install-file define do-install-file
$(MKDIR) -p $$(@D) $(MKDIR) -p '$$(@D)'
$(RM) '$$@'
$(CP) -P '$$<' '$$@' $(CP) -P '$$<' '$$@'
endef endef
endif endif
define CopyDir define CopyDir
$1_SRC_FILES := $(shell $(FIND) $2 -type f) $1_SRC_FILES := $(shell $(FIND) $2 -type f -a ! -name "wb.jar")
$1_DST_FILES := $$(patsubst $2/%,$3/%,$$($1_SRC_FILES)) $1_DST_FILES := $$(patsubst $2/%,$3/%,$$($1_SRC_FILES))
IMPORT_TARGET_FILES += $$($1_DST_FILES) IMPORT_TARGET_FILES += $$($1_DST_FILES)
$3/% : $2/% $3/% : $2/%
...@@ -136,8 +138,8 @@ endef ...@@ -136,8 +138,8 @@ endef
$(eval $(call CopyDir,HOTSPOT0, $(HOTSPOT_LIB_DIR), $(INSTALL_LIBRARIES_HERE))) $(eval $(call CopyDir,HOTSPOT0, $(HOTSPOT_LIB_DIR), $(INSTALL_LIBRARIES_HERE)))
$(eval $(call CopyDir,HOTSPOT1, $(HOTSPOT_DIST)/lib, $(JDK_OUTPUTDIR)/lib)) $(eval $(call CopyDir,HOTSPOT1, $(HOTSPOT_DIST)/lib, $(JDK_OUTPUTDIR)/lib))
JSIG_DEBUGINFO := $(wildcard $(HOTSPOT_DIST)/jre/lib/$(LIBARCH)/libjsig.debuginfo) \ JSIG_DEBUGINFO := $(strip $(wildcard $(HOTSPOT_DIST)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjsig.debuginfo) \
$(wildcard $(HOTSPOT_DIST)/jre/lib/$(LIBARCH)/libjsig.diz) $(wildcard $(HOTSPOT_DIST)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjsig.diz) )
ifneq ($(OPENJDK_TARGET_OS), windows) ifneq ($(OPENJDK_TARGET_OS), windows)
ifeq ($(JVM_VARIANT_SERVER), true) ifeq ($(JVM_VARIANT_SERVER), true)
...@@ -155,64 +157,75 @@ ifneq ($(OPENJDK_TARGET_OS), windows) ...@@ -155,64 +157,75 @@ ifneq ($(OPENJDK_TARGET_OS), windows)
endif endif
$(INSTALL_LIBRARIES_HERE)/server/%$(SHARED_LIBRARY_SUFFIX) : $(INSTALL_LIBRARIES_HERE)/%$(SHARED_LIBRARY_SUFFIX) $(INSTALL_LIBRARIES_HERE)/server/%$(SHARED_LIBRARY_SUFFIX) : $(INSTALL_LIBRARIES_HERE)/%$(SHARED_LIBRARY_SUFFIX)
$(RM) -f $@ $(MKDIR) -p $(@D)
$(RM) $@
$(LN) -s ../$(@F) $@ $(LN) -s ../$(@F) $@
$(INSTALL_LIBRARIES_HERE)/server/%.debuginfo : $(INSTALL_LIBRARIES_HERE)/%.debuginfo $(INSTALL_LIBRARIES_HERE)/server/%.debuginfo : $(INSTALL_LIBRARIES_HERE)/%.debuginfo
$(RM) -f $@ $(MKDIR) -p $(@D)
$(RM) $@
$(LN) -s ../$(@F) $@ $(LN) -s ../$(@F) $@
$(INSTALL_LIBRARIES_HERE)/server/%.diz : $(INSTALL_LIBRARIES_HERE)/%.diz $(INSTALL_LIBRARIES_HERE)/server/%.diz : $(INSTALL_LIBRARIES_HERE)/%.diz
$(RM) -f $@ $(MKDIR) -p $(@D)
$(RM) $@
ifeq (REALLY_WEIRD,1) ifeq (REALLY_WEIRD,1)
$(LN) -s ../$(@F) $@ $(LN) -s ../$(@F) $@
else else
# #
# TODO: Check if this is what they really want...a zip containing a symlink # TODO: Check if this is what they really want...a zip containing a symlink
# #
$(RM) -f $(basename $@).debuginfo $(RM) $@.tmp $(basename $@).debuginfo
$(LN) -s ../$(basename $(@F)).debuginfo $(basename $@).debuginfo $(LN) -s ../$(basename $(@F)).debuginfo $(basename $@).debuginfo
$(ZIP) -q -y $@ $(basename $@).debuginfo $(ZIP) -q -y $@.tmp $(basename $@).debuginfo
$(RM) -f $(basename $@).debuginfo $(RM) $(basename $@).debuginfo
$(MV) $@.tmp $@
endif endif
$(INSTALL_LIBRARIES_HERE)/client/%$(SHARED_LIBRARY_SUFFIX) : $(INSTALL_LIBRARIES_HERE)/%$(SHARED_LIBRARY_SUFFIX) $(INSTALL_LIBRARIES_HERE)/client/%$(SHARED_LIBRARY_SUFFIX) : $(INSTALL_LIBRARIES_HERE)/%$(SHARED_LIBRARY_SUFFIX)
$(RM) -f $@ $(MKDIR) -p $(@D)
$(RM) $@
$(LN) -s ../$(@F) $@ $(LN) -s ../$(@F) $@
$(INSTALL_LIBRARIES_HERE)/client/%.debuginfo : $(INSTALL_LIBRARIES_HERE)/%.debuginfo $(INSTALL_LIBRARIES_HERE)/client/%.debuginfo : $(INSTALL_LIBRARIES_HERE)/%.debuginfo
$(RM) -f $@ $(MKDIR) -p $(@D)
$(RM) $@
$(LN) -s ../$(@F) $@ $(LN) -s ../$(@F) $@
$(INSTALL_LIBRARIES_HERE)/client/%.diz : $(INSTALL_LIBRARIES_HERE)/%.diz $(INSTALL_LIBRARIES_HERE)/client/%.diz : $(INSTALL_LIBRARIES_HERE)/%.diz
$(RM) -f $@ $(MKDIR) -p $(@D)
$(RM) $@
ifeq (REALLY_WEIRD,1) ifeq (REALLY_WEIRD,1)
$(LN) -s ../$(@F) $@ $(LN) -s ../$(@F) $@
else else
# #
# TODO: Check if this is what they really want...a zip containing a symlink # TODO: Check if this is what they really want...a zip containing a symlink
# #
$(RM) -f $(basename $@).debuginfo $(RM) $@.tmp $(basename $@).debuginfo
$(LN) -s ../$(basename $(@F)).debuginfo $(basename $@).debuginfo $(LN) -s ../$(basename $(@F)).debuginfo $(basename $@).debuginfo
$(ZIP) -q -y $@ $(basename $@).debuginfo $(ZIP) -q -y $@.tmp $(basename $@).debuginfo
$(RM) -f $(basename $@).debuginfo $(RM) $(basename $@).debuginfo
$(MV) $@.tmp $@
endif endif
####### #######
ifeq ($(OPENJDK_TARGET_OS),solaris) ifeq ($(OPENJDK_TARGET_OS),solaris)
define install-file define install-file
$(MKDIR) -p $(@D) $(MKDIR) -p '$(@D)'
$(RM) '$@'
$(CP) -r -P '$<' '$(@D)' $(CP) -r -P '$<' '$(@D)'
endef endef
else ifeq ($(OPENJDK_TARGET_OS),macosx) else ifeq ($(OPENJDK_TARGET_OS),macosx)
define install-file define install-file
$(MKDIR) -p $(@D) $(MKDIR) -p '$(@D)'
$(RM) '$@'
$(CP) -pRP '$<' '$@' $(CP) -pRP '$<' '$@'
endef endef
else else
define install-file define install-file
$(MKDIR) -p $(@D) $(MKDIR) -p '$(@D)'
$(RM) '$@'
$(CP) -P '$<' '$@' $(CP) -P '$<' '$@'
endef endef
endif endif
......
...@@ -26,6 +26,11 @@ ...@@ -26,6 +26,11 @@
# This must be the first rule # This must be the first rule
default: all default: all
# Inclusion of this pseudo-target will cause make to execute this file
# serially, regardless of -j. Recursively called makefiles will not be
# affected, however. This is required for correct dependency management.
.NOTPARALLEL:
include $(SPEC) include $(SPEC)
include MakeBase.gmk include MakeBase.gmk
include JavaCompilation.gmk include JavaCompilation.gmk
...@@ -37,39 +42,72 @@ include Setup.gmk ...@@ -37,39 +42,72 @@ include Setup.gmk
# Setup the build tools. # Setup the build tools.
include Tools.gmk include Tools.gmk
all: $(BUILD_TOOLS) import: $(BUILD_TOOLS) import-only
import-only:
# Import (corba jaxp jaxws langtools hotspot) # Import (corba jaxp jaxws langtools hotspot)
+$(MAKE) -f Import.gmk +$(MAKE) -f Import.gmk
#
gensrc: import gensrc-only
gensrc-only:
+$(MAKE) -f GenerateJavaSources.gmk +$(MAKE) -f GenerateJavaSources.gmk
# Ok, now gensrc is fully populated. # Ok, now gensrc is fully populated.
gendata: gensrc gendata-only
gendata-only:
+$(MAKE) -f GenerateData.gmk +$(MAKE) -f GenerateData.gmk
classes: gendata classes-only
classes-only:
+$(MAKE) -f CompileJavaClasses.gmk +$(MAKE) -f CompileJavaClasses.gmk
# The classes are now built and # The classes are now built and
# any javah files have now been generated. # any javah files have now been generated.
libs: classes libs-only
libs-only:
+$(MAKE) -f CompileNativeLibraries.gmk +$(MAKE) -f CompileNativeLibraries.gmk
launchers: libs launchers-only
launchers-only:
# Finally compile the launchers. # Finally compile the launchers.
+$(MAKE) -f CompileLaunchers.gmk +$(MAKE) -f CompileLaunchers.gmk
genclasses: launchers genclasses-only
genclasses-only:
# Generate classes that have other sources. Needs # Generate classes that have other sources. Needs
# to execute launchers. # to execute launchers.
+$(MAKE) -f GenerateClasses.gmk +$(MAKE) -f GenerateClasses.gmk
demos: genclasses demos-only
demos-only:
# Now we have a complete jdk, which you can run. # Now we have a complete jdk, which you can run.
# It is not yet wrapped up as an installed image. # It is not yet wrapped up as an installed image.
# The demos are compiled against this jdk. # The demos are compiled against this jdk.
ifndef NO_DEMOS ifndef NO_DEMOS
+$(MAKE) -f CompileDemos.gmk +$(MAKE) -f CompileDemos.gmk
endif endif
samples: demos samples-only
samples-only:
# Now copy the sample sources into the jdk. # Now copy the sample sources into the jdk.
ifndef NO_SAMPLES ifndef NO_SAMPLES
+$(MAKE) -f CopySamples.gmk +$(MAKE) -f CopySamples.gmk
endif endif
# The all target builds the JDK, but not the images
all: import gensrc gendata classes libs launchers genclasses demos samples
.PHONY: all images install overlay-images import-only gensrc-only gendata-only classes-only
.PHONY: libs-only launchers-only genclasses-only demos-only samples-only
# Create the final jdk and jre images, to be wrapped up # Create the final jdk and jre images, to be wrapped up
# into packages, or installed. # into packages, or installed.
images: images:
+$(MAKE) -f CreateJars.gmk +$(MAKE) -f CreateJars.gmk
+$(MAKE) -f Images.gmk +$(MAKE) -f Images.gmk
overlay-images:
+$(MAKE) -f CompileLaunchers.gmk OVERLAY_IMAGES=true
+$(MAKE) -f Images.gmk overlay-images
BINARIES:=$(shell if test -d $(IMAGES_OUTPUTDIR)/j2sdk-image/bin; then cd $(IMAGES_OUTPUTDIR)/j2sdk-image/bin && $(LS) ; fi) BINARIES:=$(shell if test -d $(IMAGES_OUTPUTDIR)/j2sdk-image/bin; then cd $(IMAGES_OUTPUTDIR)/j2sdk-image/bin && $(LS) ; fi)
INSTALLDIR:=openjdk-$(RELEASE) INSTALLDIR:=openjdk-$(RELEASE)
...@@ -84,5 +122,3 @@ install: images ...@@ -84,5 +122,3 @@ install: images
$(CP) -rp $(IMAGES_OUTPUTDIR)/j2sdk-image/* $(INSTALL_PREFIX)/jvm/$(INSTALLDIR) $(CP) -rp $(IMAGES_OUTPUTDIR)/j2sdk-image/* $(INSTALL_PREFIX)/jvm/$(INSTALLDIR)
$(RM) $(addprefix $(INSTALL_PREFIX)/bin/,$(BINARIES)) $(RM) $(addprefix $(INSTALL_PREFIX)/bin/,$(BINARIES))
$(foreach b,$(BINARIES),$(LN) -s $(INSTALL_PREFIX)/jvm/$(INSTALLDIR)/bin/$b $(INSTALL_PREFIX)/bin/$b &&) true $(foreach b,$(BINARIES),$(LN) -s $(INSTALL_PREFIX)/jvm/$(INSTALLDIR)/bin/$b $(INSTALL_PREFIX)/bin/$b &&) true
.PHONY: all install images
...@@ -36,10 +36,8 @@ $(eval $(call SetupJavaCompiler,GENERATE_OLDBYTECODE,\ ...@@ -36,10 +36,8 @@ $(eval $(call SetupJavaCompiler,GENERATE_OLDBYTECODE,\
JVM:=$(JAVA),\ JVM:=$(JAVA),\
JAVAC:=$(JAVAC_JARS),\ JAVAC:=$(JAVAC_JARS),\
FLAGS:=-source 7 -target 7 -bootclasspath $(BOOT_RTJAR) $(DISABLE_WARNINGS),\ FLAGS:=-source 7 -target 7 -bootclasspath $(BOOT_RTJAR) $(DISABLE_WARNINGS),\
SERVER_DIR:=$(JAVAC_SERVERS),\ SERVER_DIR:=$(SJAVAC_SERVER_DIR),\
SERVER_JVM:=$(SERVER_JAVA),\ SERVER_JVM:=$(SJAVAC_SERVER_JAVA)))
MODE:=$(JAVAC_USE_MODE),\
USE_DEPS:=$(JAVAC_USE_DEPS)))
# The generate new bytecode javac setup uses the new compiler to compile for the # The generate new bytecode javac setup uses the new compiler to compile for the
# new jdk. This new bytecode might only be possible to run using the new jvm. # new jdk. This new bytecode might only be possible to run using the new jvm.
...@@ -47,11 +45,9 @@ $(eval $(call SetupJavaCompiler,GENERATE_JDKBYTECODE,\ ...@@ -47,11 +45,9 @@ $(eval $(call SetupJavaCompiler,GENERATE_JDKBYTECODE,\
JVM:=$(JAVA),\ JVM:=$(JAVA),\
JAVAC:=$(JAVAC_JARS),\ JAVAC:=$(JAVAC_JARS),\
JAVAH:=$(JAVAH_JARS),\ JAVAH:=$(JAVAH_JARS),\
FLAGS:=-bootclasspath "$(JDK_OUTPUTDIR)/classes" -Xprefer:source -XDignore.symbol.file=true $(DISABLE_WARNINGS),\ FLAGS:=-bootclasspath $(JDK_OUTPUTDIR)/classes -source 7 -target 7 -encoding ascii -XDignore.symbol.file=true $(DISABLE_WARNINGS),\
SERVER_DIR:=$(JAVAC_SERVERS),\ SERVER_DIR:=$(SJAVAC_SERVER_DIR),\
SERVER_JVM:=$(SERVER_JAVA),\ SERVER_JVM:=$(SJAVAC_SERVER_JAVA)))
MODE:=$(JAVAC_USE_MODE),\
USE_DEPS:=$(JAVAC_USE_DEPS)))
# After the jdk is built, we want to build demos using only the recently # After the jdk is built, we want to build demos using only the recently
# generated jdk classes and nothing else, no jdk source, etc etc. # generated jdk classes and nothing else, no jdk source, etc etc.
...@@ -60,19 +56,6 @@ $(eval $(call SetupJavaCompiler,GENERATE_JDKBYTECODE,\ ...@@ -60,19 +56,6 @@ $(eval $(call SetupJavaCompiler,GENERATE_JDKBYTECODE,\
$(eval $(call SetupJavaCompiler,GENERATE_USINGJDKBYTECODE,\ $(eval $(call SetupJavaCompiler,GENERATE_USINGJDKBYTECODE,\
JVM:=$(JAVA),\ JVM:=$(JAVA),\
JAVAC:=$(JAVAC_JARS),\ JAVAC:=$(JAVAC_JARS),\
FLAGS:= -Xbootclasspath:$(JDK_OUTPUTDIR)/classes $(DISABLE_WARNINGS),\ FLAGS:=-bootclasspath $(JDK_OUTPUTDIR)/classes $(DISABLE_WARNINGS),\
SERVER_DIR:=$(JAVAC_SERVERS),\ SERVER_DIR:=$(SJAVAC_SERVER_DIR),\
SERVER_JVM:=$(SERVER_JAVA),\ SERVER_JVM:=$(SJAVAC_SERVER_JAVA)))
MODE:=$(JAVAC_USE_MODE),\
USE_DEPS:=$(JAVAC_USE_DEPS)))
# A temporary solution to work around the fact that Matrix3D.java
# exists in several applets. The javacserver does not like to be
# fed the same class twice. Thus we compile one applet outside of the
# javacserver.
$(eval $(call SetupJavaCompiler,GENERATE_USINGJDKBYTECODE_NOSERV,\
JVM:=$(JAVA),\
JAVAC:=$(JAVAC_JARS),\
FLAGS:= -Xbootclasspath:$(JDK_OUTPUTDIR)/classes $(DISABLE_WARNINGS),\
MODE:=SINGLE_THREADED_BATCH,\
USE_DEPS:=FALSE))
...@@ -134,8 +134,8 @@ TOOL_CLDRCONVERTER=$(JAVA) -cp $(JDK_OUTPUTDIR)/btclasses \ ...@@ -134,8 +134,8 @@ TOOL_CLDRCONVERTER=$(JAVA) -cp $(JDK_OUTPUTDIR)/btclasses \
$(eval $(call SetupNativeCompilation,ADD_GNU_DEBUGLINK,\ $(eval $(call SetupNativeCompilation,ADD_GNU_DEBUGLINK,\
SRC:=$(JDK_TOPDIR)/make/tools/add_gnu_debuglink,\ SRC:=$(JDK_TOPDIR)/make/tools/add_gnu_debuglink,\
LANG:=C,\ LANG:=C,\
CC:=$(HOST_CC),\ CC:=$(BUILD_CC),\
LDEXE:=$(HOST_LD),\ LDEXE:=$(BUILD_LD),\
LDFLAGS:=-lelf,\ LDFLAGS:=-lelf,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/add_gnu_debuglink,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/add_gnu_debuglink,\
OUTPUT_DIR:=$(JDK_OUTPUTDIR)/btbin,\ OUTPUT_DIR:=$(JDK_OUTPUTDIR)/btbin,\
...@@ -144,8 +144,8 @@ $(eval $(call SetupNativeCompilation,ADD_GNU_DEBUGLINK,\ ...@@ -144,8 +144,8 @@ $(eval $(call SetupNativeCompilation,ADD_GNU_DEBUGLINK,\
$(eval $(call SetupNativeCompilation,FIX_EMPTY_SEC_HDR_FLAGS,\ $(eval $(call SetupNativeCompilation,FIX_EMPTY_SEC_HDR_FLAGS,\
SRC:=$(JDK_TOPDIR)/make/tools/fix_empty_sec_hdr_flags,\ SRC:=$(JDK_TOPDIR)/make/tools/fix_empty_sec_hdr_flags,\
LANG:=C,\ LANG:=C,\
CC:=$(HOST_CC),\ CC:=$(BUILD_CC),\
LDEXE:=$(HOST_LD),\ LDEXE:=$(BUILD_LD),\
LDFLAGS:=-lelf,\ LDFLAGS:=-lelf,\
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/fix_empty_sec_hdr_flags,\ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/fix_empty_sec_hdr_flags,\
OUTPUT_DIR:=$(JDK_OUTPUTDIR)/btbin,\ OUTPUT_DIR:=$(JDK_OUTPUTDIR)/btbin,\
......
# #
# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
...@@ -22,55 +22,27 @@ ...@@ -22,55 +22,27 @@
# or visit www.oracle.com if you need additional information or have any # or visit www.oracle.com if you need additional information or have any
# questions. # questions.
# #
#
# Variable definitions for SE Embedded builds. This file should
# not contain rules.
# #
ifdef JAVASE_EMBEDDED # Specify what global symbols we export. Note that we're not really
# interested in declaring a version, simply scoping the file is sufficient.
# Compress jar files #
COMPRESS_JARS = true
SUNWprivate_1.1 {
# Don't mmap zip files global:
LIBZIP_CAN_USE_MMAP = false main; # Provides basic adb symbol offsets
environ; # Public symbols and required by Java run time
# Disable ALSA version check _environ;
REQUIRED_ALSA_VERSION = __environ_lock;
___Argv; # The following are private, but as they are
# Compilation settings _start; # exported from ctr1/crtn, the clever hacker
OTHER_CPPFLAGS += -DJAVASE_EMBEDDED _init; # might know about them. However note, that
_fini; # their use is strictly not supported.
# Product naming _lib_version;
PRODUCT_SUFFIX = SE Embedded Runtime Environment # _mcount;
RUNTIME_NAME = $(PRODUCT_NAME) $(PRODUCT_SUFFIX) __fsr;
__fsr_init_value;
# Reduced JRE locations __longdouble_used;
JRE_REDUCED_HEADLESS_IMAGE_DIR = $(ABS_OUTPUTDIR)/j2re-reduced-headless-image
JRE_REDUCED_IMAGE_DIR = $(ABS_OUTPUTDIR)/j2re-reduced-image local:
*;
# Override on linux to further reduce binary/lib sizes in product build };
ifeq ($(PLATFORM), linux)
ifeq ($(VARIANT), OPT)
ifneq ($(NO_STRIP), true)
ifneq ($(DEBUG_BINARIES), true)
POST_STRIP_PROCESS = $(STRIP) --strip-unneeded
endif
endif
endif
endif
# NIO Platform specific source file location
ifdef CROSS_COMPILE_ARCH
NIO_PLATFORM_CLASSES_ROOT_DIR = $(CLOSED_PLATFORM_SRC)/classes/
endif
# For ARM sflt we need to link to a library with improved FP accuracy
# and it must be linked after fdlibm - this places it at the end after libc
# -z muldefs avoids linker errors for duplicate symbols.
ifeq ($(CROSS_COMPILE_ARCH), arm)
EXTRA_LIBS += $(EXT_LIBS_PATH)/sflt_glibc_jdk.a -Xlinker -z -Xlinker muldefs
endif
endif # JAVASE_EMBEDDED
#
# 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. 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.
#
#
# Specify what global symbols we export. Note that we're not really
# interested in declaring a version, simply scoping the file is sufficient.
#
SUNWprivate_1.1 {
global:
main; # Provides basic adb symbol offsets
environ; # Public symbols and required by Java run time
_environ;
__environ_lock;
local:
*;
};
...@@ -285,6 +285,8 @@ SUNWprivate_1.1 { ...@@ -285,6 +285,8 @@ SUNWprivate_1.1 {
# Java_sun_misc_VM_unsuspendSomeThreads; threads.c # Java_sun_misc_VM_unsuspendSomeThreads; threads.c
# Java_sun_misc_VM_unsuspendThreads; threads.c # Java_sun_misc_VM_unsuspendThreads; threads.c
Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getPattern;
# Outcalls from libjvm done using dlsym(). # Outcalls from libjvm done using dlsym().
VerifyClassCodes; VerifyClassCodes;
......
data = R0x2000;
text = LOAD ?RXO;
# Test Null
text: .text%_init;
text: .text%init64IO: OUTPUTDIR/UnixFileSystem_md.o;
text: .text%JNI_OnLoad;
text: .text%Canonicalize;
text: .text%canonicalize;
text: .text%collapse: OUTPUTDIR/canonicalize_md.o;
text: .text%Java_java_lang_Object_registerNatives;
text: .text%Java_java_lang_System_registerNatives;
text: .text%Java_java_lang_Thread_registerNatives;
text: .text%Java_java_security_AccessController_getStackAccessControlContext;
text: .text%Java_java_security_AccessController_getInheritedAccessControlContext;
text: .text%Java_java_lang_ClassLoader_registerNatives;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedAction_2;
text: .text%Java_java_lang_Class_registerNatives;
text: .text%Java_java_lang_Class_getPrimitiveClass;
text: .text%Java_java_lang_System_initProperties;
text: .text%GetJavaProperties;
text: .text%uname: OUTPUTDIR/java_props_md.o;
text: .text%mapLookup: OUTPUTDIR/java_props_md.o;
text: .text%setPathEnvironment: OUTPUTDIR/java_props_md.o;
text: .text%JNU_NewStringPlatform;
text: .text%JNU_CallStaticMethodByName;
text: .text%NewStringPlatform;
text: .text%Java_java_io_FileInputStream_initIDs;
text: .text%Java_java_io_FileDescriptor_initIDs;
text: .text%Java_java_io_FileOutputStream_initIDs;
text: .text%Java_java_lang_System_setIn0;
text: .text%Java_sun_reflect_Reflection_getCallerClass;
text: .text%Java_java_lang_Class_forName0;
text: .text%Java_java_lang_String_intern;
text: .text%Java_sun_reflect_NativeConstructorAccessorImpl_newInstance0;
text: .text%Java_java_lang_Throwable_fillInStackTrace;
text: .text%Java_java_lang_System_setOut0;
text: .text%Java_java_lang_System_setErr0;
text: .text%Java_java_lang_Compiler_registerNatives;
text: .text%Java_java_io_FileSystem_getFileSystem;
text: .text%JNU_NewObjectByName;
text: .text%Java_java_io_UnixFileSystem_initIDs;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedExceptionAction_2;
text: .text%Java_java_io_UnixFileSystem_list;
text: .text%JNU_GetStringPlatformChars;
text: .text%JNU_ReleaseStringPlatformChars;
text: .text%JNU_ClassString;
text: .text%JNU_CopyObjectArray;
text: .text%Java_java_io_UnixFileSystem_canonicalize;
text: .text%Java_java_io_UnixFileSystem_getBooleanAttributes0;
text: .text%Java_java_lang_ClassLoader_findLoadedClass;
text: .text%Java_java_lang_ClassLoader_findBootstrapClass;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedExceptionAction_2Ljava_security_AccessControlContext_2;
text: .text%Java_java_lang_System_mapLibraryName;
text: .text%cpchars: OUTPUTDIR/System.o;
text: .text%Java_java_lang_ClassLoader_00024NativeLibrary_load;
text: .text%Java_java_lang_ClassLoader_00024NativeLibrary_find;
text: .text%Java_java_lang_Float_floatToIntBits;
text: .text%Java_java_lang_Double_doubleToLongBits;
text: .text%Java_java_io_FileInputStream_open;
text: .text%fileOpen;
text: .text%Java_java_io_UnixFileSystem_getLength;
text: .text%Java_java_io_FileInputStream_readBytes;
text: .text%readBytes;
text: .text%Java_java_io_FileInputStream_close0;
text: .text%Java_java_lang_Object_getClass;
text: .text%Java_java_lang_ClassLoader_defineClass0;
text: .text%VerifyClassCodes;
# Test Exit
text: .text%Java_java_lang_Shutdown_halt;
# Test Hello
text: .text%Java_java_io_FileOutputStream_writeBytes;
text: .text%writeBytes;
# Test Sleep
# Test IntToString
# Test LoadToolkit
text: .text%Java_java_util_ResourceBundle_getClassContext;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedAction_2Ljava_security_AccessControlContext_2;
text: .text%JNU_GetEnv;
text: .text%Java_java_io_UnixFileSystem_checkAccess;
text: .text%Java_sun_reflect_NativeMethodAccessorImpl_invoke0;
text: .text%Java_java_lang_ref_Finalizer_invokeFinalizeMethod;
text: .text%Java_java_io_FileInputStream_available;
text: .text%Java_java_lang_reflect_Array_newArray;
text: .text%Java_java_lang_Throwable_getStackTraceDepth;
text: .text%Java_java_lang_Throwable_getStackTraceElement;
text: .text%Java_java_lang_System_identityHashCode;
text: .text%Java_sun_misc_Signal_findSignal;
text: .text%Java_sun_misc_Signal_handle0;
text: .text%JNU_NotifyAll;
# Test LoadFrame
text: .text%JNU_CallMethodByName;
text: .text%JNU_CallMethodByNameV;
text: .text%Java_java_util_logging_FileHandler_lockFile;
text: .text%Java_java_io_FileOutputStream_open;
text: .text%Java_java_io_UnixFileSystem_createDirectory;
text: .text%Java_java_io_UnixFileSystem_getLastModifiedTime;
text: .text%Java_java_util_prefs_FileSystemPreferences_lockFile0;
text: .text%Java_java_io_UnixFileSystem_setLastModifiedTime;
text: .text%Java_java_util_prefs_FileSystemPreferences_unlockFile0;
text: .text%Java_java_io_FileOutputStream_close0;
text: .text%Java_java_util_logging_FileHandler_unlockFile;
# Test LoadJFrame
text: .text%Java_java_lang_Class_isAssignableFrom;
text: .text%Java_java_lang_Class_isInstance;
# Test JHello
# SwingSet
text: .text%Java_java_util_TimeZone_getSystemTimeZoneID;
text: .text%findJavaTZ_md;
text: .text%Java_java_lang_StrictMath_log;
...@@ -34,6 +34,8 @@ SUNWprivate_1.1 { ...@@ -34,6 +34,8 @@ SUNWprivate_1.1 {
JLI_ReportErrorMessageSys; JLI_ReportErrorMessageSys;
JLI_ReportMessage; JLI_ReportMessage;
JLI_ReportExceptionDescription; JLI_ReportExceptionDescription;
JLI_GetStdArgs;
JLI_GetStdArgc;
local: local:
*; *;
}; };
data = R0x2000;
text = LOAD ?RXO;
# Test Null
# Test Exit
# Test Hello
# Test Sleep
# Test IntToString
# Test LoadToolkit
# Test LoadFrame
# Test LoadJFrame
# Test JHello
# SwingSet
text: .text%JNI_OnLoad;
text: .text%Java_sun_awt_image_JPEGImageDecoder_initIDs;
text: .text%Java_sun_awt_image_JPEGImageDecoder_readImage;
text: .text%jStdError;
text: .text%jCreaDecompress;
text: .text%jIMemMgr;
text: .text%jMemInit;
text: .text%jGetSmall;
text: .text%jIMReader;
text: .text%alloc_small: OUTPUTDIR/jmemmgr.o;
text: .text%reset_marker_reader: OUTPUTDIR/jdmarker.o;
text: .text%jIInCtlr;
# text: .text%GET_ARRAYS: OUTPUTDIR/jpegdecoder.o;
text: .text%jReadHeader;
text: .text%jConsumeInput;
text: .text%reset_input_controller: OUTPUTDIR/jdinput.o;
text: .text%reset_error_mgr: OUTPUTDIR/jerror.o;
text: .text%sun_jpeg_init_source;
text: .text%consume_markers: OUTPUTDIR/jdinput.o;
text: .text%read_markers: OUTPUTDIR/jdmarker.o;
# text: .text%first_marker: OUTPUTDIR/jdmarker.o;
text: .text%sun_jpeg_fill_input_buffer;
# text: .text%RELEASE_ARRAYS: OUTPUTDIR/jpegdecoder.o;
# text: .text%get_soi: OUTPUTDIR/jdmarker.o;
text: .text%emit_message: OUTPUTDIR/jerror.o;
# text: .text%next_marker: OUTPUTDIR/jdmarker.o;
text: .text%get_interesting_appn: OUTPUTDIR/jdmarker.o;
# text: .text%examine_app0: OUTPUTDIR/jdmarker.o;
text: .text%skip_variable: OUTPUTDIR/jdmarker.o;
text: .text%sun_jpeg_skip_input_data;
# text: .text%examine_app14: OUTPUTDIR/jdmarker.o;
text: .text%get_dqt: OUTPUTDIR/jdmarker.o;
text: .text%jAlcQTable;
text: .text%get_sof: OUTPUTDIR/jdmarker.o;
# text: .text%get_dri: OUTPUTDIR/jdmarker.o;
text: .text%get_dht: OUTPUTDIR/jdmarker.o;
text: .text%jAlcHTable;
text: .text%get_sos: OUTPUTDIR/jdmarker.o;
# text: .text%initial_setup: OUTPUTDIR/jdinput.o;
text: .text%jDivRound;
# text: .text%default_decompress_parms: OUTPUTDIR/jdapimin.o;
text: .text%jHasMultScn;
text: .text%jStrtDecompress;
text: .text%jIDMaster;
# text: .text%master_selection: OUTPUTDIR/jdmaster.o;
text: .text%jCalcDimensions;
# text: .text%use_merged_upsample: OUTPUTDIR/jdmaster.o;
# text: .text%prepare_range_limit_table: OUTPUTDIR/jdmaster.o;
text: .text%jIDColor;
# text: .text%build_ycc_rgb_table: OUTPUTDIR/jdcolor.o;
text: .text%jIUpsampler;
text: .text%jRound;
text: .text%alloc_sarray: OUTPUTDIR/jmemmgr.o;
text: .text%alloc_large: OUTPUTDIR/jmemmgr.o;
text: .text%jGetLarge;
text: .text%jIDPostC;
text: .text%jIIDCT;
text: .text%jIHDecoder;
text: .text%jIDCoefC;
text: .text%jIDMainC;
# text: .text%alloc_funny_pointers: OUTPUTDIR/jdmainct.o;
text: .text%realize_virt_arrays: OUTPUTDIR/jmemmgr.o;
text: .text%start_input_pass: OUTPUTDIR/jdinput.o;
# text: .text%per_scan_setup: OUTPUTDIR/jdinput.o;
# text: .text%latch_quant_tables: OUTPUTDIR/jdinput.o;
text: .text%start_pass_huff_decoder: OUTPUTDIR/jdhuff.o;
text: .text%jMkDDerived;
text: .text%start_input_pass: OUTPUTDIR/jdcoefct.o;
# text: .text%start_iMCU_row: OUTPUTDIR/jdcoefct.o;
# text: .text%output_pass_setup: OUTPUTDIR/jdapistd.o;
text: .text%prepare_for_output_pass: OUTPUTDIR/jdmaster.o;
text: .text%start_pass: OUTPUTDIR/jddctmgr.o;
text: .text%start_output_pass: OUTPUTDIR/jdcoefct.o;
text: .text%start_pass_dcolor: OUTPUTDIR/jdcolor.o;
text: .text%start_pass_upsample: OUTPUTDIR/jdsample.o;
text: .text%start_pass_dpost: OUTPUTDIR/jdpostct.o;
text: .text%start_pass_main: OUTPUTDIR/jdmainct.o;
# text: .text%make_funny_pointers: OUTPUTDIR/jdmainct.o;
text: .text%jReadScanlines;
text: .text%process_data_context_main: OUTPUTDIR/jdmainct.o;
text: .text%decompress_onepass: OUTPUTDIR/jdcoefct.o;
text: .text%jZeroFar;
text: .text%decode_mcu: OUTPUTDIR/jdhuff.o;
text: .text%jFilBitBuf;
text: .text%jHufDecode;
text: .text%jRDislow;
text: .text%sep_upsample: OUTPUTDIR/jdsample.o;
text: .text%fullsize_upsample: OUTPUTDIR/jdsample.o;
text: .text%h2v2_fancy_upsample: OUTPUTDIR/jdsample.o;
text: .text%ycc_rgb_convert: OUTPUTDIR/jdcolor.o;
# text: .text%set_wraparound_pointers: OUTPUTDIR/jdmainct.o;
# text: .text%process_restart: OUTPUTDIR/jdhuff.o;
text: .text%read_restart_marker: OUTPUTDIR/jdmarker.o;
text: .text%finish_input_pass: OUTPUTDIR/jdinput.o;
# text: .text%set_bottom_pointers: OUTPUTDIR/jdmainct.o;
text: .text%jFinDecompress;
text: .text%finish_output_pass: OUTPUTDIR/jdmaster.o;
text: .text%sun_jpeg_term_source;
text: .text%jAbort;
text: .text%free_pool: OUTPUTDIR/jmemmgr.o;
text: .text%jFreeLarge;
text: .text%jFreeSmall;
text: .text%jDestDecompress;
text: .text%jDestroy;
text: .text%self_destruct: OUTPUTDIR/jmemmgr.o;
text: .text%jMemTerm;
text: .text%process_data_simple_main: OUTPUTDIR/jdmainct.o;
...@@ -143,6 +143,7 @@ SUNWprivate_1.1 { ...@@ -143,6 +143,7 @@ SUNWprivate_1.1 {
Java_sun_nio_fs_LinuxNativeDispatcher_fsetxattr0; Java_sun_nio_fs_LinuxNativeDispatcher_fsetxattr0;
Java_sun_nio_fs_LinuxNativeDispatcher_fremovexattr0; Java_sun_nio_fs_LinuxNativeDispatcher_fremovexattr0;
Java_sun_nio_fs_LinuxNativeDispatcher_setmntent0; Java_sun_nio_fs_LinuxNativeDispatcher_setmntent0;
Java_sun_nio_fs_LinuxNativeDispatcher_getmntent;
Java_sun_nio_fs_LinuxNativeDispatcher_endmntent; Java_sun_nio_fs_LinuxNativeDispatcher_endmntent;
Java_sun_nio_fs_UnixNativeDispatcher_init; Java_sun_nio_fs_UnixNativeDispatcher_init;
Java_sun_nio_fs_UnixNativeDispatcher_getcwd; Java_sun_nio_fs_UnixNativeDispatcher_getcwd;
...@@ -189,7 +190,6 @@ SUNWprivate_1.1 { ...@@ -189,7 +190,6 @@ SUNWprivate_1.1 {
Java_sun_nio_fs_UnixNativeDispatcher_getgrgid; Java_sun_nio_fs_UnixNativeDispatcher_getgrgid;
Java_sun_nio_fs_UnixNativeDispatcher_getpwnam0; Java_sun_nio_fs_UnixNativeDispatcher_getpwnam0;
Java_sun_nio_fs_UnixNativeDispatcher_getgrnam0; Java_sun_nio_fs_UnixNativeDispatcher_getgrnam0;
Java_sun_nio_fs_UnixNativeDispatcher_getextmntent;
Java_sun_nio_fs_UnixCopyFile_transfer; Java_sun_nio_fs_UnixCopyFile_transfer;
handleSocketError; handleSocketError;
......
#
# Copyright (c) 2001, 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. 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.
#
SUNWprivate_1.1 {
global:
Java_java_nio_MappedByteBuffer_force0;
Java_java_nio_MappedByteBuffer_isLoaded0;
Java_java_nio_MappedByteBuffer_load0;
Java_sun_nio_ch_DatagramChannelImpl_disconnect0;
Java_sun_nio_ch_DatagramChannelImpl_initIDs;
Java_sun_nio_ch_DatagramChannelImpl_receive0;
Java_sun_nio_ch_DatagramChannelImpl_send0;
Java_sun_nio_ch_DatagramDispatcher_read0;
Java_sun_nio_ch_DatagramDispatcher_readv0;
Java_sun_nio_ch_DatagramDispatcher_write0;
Java_sun_nio_ch_DatagramDispatcher_writev0;
Java_sun_nio_ch_FileChannelImpl_close0;
Java_sun_nio_ch_FileChannelImpl_initIDs;
Java_sun_nio_ch_FileChannelImpl_map0;
Java_sun_nio_ch_FileChannelImpl_position0;
Java_sun_nio_ch_FileChannelImpl_transferTo0;
Java_sun_nio_ch_FileChannelImpl_unmap0;
Java_sun_nio_ch_FileDispatcherImpl_close0;
Java_sun_nio_ch_FileDispatcherImpl_closeIntFD;
Java_sun_nio_ch_FileDispatcherImpl_force0;
Java_sun_nio_ch_FileDispatcherImpl_init;
Java_sun_nio_ch_FileDispatcherImpl_lock0;
Java_sun_nio_ch_FileDispatcherImpl_preClose0;
Java_sun_nio_ch_FileDispatcherImpl_pread0;
Java_sun_nio_ch_FileDispatcherImpl_pwrite0;
Java_sun_nio_ch_FileDispatcherImpl_read0;
Java_sun_nio_ch_FileDispatcherImpl_readv0;
Java_sun_nio_ch_FileDispatcherImpl_release0;
Java_sun_nio_ch_FileDispatcherImpl_size0;
Java_sun_nio_ch_FileDispatcherImpl_truncate0;
Java_sun_nio_ch_FileDispatcherImpl_write0;
Java_sun_nio_ch_FileDispatcherImpl_writev0;
Java_sun_nio_ch_FileKey_init;
Java_sun_nio_ch_FileKey_initIDs;
Java_sun_nio_ch_InheritedChannel_close0;
Java_sun_nio_ch_InheritedChannel_dup;
Java_sun_nio_ch_InheritedChannel_dup2;
Java_sun_nio_ch_InheritedChannel_open0;
Java_sun_nio_ch_InheritedChannel_peerAddress0;
Java_sun_nio_ch_InheritedChannel_peerPort0;
Java_sun_nio_ch_InheritedChannel_soType0;
Java_sun_nio_ch_IOUtil_configureBlocking;
Java_sun_nio_ch_IOUtil_drain;
Java_sun_nio_ch_IOUtil_fdVal;
Java_sun_nio_ch_IOUtil_initIDs;
Java_sun_nio_ch_IOUtil_makePipe;
Java_sun_nio_ch_IOUtil_randomBytes;
Java_sun_nio_ch_IOUtil_setfdVal;
Java_sun_nio_ch_KQueue_kqueue;
Java_sun_nio_ch_KQueue_keventRegister;
Java_sun_nio_ch_KQueue_keventPoll;
Java_sun_nio_ch_KQueue_keventSize;
Java_sun_nio_ch_KQueue_identOffset;
Java_sun_nio_ch_KQueue_filterOffset;
Java_sun_nio_ch_KQueue_flagsOffset;
Java_sun_nio_ch_KQueuePort_socketpair;
Java_sun_nio_ch_KQueuePort_interrupt;
Java_sun_nio_ch_KQueuePort_drain1;
Java_sun_nio_ch_KQueuePort_close0;
Java_sun_nio_ch_NativeThread_current;
Java_sun_nio_ch_NativeThread_init;
Java_sun_nio_ch_NativeThread_signal;
Java_sun_nio_ch_Net_canIPv6SocketJoinIPv4Group0;
Java_sun_nio_ch_Net_canJoin6WithIPv4Group0;
Java_sun_nio_ch_Net_socket0;
Java_sun_nio_ch_Net_bind0;
Java_sun_nio_ch_Net_connect0;
Java_sun_nio_ch_Net_listen;
Java_sun_nio_ch_Net_localPort;
Java_sun_nio_ch_Net_localInetAddress;
Java_sun_nio_ch_Net_getIntOption0;
Java_sun_nio_ch_Net_setIntOption0;
Java_sun_nio_ch_Net_initIDs;
Java_sun_nio_ch_Net_isIPv6Available0;
Java_sun_nio_ch_Net_joinOrDrop4;
Java_sun_nio_ch_Net_blockOrUnblock4;
Java_sun_nio_ch_Net_joinOrDrop6;
Java_sun_nio_ch_Net_blockOrUnblock6;
Java_sun_nio_ch_Net_setInterface4;
Java_sun_nio_ch_Net_getInterface4;
Java_sun_nio_ch_Net_setInterface6;
Java_sun_nio_ch_Net_getInterface6;
Java_sun_nio_ch_Net_shutdown;
Java_sun_nio_ch_PollArrayWrapper_interrupt;
Java_sun_nio_ch_PollArrayWrapper_poll0;
Java_sun_nio_ch_ServerSocketChannelImpl_accept0;
Java_sun_nio_ch_ServerSocketChannelImpl_initIDs;
Java_sun_nio_ch_SocketChannelImpl_checkConnect;
Java_sun_nio_ch_SocketChannelImpl_sendOutOfBandData;
Java_sun_nio_ch_UnixAsynchronousServerSocketChannelImpl_accept0;
Java_sun_nio_ch_UnixAsynchronousServerSocketChannelImpl_initIDs;
Java_sun_nio_ch_UnixAsynchronousSocketChannelImpl_checkConnect;
Java_sun_nio_fs_BsdNativeDispatcher_initIDs;
Java_sun_nio_fs_BsdNativeDispatcher_getfsstat;
Java_sun_nio_fs_BsdNativeDispatcher_fsstatEntry;
Java_sun_nio_fs_BsdNativeDispatcher_endfsstat;
Java_sun_nio_fs_UnixNativeDispatcher_init;
Java_sun_nio_fs_UnixNativeDispatcher_getcwd;
Java_sun_nio_fs_UnixNativeDispatcher_strerror;
Java_sun_nio_fs_UnixNativeDispatcher_dup;
Java_sun_nio_fs_UnixNativeDispatcher_access0;
Java_sun_nio_fs_UnixNativeDispatcher_stat0;
Java_sun_nio_fs_UnixNativeDispatcher_lstat0;
Java_sun_nio_fs_UnixNativeDispatcher_fstat;
Java_sun_nio_fs_UnixNativeDispatcher_fstatat0;
Java_sun_nio_fs_UnixNativeDispatcher_chmod0;
Java_sun_nio_fs_UnixNativeDispatcher_fchmod;
Java_sun_nio_fs_UnixNativeDispatcher_chown0;
Java_sun_nio_fs_UnixNativeDispatcher_lchown0;
Java_sun_nio_fs_UnixNativeDispatcher_fchown;
Java_sun_nio_fs_UnixNativeDispatcher_utimes0;
Java_sun_nio_fs_UnixNativeDispatcher_futimes;
Java_sun_nio_fs_UnixNativeDispatcher_open0;
Java_sun_nio_fs_UnixNativeDispatcher_openat0;
Java_sun_nio_fs_UnixNativeDispatcher_close;
Java_sun_nio_fs_UnixNativeDispatcher_read;
Java_sun_nio_fs_UnixNativeDispatcher_write;
Java_sun_nio_fs_UnixNativeDispatcher_fopen0;
Java_sun_nio_fs_UnixNativeDispatcher_fclose;
Java_sun_nio_fs_UnixNativeDispatcher_opendir0;
Java_sun_nio_fs_UnixNativeDispatcher_fdopendir;
Java_sun_nio_fs_UnixNativeDispatcher_readdir;
Java_sun_nio_fs_UnixNativeDispatcher_closedir;
Java_sun_nio_fs_UnixNativeDispatcher_link0;
Java_sun_nio_fs_UnixNativeDispatcher_unlink0;
Java_sun_nio_fs_UnixNativeDispatcher_unlinkat0;
Java_sun_nio_fs_UnixNativeDispatcher_rename0;
Java_sun_nio_fs_UnixNativeDispatcher_renameat0;
Java_sun_nio_fs_UnixNativeDispatcher_mkdir0;
Java_sun_nio_fs_UnixNativeDispatcher_rmdir0;
Java_sun_nio_fs_UnixNativeDispatcher_symlink0;
Java_sun_nio_fs_UnixNativeDispatcher_readlink0;
Java_sun_nio_fs_UnixNativeDispatcher_realpath0;
Java_sun_nio_fs_UnixNativeDispatcher_statvfs0;
Java_sun_nio_fs_UnixNativeDispatcher_pathconf0;
Java_sun_nio_fs_UnixNativeDispatcher_fpathconf;
Java_sun_nio_fs_UnixNativeDispatcher_mknod0;
Java_sun_nio_fs_UnixNativeDispatcher_getpwuid;
Java_sun_nio_fs_UnixNativeDispatcher_getgrgid;
Java_sun_nio_fs_UnixNativeDispatcher_getpwnam0;
Java_sun_nio_fs_UnixNativeDispatcher_getgrnam0;
Java_sun_nio_fs_UnixCopyFile_transfer;
handleSocketError;
local:
*;
};
...@@ -169,10 +169,10 @@ SUNWprivate_1.1 { ...@@ -169,10 +169,10 @@ SUNWprivate_1.1 {
Java_sun_nio_fs_UnixNativeDispatcher_getgrgid; Java_sun_nio_fs_UnixNativeDispatcher_getgrgid;
Java_sun_nio_fs_UnixNativeDispatcher_getpwnam0; Java_sun_nio_fs_UnixNativeDispatcher_getpwnam0;
Java_sun_nio_fs_UnixNativeDispatcher_getgrnam0; Java_sun_nio_fs_UnixNativeDispatcher_getgrnam0;
Java_sun_nio_fs_UnixNativeDispatcher_getextmntent;
Java_sun_nio_fs_UnixCopyFile_transfer; Java_sun_nio_fs_UnixCopyFile_transfer;
Java_sun_nio_fs_SolarisNativeDispatcher_init; Java_sun_nio_fs_SolarisNativeDispatcher_init;
Java_sun_nio_fs_SolarisNativeDispatcher_facl; Java_sun_nio_fs_SolarisNativeDispatcher_facl;
Java_sun_nio_fs_SolarisNativeDispatcher_getextmntent;
Java_sun_nio_fs_SolarisWatchService_init; Java_sun_nio_fs_SolarisWatchService_init;
Java_sun_nio_fs_SolarisWatchService_portCreate; Java_sun_nio_fs_SolarisWatchService_portCreate;
Java_sun_nio_fs_SolarisWatchService_portAssociate; Java_sun_nio_fs_SolarisWatchService_portAssociate;
......
data = R0x2000;
text = LOAD ?RXO;
# Test Null
# Test Exit
# Test Hello
# Test Sleep
# Test IntToString
# Test LoadToolkit
text: .text%Java_sun_nio_ch_FileChannelImpl_initIDs;
text: .text%Java_sun_nio_ch_FileDispatcher_initIDs;
text: .text%Java_sun_nio_ch_IOUtil_initIDs;
text: .text%Java_sun_nio_ch_FileDispatcher_read0;
text: .text%convertReturnVal;
# Test LoadFrame
# Test LoadJFrame
# Test JHello
# SwingSet
data = R0x2000;
text = LOAD ?RXO;
# Test Null
text: .text%VerifyFixClassname;
text: .text%VerifyClassname;
text: .text%skip_over_fieldname: OUTPUTDIR/check_format.o;
text: .text%skip_over_field_signature: OUTPUTDIR/check_format.o;
text: .text%VerifyClass;
text: .text%make_class_info_from_name: OUTPUTDIR/check_code.o;
text: .text%class_name_to_ID: OUTPUTDIR/check_code.o;
text: .text%make_class_info: OUTPUTDIR/check_code.o;
text: .text%free_block: OUTPUTDIR/check_code.o;
text: .text%verify_method: OUTPUTDIR/check_code.o;
text: .text%verify_opcode_operands: OUTPUTDIR/check_code.o;
text: .text%initialize_dataflow: OUTPUTDIR/check_code.o;
text: .text%signature_to_fieldtype: OUTPUTDIR/check_code.o;
text: .text%check_register_values: OUTPUTDIR/check_code.o;
text: .text%pop_stack: OUTPUTDIR/check_code.o;
text: .text%update_registers: OUTPUTDIR/check_code.o;
text: .text%push_stack: OUTPUTDIR/check_code.o;
text: .text%merge_into_successors: OUTPUTDIR/check_code.o;
text: .text%cp_index_to_class_fullinfo: OUTPUTDIR/check_code.o;
text: .text%set_protected: OUTPUTDIR/check_code.o;
text: .text%merge_into_one_successor: OUTPUTDIR/check_code.o;
text: .text%merge_registers: OUTPUTDIR/check_code.o;
# Test Exit
# Test Hello
text: .text%merge_fullinfo_types: OUTPUTDIR/check_code.o;
text: .text%isAssignableTo: OUTPUTDIR/check_code.o;
# Test Sleep
text: .text%isLegalTarget: OUTPUTDIR/check_code.o;
text: .text%verify_constant_pool_type: OUTPUTDIR/check_code.o;
# Test IntToString
# Test LoadToolkit
# Test LoadFrame
# Test LoadJFrame
# Test JHello
# SwingSet
text: .text%copy_stack: OUTPUTDIR/check_code.o;
text: .text%ntohl: OUTPUTDIR/check_code.o;
...@@ -37,16 +37,12 @@ SUNWprivate_1.1 { ...@@ -37,16 +37,12 @@ SUNWprivate_1.1 {
Java_java_util_zip_Deflater_deflateBytes; Java_java_util_zip_Deflater_deflateBytes;
Java_java_util_zip_Deflater_end; Java_java_util_zip_Deflater_end;
Java_java_util_zip_Deflater_getAdler; Java_java_util_zip_Deflater_getAdler;
Java_java_util_zip_Deflater_getBytesRead;
Java_java_util_zip_Deflater_getBytesWritten;
Java_java_util_zip_Deflater_init; Java_java_util_zip_Deflater_init;
Java_java_util_zip_Deflater_initIDs; Java_java_util_zip_Deflater_initIDs;
Java_java_util_zip_Deflater_reset; Java_java_util_zip_Deflater_reset;
Java_java_util_zip_Deflater_setDictionary; Java_java_util_zip_Deflater_setDictionary;
Java_java_util_zip_Inflater_end; Java_java_util_zip_Inflater_end;
Java_java_util_zip_Inflater_getAdler; Java_java_util_zip_Inflater_getAdler;
Java_java_util_zip_Inflater_getBytesRead;
Java_java_util_zip_Inflater_getBytesWritten;
Java_java_util_zip_Inflater_inflateBytes; Java_java_util_zip_Inflater_inflateBytes;
Java_java_util_zip_Inflater_init; Java_java_util_zip_Inflater_init;
Java_java_util_zip_Inflater_initIDs; Java_java_util_zip_Inflater_initIDs;
......
data = R0x2000;
text = LOAD ?RXO;
# Test Null
text: .text%ZIP_Open;
text: .text%ZIP_Open_Generic;
text: .text%InitializeZip;
text: .text%allocZip;
text: .text%readCEN: OUTPUTDIR/zip_util.o;
text: .text%findEND: OUTPUTDIR/zip_util.o;
text: .text%hash: OUTPUTDIR/zip_util.o;
text: .text%isMetaName: OUTPUTDIR/zip_util.o;
text: .text%addMetaName: OUTPUTDIR/zip_util.o;
text: .text%ZIP_FindEntry;
text: .text%ZIP_GetEntry;
text: .text%ZIP_Lock;
text: .text%readLOC: OUTPUTDIR/zip_util.o;
text: .text%ZIP_Unlock;
text: .text%ZIP_FreeEntry;
text: .text%Java_java_util_zip_ZipFile_initIDs;
text: .text%Java_java_util_zip_ZipFile_open;
text: .text%Java_java_util_zip_ZipFile_getTotal;
text: .text%Java_java_util_zip_ZipFile_getEntry;
text: .text%Java_java_util_zip_ZipFile_freeEntry;
text: .text%Java_java_util_zip_ZipFile_getEntryTime;
text: .text%Java_java_util_zip_ZipFile_getEntryCrc;
text: .text%Java_java_util_zip_ZipFile_getEntryCSize;
text: .text%Java_java_util_zip_ZipFile_getEntrySize;
text: .text%Java_java_util_zip_ZipFile_getEntryFlag;
text: .text%Java_java_util_zip_ZipFile_getEntryMethod;
text: .text%Java_java_util_zip_ZipFile_getEntryBytes;
text: .text%Java_java_util_zip_Inflater_initIDs;
text: .text%Java_java_util_zip_Inflater_init;
text: .text%inflateInit2_;
text: .text%zcalloc;
text: .text%inflateReset;
text: .text%Java_java_util_zip_Inflater_inflateBytes;
text: .text%inflate;
text: .text%Java_java_util_zip_ZipFile_read;
text: .text%ZIP_Read;
text: .text%huft_build: OUTPUTDIR/inftrees.o;
text: .text%zcfree;
text: .text%Java_java_util_jar_JarFile_getMetaInfEntryNames;
text: .text%ZIP_ReadEntry;
text: .text%InflateFully;
text: .text%inflateEnd;
text: .text%Java_java_util_zip_Inflater_reset;
text: .text%Java_java_util_zip_ZipFile_close;
text: .text%ZIP_Close;
text: .text%Java_java_util_zip_Inflater_end;
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册