annotate make/CompileJavaClasses.gmk @ 9190:6210b60a16ea

Merge
author kvn
date Thu, 05 Dec 2013 15:10:36 -0800
parents makefiles/CompileJavaClasses.gmk@48e71aa633bd makefiles/CompileJavaClasses.gmk@4be14673b9bf
children 902aa2b3265c
rev   line source
ohair@5221 1 #
ohair@5221 2 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
ohair@5221 3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
ohair@5221 4 #
ohair@5221 5 # This code is free software; you can redistribute it and/or modify it
ohair@5221 6 # under the terms of the GNU General Public License version 2 only, as
ohair@5221 7 # published by the Free Software Foundation. Oracle designates this
ohair@5221 8 # particular file as subject to the "Classpath" exception as provided
ohair@5221 9 # by Oracle in the LICENSE file that accompanied this code.
ohair@5221 10 #
ohair@5221 11 # This code is distributed in the hope that it will be useful, but WITHOUT
ohair@5221 12 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
ohair@5221 13 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
ohair@5221 14 # version 2 for more details (a copy is included in the LICENSE file that
ohair@5221 15 # accompanied this code).
ohair@5221 16 #
ohair@5221 17 # You should have received a copy of the GNU General Public License version
ohair@5221 18 # 2 along with this work; if not, write to the Free Software Foundation,
ohair@5221 19 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
ohair@5221 20 #
ohair@5221 21 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
ohair@5221 22 # or visit www.oracle.com if you need additional information or have any
ohair@5221 23 # questions.
ohair@5221 24 #
ohair@5221 25
ohair@5221 26 default: all
ohair@5221 27
ohair@5221 28 include $(SPEC)
ohair@5221 29 include MakeBase.gmk
ohair@5221 30 include JavaCompilation.gmk
ohair@5221 31
ohair@5221 32 # Setup the java compilers for the JDK build.
ohair@5221 33 include Setup.gmk
ohair@5221 34
erikj@5507 35 JARS :=
erikj@5507 36 EXFILES :=
erikj@5507 37 EXCLUDES :=
erikj@5507 38
erikj@5507 39 ##########################################################################################
erikj@5507 40
ihse@8330 41 EXCLUDES += com/sun/pept \
ihse@8330 42 com/sun/tools/example/trace \
ihse@8330 43 com/sun/tools/example/debug/bdi \
ihse@8330 44 com/sun/tools/example/debug/event \
ihse@8330 45 com/sun/tools/example/debug/gui
ohair@5221 46
ohair@5221 47 ifdef OPENJDK
ihse@8330 48 EXCLUDES += sun/dc \
ihse@8330 49 com/sun/jmx/snmp \
ihse@8330 50 sun/management/snmp \
ihse@8330 51 com/sun/script
ohair@5221 52 endif
ohair@5221 53
erikj@5507 54 ifndef OPENJDK
ihse@8330 55 # There exists two versions of this file...
ihse@8330 56 EXFILES := $(JDK_TOPDIR)/src/share/classes/javax/crypto/JarVerifier.java
ohair@5819 57
ihse@8330 58 ifeq ($(OPENJDK_TARGET_OS), windows)
ihse@8330 59 # This gets built on unix platforms implicitly in the old build even though
ihse@8330 60 # it's excluded in the closed build.
ihse@8330 61 EXCLUDES += sun/java2d/pisces
raginip@6453 62
ihse@8330 63 # AccessBridge is compiled separately below.
ihse@8330 64 EXFILES += AccessBridge.java \
ihse@8330 65 AccessBridgeLoader.java \
ihse@8330 66 com/sun/java/accessibility/util/java/awt/ChoiceTranslator.java
ihse@8330 67 # This seems to never be built
ihse@8330 68 EXCLUDES += com/sun/java/accessibility/extensions
ihse@8330 69 endif
ohair@5819 70
erikj@5507 71 endif
erikj@5507 72
ihse@8330 73 ifneq ($(OPENJDK_TARGET_OS), solaris)
ihse@8330 74 # Exclude Solaris nio and two security related files in src/share/classes
ihse@8330 75 EXFILES += SolarisAclFileAttributeView.java \
ihse@8330 76 SolarisFileStore.java \
ihse@8330 77 SolarisFileSystem.java \
ihse@8330 78 SolarisFileSystemProvider.java \
ihse@8330 79 SolarisNativeDispatcher.java \
ihse@8330 80 SolarisUserDefinedFileAttributeView.java \
ihse@8330 81 SolarisWatchService.java \
ihse@8330 82 SolarisAclFileAttributeView.java \
ihse@8330 83 SolarisLoginModule.java \
ihse@8330 84 SolarisSystem.java \
ihse@8330 85 sun/nio/ch/DevPollArrayWrapper.java \
ihse@8330 86 sun/nio/ch/DevPollSelectorImpl.java \
ihse@8330 87 sun/nio/ch/DevPollSelectorProvider.java \
ihse@8330 88 sun/nio/ch/EventPortSelectorImpl.java \
ihse@8330 89 sun/nio/ch/EventPortSelectorProvider.java \
ihse@8330 90 sun/nio/ch/EventPortWrapper.java \
ihse@8330 91 sun/nio/ch/SolarisAsynchronousChannelProvider.java \
ihse@8330 92 sun/nio/ch/SolarisEventPort.java \
ihse@8330 93 sun/tools/attach/SolarisAttachProvider.java \
ihse@8330 94 sun/tools/attach/SolarisVirtualMachine.java
erikj@6356 95
ihse@8330 96 EXCLUDES += com/oracle/security
ohair@5221 97 endif
ohair@5221 98
dholmes@8500 99 EXFILES += WrapperGenerator.java
ohair@5221 100
ihse@8330 101 ifneq ($(OPENJDK_TARGET_OS), windows)
ihse@8330 102 # Exclude Window security related files in src/share/classes
ihse@8330 103 EXFILES += NTLoginModule.java \
ihse@8330 104 NTSystem.java
ohair@5819 105 else
ihse@8330 106 EXFILES += UnixLoginModule.java \
ihse@8330 107 UnixSystem.java
ohair@5221 108 endif
ohair@5221 109
ihse@8330 110 ifeq ($(OPENJDK_TARGET_OS), windows)
ihse@8330 111 # Don't build GTK L&F on Windows
ihse@8330 112 EXCLUDES += com/sun/java/swing/plaf/gtk
ohair@5221 113 endif
ohair@5221 114
ihse@8330 115 ifneq ($(OPENJDK_TARGET_OS), linux)
ihse@8330 116 EXFILES += sun/tools/attach/LinuxAttachProvider.java \
ihse@8330 117 sun/tools/attach/LinuxVirtualMachine.java \
ihse@8330 118 sun/nio/ch/EPoll.java \
ihse@8330 119 sun/nio/ch/EPollArrayWrapper.java \
ihse@8330 120 sun/nio/ch/EPollPort.java \
ihse@8330 121 sun/nio/ch/EPollSelectorImpl.java \
ihse@8330 122 sun/nio/ch/EPollSelectorProvider.java \
ihse@8330 123 sun/nio/ch/LinuxAsynchronousChannelProvider.java \
ihse@8330 124 sun/nio/fs/LinuxDosFileAttributeView.java \
ihse@8330 125 sun/nio/fs/LinuxFileStore.java \
ihse@8330 126 sun/nio/fs/LinuxFileSystem.java \
ihse@8330 127 sun/nio/fs/LinuxFileSystemProvider.java \
ihse@8330 128 sun/nio/fs/MagicFileTypeDetector.java \
ihse@8330 129 sun/nio/fs/LinuxNativeDispatcher.java \
ihse@8330 130 sun/nio/fs/LinuxUserDefinedFileAttributeView.java \
ihse@8330 131 sun/nio/fs/LinuxWatchService.java
ohair@5221 132 endif
ohair@5221 133
ihse@8330 134 ifneq ($(OPENJDK_TARGET_OS), macosx)
ihse@8330 135 EXFILES += sun/nio/ch/BsdAsynchronousChannelProvider.java \
ihse@8330 136 sun/nio/ch/KQueue.java \
ihse@8330 137 sun/nio/ch/KQueuePort.java \
ihse@8330 138 sun/nio/fs/BsdFileStore.java \
ihse@8330 139 sun/nio/fs/BsdFileSystem.java \
ihse@8330 140 sun/nio/fs/BsdFileSystemProvider.java \
ihse@8330 141 sun/nio/fs/BsdNativeDispatcher.java \
ihse@8330 142 sun/nio/fs/MacOSXFileSystemProvider.java \
ihse@8330 143 sun/nio/fs/MacOSXFileSystem.java \
ihse@8330 144 sun/nio/fs/MacOSXNativeDispatcher.java \
ihse@8330 145 sun/tools/attach/BsdAttachProvider.java \
ihse@8330 146 sun/tools/attach/BsdVirtualMachine.java
ohair@5221 147 endif
ohair@5221 148
simonis@9185 149 ifneq ($(OPENJDK_TARGET_OS),aix)
simonis@9185 150 EXFILES+=sun/nio/ch/AixAsynchronousChannelProvider.java \
simonis@9185 151 sun/nio/ch/AixPollPort.java \
simonis@9185 152 sun/nio/fs/AixFileStore.java \
simonis@9185 153 sun/nio/fs/AixFileSystem.java \
simonis@9185 154 sun/nio/fs/AixFileSystemProvider.java \
simonis@9187 155 sun/nio/fs/AixNativeDispatcher.java \
simonis@9187 156 sun/tools/attach/AixAttachProvider.java \
simonis@9187 157 sun/tools/attach/AixVirtualMachine.java
simonis@9185 158 endif
simonis@9185 159
ohair@5221 160 # Exclude BreakIterator classes that are just used in compile process to generate
ohair@5221 161 # data files and shouldn't go in the product
ihse@8330 162 EXFILES += sun/text/resources/BreakIteratorRules.java \
ihse@8330 163 sun/text/resources/BreakIteratorRules_th.java
ohair@5221 164
ohair@5221 165 # TODO: Add BUILD_HEADLESS_ONLY to configure?
ohair@5221 166 ifdef BUILD_HEADLESS_ONLY
ihse@8330 167 EXCLUDES += sun/applet
ohair@5221 168 endif
ohair@5221 169
ohair@5221 170 ifdef OPENJDK
ihse@8330 171 EXCLUDES += sun/java2d/cmm/kcms
ohair@5221 172 endif
ohair@5221 173
erikj@5507 174 # Used on windows and macosx
ihse@8330 175 ifeq (, $(filter $(OPENJDK_TARGET_OS), windows macosx))
ihse@8330 176 EXFILES += sun/awt/AWTCharset.java
ohair@5221 177 endif
ohair@5221 178
dholmes@8500 179 ifeq ($(OPENJDK_TARGET_OS), macosx)
dholmes@8500 180 # exclude all X11 on Mac, we can't exclude some like below or we'll have compilation errors
dholmes@8500 181 EXCLUDES += sun/awt/X11
dholmes@8500 182 else
dholmes@8500 183 # TBD: figure out how to eliminate this long list
ihse@8330 184 EXFILES += sun/awt/X11/ScreenFormat.java \
ihse@8330 185 sun/awt/X11/XArc.java \
ihse@8330 186 sun/awt/X11/XChar2b.java \
ihse@8330 187 sun/awt/X11/XCharStruct.java \
ihse@8330 188 sun/awt/X11/XClassHint.java \
ihse@8330 189 sun/awt/X11/XComposeStatus.java \
ihse@8330 190 sun/awt/X11/XExtCodes.java \
ihse@8330 191 sun/awt/X11/XFontProp.java \
ihse@8330 192 sun/awt/X11/XFontSetExtents.java \
ihse@8330 193 sun/awt/X11/XFontStruct.java \
ihse@8330 194 sun/awt/X11/XGCValues.java \
ihse@8330 195 sun/awt/X11/XHostAddress.java \
ihse@8330 196 sun/awt/X11/XIMCallback.java \
ihse@8330 197 sun/awt/X11/XIMHotKeyTrigger.java \
ihse@8330 198 sun/awt/X11/XIMHotKeyTriggers.java \
ihse@8330 199 sun/awt/X11/XIMPreeditCaretCallbackStruct.java \
ihse@8330 200 sun/awt/X11/XIMPreeditDrawCallbackStruct.java \
ihse@8330 201 sun/awt/X11/XIMPreeditStateNotifyCallbackStruct.java \
ihse@8330 202 sun/awt/X11/XIMStatusDrawCallbackStruct.java \
ihse@8330 203 sun/awt/X11/XIMStringConversionCallbackStruct.java \
ihse@8330 204 sun/awt/X11/XIMStringConversionText.java \
ihse@8330 205 sun/awt/X11/XIMStyles.java \
ihse@8330 206 sun/awt/X11/XIMText.java \
ihse@8330 207 sun/awt/X11/XIMValuesList.java \
ihse@8330 208 sun/awt/X11/XImage.java \
ihse@8330 209 sun/awt/X11/XKeyboardControl.java \
ihse@8330 210 sun/awt/X11/XKeyboardState.java \
ihse@8330 211 sun/awt/X11/XOMCharSetList.java \
ihse@8330 212 sun/awt/X11/XOMFontInfo.java \
ihse@8330 213 sun/awt/X11/XOMOrientation.java \
ihse@8330 214 sun/awt/X11/XPoint.java \
ihse@8330 215 sun/awt/X11/XRectangle.java \
ihse@8330 216 sun/awt/X11/XSegment.java \
ihse@8330 217 sun/awt/X11/XStandardColormap.java \
ihse@8330 218 sun/awt/X11/XTextItem.java \
ihse@8330 219 sun/awt/X11/XTextItem16.java \
ihse@8330 220 sun/awt/X11/XTextProperty.java \
ihse@8330 221 sun/awt/X11/XTimeCoord.java \
ihse@8330 222 sun/awt/X11/XWindowChanges.java \
ihse@8330 223 sun/awt/X11/XdbeSwapInfo.java \
ihse@8330 224 sun/awt/X11/XmbTextItem.java \
ihse@8330 225 sun/awt/X11/XwcTextItem.java
erikj@5507 226 endif
ohair@5221 227
ohair@5221 228 # Exclude another implicitly not included file.
ihse@8330 229 EXFILES += sun/util/locale/AsciiUtil.java
ohair@5221 230
ihse@8330 231 ifeq (, $(filter $(OPENJDK_TARGET_OS), solaris macosx))
ihse@8330 232 #
ihse@8330 233 # only solaris and macosx
ihse@8330 234 #
ihse@8330 235 EXFILES += sun/nio/fs/PollingWatchService.java
ohair@5221 236 endif
ohair@5221 237
ohair@5221 238 # TODO: Fix when converting NIO
ohair@5221 239 # Exclude *-linux-arm.java and *-linux-ppc.java from closed.
ihse@8330 240 EXFILES += -linux-arm.java \
ihse@8330 241 -linux-ppc.java
ohair@5221 242
erikj@5596 243 ifeq ($(OPENJDK_TARGET_OS), windows)
ihse@8330 244 EXFILES += sun/nio/ch/AbstractPollSelectorImpl.java \
ihse@8330 245 sun/nio/ch/PollSelectorProvider.java \
ihse@8330 246 sun/nio/ch/SimpleAsynchronousFileChannelImpl.java
ohair@5221 247 endif
ohair@5221 248
erikj@6358 249 # These files do not appear in the build result of the old build. This
erikj@6358 250 # is because they are generated sources, but the AUTO_JAVA_FILES won't
ihse@8330 251 # pick them up since they aren't generated when the source dirs are
erikj@6358 252 # searched and they aren't referenced by any other classes so they won't
erikj@6358 253 # be picked up by implicit compilation. On a rebuild, they are picked up
ihse@8330 254 # and compiled. Exclude them here to produce the same rt.jar as the old
erikj@6358 255 # build does when building just once.
ihse@8330 256 EXFILES += javax/swing/plaf/nimbus/InternalFrameTitlePanePainter.java \
ihse@8330 257 javax/swing/plaf/nimbus/OptionPaneMessageAreaPainter.java \
ihse@8330 258 javax/swing/plaf/nimbus/ScrollBarPainter.java \
ihse@8330 259 javax/swing/plaf/nimbus/SliderPainter.java \
ihse@8330 260 javax/swing/plaf/nimbus/SpinnerPainter.java \
ihse@8330 261 javax/swing/plaf/nimbus/SplitPanePainter.java \
ihse@8330 262 javax/swing/plaf/nimbus/TabbedPanePainter.java
erikj@5507 263
ohair@5221 264 # Acquire a list of files that should be copied straight over to the classes.
ohair@5221 265 include CopyIntoClasses.gmk
ohair@5221 266 # Now we have COPY_PATTERNS, COPY_FILES and COPY_EXTRA
ohair@5221 267
ohair@5221 268 ifndef OPENJDK
ihse@8330 269 CLOSED_SRC_DIRS := $(JDK_TOPDIR)/src/closed/share/classes \
ihse@8330 270 $(JDK_TOPDIR)/src/closed/$(OPENJDK_TARGET_OS_API_DIR)/classes
ohair@5221 271 endif
ohair@5221 272
erikj@5507 273 MACOSX_SRC_DIRS :=
ihse@8330 274 ifeq ($(OPENJDK_TARGET_OS), macosx)
ihse@8330 275 MACOSX_SRC_DIRS += $(JDK_TOPDIR)/src/macosx/classes
erikj@5507 276
ihse@8330 277 # this files are duplicated in MACOSX_SRC_DIRS
ihse@8330 278 EXFILES += $(JDK_TOPDIR)/src/solaris/classes/sun/nio/ch/DefaultSelectorProvider.java \
ihse@8330 279 $(JDK_TOPDIR)/src/solaris/classes/sun/java2d/BackBufferCapsProvider.java \
ihse@8330 280 $(JDK_TOPDIR)/src/solaris/classes/java/net/DefaultInterface.java \
ihse@8330 281 $(JDK_TOPDIR)/src/solaris/classes/java/lang/ClassLoaderHelper.java \
ihse@8330 282 $(JDK_TOPDIR)/src/solaris/classes/sun/util/locale/provider/HostLocaleProviderAdapterImpl.java \
lana@8479 283 $(JDK_TOPDIR)/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java \
lana@8479 284 $(JDK_TOPDIR)/src/solaris/classes/sun/nio/ch/sctp/SctpChannelImpl.java \
lana@8479 285 $(JDK_TOPDIR)/src/solaris/classes/sun/nio/ch/sctp/SctpMultiChannelImpl.java \
lana@8479 286 $(JDK_TOPDIR)/src/solaris/classes/sun/nio/ch/sctp/SctpServerChannelImpl.java
erikj@5596 287
ihse@8330 288 # JObjC.jar contains 1.5 byte-code...so skip it here :-(
ihse@8330 289 # MACOSX_SRC_DIRS += $(JDK_TOPDIR)/src/macosx/native/jobjc/src
ihse@8330 290 # EXCLUDES += tests/java/com/apple/jobjc
erikj@5596 291
ihse@8330 292 EXCLUDES += com/apple/jobjc
erikj@5507 293 endif
erikj@5507 294
erikj@8498 295 # The security classes should not end up in the classes directory as that will prevent them
erikj@8498 296 # from working when running the exploded jdk image. Compile them separately to a different
erikj@8498 297 # directory from where the jars can be created.
erikj@8498 298 SECURITY_PKGS := \
erikj@8498 299 com/oracle/security/ucrypto \
erikj@8498 300 com/sun/crypto/provider \
erikj@8498 301 javax/crypto \
erikj@8498 302 sun/security/ec \
erikj@8498 303 sun/security/internal \
erikj@8498 304 sun/security/mscapi \
erikj@8498 305 sun/security/pkcs11 \
erikj@8498 306 #
erikj@8498 307
simonis@9187 308 AIX_SRC_DIRS :=
simonis@9187 309 ifeq ($(OPENJDK_TARGET_OS),aix)
simonis@9187 310 AIX_SRC_DIRS += $(JDK_TOPDIR)/src/aix/classes
simonis@9187 311 endif
simonis@9187 312
erikj@5507 313 # The exception handling of swing beaninfo
erikj@5507 314 # These resources violates the convention of having code and resources together under
erikj@5507 315 # $(JDK_TOPDIR)/src/.../classes directories
ihse@8845 316 $(JDK_OUTPUTDIR)/classes/javax/swing/beaninfo/images/%.gif: $(JDK_TOPDIR)/make/data/swingbeaninfo/images/%.gif
erikj@6824 317 $(call install-file)
erikj@5507 318
ohair@5819 319 # The JDK_USER_DEFINED_FILTER is a poor man's incremental build: by specifying
ohair@5819 320 # JDK_FILTER at the make command line, only a subset of the JDK java files will
ohair@5819 321 # be recompiled. If multiple paths are separated by comma, convert that into a
ohair@5819 322 # space separated list.
ihse@8330 323 JDK_USER_DEFINED_FILTER := $(strip $(subst $(COMMA),$(SPACE), $(JDK_FILTER)))
ohair@5819 324
erikj@8498 325 ifeq ($(ENABLE_SJAVAC),yes)
erikj@8498 326 # With sjavac enabled, excluded sources are not even considered for linking.
erikj@8498 327 # Explicitly add the security sources to sourcepath for linking.
erikj@8498 328 BUILD_JDK_SOURCEPATH:=$(patsubst %,-i$(SPACE)%.*,$(subst /,.,$(SECURITY_PKGS))) \
erikj@8498 329 -sourcepath $(JDK_TOPDIR)/src/share/classes
erikj@8498 330 endif
erikj@8498 331
erikj@8498 332 $(eval $(call SetupJavaCompilation,BUILD_JDK,\
erikj@8498 333 SETUP:=GENERATE_JDKBYTECODE,\
erikj@8498 334 SRC:=$(JDK_TOPDIR)/src/share/classes \
erikj@8498 335 $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes \
erikj@8498 336 $(MACOSX_SRC_DIRS) \
simonis@9187 337 $(AIX_SRC_DIRS) \
erikj@8498 338 $(JDK_OUTPUTDIR)/gensrc \
erikj@8498 339 $(JDK_OUTPUTDIR)/gensrc_no_srczip \
erikj@8498 340 $(CLOSED_SRC_DIRS),\
erikj@8498 341 INCLUDES:=$(JDK_USER_DEFINED_FILTER),\
erikj@8498 342 EXCLUDES:=$(EXCLUDES) $(SECURITY_PKGS),\
erikj@8498 343 EXCLUDE_FILES:=$(EXFILES),\
erikj@8498 344 BIN:=$(JDK_OUTPUTDIR)/classes,\
erikj@8498 345 COPY:=$(COPY_PATTERNS),\
erikj@8498 346 COPY_FILES:=$(COPY_FILES),\
erikj@8498 347 HEADERS:=$(JDK_OUTPUTDIR)/gensrc_headers,\
erikj@8498 348 ADD_JAVAC_FLAGS:=$(BUILD_JDK_SOURCEPATH)))
erikj@8498 349
erikj@8498 350 ##########################################################################################
erikj@8498 351
erikj@8498 352 $(eval $(call SetupJavaCompilation,BUILD_SECURITY, \
ihse@8330 353 SETUP := GENERATE_JDKBYTECODE, \
ihse@8330 354 SRC := $(JDK_TOPDIR)/src/share/classes \
erikj@8498 355 $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes \
erikj@8498 356 $(MACOSX_SRC_DIRS) \
erikj@8498 357 $(CLOSED_SRC_DIRS), \
erikj@8498 358 INCLUDES := $(SECURITY_PKGS), \
ihse@8330 359 EXCLUDES := $(EXCLUDES), \
ihse@8330 360 EXCLUDE_FILES := $(EXFILES), \
erikj@8498 361 BIN := $(JDK_OUTPUTDIR)/classes_security, \
ihse@8330 362 HEADERS := $(JDK_OUTPUTDIR)/gensrc_headers))
ohair@5221 363
erikj@8498 364 $(BUILD_SECURITY): $(BUILD_JDK)
erikj@8498 365
erikj@5507 366 ##########################################################################################
erikj@5507 367
erikj@5507 368 $(JDK_OUTPUTDIR)/classes/META-INF/services/com.sun.tools.xjc.Plugin:
erikj@5507 369 $(MKDIR) -p $(@D)
erikj@5507 370 $(TOUCH) $@
erikj@5507 371
erikj@5507 372 ##########################################################################################
erikj@5507 373
ihse@8330 374 ifeq ($(OPENJDK_TARGET_OS), macosx)
ihse@8330 375 #
ihse@8330 376 # JObjC.jar is compiled with BOOT_JAVAC which (may) not support the "-h" flag.
ihse@8330 377 # so we first compile classes with BOOT_JAVAC and then with JDK_JAVAC :-(
ihse@8330 378 #
ihse@8330 379 $(eval $(call SetupJavaCompiler,GENERATE_15BYTECODE, \
ihse@8330 380 JAVAC := $(JAVAC), \
ihse@8330 381 FLAGS := -source 1.5 -target 1.5 -g -bootclasspath $(BOOT_RTJAR) -cp $(JDK_OUTPUTDIR)/../langtools/dist/lib/classes.jar $(DISABLE_WARNINGS), \
ihse@8330 382 SERVER_DIR := $(SJAVAC_SERVER_DIR), \
ihse@8330 383 SERVER_JVM := $(SJAVAC_SERVER_JAVA)))
erikj@5596 384
ihse@8330 385 $(eval $(call SetupJavaCompilation,BUILD_JOBJC, \
ihse@8330 386 SETUP := GENERATE_15BYTECODE, \
ihse@8330 387 DISABLE_SJAVAC := true, \
ihse@8330 388 SRC := $(JDK_TOPDIR)/src/macosx/native/jobjc/src/core/java \
ihse@8330 389 $(JDK_TOPDIR)/src/macosx/native/jobjc/src/runtime-additions/java \
ihse@8330 390 $(JDK_OUTPUTDIR)/gensrc_jobjc/src, \
ihse@8330 391 INCLUDES := com/apple/jobjc, \
ihse@8330 392 EXCLUDES := tests/java/com/apple/jobjc, \
ihse@8330 393 BIN := $(JDK_OUTPUTDIR)/jobjc_classes, \
ihse@8330 394 JAR := $(JDK_OUTPUTDIR)/lib/JObjC.jar, \
ihse@8330 395 JARINDEX := true))
erikj@5596 396
ihse@8330 397 $(BUILD_JOBJC): $(BUILD_JDK)
erikj@5596 398
ihse@8330 399 $(eval $(call SetupJavaCompilation,BUILD_JOBJC_HEADERS, \
ihse@8330 400 SETUP := GENERATE_JDKBYTECODE, \
ihse@8330 401 SRC := $(JDK_TOPDIR)/src/macosx/native/jobjc/src/core/java \
ihse@8330 402 $(JDK_TOPDIR)/src/macosx/native/jobjc/src/runtime-additions/java \
ihse@8330 403 $(JDK_OUTPUTDIR)/gensrc_jobjc/src, \
ihse@8330 404 INCLUDES := com/apple/jobjc, \
ihse@8330 405 EXCLUDES := tests/java/com/apple/jobjc, \
ihse@8330 406 BIN := $(JDK_OUTPUTDIR)/jobjc_classes_headers, \
ihse@8330 407 HEADERS := $(JDK_OUTPUTDIR)/gensrc_headers_jobjc))
erikj@5596 408
ihse@8330 409 $(BUILD_JOBJC_HEADERS): $(BUILD_JDK)
erikj@5596 410
erikj@5596 411 endif
erikj@5596 412
erikj@5596 413 ##########################################################################################
erikj@5596 414
raginip@6453 415 ifndef OPENJDK
ihse@8330 416 ifeq ($(OPENJDK_TARGET_OS), windows)
ihse@8330 417 ifeq ($(OPENJDK_TARGET_CPU_BITS), 32)
ihse@8330 418 $(eval $(call SetupJavaCompilation,BUILD_ACCESSBRIDGE_32, \
ihse@8330 419 SETUP := GENERATE_JDKBYTECODE, \
ihse@8330 420 JAVAC_FLAGS := -cp $(JDK_OUTPUTDIR)/classes, \
ihse@8330 421 SRC := $(JDK_OUTPUTDIR)/gensrc_ab/32bit, \
ihse@8330 422 BIN := $(JDK_OUTPUTDIR)/classes_ab/32bit))
raginip@6453 423
ihse@8330 424 $(BUILD_ACCESSBRIDGE_32): $(BUILD_JDK)
raginip@6453 425
ihse@8330 426 $(eval $(call SetupJavaCompilation,BUILD_ACCESSBRIDGE_LEGACY, \
ihse@8330 427 SETUP := GENERATE_JDKBYTECODE, \
ihse@8330 428 JAVAC_FLAGS := -cp $(JDK_OUTPUTDIR)/classes, \
ihse@8330 429 SRC := $(JDK_OUTPUTDIR)/gensrc_ab/legacy, \
ihse@8330 430 BIN := $(JDK_OUTPUTDIR)/classes_ab/legacy))
raginip@6453 431
ihse@8330 432 $(BUILD_ACCESSBRIDGE_LEGACY): $(BUILD_JDK)
raginip@6453 433
ihse@8330 434 else
raginip@6453 435
ihse@8330 436 $(eval $(call SetupJavaCompilation,BUILD_ACCESSBRIDGE_64, \
ihse@8330 437 SETUP := GENERATE_JDKBYTECODE, \
ihse@8330 438 JAVAC_FLAGS := -cp $(JDK_OUTPUTDIR)/classes, \
ihse@8330 439 SRC := $(JDK_OUTPUTDIR)/gensrc_ab/64bit, \
ihse@8330 440 BIN := $(JDK_OUTPUTDIR)/classes_ab/64bit))
raginip@6453 441
ihse@8330 442 $(BUILD_ACCESSBRIDGE_64): $(BUILD_JDK)
raginip@6453 443
ihse@8330 444 endif
ihse@8330 445 endif
raginip@6453 446 endif
raginip@6453 447
raginip@6453 448 ##########################################################################################
raginip@6453 449
erikj@8498 450 all: $(BUILD_JDK) $(BUILD_SECURITY) $(BUILD_JOBJC) $(BUILD_JOBJC_HEADERS) $(COPY_EXTRA) \
ihse@8330 451 $(JDK_OUTPUTDIR)/classes/META-INF/services/com.sun.tools.xjc.Plugin \
ihse@8330 452 $(BUILD_ACCESSBRIDGE_32) $(BUILD_ACCESSBRIDGE_64) \
ihse@8330 453 $(BUILD_ACCESSBRIDGE_LEGACY)
ohair@5221 454
ohair@5221 455 .PHONY: all