e32ab98b32
New makefiles transition, old and new living side by side for now. Co-authored-by: Erik Joelsson <erik.joelsson@oracle.com> Co-authored-by: Magnus Ihse Bursie <magnus.ihse.bursie@oracle.com> Co-authored-by: Torbjorn Granat <torbjorn.granat@oracle.com> Co-authored-by: Yekaterina Kantserova <yekaterina.kantserova@oracle.com> Reviewed-by: ohair, jjg, dholmes, ohrstrom, erikj, ihse, tgranat, ykantser
244 lines
7.9 KiB
Plaintext
244 lines
7.9 KiB
Plaintext
#
|
|
# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
|
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
#
|
|
# This code is free software; you can redistribute it and/or modify it
|
|
# under the terms of the GNU General Public License version 2 only, as
|
|
# published by the Free Software Foundation. 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.
|
|
#
|
|
|
|
default: all
|
|
|
|
include $(SPEC)
|
|
include MakeBase.gmk
|
|
include JavaCompilation.gmk
|
|
|
|
# Setup the java compilers for the JDK build.
|
|
include Setup.gmk
|
|
|
|
EXCLUDES:= sun/dc \
|
|
sun/security/pkcs11 \
|
|
com/sun/pept \
|
|
com/sun/tools/example/trace\
|
|
com/sun/tools/example/debug/bdi\
|
|
com/sun/tools/example/debug/event\
|
|
com/sun/tools/example/debug/gui \
|
|
javax/crypto \
|
|
com/oracle/security
|
|
|
|
ifdef OPENJDK
|
|
EXCLUDES+= com/sun/jmx/snmp \
|
|
sun/management/snmp \
|
|
com/sun/script
|
|
endif
|
|
|
|
ifneq ($(PLATFORM),solaris)
|
|
# Exclude Solaris nio and two security related files in src/share/classes
|
|
EXFILES:=SolarisAclFileAttributeView.java \
|
|
SolarisFileStore.java \
|
|
SolarisFileSystem.java \
|
|
SolarisFileSystemProvider.java \
|
|
SolarisNativeDispatcher.java \
|
|
SolarisUserDefinedFileAttributeView.java \
|
|
SolarisWatchService.java \
|
|
DevPollArrayWrapper.java \
|
|
DevPollSelectorImpl.java \
|
|
DevPollSelectorProvider.java \
|
|
SolarisAsynchronousChannelProvider.java \
|
|
SolarisEventPort.java \
|
|
SolarisAclFileAttributeView.java \
|
|
SolarisFileStore.java \
|
|
SolarisFileSystem.java \
|
|
SolarisFileSystemProvider.java \
|
|
SolarisUserDefinedFileAttributeView.java \
|
|
SolarisNativeDispatcher.java \
|
|
SolarisWatchService.java \
|
|
SolarisLoginModule.java \
|
|
SolarisSystem.java \
|
|
sun/tools/attach/SolarisAttachProvider.java \
|
|
sun/tools/attach/SolarisVirtualMachine.java
|
|
endif
|
|
|
|
# Why?
|
|
EXFILES+=WrapperGenerator.java
|
|
|
|
ifneq ($(PLATFORM),windows)
|
|
# Exclude Window security related files in src/share/classes
|
|
EXFILES+=NTLoginModule.java \
|
|
NTSystem.java
|
|
|
|
endif
|
|
|
|
ifeq ($(PLATFORM),windows)
|
|
# Does nio channels exist on Windows?
|
|
EXCLUDES+=sun/nio/ch
|
|
endif
|
|
|
|
ifneq ($(PLATFORM),linux)
|
|
EXCLUDES+=com/sun/java/swing/plaf/gtk
|
|
EXFILES+=sun/tools/attach/LinuxAttachProvider.java \
|
|
sun/tools/attach/LinuxVirtualMachine.java
|
|
endif
|
|
|
|
ifneq ($(PLATFORM),macosx)
|
|
EXFILES+=sun/nio/fs/BsdFileStore.java \
|
|
sun/nio/fs/BsdFileSystem.java \
|
|
sun/nio/fs/BsdFileSystemProvider.java \
|
|
sun/nio/fs/BsdNativeDispatcher.java \
|
|
sun/tools/attach/BsdAttachProvider.java \
|
|
sun/tools/attach/BsdVirtualMachine.java
|
|
endif
|
|
|
|
# Generated nimbus files that apparently should not be compiled...
|
|
EXFILES+=InternalFrameTitlePanePainter.java \
|
|
OptionPaneMessageAreaPainter.java \
|
|
ScrollBarPainter.java \
|
|
SliderPainter.java \
|
|
SpinnerPainter.java \
|
|
SplitPanePainter.java \
|
|
TabbedPanePainter.java
|
|
|
|
# New class /java/lang/annotation/ContainerAnnotation.java is not included in old
|
|
# build
|
|
EXFILES+=java/lang/annotation/ContainerAnnotation.java
|
|
|
|
# Exclude BreakIterator classes that are just used in compile process to generate
|
|
# data files and shouldn't go in the product
|
|
EXFILES+=sun/text/resources/BreakIteratorRules.java \
|
|
sun/text/resources/BreakIteratorRules_th.java
|
|
|
|
# TODO: Add BUILD_HEADLESS_ONLY to configure?
|
|
ifdef BUILD_HEADLESS_ONLY
|
|
EXCLUDES+=sun/applet
|
|
endif
|
|
|
|
ifdef OPENJDK
|
|
EXCLUDES+=sun/java2d/cmm/kcms
|
|
else
|
|
EXCLUDES+=sun/java2d/cmm/lcms
|
|
endif
|
|
|
|
# Not used on windows
|
|
ifneq ($(PLATFORM), windows)
|
|
EXFILES+=sun/awt/AWTCharset.java
|
|
endif
|
|
|
|
# Exclude some generated AWT files that were implicitly not included by the old build.
|
|
EXFILES+=sun/awt/X11/ScreenFormat.java \
|
|
sun/awt/X11/XArc.java \
|
|
sun/awt/X11/XChar2b.java \
|
|
sun/awt/X11/XCharStruct.java \
|
|
sun/awt/X11/XClassHint.java \
|
|
sun/awt/X11/XComposeStatus.java \
|
|
sun/awt/X11/XExtCodes.java \
|
|
sun/awt/X11/XFontProp.java \
|
|
sun/awt/X11/XFontSetExtents.java \
|
|
sun/awt/X11/XFontStruct.java \
|
|
sun/awt/X11/XGCValues.java \
|
|
sun/awt/X11/XHostAddress.java \
|
|
sun/awt/X11/XIMCallback.java \
|
|
sun/awt/X11/XIMHotKeyTrigger.java \
|
|
sun/awt/X11/XIMHotKeyTriggers.java \
|
|
sun/awt/X11/XIMPreeditCaretCallbackStruct.java \
|
|
sun/awt/X11/XIMPreeditDrawCallbackStruct.java \
|
|
sun/awt/X11/XIMPreeditStateNotifyCallbackStruct.java \
|
|
sun/awt/X11/XIMStatusDrawCallbackStruct.java \
|
|
sun/awt/X11/XIMStringConversionCallbackStruct.java \
|
|
sun/awt/X11/XIMStringConversionText.java \
|
|
sun/awt/X11/XIMStyles.java \
|
|
sun/awt/X11/XIMText.java \
|
|
sun/awt/X11/XIMValuesList.java \
|
|
sun/awt/X11/XImage.java \
|
|
sun/awt/X11/XKeyboardControl.java \
|
|
sun/awt/X11/XKeyboardState.java \
|
|
sun/awt/X11/XOMCharSetList.java \
|
|
sun/awt/X11/XOMFontInfo.java \
|
|
sun/awt/X11/XOMOrientation.java \
|
|
sun/awt/X11/XPoint.java \
|
|
sun/awt/X11/XRectangle.java \
|
|
sun/awt/X11/XSegment.java \
|
|
sun/awt/X11/XStandardColormap.java \
|
|
sun/awt/X11/XTextItem.java \
|
|
sun/awt/X11/XTextItem16.java \
|
|
sun/awt/X11/XTextProperty.java \
|
|
sun/awt/X11/XTimeCoord.java \
|
|
sun/awt/X11/XWindowChanges.java \
|
|
sun/awt/X11/XdbeSwapInfo.java \
|
|
sun/awt/X11/XmbTextItem.java \
|
|
sun/awt/X11/XwcTextItem.java
|
|
|
|
# Exclude sun/security files that should go in a separate jar
|
|
EXFILES+=sun/security/ec/ECDHKeyAgreement.java \
|
|
sun/security/ec/ECDSASignature.java \
|
|
sun/security/ec/ECKeyPairGenerator.java \
|
|
sun/security/ec/SunEC$1.java \
|
|
sun/security/ec/SunEC.java \
|
|
sun/security/ec/SunECEntries.java
|
|
|
|
# Exclude another implicitly not included file.
|
|
EXFILES+=sun/util/locale/AsciiUtil.java
|
|
|
|
ifeq ($(PLATFORM), linux)
|
|
EXFILES+=sun/nio/fs/PollingWatchService.java
|
|
endif
|
|
|
|
# TODO: Fix when converting NIO
|
|
# Exclude *-linux-arm.java and *-linux-ppc.java from closed.
|
|
EXFILES+=-linux-arm.java \
|
|
-linux-ppc.java
|
|
|
|
# TODO: Is this necessary?
|
|
ifeq ($(PLATFORM), windows)
|
|
EXFILES+=sun/net/sdp/SdpProvider.java
|
|
else
|
|
EXFILES+=sun/net/www/protocol/http/ntlm/NTLMAuthSequence.java
|
|
endif
|
|
|
|
# Acquire a list of files that should be copied straight over to the classes.
|
|
include CopyIntoClasses.gmk
|
|
# Now we have COPY_PATTERNS, COPY_FILES and COPY_EXTRA
|
|
|
|
ifndef OPENJDK
|
|
CLOSED_SRC_DIRS:=$(JDK_TOPDIR)/src/closed/share/classes \
|
|
$(JDK_TOPDIR)/src/closed/$(LEGACY_HOST_OS_API)/classes
|
|
endif
|
|
|
|
$(eval $(call SetupJavaCompilation,BUILD_JDK,\
|
|
SETUP:=GENERATE_JDKBYTECODE,\
|
|
SRC:=$(JDK_TOPDIR)/src/share/classes \
|
|
$(JDK_TOPDIR)/src/$(LEGACY_HOST_OS_API)/classes \
|
|
$(JDK_OUTPUTDIR)/gensrc \
|
|
$(CLOSED_SRC_DIRS),\
|
|
EXCLUDES:=$(EXCLUDES),\
|
|
EXCLUDE_FILES:=$(EXFILES),\
|
|
BIN:=$(JDK_OUTPUTDIR)/newclasses,\
|
|
COPY:=$(COPY_PATTERNS),\
|
|
COPY_FILES:=$(COPY_FILES),\
|
|
JAR:=$(JDK_OUTPUTDIR)/newrt.jar,\
|
|
HEADERS:=$(JDK_OUTPUTDIR)/gensrc_headers))
|
|
|
|
# copy with -a to preserve timestamps so dependencies down the line aren't messed up
|
|
all: $(BUILD_JDK) $(JDK_OUTPUTDIR)/newrt.jar $(COPY_EXTRA)
|
|
(cd $(JDK_OUTPUTDIR); \
|
|
$(CP) -rp newclasses/* classes; \
|
|
$(FIND) classes -name "_the.*" $(FIND_DELETE); \
|
|
$(TOUCH) $(JDK_OUTPUTDIR)/classes/META-INF/services/com.sun.tools.xjc.Plugin)
|
|
|
|
.PHONY: all
|