1 #
  2 # Copyright (c) 2011, 2024, Oracle and/or its affiliates. All rights reserved.
  3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  4 #
  5 # This code is free software; you can redistribute it and/or modify it
  6 # under the terms of the GNU General Public License version 2 only, as
  7 # published by the Free Software Foundation.  Oracle designates this
  8 # particular file as subject to the "Classpath" exception as provided
  9 # by Oracle in the LICENSE file that accompanied this code.
 10 #
 11 # This code is distributed in the hope that it will be useful, but WITHOUT
 12 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 13 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 14 # version 2 for more details (a copy is included in the LICENSE file that
 15 # accompanied this code).
 16 #
 17 # You should have received a copy of the GNU General Public License version
 18 # 2 along with this work; if not, write to the Free Software Foundation,
 19 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 20 #
 21 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
 22 # or visit www.oracle.com if you need additional information or have any
 23 # questions.
 24 #
 25 
 26 # Configured @DATE_WHEN_CONFIGURED@ to build
 27 # for target system @OPENJDK_TARGET_OS@-@OPENJDK_TARGET_CPU@
 28 #   (called @OPENJDK_TARGET_AUTOCONF_NAME@ by autoconf)
 29 # on build system @OPENJDK_BUILD_OS@-@OPENJDK_BUILD_CPU@
 30 #   (called @OPENJDK_BUILD_AUTOCONF_NAME@ by autoconf)
 31 # using 'configure @CONFIGURE_COMMAND_LINE@'
 32 
 33 # The command line given to configure.
 34 CONFIGURE_COMMAND_LINE := @CONFIGURE_COMMAND_LINE@
 35 # The current directory when configure was run
 36 CONFIGURE_START_DIR := @CONFIGURE_START_DIR@
 37 
 38 # How configure was originally called, if not called directly
 39 REAL_CONFIGURE_COMMAND_EXEC_SHORT := @REAL_CONFIGURE_COMMAND_EXEC_SHORT@
 40 REAL_CONFIGURE_COMMAND_EXEC_FULL := @REAL_CONFIGURE_COMMAND_EXEC_FULL@
 41 REAL_CONFIGURE_COMMAND_LINE := @REAL_CONFIGURE_COMMAND_LINE@
 42 
 43 # A self-referential reference to this file.
 44 SPEC := @SPEC@
 45 
 46 # Path to autoconf if overridden by the user, to be used by "make reconfigure"
 47 AUTOCONF := @AUTOCONF@
 48 
 49 # SPACE and COMMA are defined in MakeBase.gmk, but they are also used in
 50 # some definitions here, and are needed if MakeBase.gmk is not included before
 51 # this file.
 52 X :=
 53 SPACE := $(X) $(X)
 54 COMMA := ,
 55 
 56 # What make to use for main processing, after bootstrapping top-level Makefile.
 57 MAKE := @MAKE@
 58 
 59 # Make sure all shell commands are executed with a proper locale
 60 export LC_ALL := @LOCALE_USED@
 61 
 62 # Make sure we override any local CLASSPATH variable
 63 export CLASSPATH := @CLASSPATH@
 64 
 65 # The default make arguments
 66 MAKE_ARGS = $(MAKE_LOG_FLAGS) -r -R -I $(TOPDIR)/make/common SPEC=$(SPEC) \
 67     MAKE_LOG_FLAGS="$(MAKE_LOG_FLAGS)" $(MAKE_LOG_VARS)
 68 
 69 OUTPUT_SYNC_SUPPORTED := @OUTPUT_SYNC_SUPPORTED@
 70 OUTPUT_SYNC := @OUTPUT_SYNC@
 71 
 72 # Override the shell with bash
 73 BASH := @BASH@
 74 BASH_ARGS := @BASH_ARGS@
 75 SHELL := $(BASH) $(BASH_ARGS)
 76 
 77 # The "human readable" name of this configuration
 78 CONF_NAME := @CONF_NAME@
 79 
 80 # The built jdk will run in this target system.
 81 OPENJDK_TARGET_OS := @OPENJDK_TARGET_OS@
 82 OPENJDK_TARGET_OS_TYPE := @OPENJDK_TARGET_OS_TYPE@
 83 OPENJDK_TARGET_OS_ENV := @OPENJDK_TARGET_OS_ENV@
 84 OPENJDK_TARGET_OS_UPPERCASE := @OPENJDK_TARGET_OS_UPPERCASE@
 85 
 86 OPENJDK_TARGET_CPU := @OPENJDK_TARGET_CPU@
 87 OPENJDK_TARGET_CPU_ARCH := @OPENJDK_TARGET_CPU_ARCH@
 88 OPENJDK_TARGET_CPU_BITS := @OPENJDK_TARGET_CPU_BITS@
 89 OPENJDK_TARGET_CPU_ENDIAN := @OPENJDK_TARGET_CPU_ENDIAN@
 90 
 91 OPENJDK_TARGET_LIBC := @OPENJDK_TARGET_LIBC@
 92 
 93 COMPILE_TYPE := @COMPILE_TYPE@
 94 
 95 # Legacy support
 96 OPENJDK_TARGET_CPU_LEGACY := @OPENJDK_TARGET_CPU_LEGACY@
 97 OPENJDK_TARGET_CPU_LEGACY_LIB := @OPENJDK_TARGET_CPU_LEGACY_LIB@
 98 OPENJDK_TARGET_CPU_OSARCH := @OPENJDK_TARGET_CPU_OSARCH@
 99 OPENJDK_TARGET_OS_INCLUDE_SUBDIR := @OPENJDK_TARGET_OS_INCLUDE_SUBDIR@
