author | duke |
Wed, 05 Jul 2017 21:45:33 +0200 | |
changeset 38542 | 5e3480add088 |
parent 37968 | 460af7a94475 |
child 38546 | 91a5c3430d4f |
permissions | -rw-r--r-- |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
1 |
# |
35747 | 2 |
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
4 |
# |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
5 |
# This code is free software; you can redistribute it and/or modify it |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
7 |
# published by the Free Software Foundation. Oracle designates this |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
8 |
# particular file as subject to the "Classpath" exception as provided |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
9 |
# by Oracle in the LICENSE file that accompanied this code. |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
10 |
# |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
11 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
12 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
14 |
# version 2 for more details (a copy is included in the LICENSE file that |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
15 |
# accompanied this code). |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
16 |
# |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
17 |
# You should have received a copy of the GNU General Public License version |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
18 |
# 2 along with this work; if not, write to the Free Software Foundation, |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
19 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
20 |
# |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
21 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
22 |
# or visit www.oracle.com if you need additional information or have any |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
23 |
# questions. |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
24 |
# |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
25 |
|
34596
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
26 |
############################################################################### |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
27 |
# Check which variant of the JDK that we want to build. |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
28 |
# Currently we have: |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
29 |
# normal: standard edition |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
30 |
# but the custom make system may add other variants |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
31 |
# |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
32 |
# Effectively the JDK variant gives a name to a specific set of |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
33 |
# modules to compile into the JDK. |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
34 |
AC_DEFUN_ONCE([JDKOPT_SETUP_JDK_VARIANT], |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
35 |
[ |
20363 | 36 |
AC_MSG_CHECKING([which variant of the JDK to build]) |
37 |
AC_ARG_WITH([jdk-variant], [AS_HELP_STRING([--with-jdk-variant], |
|
38 |
[JDK variant to build (normal) @<:@normal@:>@])]) |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
39 |
|
20363 | 40 |
if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
41 |
JDK_VARIANT="normal" |
20363 | 42 |
else |
13697 | 43 |
AC_MSG_ERROR([The available JDK variants are: normal]) |
20363 | 44 |
fi |
13697 | 45 |
|
20363 | 46 |
AC_SUBST(JDK_VARIANT) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
47 |
|
20363 | 48 |
AC_MSG_RESULT([$JDK_VARIANT]) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
49 |
]) |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
50 |
|
22460
0273c023680c
8017568: PPC64: Generic build preparations needed to enable new build on Linux/PPC64
simonis
parents:
17819
diff
changeset
|
51 |
############################################################################### |
34596
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
52 |
# Set the debug level |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
53 |
# release: no debug information, all optimizations, no asserts. |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
54 |
# optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
55 |
# fastdebug: debug information (-g), all optimizations, all asserts |
e8328ce5b64e
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34495
diff
changeset
|
56 |
# slowdebug: debug information (-g), no optimizations, all asserts |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
57 |
AC_DEFUN_ONCE([JDKOPT_SETUP_DEBUG_LEVEL], |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
58 |
[ |
20363 | 59 |
DEBUG_LEVEL="release" |
60 |
AC_MSG_CHECKING([which debug level to use]) |
|
61 |
AC_ARG_ENABLE([debug], [AS_HELP_STRING([--enable-debug], |
|
62 |
[set the debug level to fastdebug (shorthand for --with-debug-level=fastdebug) @<:@disabled@:>@])], |
|
63 |
[ |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
64 |
ENABLE_DEBUG="${enableval}" |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
65 |
DEBUG_LEVEL="fastdebug" |
20363 | 66 |
], [ENABLE_DEBUG="no"]) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
67 |
|
20363 | 68 |
AC_ARG_WITH([debug-level], [AS_HELP_STRING([--with-debug-level], |
35747 | 69 |
[set the debug level (release, fastdebug, slowdebug, optimized) @<:@release@:>@])], |
20363 | 70 |
[ |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
71 |
DEBUG_LEVEL="${withval}" |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
72 |
if test "x$ENABLE_DEBUG" = xyes; then |
20363 | 73 |
AC_MSG_ERROR([You cannot use both --enable-debug and --with-debug-level at the same time.]) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
74 |
fi |
20363 | 75 |
]) |
76 |
AC_MSG_RESULT([$DEBUG_LEVEL]) |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
77 |
|
20363 | 78 |
if test "x$DEBUG_LEVEL" != xrelease && \ |
23424
65039fb99fda
8037298: Export HotSpots 'optimized' (i.e. not-product) configuration in the top-level configure/makefile
simonis
parents:
22721
diff
changeset
|
79 |
test "x$DEBUG_LEVEL" != xoptimized && \ |
20363 | 80 |
test "x$DEBUG_LEVEL" != xfastdebug && \ |
81 |
test "x$DEBUG_LEVEL" != xslowdebug; then |
|
35747 | 82 |
AC_MSG_ERROR([Allowed debug levels are: release, fastdebug, slowdebug and optimized]) |
20363 | 83 |
fi |
37402 | 84 |
|
85 |
# Translate DEBUG_LEVEL to debug level used by Hotspot |
|
86 |
HOTSPOT_DEBUG_LEVEL="$DEBUG_LEVEL" |
|
87 |
if test "x$DEBUG_LEVEL" = xrelease; then |
|
88 |
HOTSPOT_DEBUG_LEVEL="product" |
|
89 |
elif test "x$DEBUG_LEVEL" = xslowdebug; then |
|
90 |
HOTSPOT_DEBUG_LEVEL="debug" |
|
91 |
fi |
|
92 |
||
93 |
if test "x$DEBUG_LEVEL" = xoptimized; then |
|
94 |
# The debug level 'optimized' is a little special because it is currently only |
|
95 |
# applicable to the HotSpot build where it means to build a completely |
|
96 |
# optimized version of the VM without any debugging code (like for the |
|
97 |
# 'release' debug level which is called 'product' in the HotSpot build) but |
|
98 |
# with the exception that it can contain additional code which is otherwise |
|
99 |
# protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to |
|
100 |
# test new and/or experimental features which are not intended for customer |
|
101 |
# shipment. Because these new features need to be tested and benchmarked in |
|
102 |
# real world scenarios, we want to build the containing JDK at the 'release' |
|
103 |
# debug level. |
|
104 |
DEBUG_LEVEL="release" |
|
105 |
fi |
|
106 |
||
107 |
AC_SUBST(HOTSPOT_DEBUG_LEVEL) |
|
108 |
AC_SUBST(DEBUG_LEVEL) |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
109 |
]) |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
110 |
|
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
111 |
############################################################################### |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
112 |
# |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
113 |
# Should we build only OpenJDK even if closed sources are present? |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
114 |
# |
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
115 |
AC_DEFUN_ONCE([JDKOPT_SETUP_OPEN_OR_CUSTOM], |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
116 |
[ |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
117 |
AC_ARG_ENABLE([openjdk-only], [AS_HELP_STRING([--enable-openjdk-only], |
20363 | 118 |
[suppress building custom source even if present @<:@disabled@:>@])],,[enable_openjdk_only="no"]) |
14111 | 119 |
|
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
120 |
AC_MSG_CHECKING([for presence of closed sources]) |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
121 |
if test -d "$SRC_ROOT/jdk/src/closed"; then |
14111 | 122 |
CLOSED_SOURCE_PRESENT=yes |
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
123 |
else |
14111 | 124 |
CLOSED_SOURCE_PRESENT=no |
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
125 |
fi |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
126 |
AC_MSG_RESULT([$CLOSED_SOURCE_PRESENT]) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
127 |
|
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
128 |
AC_MSG_CHECKING([if closed source is suppressed (openjdk-only)]) |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
129 |
SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only" |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
130 |
AC_MSG_RESULT([$SUPPRESS_CLOSED_SOURCE]) |
14111 | 131 |
|
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
132 |
if test "x$CLOSED_SOURCE_PRESENT" = xno; then |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
133 |
OPENJDK=true |
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
134 |
if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
135 |
AC_MSG_WARN([No closed source present, --enable-openjdk-only makes no sense]) |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
136 |
fi |
14111 | 137 |
else |
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
138 |
if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
139 |
OPENJDK=true |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
140 |
else |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
141 |
OPENJDK=false |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
142 |
fi |
14111 | 143 |
fi |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
144 |
|
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
145 |
if test "x$OPENJDK" = "xtrue"; then |
14111 | 146 |
SET_OPENJDK="OPENJDK=true" |
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
147 |
fi |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
148 |
|
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
149 |
AC_SUBST(SET_OPENJDK) |
22714
a752920c4317
8034191: Move relevant parts of build system to new closed repo
ihse
parents:
22709
diff
changeset
|
150 |
|
a752920c4317
8034191: Move relevant parts of build system to new closed repo
ihse
parents:
22709
diff
changeset
|
151 |
# custom-make-dir is deprecated. Please use your custom-hook.m4 to override |
a752920c4317
8034191: Move relevant parts of build system to new closed repo
ihse
parents:
22709
diff
changeset
|
152 |
# the IncludeCustomExtension macro. |
a752920c4317
8034191: Move relevant parts of build system to new closed repo
ihse
parents:
22709
diff
changeset
|
153 |
BASIC_DEPRECATED_ARG_WITH(custom-make-dir) |
15069
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
154 |
]) |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
155 |
|
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
156 |
AC_DEFUN_ONCE([JDKOPT_SETUP_JDK_OPTIONS], |
c6dab988d808
8005850: build-infra: Make --enable-openjdk-only really disable custom
erikj
parents:
15067
diff
changeset
|
157 |
[ |
20363 | 158 |
# Should we build a JDK/JVM with headful support (ie a graphical ui)? |
159 |
# We always build headless support. |
|
160 |
AC_MSG_CHECKING([headful support]) |
|
161 |
AC_ARG_ENABLE([headful], [AS_HELP_STRING([--disable-headful], |
|
162 |
[disable building headful support (graphical UI support) @<:@enabled@:>@])], |
|
163 |
[SUPPORT_HEADFUL=${enable_headful}], [SUPPORT_HEADFUL=yes]) |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
164 |
|
20363 | 165 |
SUPPORT_HEADLESS=yes |
166 |
BUILD_HEADLESS="BUILD_HEADLESS:=true" |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
167 |
|
20363 | 168 |
if test "x$SUPPORT_HEADFUL" = xyes; then |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
169 |
# We are building both headful and headless. |
20273 | 170 |
headful_msg="include support for both headful and headless" |
20363 | 171 |
fi |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
172 |
|
20363 | 173 |
if test "x$SUPPORT_HEADFUL" = xno; then |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
174 |
# Thus we are building headless only. |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
175 |
BUILD_HEADLESS="BUILD_HEADLESS:=true" |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
176 |
headful_msg="headless only" |
20363 | 177 |
fi |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
178 |
|
20363 | 179 |
AC_MSG_RESULT([$headful_msg]) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
180 |
|
20363 | 181 |
AC_SUBST(SUPPORT_HEADLESS) |
182 |
AC_SUBST(SUPPORT_HEADFUL) |
|
183 |
AC_SUBST(BUILD_HEADLESS) |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
184 |
|
20363 | 185 |
# Choose cacerts source file |
186 |
AC_ARG_WITH(cacerts-file, [AS_HELP_STRING([--with-cacerts-file], |
|
187 |
[specify alternative cacerts file])]) |
|
188 |
if test "x$with_cacerts_file" != x; then |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
189 |
CACERTS_FILE=$with_cacerts_file |
20363 | 190 |
fi |
191 |
AC_SUBST(CACERTS_FILE) |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
192 |
|
20363 | 193 |
# Enable or disable unlimited crypto |
194 |
AC_ARG_ENABLE(unlimited-crypto, [AS_HELP_STRING([--enable-unlimited-crypto], |
|
195 |
[Enable unlimited crypto policy @<:@disabled@:>@])],, |
|
196 |
[enable_unlimited_crypto=no]) |
|
197 |
if test "x$enable_unlimited_crypto" = "xyes"; then |
|
14112
1b447f5cb0d1
8001897: build-infra: misc adjustments to configure script
ihse
parents:
14111
diff
changeset
|
198 |
UNLIMITED_CRYPTO=true |
20363 | 199 |
else |
14112
1b447f5cb0d1
8001897: build-infra: misc adjustments to configure script
ihse
parents:
14111
diff
changeset
|
200 |
UNLIMITED_CRYPTO=false |
20363 | 201 |
fi |
202 |
AC_SUBST(UNLIMITED_CRYPTO) |
|
14112
1b447f5cb0d1
8001897: build-infra: misc adjustments to configure script
ihse
parents:
14111
diff
changeset
|
203 |
|
35747 | 204 |
# Should we build the serviceability agent (SA)? |
205 |
INCLUDE_SA=true |
|
37402 | 206 |
if HOTSPOT_CHECK_JVM_VARIANT(zero) || HOTSPOT_CHECK_JVM_VARIANT(zeroshark); then |
35747 | 207 |
INCLUDE_SA=false |
208 |
fi |
|
209 |
if test "x$OPENJDK_TARGET_OS" = xaix ; then |
|
210 |
INCLUDE_SA=false |
|
211 |
fi |
|
212 |
AC_SUBST(INCLUDE_SA) |
|
213 |
||
20363 | 214 |
# Compress jars |
215 |
COMPRESS_JARS=false |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
216 |
|
20363 | 217 |
AC_SUBST(COMPRESS_JARS) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
218 |
|
33926
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
219 |
# Setup default copyright year. Mostly overridden when building close to a new year. |
27584
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
220 |
AC_ARG_WITH(copyright-year, [AS_HELP_STRING([--with-copyright-year], |
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
221 |
[Set copyright year value for build @<:@current year@:>@])]) |
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
222 |
if test "x$with_copyright_year" = xyes; then |
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
223 |
AC_MSG_ERROR([Copyright year must have a value]) |
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
224 |
elif test "x$with_copyright_year" != x; then |
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
225 |
COPYRIGHT_YEAR="$with_copyright_year" |
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
226 |
else |
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
227 |
COPYRIGHT_YEAR=`date +'%Y'` |
01a719b65d1e
8065183: Add --with-copyright-year option to configure
erikj
parents:
27133
diff
changeset
|
228 |
fi |
20363 | 229 |
AC_SUBST(COPYRIGHT_YEAR) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
230 |
]) |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
231 |
|
33926
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
232 |
############################################################################### |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
233 |
# |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
234 |
# Enable or disable the elliptic curve crypto implementation |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
235 |
# |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
236 |
AC_DEFUN_ONCE([JDKOPT_DETECT_INTREE_EC], |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
237 |
[ |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
238 |
AC_MSG_CHECKING([if elliptic curve crypto implementation is present]) |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
239 |
|
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
240 |
if test -d "${SRC_ROOT}/jdk/src/jdk.crypto.ec/share/native/libsunec/impl"; then |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
241 |
ENABLE_INTREE_EC=yes |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
242 |
AC_MSG_RESULT([yes]) |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
243 |
else |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
244 |
ENABLE_INTREE_EC=no |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
245 |
AC_MSG_RESULT([no]) |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
246 |
fi |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
247 |
|
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
248 |
AC_SUBST(ENABLE_INTREE_EC) |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
249 |
]) |
3a19edba4808
8085822: JEP 223: New Version-String Scheme (initial integration)
ihse
parents:
29305
diff
changeset
|
250 |
|
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
251 |
AC_DEFUN_ONCE([JDKOPT_SETUP_DEBUG_SYMBOLS], |
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
252 |
[ |
20363 | 253 |
# |
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
254 |
# NATIVE_DEBUG_SYMBOLS |
20363 | 255 |
# This must be done after the toolchain is setup, since we're looking at objcopy. |
256 |
# |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
257 |
AC_MSG_CHECKING([what type of native debug symbols to use]) |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
258 |
AC_ARG_WITH([native-debug-symbols], |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
259 |
[AS_HELP_STRING([--with-native-debug-symbols], |
35747 | 260 |
[set the native debug symbol configuration (none, internal, external, zipped) @<:@varying@:>@])], |
34605
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
261 |
[ |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
262 |
if test "x$OPENJDK_TARGET_OS" = xaix; then |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
263 |
if test "x$withval" = xexternal || test "x$withval" = xzipped; then |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
264 |
AC_MSG_ERROR([AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols]) |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
265 |
fi |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
266 |
fi |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
267 |
], |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
268 |
[ |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
269 |
if test "x$OPENJDK_TARGET_OS" = xaix; then |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
270 |
# AIX doesn't support 'zipped' so use 'internal' as default |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
271 |
with_native_debug_symbols="internal" |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
272 |
else |
35747 | 273 |
if test "x$STATIC_BUILD" = xtrue; then |
274 |
with_native_debug_symbols="none" |
|
275 |
else |
|
276 |
with_native_debug_symbols="zipped" |
|
277 |
fi |
|
34605
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
278 |
fi |
60c12f0860d6
8145560: AIX: change '8036003: Add --with-debug-symbols' broke AIX build
simonis
parents:
34596
diff
changeset
|
279 |
]) |
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
280 |
NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
281 |
AC_MSG_RESULT([$NATIVE_DEBUG_SYMBOLS]) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
282 |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
283 |
if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
284 |
|
34495 | 285 |
if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then |
286 |
if test "x$OBJCOPY" = x; then |
|
287 |
# enabling of enable-debug-symbols and can't find objcopy |
|
288 |
# this is an error |
|
289 |
AC_MSG_ERROR([Unable to find objcopy, cannot enable native debug symbols]) |
|
290 |
fi |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
291 |
fi |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
292 |
|
35032 | 293 |
COMPILE_WITH_DEBUG_SYMBOLS=true |
294 |
COPY_DEBUG_SYMBOLS=true |
|
295 |
ZIP_EXTERNAL_DEBUG_SYMBOLS=true |
|
296 |
||
297 |
# Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true |
|
35010
d0e2516cc2a2
8145564: 8036003: startup regression on linux fastdebug builds
erikj
parents:
34495
diff
changeset
|
298 |
DEBUG_BINARIES=false |
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
299 |
STRIP_POLICY=min_strip |
35747 | 300 |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
301 |
elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then |
35032 | 302 |
COMPILE_WITH_DEBUG_SYMBOLS=false |
303 |
COPY_DEBUG_SYMBOLS=false |
|
304 |
ZIP_EXTERNAL_DEBUG_SYMBOLS=false |
|
305 |
||
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
306 |
DEBUG_BINARIES=false |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
307 |
STRIP_POLICY=no_strip |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
308 |
elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then |
35032 | 309 |
COMPILE_WITH_DEBUG_SYMBOLS=true |
310 |
COPY_DEBUG_SYMBOLS=false |
|
311 |
ZIP_EXTERNAL_DEBUG_SYMBOLS=false |
|
312 |
||
313 |
# Hotspot legacy support, will turn on -g when COPY_DEBUG_SYMBOLS=false |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
314 |
DEBUG_BINARIES=true |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
315 |
STRIP_POLICY=no_strip |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
316 |
STRIP="" |
35747 | 317 |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
318 |
elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
319 |
|
34495 | 320 |
if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then |
321 |
if test "x$OBJCOPY" = x; then |
|
322 |
# enabling of enable-debug-symbols and can't find objcopy |
|
323 |
# this is an error |
|
324 |
AC_MSG_ERROR([Unable to find objcopy, cannot enable native debug symbols]) |
|
325 |
fi |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
326 |
fi |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
327 |
|
35032 | 328 |
COMPILE_WITH_DEBUG_SYMBOLS=true |
329 |
COPY_DEBUG_SYMBOLS=true |
|
330 |
ZIP_EXTERNAL_DEBUG_SYMBOLS=false |
|
331 |
||
332 |
# Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true |
|
35010
d0e2516cc2a2
8145564: 8036003: startup regression on linux fastdebug builds
erikj
parents:
34495
diff
changeset
|
333 |
DEBUG_BINARIES=false |
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
334 |
STRIP_POLICY=min_strip |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
335 |
else |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
336 |
AC_MSG_ERROR([Allowed native debug symbols are: none, internal, external, zipped]) |
20363 | 337 |
fi |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
338 |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
339 |
# --enable-debug-symbols is deprecated. |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
340 |
# Please use --with-native-debug-symbols=[internal,external,zipped] . |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
341 |
BASIC_DEPRECATED_ARG_ENABLE(debug-symbols, debug_symbols, |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
342 |
[Please use --with-native-debug-symbols=[[internal,external,zipped]] .]) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
343 |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
344 |
# --enable-zip-debug-info is deprecated. |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
345 |
# Please use --with-native-debug-symbols=zipped . |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
346 |
BASIC_DEPRECATED_ARG_ENABLE(zip-debug-info, zip_debug_info, |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
347 |
[Please use --with-native-debug-symbols=zipped .]) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
348 |
|
35032 | 349 |
AC_SUBST(COMPILE_WITH_DEBUG_SYMBOLS) |
350 |
AC_SUBST(COPY_DEBUG_SYMBOLS) |
|
351 |
AC_SUBST(ZIP_EXTERNAL_DEBUG_SYMBOLS) |
|
352 |
||
353 |
# Legacy values |
|
34493
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
354 |
AC_SUBST(DEBUG_BINARIES) |
c68e0ab807d8
8036003: Add --with-debug-symbols=[none|internal|external|zipped]
ysuenaga
parents:
33954
diff
changeset
|
355 |
AC_SUBST(STRIP_POLICY) |
13133
701e61c32ece
7182051: Update of latest build-infra Makefiles (missing files)
erikj
parents:
diff
changeset
|
356 |
]) |
29305
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
357 |
|
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
358 |
################################################################################ |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
359 |
# |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
360 |
# Gcov coverage data for hotspot |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
361 |
# |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
362 |
AC_DEFUN_ONCE([JDKOPT_SETUP_CODE_COVERAGE], |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
363 |
[ |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
364 |
AC_ARG_ENABLE(native-coverage, [AS_HELP_STRING([--enable-native-coverage], |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
365 |
[enable native compilation with code coverage data@<:@disabled@:>@])]) |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
366 |
GCOV_ENABLED="false" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
367 |
if test "x$enable_native_coverage" = "xyes"; then |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
368 |
if test "x$TOOLCHAIN_TYPE" = "xgcc"; then |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
369 |
AC_MSG_CHECKING([if native coverage is enabled]) |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
370 |
AC_MSG_RESULT([yes]) |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
371 |
GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
372 |
GCOV_LDFLAGS="-fprofile-arcs" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
373 |
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $GCOV_CFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
374 |
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $GCOV_CFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
375 |
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $GCOV_LDFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
376 |
CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
377 |
CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
378 |
CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
379 |
CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
380 |
LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
381 |
LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
382 |
GCOV_ENABLED="true" |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
383 |
else |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
384 |
AC_MSG_ERROR([--enable-native-coverage only works with toolchain type gcc]) |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
385 |
fi |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
386 |
elif test "x$enable_native_coverage" = "xno"; then |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
387 |
AC_MSG_CHECKING([if native coverage is enabled]) |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
388 |
AC_MSG_RESULT([no]) |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
389 |
elif test "x$enable_native_coverage" != "x"; then |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
390 |
AC_MSG_ERROR([--enable-native-coverage can only be assigned "yes" or "no"]) |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
391 |
fi |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
392 |
|
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
393 |
AC_SUBST(GCOV_ENABLED) |
4ddc6faf7842
8073021: add native code coverage target into makefiles
erikj
parents:
29162
diff
changeset
|
394 |
]) |
33562
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
395 |
|
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
396 |
################################################################################ |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
397 |
# |
35747 | 398 |
# Static build support. When enabled will generate static |
33562
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
399 |
# libraries instead of shared libraries for all JDK libs. |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
400 |
# |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
401 |
AC_DEFUN_ONCE([JDKOPT_SETUP_STATIC_BUILD], |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
402 |
[ |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
403 |
AC_ARG_ENABLE([static-build], [AS_HELP_STRING([--enable-static-build], |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
404 |
[enable static library build @<:@disabled@:>@])]) |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
405 |
STATIC_BUILD=false |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
406 |
if test "x$enable_static_build" = "xyes"; then |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
407 |
AC_MSG_CHECKING([if static build is enabled]) |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
408 |
AC_MSG_RESULT([yes]) |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
409 |
if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
410 |
AC_MSG_ERROR([--enable-static-build is only supported for macosx builds]) |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
411 |
fi |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
412 |
STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
413 |
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $STATIC_BUILD_CFLAGS" |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
414 |
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $STATIC_BUILD_CFLAGS" |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
415 |
CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
416 |
CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
417 |
STATIC_BUILD=true |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
418 |
elif test "x$enable_static_build" = "xno"; then |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
419 |
AC_MSG_CHECKING([if static build is enabled]) |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
420 |
AC_MSG_RESULT([no]) |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
421 |
elif test "x$enable_static_build" != "x"; then |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
422 |
AC_MSG_ERROR([--enable-static-build can only be assigned "yes" or "no"]) |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
423 |
fi |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
424 |
|
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
425 |
AC_SUBST(STATIC_BUILD) |
c76b2fa11486
8136556: Add the ability to perform static builds of MacOSX x64 binaries
bobv
parents:
32554
diff
changeset
|
426 |
]) |
36506 | 427 |
|
428 |
################################################################################ |
|
429 |
# |
|
37035
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
430 |
# jlink options. |
36506 | 431 |
# We always keep packaged modules in JDK image. |
432 |
# |
|
433 |
AC_DEFUN_ONCE([JDKOPT_SETUP_JLINK_OPTIONS], |
|
434 |
[ |
|
435 |
AC_ARG_ENABLE([keep-packaged-modules], [AS_HELP_STRING([--disable-keep-packaged-modules], |
|
436 |
[Do not keep packaged modules in jdk image @<:@enable@:>@])]) |
|
437 |
||
438 |
if test "x$enable_keep_packaged_modules" = "xyes"; then |
|
439 |
AC_MSG_CHECKING([if packaged modules are kept]) |
|
440 |
AC_MSG_RESULT([yes]) |
|
441 |
JLINK_KEEP_PACKAGED_MODULES=true |
|
442 |
elif test "x$enable_keep_packaged_modules" = "xno"; then |
|
443 |
AC_MSG_CHECKING([if packaged modules are kept]) |
|
444 |
AC_MSG_RESULT([no]) |
|
445 |
JLINK_KEEP_PACKAGED_MODULES=false |
|
446 |
elif test "x$enable_keep_packaged_modules" = "x"; then |
|
447 |
AC_MSG_RESULT([yes (default)]) |
|
448 |
JLINK_KEEP_PACKAGED_MODULES=true |
|
449 |
else |
|
450 |
AC_MSG_ERROR([--enable-keep-packaged-modules accepts no argument]) |
|
451 |
fi |
|
452 |
||
453 |
AC_SUBST(JLINK_KEEP_PACKAGED_MODULES) |
|
454 |
]) |
|
37035
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
455 |
|
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
456 |
################################################################################ |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
457 |
# |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
458 |
# Check if building of the jtreg failure handler should be enabled. |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
459 |
# |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
460 |
AC_DEFUN_ONCE([JDKOPT_ENABLE_DISABLE_FAILURE_HANDLER], |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
461 |
[ |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
462 |
AC_ARG_ENABLE([jtreg-failure-handler], [AS_HELP_STRING([--enable-jtreg-failure-handler], |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
463 |
[forces build of the jtreg failure handler to be enabled, missing dependencies |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
464 |
become fatal errors. Default is auto, where the failure handler is built if all |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
465 |
dependencies are present and otherwise just disabled.])]) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
466 |
|
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
467 |
AC_MSG_CHECKING([if jtreg failure handler should be built]) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
468 |
|
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
469 |
if test "x$enable_jtreg_failure_handler" = "xyes"; then |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
470 |
if test "x$JT_HOME" = "x"; then |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
471 |
AC_MSG_ERROR([Cannot enable jtreg failure handler without jtreg.]) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
472 |
else |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
473 |
BUILD_FAILURE_HANDLER=true |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
474 |
AC_MSG_RESULT([yes, forced]) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
475 |
fi |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
476 |
elif test "x$enable_jtreg_failure_handler" = "xno"; then |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
477 |
BUILD_FAILURE_HANDLER=false |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
478 |
AC_MSG_RESULT([no, forced]) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
479 |
elif test "x$enable_jtreg_failure_handler" = "xauto" \ |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
480 |
|| test "x$enable_jtreg_failure_handler" = "x"; then |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
481 |
if test "x$JT_HOME" = "x"; then |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
482 |
BUILD_FAILURE_HANDLER=false |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
483 |
AC_MSG_RESULT([no, missing jtreg]) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
484 |
else |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
485 |
BUILD_FAILURE_HANDLER=true |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
486 |
AC_MSG_RESULT([yes, jtreg present]) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
487 |
fi |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
488 |
else |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
489 |
AC_MSG_ERROR([Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler]) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
490 |
fi |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
491 |
|
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
492 |
AC_SUBST(BUILD_FAILURE_HANDLER) |
08e00f202d7a
8154292: jdk9-dev: All SE builds failed on 2016-04-14
erikj
parents:
36506
diff
changeset
|
493 |
]) |