spec.gmk.in revision 476:2ba6f4da4bf3
1#
2# Copyright (c) 2011, 2012, 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# When calling macros, the spaces between arguments are 
34# often semantically important! Sometimes we need to subst 
35# spaces and commas, therefore we need the following macros.
36X:=
37SPACE:=$(X) $(X)
38COMMA:=,
39HASH:=\#
40SQUOTE:='
41#'
42DQUOTE:="
43#"
44define NEWLINE:=
45endef
46
47# A self-referential reference to this file.
48SPEC:=@SPEC@
49
50# Specify where the spec file is.
51MAKE_ARGS="SPEC=$(SPEC)"
52
53# TODO The logic for finding and setting MAKE is currently not working 
54# well on windows. Disable it TEMPORARILY there for now.
55ifneq (@OPENJDK_TARGET_OS@,windows)
56    MAKE:=@MAKE@
57endif
58
59# Pass along the verbosity setting.
60ifeq (,$(findstring VERBOSE=,$(MAKE)))
61    MAKE:=$(MAKE) $(VERBOSE) VERBOSE="$(VERBOSE)"
62endif
63
64# No implicit variables or rules!
65ifeq (,$(findstring -R,$(MAKE)))
66    MAKE:=$(MAKE) -R
67endif
68
69# Specify where the common include directory for makefiles is.
70ifeq (,$(findstring -I @SRC_ROOT@/common/makefiles,$(MAKE)))
71    MAKE:=$(MAKE) -I @SRC_ROOT@/common/makefiles
72endif
73
74# The "human readable" name of this configuration
75CONF_NAME:=@CONF_NAME@
76
77# The built jdk will run in this target system.
78OPENJDK_TARGET_OS:=@OPENJDK_TARGET_OS@
79OPENJDK_TARGET_OS_API:=@OPENJDK_TARGET_OS_API@
80
81OPENJDK_TARGET_CPU:=@OPENJDK_TARGET_CPU@
82OPENJDK_TARGET_CPU_ARCH:=@OPENJDK_TARGET_CPU_ARCH@
83OPENJDK_TARGET_CPU_BITS:=@OPENJDK_TARGET_CPU_BITS@
84OPENJDK_TARGET_CPU_ENDIAN:=@OPENJDK_TARGET_CPU_ENDIAN@
85
86COMPILE_TYPE:=@COMPILE_TYPE@
87
88# Legacy support
89OPENJDK_TARGET_CPU_ISADIR:=@OPENJDK_TARGET_CPU_ISADIR@
90OPENJDK_TARGET_CPU_LIBDIR:=@OPENJDK_TARGET_CPU_LIBDIR@
91OPENJDK_TARGET_CPU_LEGACY:=@OPENJDK_TARGET_CPU_LEGACY@
92OPENJDK_TARGET_CPU_LEGACY_LIB:=@OPENJDK_TARGET_CPU_LEGACY_LIB@
93OPENJDK_TARGET_CPU_OSARCH:=@OPENJDK_TARGET_CPU_OSARCH@
94OPENJDK_TARGET_CPU_JLI_CFLAGS:=@OPENJDK_TARGET_CPU_JLI_CFLAGS@
95OPENJDK_TARGET_OS_API_DIR:=@OPENJDK_TARGET_OS_API_DIR@
96
97# We are building on this build system.
98# When not cross-compiling, it is the same as the target.
99OPENJDK_BUILD_OS:=@OPENJDK_BUILD_OS@
100OPENJDK_BUILD_OS_API:=@OPENJDK_BUILD_OS_API@
101
102OPENJDK_BUILD_CPU:=@OPENJDK_BUILD_CPU@
103OPENJDK_BUILD_CPU_ARCH:=@OPENJDK_BUILD_CPU_ARCH@
104OPENJDK_BUILD_CPU_BITS:=@OPENJDK_BUILD_CPU_BITS@
105OPENJDK_BUILD_CPU_ENDIAN:=@OPENJDK_BUILD_CPU_ENDIAN@
106
107# Legacy OS values for use in release file.
108REQUIRED_OS_NAME:=@REQUIRED_OS_NAME@
109REQUIRED_OS_VERSION:=@REQUIRED_OS_VERSION@
110
111@SET_OPENJDK@
112JIGSAW:=@JIGSAW@
113LIBM:=-lm
114LIBDL:=@LIBDL@
115
116# colon or semicolon
117PATH_SEP:=@PATH_SEP@
118
119# Set special env variables, to be passed to external tools.
120# Used for cygwin setups.
121@SETUPDEVENV@
122
123# The sys root where standard headers and libraries are found.
124# Usually not needed since the configure script should have
125# taken it into account already when setting CFLAGS et al.
126SYS_ROOT:=@SYS_ROOT@
127
128# Paths to the source code
129SRC_ROOT:=@SRC_ROOT@
130ADD_SRC_ROOT:=@ADD_SRC_ROOT@
131OVERRIDE_SRC_ROOT:=@OVERRIDE_SRC_ROOT@
132TOPDIR:=@SRC_ROOT@
133OUTPUT_ROOT:=@OUTPUT_ROOT@
134JDK_MAKE_SHARED_DIR:=@JDK_TOPDIR@/makefiles/common/shared
135JDK_TOPDIR:=@JDK_TOPDIR@
136LANGTOOLS_TOPDIR:=@LANGTOOLS_TOPDIR@
137CORBA_TOPDIR:=@CORBA_TOPDIR@
138JAXP_TOPDIR:=@JAXP_TOPDIR@
139JAXWS_TOPDIR:=@JAXWS_TOPDIR@
140HOTSPOT_TOPDIR:=@HOTSPOT_TOPDIR@
141COPYRIGHT_YEAR:=@COPYRIGHT_YEAR@
142
143# Location where build customization files may be found
144CUSTOM_MAKE_DIR:=@CUSTOM_MAKE_DIR@
145
146# Information gathered from the version.numbers file.
147JDK_MAJOR_VERSION:=@JDK_MAJOR_VERSION@
148JDK_MINOR_VERSION:=@JDK_MINOR_VERSION@
149JDK_MICRO_VERSION:=@JDK_MICRO_VERSION@
150JDK_UPDATE_VERSION:=@JDK_UPDATE_VERSION@
151JDK_BUILD_NUMBER:=@JDK_BUILD_NUMBER@
152MILESTONE:=@MILESTONE@
153LAUNCHER_NAME:=@LAUNCHER_NAME@
154PRODUCT_NAME:=@PRODUCT_NAME@
155PRODUCT_SUFFIX:=@PRODUCT_SUFFIX@
156JDK_RC_PLATFORM_NAME:=@JDK_RC_PLATFORM_NAME@
157COMPANY_NAME:=@COMPANY_NAME@
158
159# Different version strings generated from the above information.
160JDK_VERSION:=@JDK_VERSION@
161RUNTIME_NAME:=@RUNTIME_NAME@
162FULL_VERSION:=@FULL_VERSION@
163JRE_RELEASE_VERSION:=@FULL_VERSION@
164RELEASE:=@RELEASE@
165COOKED_BUILD_NUMBER:=@COOKED_BUILD_NUMBER@
166
167# How to compile the code: release, fastdebug or slowdebug
168DEBUG_LEVEL:=@DEBUG_LEVEL@
169
170# This is the JDK variant to build.
171# The JDK variant is a name for a specific set of modules to be compiled for the JDK.
172JDK_VARIANT:=@JDK_VARIANT@
173
174# Should we compile support for running with a graphical UI? (ie headful)
175# Should we compile support for running without? (ie headless)
176SUPPORT_HEADFUL:=@SUPPORT_HEADFUL@
177SUPPORT_HEADLESS:=@SUPPORT_HEADLESS@
178# Legacy defines controlled by the SUPPORT_HEADLESS and SUPPORT_HEADFUL options.
179@BUILD_HEADLESS@
180
181# These are the libjvms that we want to build.
182# The java launcher uses the default.
183# The other can be selected by specifying -client -server -kernel -zero or -zeroshark
184# on the java launcher command line.
185JVM_VARIANTS:=@JVM_VARIANTS@
186JVM_VARIANT_SERVER:=@JVM_VARIANT_SERVER@
187JVM_VARIANT_CLIENT:=@JVM_VARIANT_CLIENT@
188JVM_VARIANT_KERNEL:=@JVM_VARIANT_KERNEL@
189JVM_VARIANT_ZERO:=@JVM_VARIANT_ZERO@
190JVM_VARIANT_ZEROSHARK:=@JVM_VARIANT_ZEROSHARK@
191
192# Universal binaries on macosx
193MACOSX_UNIVERSAL=@MACOSX_UNIVERSAL@
194
195# Legacy setting: -debug or -fastdebug
196# Still used in version string...
197BUILD_VARIANT_RELEASE:=@BUILD_VARIANT_RELEASE@
198
199# JDK_OUTPUTDIR specifies where a working jvm is built.
200# You can run $(JDK_OUTPUTDIR)/bin/java
201# Though the layout of the contents of $(JDK_OUTPUTDIR) is not
202# yet the same as a default installation.
203#
204# When you run "make install" it will create the standardized
205# layout for the jdk and the jre inside the IMAGES_OUTPUTDIR subdir.
206# Then it will copy the contents of the jdk into the installation
207# directory.
208
209BUILD_OUTPUT:=@BUILD_OUTPUT@
210LANGTOOLS_OUTPUTDIR=$(BUILD_OUTPUT)/langtools
211CORBA_OUTPUTDIR=$(BUILD_OUTPUT)/corba
212JAXP_OUTPUTDIR=$(BUILD_OUTPUT)/jaxp
213JAXWS_OUTPUTDIR=$(BUILD_OUTPUT)/jaxws
214HOTSPOT_OUTPUTDIR=$(BUILD_OUTPUT)/hotspot
215JDK_OUTPUTDIR=$(BUILD_OUTPUT)/jdk
216IMAGES_OUTPUTDIR=$(BUILD_OUTPUT)/images
217
218LANGTOOLS_DIST=$(LANGTOOLS_OUTPUTDIR)/dist
219CORBA_DIST=$(CORBA_OUTPUTDIR)/dist
220JAXP_DIST=$(JAXP_OUTPUTDIR)/dist
221JAXWS_DIST=$(JAXWS_OUTPUTDIR)/dist
222HOTSPOT_DIST=$(HOTSPOT_OUTPUTDIR)/dist
223
224# The boot jdk to use
225BOOT_JDK:=@BOOT_JDK@
226BOOT_JDK_JVMARGS:=@BOOT_JDK_JVMARGS@
227BOOT_RTJAR:=@BOOT_RTJAR@
228BOOT_TOOLSJAR=$(BOOT_JDK)/lib/tools.jar
229
230# When compiling Java source to be run by the boot jdk
231# use these extra flags, eg -source 6 -target 6
232BOOT_JDK_SOURCETARGET:=@BOOT_JDK_SOURCETARGET@
233
234# Information about the build system
235NUM_CORES:=@NUM_CORES@
236# Enable sjavac support = use a javac server,
237# multi core javac compilation and dependency tracking.
238ENABLE_SJAVAC:=@ENABLE_SJAVAC@
239# Store sjavac server synchronization files here, and
240# the sjavac server log files.
241SJAVAC_SERVER_DIR:=@SJAVAC_SERVER_DIR@
242# We can block the Javac server to never use more cores than this.
243# This is not for performance reasons, but for memory usage, since each
244# core requires its own JavaCompiler. We might have 64 cores and 4GB
245# of memory, 64 JavaCompilers will currently not fit in a 3GB heap.
246# Since there is no sharing of data between the JavaCompilers.
247SJAVAC_SERVER_CORES:=@SJAVAC_SERVER_CORES@
248
249# The OpenJDK makefiles should be changed to using the standard
250# configure output ..._CFLAGS and ..._LIBS. In the meantime we
251# extract the information here.
252FREETYPE2_LIB_PATH:=@FREETYPE2_LIB_PATH@
253FREETYPE2_LIBS:=@FREETYPE2_LIBS@
254FREETYPE2_CFLAGS:=@FREETYPE2_CFLAGS@
255USING_SYSTEM_FT_LIB=@USING_SYSTEM_FT_LIB@
256CUPS_CFLAGS:=@CUPS_CFLAGS@
257
258PACKAGE_PATH=@PACKAGE_PATH@
259
260# Source file for cacerts
261CACERTS_FILE=@CACERTS_FILE@
262
263# Necessary additional compiler flags to compile X11 
264X_CFLAGS:=@X_CFLAGS@
265X_LIBS:=@X_LIBS@
266OPENWIN_HOME:=@OPENWIN_HOME@
267
268# There are two types: CC or CL
269# CC is gcc and others behaving reasonably similar.
270# CL is cl.exe only.
271COMPILER_TYPE:=@COMPILER_TYPE@
272
273CC_OUT_OPTION:=@CC_OUT_OPTION@
274EXE_OUT_OPTION:=@EXE_OUT_OPTION@
275LD_OUT_OPTION:=@LD_OUT_OPTION@
276AR_OUT_OPTION:=@AR_OUT_OPTION@
277
278# Flags used for overriding the default opt setting for a C/C++ source file.
279C_O_FLAG_HIGHEST:=@C_O_FLAG_HIGHEST@
280C_O_FLAG_HI:=@C_O_FLAG_HI@
281C_O_FLAG_NORM:=@C_O_FLAG_NORM@
282C_O_FLAG_NONE:=@C_O_FLAG_NONE@
283CXX_O_FLAG_HIGHEST:=@CXX_O_FLAG_HIGHEST@
284CXX_O_FLAG_HI:=@CXX_O_FLAG_HI@
285CXX_O_FLAG_NORM:=@CXX_O_FLAG_NORM@
286CXX_O_FLAG_NONE:=@CXX_O_FLAG_NONE@
287
288C_FLAG_DEPS:=@C_FLAG_DEPS@
289CXX_FLAG_DEPS:=@CXX_FLAG_DEPS@
290
291# Tools that potentially need to be cross compilation aware.
292CC:=@UNCYGDRIVE@ @CCACHE@ @CC@
293
294# CFLAGS used to compile the jdk native libraries (C-code)
295CFLAGS_JDKLIB:=@CFLAGS_JDKLIB@
296CXXFLAGS_JDKLIB:=@CXXFLAGS_JDKLIB@
297
298# CFLAGS used to compile the jdk native launchers (C-code)
299CFLAGS_JDKEXE:=@CFLAGS_JDKEXE@
300CXXFLAGS_JDKEXE:=@CXXFLAGS_JDKEXE@
301
302CXX:=@UNCYGDRIVE@ @CCACHE@ @CXX@
303#CXXFLAGS:=@CXXFLAGS@
304
305OBJC:=@CCACHE@ @OBJC@
306#OBJCFLAGS:=@OBJCFLAGS@
307
308CPP:=@UNCYGDRIVE@ @CPP@
309#CPPFLAGS:=@CPPFLAGS@
310
311# The linker can be gcc or ld on posix systems, or link.exe on windows systems.
312LD:=@UNCYGDRIVE@ @LD@
313
314# LDFLAGS used to link the jdk native libraries (C-code)
315LDFLAGS_JDKLIB:=@LDFLAGS_JDKLIB@
316LDFLAGS_JDKLIB_SUFFIX:=@LDFLAGS_JDKLIB_SUFFIX@
317
318# On some platforms the linker cannot be used to create executables, thus
319# the need for a separate LDEXE command.
320LDEXE:=@UNCYGDRIVE@ @LDEXE@
321
322# LDFLAGS used to link the jdk native launchers (C-code)
323LDFLAGS_JDKEXE:=@LDFLAGS_JDKEXE@
324LDFLAGS_JDKEXE_SUFFIX:=@LDFLAGS_JDKEXE_SUFFIX@
325
326# LDFLAGS specific to C++ linking.
327LDFLAGS_CXX_JDK:=@LDFLAGS_CXX_JDK@
328
329# Sometimes a different linker is needed for c++ libs
330LDCXX:=@UNCYGDRIVE@ @LDCXX@
331# The flags for linking libstdc++ linker.
332LIBCXX:=@LIBCXX@
333
334# Sometimes a different linker is needed for c++ executables
335LDEXECXX:=@UNCYGDRIVE@ @LDEXECXX@
336
337# BUILD_CC/BUILD_LD is a compiler/linker that generates code that is runnable on the
338# build platform.
339BUILD_CC:=@UNCYGDRIVE@ @BUILD_CC@
340BUILD_LD:=@UNCYGDRIVE@ @BUILD_LD@
341
342AS:=@UNCYGDRIVE@ @AS@
343
344# AR is used to create a static library (is ar in posix, lib.exe in windows)
345AR:=@UNCYGDRIVE@ @AR@
346ARFLAGS:=@ARFLAGS@
347
348NM:=@NM@
349STRIP:=@STRIP@
350MCS:=@MCS@
351
352LIPO:=@LIPO@
353
354# Command to create a shared library
355SHARED_LIBRARY_FLAGS:=@SHARED_LIBRARY_FLAGS@
356
357# Options to linker to specify a mapfile. 
358# (Note absence of := assignment, because we do not want to evaluate the macro body here)
359SET_SHARED_LIBRARY_MAPFILE=@SET_SHARED_LIBRARY_MAPFILE@
360
361# Options for C/CXX compiler to be used if linking is performed
362#   using reorder file
363C_FLAG_REORDER:=@C_FLAG_REORDER@
364CXX_FLAG_REORDER:=@CXX_FLAG_REORDER@
365
366#
367# Options for generating debug symbols
368ENABLE_DEBUG_SYMBOLS:=@ENABLE_DEBUG_SYMBOLS@
369CFLAGS_DEBUG_SYMBOLS:=@CFLAGS_DEBUG_SYMBOLS@
370CXXFLAGS_DEBUG_SYMBOLS:=@CXXFLAGS_DEBUG_SYMBOLS@
371ZIP_DEBUGINFO_FILES:=@ZIP_DEBUGINFO_FILES@
372
373#
374# Compress (or not) jars
375COMPRESS_JARS=@COMPRESS_JARS@
376
377# Options to linker to specify the library name.
378# (Note absence of := assignment, because we do not want to evaluate the macro body here)
379SET_SHARED_LIBRARY_NAME=@SET_SHARED_LIBRARY_NAME@
380
381# Set origin using the linker, ie use the relative path to the dependent library to find the dependees.
382# (Note absence of := assignment, because we do not want to evaluate the macro body here)
383SET_SHARED_LIBRARY_ORIGIN=@SET_SHARED_LIBRARY_ORIGIN@
384SET_EXECUTABLE_ORIGIN=@SET_EXECUTABLE_ORIGIN@
385
386# Different OS:es have different ways of naming shared libraries.
387# The SHARED_LIBRARY macro takes "verify" as and argument and returns:
388#    "libverify.so" or "libverify.dylib" or "verify.dll" depending on platform.
389# (Note absence of := assignment, because we do not want to evaluate the macro body here)
390SHARED_LIBRARY=@SHARED_LIBRARY@
391STATIC_LIBRARY=@STATIC_LIBRARY@
392LIBRARY_PREFIX:=@LIBRARY_PREFIX@
393SHARED_LIBRARY_SUFFIX:=@SHARED_LIBRARY_SUFFIX@
394STATIC_LIBRARY_SUFFIX:=@STATIC_LIBRARY_SUFFIX@
395EXE_SUFFIX:=@EXE_SUFFIX@
396OBJ_SUFFIX:=@OBJ_SUFFIX@
397
398POST_STRIP_CMD:=@POST_STRIP_CMD@
399POST_MCS_CMD:=@POST_MCS_CMD@
400
401JAVA_FLAGS:=@BOOT_JDK_JVMARGS@
402
403JAVA=@UNCYGDRIVE@ $(BOOT_JDK)/bin/java $(JAVA_FLAGS)
404
405JAVAC=@UNCYGDRIVE@ $(BOOT_JDK)/bin/javac
406# Hotspot sets this variable before reading the SPEC when compiling sa-jdi.jar. Avoid
407# overriding that value by using ?=.
408JAVAC_FLAGS?=@JAVAC_FLAGS@
409
410JAVAH=@UNCYGDRIVE@ $(BOOT_JDK)/bin/javah
411
412JAR=@UNCYGDRIVE@ $(BOOT_JDK)/bin/jar
413
414RMIC=@UNCYGDRIVE@ $(BOOT_JDK)/bin/rmic
415
416NATIVE2ASCII=@UNCYGDRIVE@ $(BOOT_JDK)/bin/native2ascii
417
418# Base flags for RC
419# Guarding this against resetting value. Legacy make files include spec multiple
420# times.
421ifndef RC_FLAGS
422RC_FLAGS:=@RC_FLAGS@
423endif
424
425# A specific java binary with specific options can be used to run
426# the long running background sjavac servers and other long running tasks.
427SJAVAC_SERVER_JAVA:=@UNCYGDRIVE@ @SJAVAC_SERVER_JAVA@
428
429# Tools adhering to a minimal and common standard of posix compliance.
430AWK:=@AWK@
431BASENAME:=@BASENAME@
432CAT:=@CAT@
433CCACHE:=@CCACHE@
434# CD is going away, but remains to cater for legacy makefiles.
435CD:=cd
436CHMOD:=@CHMOD@
437CP:=@CP@
438CPIO:=@CPIO@
439CUT:=@CUT@
440DATE:=@DATE@
441DF:=@DF@
442DIFF:=@DIFF@
443FIND:=@FIND@
444FIND_DELETE:=@FIND_DELETE@
445ECHO:=@ECHO@
446EGREP:=@EGREP@
447FGREP:=@FGREP@
448GREP:=@GREP@
449HEAD:=@HEAD@
450LS:=@LS@
451LN:=@LN@
452MKDIR:=@MKDIR@
453MV:=@MV@
454NAWK:=@NAWK@
455PRINTF:=@PRINTF@
456PWD:=@THEPWDCMD@
457RM:=@RM@
458SED:=@SED@
459SH:=@SH@
460SORT:=@SORT@
461TAR:=@TAR@
462TAIL:=@TAIL@
463TEE:=@TEE@
464TR:=@TR@
465TOUCH:=@TOUCH@
466WC:=@WC@
467XARGS:=@XARGS@
468ZIPEXE:=@ZIP@
469ZIP:=@ZIP@
470UNZIP:=@UNZIP@
471MT:=@UNCYGDRIVE@ @MT@
472RC:=@UNCYGDRIVE@ @RC@
473DUMPBIN:=@UNCYGDRIVE@ @DUMPBIN@
474CYGPATH:=@CYGPATH@
475LDD:=@LDD@
476OTOOL:=@OTOOL@
477READELF:=@READELF@
478EXPR:=@EXPR@
479FILE:=@FILE@
480HG:=@HG@
481OBJCOPY:=@OBJCOPY@
482
483UNCYGDRIVE:=@UNCYGDRIVE@
484
485# Where the build output is stored for your convenience.
486BUILD_LOG:=@BUILD_LOG@
487BUILD_LOG_PREVIOUS:=@BUILD_LOG_PREVIOUS@
488BUILD_LOG_WRAPPER:=@BUILD_LOG_WRAPPER@
489
490# Build setup
491DISABLE_NIMBUS:=@DISABLE_NIMBUS@
492ENABLE_JFR=@ENABLE_JFR@
493USE_EXTERNAL_LIBJPEG:=@USE_EXTERNAL_LIBJPEG@
494USE_EXTERNAL_LIBGIF:=@USE_EXTERNAL_LIBGIF@
495USE_EXTERNAL_LIBZ:=@USE_EXTERNAL_LIBZ@
496LIBZIP_CAN_USE_MMAP:=@LIBZIP_CAN_USE_MMAP@
497CHECK_FOR_VCINSTALLDIR=@CHECK_FOR_VCINSTALLDIR@
498MSVCRNN_DLL:=@MSVCR100DLL@
499
500
501# ADD_SRCS takes a single argument with source roots
502# and appends any corresponding source roots found
503# below --with-add-source-root and below
504# --with-override-source-root. It is the responsibility
505# of the next macro to get rid of superfluous files.
506ADD_SRCS=$1
507ifneq (,$(ADD_SRC_ROOT))
508    # Append wildcard rule to pickup any matching source roots found below ADD_SRC_ROOT 
509    ADD_SRCS+=$(wildcard $(subst $(SRC_ROOT),$(ADD_SRC_ROOT),$1))
510endif
511ifneq (,$(OVERRIDE_SRC_ROOT))
512    # Append wildcard rule to pickup any matching source roots found below OVERRIDE_SRC_ROOT 
513    ADD_SRCS+=$(wildcard $(subst $(SRC_ROOT),$(OVERRIDE_SRC_ROOT),$1))
514endif
515
516# OVR_SRCS creates a filter expression to filter out sources in
517# the original source directory that lie inside directories below
518# --with-override-source-root.
519# Use := here since we want to scan for these files here. To avoid recomputation later.
520# We cannot do the scan in configure, since that would force us to rerun configure when
521# we add overridden sources.
522ifneq (,$(OVERRIDE_SRC_ROOT))
523    OVR_SRCS:=$(addsuffix %,$(subst $(OVERRIDE_SRC_ROOT),$(SRC_ROOT),$(sort $(dir $(shell $(FIND) $(OVERRIDE_SRC_ROOT) -type f)))))
524else
525    OVR_SRCS:=
526endif
527
528####################################################
529#
530# INSTALLATION
531#
532
533# Common prefix for all installed files. Defaults to /usr/local,
534# but /opt/myjdk is another common version. 
535INSTALL_PREFIX=@prefix@
536
537# Directories containing architecture-dependent files should be relative to exec_prefix
538INSTALL_EXECPREFIX=@exec_prefix@
539
540# java,javac,javah,javap etc are installed here.
541INSTALL_BINDIR=@bindir@
542
543# Read only architecture-independent data
544INSTALL_DATADIR=@datadir@
545
546# Root of above.
547INSTALL_DATAROOTDIR=@datarootdir@
548
549# Doc files, other than info and man.
550INSTALL_DOCDIR=@docdir@
551
552# Html documentation
553INSTALL_HTMLDIR=@htmldir@
554
555# Installing C header files, JNI headers for example.
556INSTALL_INCLUDEDIR=@includedir@
557
558# Installing library files....
559INSTALL_INCLUDEDIR=@libdir@
560
561# Executables that other programs run.
562INSTALL_LIBEXECDIR=@libexecdir@
563
564# Locale-dependent but architecture-independent data, such as message catalogs. 
565INSTALL_LOCALEDIR=@localedir@
566
567# Modifiable single-machine data
568INSTALL_LOCALSTATEDIR=@localstatedir@
569
570# Man pages
571INSTALL_MANDIR=@mandir@
572
573# Modifiable architecture-independent data.
574INSTALL_SHAREDSTATEDIR=@sharedstatedir@
575
576# Read-only single-machine data
577INSTALL_SYSCONFDIR=@sysconfdir@
578
579
580####################################################
581#
582# Misc
583#
584
585# Name of Service Agent library
586SALIB_NAME=@SALIB_NAME@
587
588OS_VERSION_MAJOR:=@OS_VERSION_MAJOR@
589OS_VERSION_MINOR:=@OS_VERSION_MINOR@
590OS_VERSION_MICRO:=@OS_VERSION_MICRO@
591
592# Include the custom-spec.gmk file if it exists
593-include $(dir @SPEC@)/custom-spec.gmk
594