100 
101 HOTSPOT_TARGET_OS := @HOTSPOT_TARGET_OS@
102 HOTSPOT_TARGET_OS_TYPE := @HOTSPOT_TARGET_OS_TYPE@
103 
104 HOTSPOT_TARGET_CPU := @HOTSPOT_TARGET_CPU@
105 HOTSPOT_TARGET_CPU_ARCH := @HOTSPOT_TARGET_CPU_ARCH@
106 HOTSPOT_TARGET_CPU_DEFINE := @HOTSPOT_TARGET_CPU_DEFINE@
107 
108 HOTSPOT_TARGET_LIBC := @HOTSPOT_TARGET_LIBC@
109 
110 OPENJDK_TARGET_BUNDLE_PLATFORM := @OPENJDK_TARGET_BUNDLE_PLATFORM@
111 JDK_ARCH_ABI_PROP_NAME := @JDK_ARCH_ABI_PROP_NAME@
112 
113 # We are building on this build system.
114 # When not cross-compiling, it is the same as the target.
115 OPENJDK_BUILD_OS := @OPENJDK_BUILD_OS@
116 OPENJDK_BUILD_OS_TYPE := @OPENJDK_BUILD_OS_TYPE@
117 OPENJDK_BUILD_OS_ENV := @OPENJDK_BUILD_OS_ENV@
118 
119 OPENJDK_BUILD_CPU := @OPENJDK_BUILD_CPU@
120 OPENJDK_BUILD_CPU_ARCH := @OPENJDK_BUILD_CPU_ARCH@
121 OPENJDK_BUILD_CPU_BITS := @OPENJDK_BUILD_CPU_BITS@
122 OPENJDK_BUILD_CPU_ENDIAN := @OPENJDK_BUILD_CPU_ENDIAN@
123 
124 OPENJDK_BUILD_LIBC := @OPENJDK_BUILD_LIBC@
125 
126 OPENJDK_BUILD_OS_INCLUDE_SUBDIR := @OPENJDK_TARGET_OS_INCLUDE_SUBDIR@
127 
128 # Target platform value in ModuleTarget class file attribute.
129 OPENJDK_MODULE_TARGET_PLATFORM := @OPENJDK_MODULE_TARGET_PLATFORM@
130 
131 # OS_* properties in release file
132 RELEASE_FILE_OS_NAME := @RELEASE_FILE_OS_NAME@
133 RELEASE_FILE_OS_ARCH := @RELEASE_FILE_OS_ARCH@
134 RELEASE_FILE_LIBC := @RELEASE_FILE_LIBC@
135 
136 SOURCE_DATE := @SOURCE_DATE@
137 ISO_8601_FORMAT_STRING := @ISO_8601_FORMAT_STRING@
138 
139 ifneq ($(SOURCE_DATE), updated)
140   # For "updated" source date value, these are set in InitSupport.gmk
141   export SOURCE_DATE_EPOCH := $(SOURCE_DATE)
142   SOURCE_DATE_ISO_8601 := @SOURCE_DATE_ISO_8601@
143 endif
144 
145 LIBM := @LIBM@
146 LIBDL := @LIBDL@
147 
148 WINENV_ROOT := @WINENV_ROOT@
149 WINENV_PREFIX := @WINENV_PREFIX@
150 
151 ifneq ($(findstring windows.wsl, @OPENJDK_BUILD_OS_ENV@), )
152   # Tell WSL to convert PATH between linux and windows
153   export WSLENV := PATH/l
154 else ifeq (@OPENJDK_BUILD_OS_ENV@, windows.msys2)
155   # Prohibit msys2 from attempting any path wrangling
156   export MSYS2_ARG_CONV_EXCL := "*"
157 endif
158 
159 # Save the original path before replacing it with the Visual Studio tools
160 ORIGINAL_PATH := @ORIGINAL_PATH@
161 
162 ifeq (@TOOLCHAIN_TYPE@, microsoft)
163   # The Visual Studio toolchain needs the PATH to be adjusted to include
164   # Visual Studio tools.
165   export PATH := @TOOLCHAIN_PATH@:$(PATH)
166 endif
167 
168 SYSROOT_CFLAGS := @SYSROOT_CFLAGS@
169 SYSROOT_LDFLAGS := @SYSROOT_LDFLAGS@
170 
171 # The top-level directory of the source repository
172 TOPDIR := @TOPDIR@
173 # Usually the top level directory, but could be something else if a custom
174 # root is defined.
175 WORKSPACE_ROOT := @WORKSPACE_ROOT@
176 IMPORT_MODULES_CLASSES := @IMPORT_MODULES_CLASSES@
177 IMPORT_MODULES_CMDS := @IMPORT_MODULES_CMDS@
178 IMPORT_MODULES_LIBS := @IMPORT_MODULES_LIBS@
179 IMPORT_MODULES_CONF := @IMPORT_MODULES_CONF@
180 IMPORT_MODULES_LEGAL := @IMPORT_MODULES_LEGAL@
181 IMPORT_MODULES_MAN := @IMPORT_MODULES_MAN@
182 IMPORT_MODULES_SRC := @IMPORT_MODULES_SRC@
183 IMPORT_MODULES_MAKE := @IMPORT_MODULES_MAKE@
184 
185 COPYRIGHT_YEAR := @COPYRIGHT_YEAR@
186 HOTSPOT_BUILD_TIME := @HOTSPOT_BUILD_TIME@
187 
188 # Platform naming variables
189 LAUNCHER_NAME := @LAUNCHER_NAME@
190 PRODUCT_NAME := @PRODUCT_NAME@
191 PRODUCT_SUFFIX := @PRODUCT_SUFFIX@
192 JDK_RC_PLATFORM_NAME := @JDK_RC_PLATFORM_NAME@
193 JDK_RC_NAME := @JDK_RC_NAME@
194 JDK_RC_COMPANY_NAME := @JDK_RC_COMPANY_NAME@
195 COMPANY_NAME := @COMPANY_NAME@
196 HOTSPOT_VM_DISTRO := @HOTSPOT_VM_DISTRO@
197 MACOSX_BUNDLE_NAME_BASE := @MACOSX_BUNDLE_NAME_BASE@
198 MACOSX_BUNDLE_ID_BASE := @MACOSX_BUNDLE_ID_BASE@
199 MACOSX_BUNDLE_BUILD_VERSION := @MACOSX_BUNDLE_BUILD_VERSION@
200 USERNAME := @USERNAME@
201 VENDOR_URL := @VENDOR_URL@
202 VENDOR_URL_BUG := @VENDOR_URL_BUG@
203 VENDOR_URL_VM_BUG := @VENDOR_URL_VM_BUG@
204 
205 # New (JEP-223) version information
206 
207 ## Building blocks of the version string
208 # First three version numbers, with well-specified meanings (numerical)
209 VERSION_FEATURE := @VERSION_FEATURE@
210 VERSION_INTERIM := @VERSION_INTERIM@
211 VERSION_UPDATE := @VERSION_UPDATE@
212 VERSION_PATCH := @VERSION_PATCH@
213 VERSION_EXTRA1 := @VERSION_EXTRA1@
214 VERSION_EXTRA2 := @VERSION_EXTRA2@
215 VERSION_EXTRA3 := @VERSION_EXTRA3@
216 # The pre-release identifier (string)
217 VERSION_PRE := @VERSION_PRE@
218 # The build number (numerical)
219 VERSION_BUILD := @VERSION_BUILD@
220 # Optional build information (string)
221 VERSION_OPT := @VERSION_OPT@
222 
223 ## Composite variables
224 # The version number as a dot separated sequence of numbers, e.g. 9.0.1
225 VERSION_NUMBER := @VERSION_NUMBER@
226 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions.
227 VERSION_NUMBER_FOUR_POSITIONS := @VERSION_NUMBER_FOUR_POSITIONS@
228 # The complete version string, with additional build information
229 VERSION_STRING := @VERSION_STRING@
230 # The short version string, without trailing zeroes and just PRE, if present.
231 VERSION_SHORT := @VERSION_SHORT@
232 # The Java specification version. It usually equals the feature version number.
233 VERSION_SPECIFICATION := @VERSION_FEATURE@
234 # A GA version is defined by the PRE string being empty. Rather than testing for
235 # that, this variable defines it with true/false.
236 VERSION_IS_GA := @VERSION_IS_GA@
237 
238 # Version date
239 VERSION_DATE := @VERSION_DATE@
240 
241 # Vendor version string
242 VENDOR_VERSION_STRING := @VENDOR_VERSION_STRING@
243 
244 # Class-file version
245 VERSION_CLASSFILE_MAJOR := @VERSION_CLASSFILE_MAJOR@
246 VERSION_CLASSFILE_MINOR := @VERSION_CLASSFILE_MINOR@
247 
248 # Version for API docs "new-since" feature
249 VERSION_DOCS_API_SINCE := @VERSION_DOCS_API_SINCE@
250 
251 JDK_SOURCE_TARGET_VERSION := @JDK_SOURCE_TARGET_VERSION@
252 
253 # Convenience CFLAGS settings for passing version information into native programs.
254 VERSION_CFLAGS = \
255     -DVERSION_FEATURE=$(VERSION_FEATURE) \
256     -DVERSION_INTERIM=$(VERSION_INTERIM) \
257     -DVERSION_UPDATE=$(VERSION_UPDATE) \
258     -DVERSION_PATCH=$(VERSION_PATCH) \
259     -DVERSION_EXTRA1=$(VERSION_EXTRA1) \
260     -DVERSION_EXTRA2=$(VERSION_EXTRA2) \
261     -DVERSION_EXTRA3=$(VERSION_EXTRA3) \
262     -DVERSION_PRE='"$(VERSION_PRE)"' \
263     -DVERSION_BUILD=$(VERSION_BUILD) \
264     -DVERSION_OPT='"$(VERSION_OPT)"' \
265     -DVERSION_NUMBER='"$(VERSION_NUMBER)"' \
266     -DVERSION_STRING='"$(VERSION_STRING)"' \
267     -DVERSION_SHORT='"$(VERSION_SHORT)"' \
268     -DVERSION_SPECIFICATION='"$(VERSION_SPECIFICATION)"' \
269     -DVERSION_DATE='"$(VERSION_DATE)"' \
270     -DVENDOR_VERSION_STRING='"$(VENDOR_VERSION_STRING)"' \
271     -DVERSION_CLASSFILE_MAJOR=$(VERSION_CLASSFILE_MAJOR) \
272     -DVERSION_CLASSFILE_MINOR=$(VERSION_CLASSFILE_MINOR) \
273     #
274 
275 ifneq ($(COMPANY_NAME),)
276   # COMPANY_NAME is set to "N/A" in make/conf/branding.conf by default,
277   # but can be customized with the '--with-vendor-name' configure option.
278   # Only export "VENDOR" to the build if COMPANY_NAME contains a real value.
279   # Otherwise the default value for VENDOR, which is used to set the "java.vendor"
280   # and "java.vm.vendor" properties is hard-coded into the source code (i.e. in
281   # VersionProps.java.template in the jdk for "java.vendor" and
282   # vm_version.cpp in the VM for "java.vm.vendor")
283   ifneq ($(COMPANY_NAME), N/A)
284     VERSION_CFLAGS += -DVENDOR='"$(COMPANY_NAME)"'
285   endif
286 endif
287 
288 # Only export VENDOR_URL, VENDOR_URL_BUG and VENDOR_VM_URL_BUG to the build if
289 # they are not empty. Otherwise, default values which are defined in the sources
290 # will be used.
291 ifneq ($(VENDOR_URL),)
292   VERSION_CFLAGS += -DVENDOR_URL='"$(VENDOR_URL)"'
293 endif
294 ifneq ($(VENDOR_URL_BUG),)
295   VERSION_CFLAGS += -DVENDOR_URL_BUG='"$(VENDOR_URL_BUG)"'
296 endif
297 ifneq ($(VENDOR_URL_VM_BUG),)
298   VERSION_CFLAGS += -DVENDOR_URL_VM_BUG='"$(VENDOR_URL_VM_BUG)"'
299 endif
300 
301 # Different naming strings generated from the above information.
302 RUNTIME_NAME = $(PRODUCT_NAME) $(PRODUCT_SUFFIX)
303 
304 # How to compile the code: release, fastdebug or slowdebug
305 DEBUG_LEVEL := @DEBUG_LEVEL@
306 HOTSPOT_DEBUG_LEVEL := @HOTSPOT_DEBUG_LEVEL@
307 
308 # Which JVM variants to build (space-separated list)
309 JVM_VARIANTS := @JVM_VARIANTS@
310 JVM_VARIANT_MAIN := @JVM_VARIANT_MAIN@
311 
312 # Lists of features per variant. Only relevant for the variants listed in
313 # JVM_VARIANTS.
314 JVM_FEATURES_server := @JVM_FEATURES_server@
315 JVM_FEATURES_client := @JVM_FEATURES_client@
316 JVM_FEATURES_core := @JVM_FEATURES_core@
317 JVM_FEATURES_minimal := @JVM_FEATURES_minimal@
318 JVM_FEATURES_zero := @JVM_FEATURES_zero@
319 JVM_FEATURES_custom := @JVM_FEATURES_custom@
320 
321 # Used for make-time verifications
322 VALID_JVM_FEATURES := @VALID_JVM_FEATURES@
323 VALID_JVM_VARIANTS := @VALID_JVM_VARIANTS@
324 
325 # Allow overriding the default hotspot library path
326 HOTSPOT_OVERRIDE_LIBPATH := @HOTSPOT_OVERRIDE_LIBPATH@
327 
328 # Control use of precompiled header in hotspot libjvm build
329 USE_PRECOMPILED_HEADER := @USE_PRECOMPILED_HEADER@
330 
331 # Only build headless support or not
332 ENABLE_HEADLESS_ONLY := @ENABLE_HEADLESS_ONLY@
333 
334 ENABLE_LINKTIME_GC := @ENABLE_LINKTIME_GC@
335 
336 # Ship debug symbols (e.g. pdbs on Windows)
337 SHIP_DEBUG_SYMBOLS := @SHIP_DEBUG_SYMBOLS@
338 
339 ENABLE_FULL_DOCS := @ENABLE_FULL_DOCS@
340 
341 # JDK_OUTPUTDIR specifies where a working jvm is built.
342 # You can run $(JDK_OUTPUTDIR)/bin/java
343 
344 OUTPUTDIR := @OUTPUTDIR@
345 # Colon left out to be able to override IMAGES_OUTPUTDIR for bootcycle-images
346 SUPPORT_OUTPUTDIR = $(OUTPUTDIR)/support
347 BUILDTOOLS_OUTPUTDIR = $(OUTPUTDIR)/buildtools
348 
349 HOTSPOT_OUTPUTDIR = $(OUTPUTDIR)/hotspot
350 JDK_OUTPUTDIR = $(OUTPUTDIR)/jdk
351 IMAGES_OUTPUTDIR = $(OUTPUTDIR)/images
352 BUNDLES_OUTPUTDIR = $(OUTPUTDIR)/bundles
353 TESTMAKE_OUTPUTDIR = $(OUTPUTDIR)/test-make
354 MAKESUPPORT_OUTPUTDIR = $(OUTPUTDIR)/make-support
355 
356 JAVA_TMP_DIR = $(SUPPORT_OUTPUTDIR)/javatmp
357 
358 # This does not get overridden in a bootcycle build
359 CONFIGURESUPPORT_OUTPUTDIR := @CONFIGURESUPPORT_OUTPUTDIR@
360 BUILDJDK_OUTPUTDIR = $(OUTPUTDIR)/buildjdk
361 
362 BUILD_FAILURE_HANDLER := @BUILD_FAILURE_HANDLER@
363 
364 BUILD_JTREG_TEST_THREAD_FACTORY := @BUILD_JTREG_TEST_THREAD_FACTORY@
365 
366 ENABLE_GENERATE_CLASSLIST := @ENABLE_GENERATE_CLASSLIST@
367 
368 EXCLUDE_TRANSLATIONS := @EXCLUDE_TRANSLATIONS@
369 
370 BUILD_MANPAGES := @BUILD_MANPAGES@
371 
372 BUILD_CDS_ARCHIVE := @BUILD_CDS_ARCHIVE@
373 BUILD_CDS_ARCHIVE_COH := @BUILD_CDS_ARCHIVE_COH@
374 
375 ENABLE_COMPATIBLE_CDS_ALIGNMENT := @ENABLE_COMPATIBLE_CDS_ALIGNMENT@
376 
377 ALLOW_ABSOLUTE_PATHS_IN_OUTPUT := @ALLOW_ABSOLUTE_PATHS_IN_OUTPUT@
378 
379 HSDIS_BACKEND := @HSDIS_BACKEND@
380 ENABLE_HSDIS_BUNDLING := @ENABLE_HSDIS_BUNDLING@
381 HSDIS_CFLAGS := @HSDIS_CFLAGS@
382 HSDIS_LDFLAGS := @HSDIS_LDFLAGS@
383 HSDIS_LIBS := @HSDIS_LIBS@
384 CAPSTONE_ARCH_AARCH64_NAME := @CAPSTONE_ARCH_AARCH64_NAME@
385 
386 # The boot jdk to use. This is overridden in bootcycle-spec.gmk. Make sure to keep
387 # it in sync.
388 BOOT_JDK := @BOOT_JDK@
389 
390 BUILD_JDK := @BUILD_JDK@
391 CREATE_BUILDJDK := @CREATE_BUILDJDK@
392 EXTERNAL_BUILDJDK := @EXTERNAL_BUILDJDK@
393 
394 # Whether the boot jdk jar supports --date=TIMESTAMP
395 BOOT_JDK_JAR_SUPPORTS_DATE := @BOOT_JDK_JAR_SUPPORTS_DATE@
396 
397 # When compiling Java source to be run by the boot jdk
398 # use these extra flags, eg -source 6 -target 6
399 BOOT_JDK_SOURCETARGET := @BOOT_JDK_SOURCETARGET@
400 
401 # Information about the build system
402 NUM_CORES := @NUM_CORES@
403 MEMORY_SIZE := @MEMORY_SIZE@
404 ENABLE_JAVAC_SERVER := @ENABLE_JAVAC_SERVER@
405 # Store javac server synchronization files here, and
406 # the javac server log files.
407 JAVAC_SERVER_DIR = $(MAKESUPPORT_OUTPUTDIR)/javacservers
408 
409 # Number of parallel jobs to use for compilation
410 JOBS ?= @JOBS@
411 TEST_JOBS ?= @TEST_JOBS@
412 
413 # Default make target
414 DEFAULT_MAKE_TARGET := @DEFAULT_MAKE_TARGET@
415 DEFAULT_LOG := @DEFAULT_LOG@
416 
417 # Fallback linker
418 ENABLE_FALLBACK_LINKER := @ENABLE_FALLBACK_LINKER@
419 
420 FREETYPE_TO_USE := @FREETYPE_TO_USE@
421 FREETYPE_LIBS := @FREETYPE_LIBS@
422 FREETYPE_CFLAGS := @FREETYPE_CFLAGS@
423 FONTCONFIG_CFLAGS := @FONTCONFIG_CFLAGS@
424 CUPS_CFLAGS := @CUPS_CFLAGS@
425 ALSA_LIBS := @ALSA_LIBS@
426 ALSA_CFLAGS := @ALSA_CFLAGS@
427 LIBFFI_LIBS := @LIBFFI_LIBS@
428 LIBFFI_CFLAGS := @LIBFFI_CFLAGS@
429 ENABLE_LIBFFI_BUNDLING := @ENABLE_LIBFFI_BUNDLING@
430 LIBFFI_LIB_FILE := @LIBFFI_LIB_FILE@
431 FILE_MACRO_CFLAGS := @FILE_MACRO_CFLAGS@
432 REPRODUCIBLE_CFLAGS := @REPRODUCIBLE_CFLAGS@
433 BRANCH_PROTECTION_CFLAGS := @BRANCH_PROTECTION_CFLAGS@
434 
435 STATIC_LIBS_CFLAGS := @STATIC_LIBS_CFLAGS@
436 
437 JMH_CORE_JAR := @JMH_CORE_JAR@
438 JMH_GENERATOR_JAR := @JMH_GENERATOR_JAR@
439 JMH_JOPT_SIMPLE_JAR := @JMH_JOPT_SIMPLE_JAR@
440 JMH_COMMONS_MATH_JAR := @JMH_COMMONS_MATH_JAR@
441 JMH_VERSION := @JMH_VERSION@
442 
443 GTEST_FRAMEWORK_SRC := @GTEST_FRAMEWORK_SRC@
444 
445 # Source file for cacerts
446 CACERTS_FILE := @CACERTS_FILE@
447 # Source folder for user provided cacerts PEM files
448 CACERTS_SRC := @CACERTS_SRC@
449 
450 # Enable unlimited crypto policy
451 UNLIMITED_CRYPTO := @UNLIMITED_CRYPTO@
452 
453 GCOV_ENABLED := @GCOV_ENABLED@
454 JCOV_ENABLED := @JCOV_ENABLED@
455 JCOV_HOME := @JCOV_HOME@
456 JCOV_INPUT_JDK := @JCOV_INPUT_JDK@
457 JCOV_FILTERS := @JCOV_FILTERS@
458 
459 # AddressSanitizer
460 ASAN_ENABLED := @ASAN_ENABLED@
461 
462 # LeakSanitizer
463 LSAN_ENABLED := @LSAN_ENABLED@
464 
465 # UndefinedBehaviorSanitizer
466 UBSAN_ENABLED := @UBSAN_ENABLED@
467 UBSAN_CFLAGS := @UBSAN_CFLAGS@
468 UBSAN_LDFLAGS := @UBSAN_LDFLAGS@
469 
470 # Necessary additional compiler flags to compile X11
471 X_CFLAGS := @X_CFLAGS@
472 X_LIBS := @X_LIBS@
473 
474 # The lowest required version of macosx
475 MACOSX_VERSION_MIN := @MACOSX_VERSION_MIN@
476 # The highest allowed version of macosx
477 MACOSX_VERSION_MAX := @MACOSX_VERSION_MAX@
478 
479 # The macosx code signing configuration
480 MACOSX_CODESIGN_MODE := @MACOSX_CODESIGN_MODE@
481 MACOSX_CODESIGN_IDENTITY := @MACOSX_CODESIGN_IDENTITY@
482 
483 # Toolchain type: gcc, clang, microsoft...
484 TOOLCHAIN_TYPE := @TOOLCHAIN_TYPE@
485 TOOLCHAIN_VERSION := @TOOLCHAIN_VERSION@
486 CC_VERSION_NUMBER := @CC_VERSION_NUMBER@
487 CXX_VERSION_NUMBER := @CXX_VERSION_NUMBER@
488 
489 # Legacy support
490 HOTSPOT_TOOLCHAIN_TYPE := @HOTSPOT_TOOLCHAIN_TYPE@
491 
492 CC_OUT_OPTION := @CC_OUT_OPTION@
493 
494 # Flags used for overriding the default opt setting for a C/C++ source file.
495 C_O_FLAG_HIGHEST_JVM := @C_O_FLAG_HIGHEST_JVM@
496 C_O_FLAG_HIGHEST := @C_O_FLAG_HIGHEST@
497 C_O_FLAG_HI := @C_O_FLAG_HI@
498 C_O_FLAG_NORM := @C_O_FLAG_NORM@
499 C_O_FLAG_NONE := @C_O_FLAG_NONE@
500 C_O_FLAG_SIZE := @C_O_FLAG_SIZE@
501 CXX_O_FLAG_HIGHEST_JVM := @CXX_O_FLAG_HIGHEST_JVM@
502 CXX_O_FLAG_HIGHEST := @CXX_O_FLAG_HIGHEST@
503 CXX_O_FLAG_HI := @CXX_O_FLAG_HI@
504 CXX_O_FLAG_NORM := @CXX_O_FLAG_NORM@
505 CXX_O_FLAG_NONE := @CXX_O_FLAG_NONE@
506 CXX_O_FLAG_SIZE := @CXX_O_FLAG_SIZE@
507 
508 GENDEPS_FLAGS := @GENDEPS_FLAGS@
509 
510 DISABLE_WARNING_PREFIX := @DISABLE_WARNING_PREFIX@
511 CFLAGS_WARNINGS_ARE_ERRORS := @CFLAGS_WARNINGS_ARE_ERRORS@
512 DISABLED_WARNINGS := @DISABLED_WARNINGS@
513 DISABLED_WARNINGS_C := @DISABLED_WARNINGS_C@
514 DISABLED_WARNINGS_CXX := @DISABLED_WARNINGS_CXX@
515 
516 # A global flag (true or false) determining if native warnings are considered errors.
517 WARNINGS_AS_ERRORS := @WARNINGS_AS_ERRORS@
518 
519 CFLAGS_CCACHE := @CFLAGS_CCACHE@
520 ADLC_LANGSTD_CXXFLAGS := @ADLC_LANGSTD_CXXFLAGS@
521 ADLC_LDFLAGS := @ADLC_LDFLAGS@
522 
523 # Tools that potentially need to be cross compilation aware.
524 CC := @CCACHE@ @ICECC@ @CC@
525 
526 # CFLAGS used to compile the jdk native libraries (C-code)
527 CFLAGS_JDKLIB := @CFLAGS_JDKLIB@
528 CXXFLAGS_JDKLIB := @CXXFLAGS_JDKLIB@
529 
530 # CFLAGS used to compile the jdk native launchers (C-code)
531 CFLAGS_JDKEXE := @CFLAGS_JDKEXE@
532 CXXFLAGS_JDKEXE := @CXXFLAGS_JDKEXE@
533 
534 FDLIBM_CFLAGS := @FDLIBM_CFLAGS@
535 JVM_CFLAGS := @JVM_CFLAGS@
536 JVM_LDFLAGS := @JVM_LDFLAGS@
537 JVM_ASFLAGS := @JVM_ASFLAGS@
538 JVM_LIBS := @JVM_LIBS@
539 
540 BASIC_ASFLAGS := @BASIC_ASFLAGS@
541 
542 MACHINE_FLAG := @MACHINE_FLAG@
543 
544 # These flags might contain variables set by a custom extension that is included later.
545 EXTRA_CFLAGS := @EXTRA_CFLAGS@
546 EXTRA_CXXFLAGS := @EXTRA_CXXFLAGS@
547 EXTRA_LDFLAGS := @EXTRA_LDFLAGS@
548 EXTRA_ASFLAGS := @EXTRA_ASFLAGS@
549 
550 CXX := @CCACHE@ @ICECC@ @CXX@
551 
552 CPP := @CPP@
553 
554 # The linker can be gcc or ld on unix systems, or link.exe on windows systems.
555 LD := @LD@
556 
557 SYSROOT := @SYSROOT@
558 
559 # LDFLAGS used to link the jdk native libraries (C-code)
560 LDFLAGS_JDKLIB := @LDFLAGS_JDKLIB@
561 
562 # LDFLAGS used to link the jdk native launchers (C-code)
563 LDFLAGS_JDKEXE := @LDFLAGS_JDKEXE@
564 
565 # LDFLAGS specific to C++ linking.
566 LDFLAGS_CXX_JDK := @LDFLAGS_CXX_JDK@
567 
568 # LDFLAGS specific to partial linking.
569 LDFLAGS_CXX_PARTIAL_LINKING := @LDFLAGS_CXX_PARTIAL_LINKING@
570 
571 # Sometimes a different linker is needed for c++ libs
572 LDCXX := @LDCXX@
573 # The flags for linking libstdc++ linker.
574 LIBCXX := @LIBCXX@
575 
576 # BUILD_CC/BUILD_LD is a compiler/linker that generates code that is runnable on the
577 # build platform.
578 BUILD_CC := @BUILD_ICECC@ @BUILD_CC@
579 BUILD_CXX := @BUILD_ICECC@ @BUILD_CXX@
580 BUILD_LD := @BUILD_LD@
581 BUILD_LDCXX := @BUILD_LDCXX@
582 BUILD_AS := @BUILD_AS@
583 BUILD_AR := @BUILD_AR@
584 BUILD_NM := @BUILD_NM@
585 BUILD_OBJCOPY := @BUILD_OBJCOPY@
586 BUILD_STRIP := @BUILD_STRIP@
587 BUILD_SYSROOT_CFLAGS := @BUILD_SYSROOT_CFLAGS@
588 BUILD_SYSROOT_LDFLAGS := @BUILD_SYSROOT_LDFLAGS@
589 
590 AS := @AS@
591 
592 AR := @AR@
593 ARFLAGS := @ARFLAGS@
594 LIB := @LIB@
595 LIBFLAGS := @LIBFLAGS@
596 NM := @NM@
597 NMFLAGS := @NMFLAGS@
598 STRIP := @STRIP@
599 OBJDUMP := @OBJDUMP@
600 CXXFILT := @CXXFILT@
601 
602 LIPO := @LIPO@
603 INSTALL_NAME_TOOL := @INSTALL_NAME_TOOL@
604 METAL := @METAL@
605 METALLIB := @METALLIB@
606 
607 #
608 # Options for generating debug symbols
609 COMPILE_WITH_DEBUG_SYMBOLS := @COMPILE_WITH_DEBUG_SYMBOLS@
610 COPY_DEBUG_SYMBOLS := @COPY_DEBUG_SYMBOLS@
611 ZIP_EXTERNAL_DEBUG_SYMBOLS := @ZIP_EXTERNAL_DEBUG_SYMBOLS@
612 
613 CFLAGS_DEBUG_SYMBOLS := @CFLAGS_DEBUG_SYMBOLS@
614 ASFLAGS_DEBUG_SYMBOLS := @ASFLAGS_DEBUG_SYMBOLS@
615 
616 #
617 # Compress (or not) jars
618 COMPRESS_JARS := @COMPRESS_JARS@
619 
620 # Options to linker to specify the library name.
621 # (Note absence of := assignment, because we do not want to evaluate the macro body here)
622 SET_SHARED_LIBRARY_NAME = @SET_SHARED_LIBRARY_NAME@
623 
624 SHARED_LIBRARY_FLAGS := @SHARED_LIBRARY_FLAGS@
625 
626 # Set origin using the linker, ie use the relative path to the dependent library to find the dependencies.
627 # (Note absence of := assignment, because we do not want to evaluate the macro body here)
628 SET_SHARED_LIBRARY_ORIGIN = @SET_SHARED_LIBRARY_ORIGIN@
629 SET_EXECUTABLE_ORIGIN = @SET_EXECUTABLE_ORIGIN@
630 
631 LIBRARY_PREFIX := @LIBRARY_PREFIX@
632 SHARED_LIBRARY_SUFFIX := @SHARED_LIBRARY_SUFFIX@
633 STATIC_LIBRARY_SUFFIX := @STATIC_LIBRARY_SUFFIX@
634 EXECUTABLE_SUFFIX := @EXECUTABLE_SUFFIX@
635 OBJ_SUFFIX := @OBJ_SUFFIX@
636 
637 STRIPFLAGS := @STRIPFLAGS@
638 
639 JAVA_FLAGS_TMPDIR := -Djava.io.tmpdir=$(JAVA_TMP_DIR)
640 JAVA_FLAGS := @JAVA_FLAGS@ $(JAVA_FLAGS_TMPDIR)
641 JAVA_FLAGS_BIG := @JAVA_FLAGS_BIG@
642 JAVA_FLAGS_SMALL := @JAVA_FLAGS_SMALL@
643 BUILD_JAVA_FLAGS_SMALL := @BUILD_JAVA_FLAGS_SMALL@
644 JAVA_TOOL_FLAGS_SMALL := @JAVA_TOOL_FLAGS_SMALL@
645 
646 # The *_CMD variables are defined separately to be easily overridden in bootcycle-spec.gmk
647 # for bootcycle-images build. Make sure to keep them in sync. Do not use the *_CMD
648 # versions of the variables directly.
649 JAVA_CMD := @JAVA@
650 JAVAC_CMD := @JAVAC@
651 JAVADOC_CMD := @JAVADOC@
652 JAR_CMD := @JAR@
653 JLINK_CMD := @JLINK@
654 JMOD_CMD := @JMOD@
655 # These variables are meant to be used. They are defined with = instead of := to make
656 # it possible to override only the *_CMD variables.
657 JAVA = $(JAVA_CMD) $(JAVA_FLAGS_BIG) $(JAVA_FLAGS)
658 JAVA_SMALL = $(JAVA_CMD) $(JAVA_FLAGS_SMALL) $(JAVA_FLAGS)
659 JAVAC = $(JAVAC_CMD)
660 JAVADOC = $(JAVADOC_CMD)
661 JAR = $(JAR_CMD)
662 JLINK = $(JLINK_CMD)
663 JMOD = $(JMOD_CMD)
664 
665 JTREG_JDK := @JTREG_JDK@
666 JTREG_JAVA = @FIXPATH@ $(JTREG_JDK)/bin/java $(JAVA_FLAGS_BIG) $(JAVA_FLAGS)
667 
668 BUILD_JAVA_FLAGS := @BOOTCYCLE_JVM_ARGS_BIG@
669 BUILD_JAVA = @FIXPATH@ $(BUILD_JDK)/bin/java $(BUILD_JAVA_FLAGS)
670 BUILD_JAVA_SMALL = @FIXPATH@ $(BUILD_JDK)/bin/java $(BUILD_JAVA_FLAGS_SMALL)
671 BUILD_JAVAC = @FIXPATH@ $(BUILD_JDK)/bin/javac
672 BUILD_JAR = @FIXPATH@ $(BUILD_JDK)/bin/jar
673 
674 DOCS_REFERENCE_JAVADOC := @DOCS_REFERENCE_JAVADOC@
675 
676 # A file containing a way to uniquely identify the source code revision that
677 # the build was created from
678 SOURCE_REVISION_TRACKER := $(SUPPORT_OUTPUTDIR)/src-rev/source-revision-tracker
679 
680 # Interim langtools modules and arguments
681 INTERIM_LANGTOOLS_BASE_MODULES := java.compiler jdk.compiler jdk.internal.md jdk.javadoc
682 INTERIM_LANGTOOLS_MODULES := $(addsuffix .interim, $(INTERIM_LANGTOOLS_BASE_MODULES))
683 INTERIM_LANGTOOLS_ADD_EXPORTS := \
684     --add-exports java.base/sun.reflect.annotation=jdk.compiler.interim \
685     --add-exports java.base/jdk.internal.jmod=jdk.compiler.interim \
686     --add-exports java.base/jdk.internal.misc=jdk.compiler.interim \
687     --add-exports java.base/sun.invoke.util=jdk.compiler.interim \
688     --add-exports java.base/jdk.internal.javac=java.compiler.interim \
689     --add-exports java.base/jdk.internal.javac=jdk.compiler.interim \
690     --add-exports jdk.internal.opt/jdk.internal.opt=jdk.compiler.interim \
691     --add-exports jdk.internal.opt/jdk.internal.opt=jdk.javadoc.interim \
692     #
693 INTERIM_LANGTOOLS_MODULES_COMMA := $(strip $(subst $(SPACE),$(COMMA),$(strip \
694     $(INTERIM_LANGTOOLS_MODULES))))
695 INTERIM_LANGTOOLS_ARGS := \
696     --limit-modules java.base,jdk.zipfs,$(INTERIM_LANGTOOLS_MODULES_COMMA) \
697     --add-modules $(INTERIM_LANGTOOLS_MODULES_COMMA) \
698     --module-path $(BUILDTOOLS_OUTPUTDIR)/interim_langtools_modules \
699     --patch-module java.base=$(BUILDTOOLS_OUTPUTDIR)/gensrc/java.base.interim \
700     $(INTERIM_LANGTOOLS_ADD_EXPORTS) \
701     #
702 JAVAC_MAIN_CLASS := -m jdk.compiler.interim/com.sun.tools.javac.Main
703 JAVADOC_MAIN_CLASS := -m jdk.javadoc.interim/jdk.javadoc.internal.tool.Main
704 
705 # You run the new javac using the boot jdk with $(BOOT_JDK)/bin/java $(NEW_JAVAC) ...
706 # Use = assignment to be able to override in bootcycle-spec.gmk
707 NEW_JAVAC = $(INTERIM_LANGTOOLS_ARGS) $(JAVAC_MAIN_CLASS)
708 NEW_JAVADOC = $(INTERIM_LANGTOOLS_ARGS) $(JAVADOC_MAIN_CLASS)
709 
710 JMOD_COMPRESS := @JMOD_COMPRESS@
711 JLINK_KEEP_PACKAGED_MODULES := @JLINK_KEEP_PACKAGED_MODULES@
712 
713 RCFLAGS := @RCFLAGS@
714 
715 # Tools adhering to a minimal and common standard of posix compliance.
716 AWK := @AWK@
717 BASENAME := @BASENAME@
718 CAT := @CAT@
719 CCACHE := @CCACHE@
720 # CD is going away, but remains to cater for legacy makefiles.
721 CD := cd
722 CHMOD := @CHMOD@
723 CODESIGN := @CODESIGN@
724 CP := @CP@
725 CUT := @CUT@
726 DATE := @DATE@
727 IS_GNU_DATE := @IS_GNU_DATE@
728 DIFF := @DIFF@
729 DIRNAME := @DIRNAME@
730 DSYMUTIL := @DSYMUTIL@
731 FIND := @FIND@
732 FIND_DELETE := @FIND_DELETE@
733 FLOCK := @FLOCK@
734 ECHO := @ECHO@
735 EGREP := @EGREP@
736 FGREP := @FGREP@
737 GREP := @GREP@
738 GZIP := @GZIP@
739 HEAD := @HEAD@
740 LS := @LS@
741 LN := @LN@
742 MIG := @MIG@
743 MKDIR := @MKDIR@
744 MV := @MV@
745 NICE := @NICE@
746 PANDOC := @PANDOC@
747 PATCH := @PATCH@
748 PRINTF := @PRINTF@
749 READLINK := @READLINK@
750 RM := @RM@
751 RMDIR := @RMDIR@
752 SED := @SED@
753 SH := @SH@
754 SORT := @SORT@
755 TAR := @TAR@
756 TAIL := @TAIL@
757 TEE := @TEE@
758 TIME := @TIME@
759 IS_GNU_TIME := @IS_GNU_TIME@
760 TR := @TR@
761 TOUCH := @TOUCH@
762 WC := @WC@
763 XARGS := @XARGS@
764 ZIPEXE := @ZIPEXE@
765 UNZIP := @UNZIP@
766 MT := @MT@
767 RC := @RC@
768 DUMPBIN := @DUMPBIN@
769 PATHTOOL := @PATHTOOL@
770 WSLPATH := @WSLPATH@
771 LDD := @LDD@
772 OTOOL := @OTOOL@
773 READELF := @READELF@
774 EXPR := @EXPR@
775 FILE := @FILE@
776 DOT := @DOT@
777 GIT := @GIT@
778 OBJCOPY := @OBJCOPY@
779 SETFILE := @SETFILE@
780 XATTR := @XATTR@
781 JT_HOME := @JT_HOME@
782 JIB_HOME := @JIB_HOME@
783 DTRACE := @DTRACE@
784 FIXPATH := @FIXPATH@
785 FIXPATH_BASE := @FIXPATH_BASE@
786 ULIMIT := @ULIMIT@
787 
788 TAR_TYPE := @TAR_TYPE@
789 TAR_INCLUDE_PARAM := @TAR_INCLUDE_PARAM@
790 TAR_SUPPORTS_TRANSFORM := @TAR_SUPPORTS_TRANSFORM@
791 
792 # Build setup
793 USE_EXTERNAL_LIBJPEG := @USE_EXTERNAL_LIBJPEG@
794 LIBJPEG_LIBS := @LIBJPEG_LIBS@
795 USE_EXTERNAL_LIBGIF := @USE_EXTERNAL_LIBGIF@
796 GIFLIB_LIBS := @GIFLIB_LIBS@
797 USE_EXTERNAL_LIBZ := @USE_EXTERNAL_LIBZ@
798 LIBZ_CFLAGS := @LIBZ_CFLAGS@
799 LIBZ_LIBS := @LIBZ_LIBS@
800 LIBZIP_CAN_USE_MMAP := @LIBZIP_CAN_USE_MMAP@
801 MSVCR_DLL := @MSVCR_DLL@
802 VCRUNTIME_1_DLL := @VCRUNTIME_1_DLL@
803 MSVCP_DLL := @MSVCP_DLL@
804 UCRT_DLL_DIR := @UCRT_DLL_DIR@
805 ENABLE_PANDOC := @ENABLE_PANDOC@
806 PANDOC_MARKDOWN_FLAG := @PANDOC_MARKDOWN_FLAG@
807 
808 ####################################################
809 #
810 # Libraries
811 #
812 
813 USE_EXTERNAL_LCMS := @USE_EXTERNAL_LCMS@
814 LCMS_CFLAGS := @LCMS_CFLAGS@
815 LCMS_LIBS := @LCMS_LIBS@
816 
817 USE_EXTERNAL_HARFBUZZ := @USE_EXTERNAL_HARFBUZZ@
818 HARFBUZZ_CFLAGS := @HARFBUZZ_CFLAGS@
819 HARFBUZZ_LIBS := @HARFBUZZ_LIBS@
820 
821 USE_EXTERNAL_LIBPNG := @USE_EXTERNAL_LIBPNG@
822 PNG_LIBS := @PNG_LIBS@
823 PNG_CFLAGS := @PNG_CFLAGS@
824 
825 ####################################################
826 #
827 # Misc
828 #
829 
830 INCLUDE_SA := @INCLUDE_SA@
831 INCLUDE_JVMCI := @INCLUDE_JVMCI@
832 INCLUDE_COMPILER2 := @INCLUDE_COMPILER2@
833 
834 OS_VERSION_MAJOR := @OS_VERSION_MAJOR@
835 OS_VERSION_MINOR := @OS_VERSION_MINOR@
836 OS_VERSION_MICRO := @OS_VERSION_MICRO@
837 
838 # Images directory definitions
839 JDK_IMAGE_SUBDIR := jdk
840 JRE_IMAGE_SUBDIR := jre
841 JCOV_IMAGE_SUBDIR := jdk-jcov
842 
843 # Colon left out to be able to override output dir for bootcycle-images
844 JDK_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(JDK_IMAGE_SUBDIR)
845 JRE_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(JRE_IMAGE_SUBDIR)
846 JCOV_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(JCOV_IMAGE_SUBDIR)
847 
848 # Test image, as above
849 TEST_IMAGE_SUBDIR := test
850 TEST_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(TEST_IMAGE_SUBDIR)
851 
852 # Symbols image
853 SYMBOLS_IMAGE_SUBDIR := symbols
854 SYMBOLS_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(SYMBOLS_IMAGE_SUBDIR)
855 
856 # Interim image
857 INTERIM_JMODS_DIR := $(SUPPORT_OUTPUTDIR)/interim-jmods
858 INTERIM_IMAGE_DIR := $(SUPPORT_OUTPUTDIR)/interim-image
859 
860 # Docs image
861 DOCS_JDK_IMAGE_SUBDIR := docs
862 DOCS_JDK_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(DOCS_JDK_IMAGE_SUBDIR)
863 DOCS_JAVASE_IMAGE_SUBDIR := docs-javase
864 DOCS_JAVASE_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(DOCS_JAVASE_IMAGE_SUBDIR)
865 DOCS_REFERENCE_IMAGE_SUBDIR := docs-reference
866 DOCS_REFERENCE_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(DOCS_REFERENCE_IMAGE_SUBDIR)
867 # Output docs directly into image
868 DOCS_OUTPUTDIR := $(DOCS_JDK_IMAGE_DIR)
869 
870 # Static libs image
871 STATIC_LIBS_IMAGE_SUBDIR := static-libs
872 STATIC_LIBS_IMAGE_DIR := $(IMAGES_OUTPUTDIR)/$(STATIC_LIBS_IMAGE_SUBDIR)
873 
874 # Graal static libs image
875 STATIC_LIBS_GRAAL_IMAGE_SUBDIR := static-libs-graal
876 STATIC_LIBS_GRAAL_IMAGE_DIR := $(IMAGES_OUTPUTDIR)/$(STATIC_LIBS_GRAAL_IMAGE_SUBDIR)
877 
878 # Graal builder image
879 GRAAL_BUILDER_IMAGE_SUBDIR := graal-builder-jdk
880 GRAAL_BUILDER_IMAGE_DIR := $(IMAGES_OUTPUTDIR)/$(GRAAL_BUILDER_IMAGE_SUBDIR)
881 
882 # Macosx bundles directory definitions
883 JDK_MACOSX_BUNDLE_SUBDIR := jdk-bundle
884 JRE_MACOSX_BUNDLE_SUBDIR := jre-bundle
885 JDK_MACOSX_BUNDLE_SUBDIR_SIGNED := jdk-bundle-signed
886 JRE_MACOSX_BUNDLE_SUBDIR_SIGNED := jre-bundle-signed
887 JDK_MACOSX_BUNDLE_DIR = $(IMAGES_OUTPUTDIR)/$(JDK_MACOSX_BUNDLE_SUBDIR)
888 JRE_MACOSX_BUNDLE_DIR = $(IMAGES_OUTPUTDIR)/$(JRE_MACOSX_BUNDLE_SUBDIR)
889 JDK_MACOSX_BUNDLE_DIR_SIGNED = $(IMAGES_OUTPUTDIR)/$(JDK_MACOSX_BUNDLE_SUBDIR_SIGNED)
890 JRE_MACOSX_BUNDLE_DIR_SIGNED = $(IMAGES_OUTPUTDIR)/$(JRE_MACOSX_BUNDLE_SUBDIR_SIGNED)
891 JDK_MACOSX_BUNDLE_TOP_DIR = jdk-$(VERSION_NUMBER).jdk
892 JRE_MACOSX_BUNDLE_TOP_DIR = jre-$(VERSION_NUMBER).jre
893 JDK_MACOSX_CONTENTS_SUBDIR = $(JDK_MACOSX_BUNDLE_TOP_DIR)/Contents
894 JRE_MACOSX_CONTENTS_SUBDIR = $(JRE_MACOSX_BUNDLE_TOP_DIR)/Contents
895 JDK_MACOSX_CONTENTS_DIR = $(JDK_MACOSX_BUNDLE_DIR)/$(JDK_MACOSX_CONTENTS_SUBDIR)
896 JRE_MACOSX_CONTENTS_DIR = $(JRE_MACOSX_BUNDLE_DIR)/$(JRE_MACOSX_CONTENTS_SUBDIR)
897 
898 # Bundle names
899 ifneq ($(VERSION_BUILD), )
900   BASE_NAME := $(VERSION_SHORT)+$(VERSION_BUILD)_$(OPENJDK_TARGET_BUNDLE_PLATFORM)
901 else
902   BASE_NAME := $(VERSION_SHORT)_$(OPENJDK_TARGET_BUNDLE_PLATFORM)
903 endif
904 
905 ifeq ($(DEBUG_LEVEL), fastdebug)
906   DEBUG_PART := -debug
907 else ifneq ($(DEBUG_LEVEL), release)
908   DEBUG_PART := -$(DEBUG_LEVEL)
909 endif
910 ifeq ($(OPENJDK_TARGET_OS), windows)
911   JDK_BUNDLE_EXTENSION := zip
912 else
913   JDK_BUNDLE_EXTENSION := tar.gz
914 endif
915 JDK_BUNDLE_NAME := jdk-$(BASE_NAME)_bin$(DEBUG_PART).$(JDK_BUNDLE_EXTENSION)
916 JRE_BUNDLE_NAME := jre-$(BASE_NAME)_bin$(DEBUG_PART).$(JDK_BUNDLE_EXTENSION)
917 JDK_SYMBOLS_BUNDLE_NAME := jdk-$(BASE_NAME)_bin$(DEBUG_PART)-symbols.tar.gz
918 TEST_DEMOS_BUNDLE_NAME := jdk-$(BASE_NAME)_bin-tests-demos$(DEBUG_PART).tar.gz
919 TEST_BUNDLE_NAME := jdk-$(BASE_NAME)_bin-tests$(DEBUG_PART).tar.gz
920 DOCS_JDK_BUNDLE_NAME := jdk-$(BASE_NAME)_doc-api-spec$(DEBUG_PART).tar.gz
921 DOCS_JAVASE_BUNDLE_NAME := javase-$(BASE_NAME)_doc-api-spec$(DEBUG_PART).tar.gz
922 DOCS_REFERENCE_BUNDLE_NAME := jdk-reference-$(BASE_NAME)_doc-api-spec$(DEBUG_PART).tar.gz
923 STATIC_LIBS_BUNDLE_NAME := jdk-$(BASE_NAME)_bin-static-libs$(DEBUG_PART).tar.gz
924 STATIC_LIBS_GRAAL_BUNDLE_NAME := jdk-$(BASE_NAME)_bin-static-libs-graal$(DEBUG_PART).tar.gz
925 JCOV_BUNDLE_NAME := jdk-jcov-$(BASE_NAME)_bin$(DEBUG_PART).$(JDK_BUNDLE_EXTENSION)
926 
927 JDK_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JDK_BUNDLE_NAME)
928 JRE_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JRE_BUNDLE_NAME)
929 JDK_SYMBOLS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JDK_SYMBOLS_BUNDLE_NAME)
930 TEST_DEMOS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(TEST_DEMOS_BUNDLE_NAME)
931 TEST_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(TEST_BUNDLE_NAME)
932 DOCS_JDK_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(DOCS_JDK_BUNDLE_NAME)
933 DOCS_JAVASE_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(DOCS_JAVASE_BUNDLE_NAME)
934 DOCS_REFERENCE_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(DOCS_REFERENCE_BUNDLE_NAME)
935 JCOV_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JCOV_BUNDLE_NAME)
936 
937 # This macro is called to allow inclusion of closed source counterparts.
938 # Unless overridden in closed sources, it expands to nothing.
939 # Usage: This function is called in an open makefile, with the following
940 # argument:
941 # $1 the name of the makefile
942 define IncludeCustomExtension
943 endef
944 
945 # Include the custom-spec.gmk file if it exists
946 -include $(dir @SPEC@)/custom-spec.gmk