Skip to content

Commit 536dc47

Browse files
committed
Merge
2 parents a46503f + fb4098f commit 536dc47

File tree

136 files changed

+4672
-2737
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

136 files changed

+4672
-2737
lines changed

doc/building.html

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ <h2 id="operating-system-requirements">Operating System
367367
</tr>
368368
<tr class="even">
369369
<td>macOS</td>
370-
<td>Mac OS X 10.13 (High Sierra)</td>
370+
<td>macOS 13 (Ventura)</td>
371371
</tr>
372372
<tr class="odd">
373373
<td>Windows</td>
@@ -464,9 +464,8 @@ <h3 id="macos">macOS</h3>
464464
a continuously updated machine running macOS. See the section on <a
465465
href="#apple-xcode">Apple Xcode</a> on some strategies to deal with
466466
this.</p>
467-
<p>It is recommended that you use at least Mac OS X 10.13 (High Sierra).
468-
At the time of writing, the JDK has been successfully compiled on macOS
469-
10.12 (Sierra).</p>
467+
<p>It is recommended that you use at least macOS 13 (Ventura) and Xcode
468+
14, but earlier versions may also work.</p>
470469
<p>The standard macOS environment contains the basic tooling needed to
471470
build, but for external libraries a package manager is recommended. The
472471
JDK uses <a href="https://brew.sh/">homebrew</a> in the examples, but
@@ -545,7 +544,7 @@ <h2 id="native-compiler-toolchain-requirements">Native Compiler
545544
</tr>
546545
<tr class="even">
547546
<td>macOS</td>
548-
<td>Apple Xcode 10.1 (using clang 10.0.0)</td>
547+
<td>Apple Xcode 14.3.1 (using clang 14.0.3)</td>
549548
</tr>
550549
<tr class="odd">
551550
<td>Windows</td>

doc/building.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ time of writing.
167167
| Operating system | Vendor/version used |
168168
| ----------------- | ---------------------------------- |
169169
| Linux | Oracle Enterprise Linux 6.4 / 7.6 |
170-
| macOS | Mac OS X 10.13 (High Sierra) |
170+
| macOS | macOS 13 (Ventura) |
171171
| Windows | Windows Server 2012 R2 |
172172

173173
The double version numbers for Linux are due to the hybrid model
@@ -270,8 +270,8 @@ difficult for a project such as the JDK to keep pace with a continuously updated
270270
machine running macOS. See the section on [Apple Xcode](#apple-xcode) on some
271271
strategies to deal with this.
272272

273-
It is recommended that you use at least Mac OS X 10.13 (High Sierra). At the time
274-
of writing, the JDK has been successfully compiled on macOS 10.12 (Sierra).
273+
It is recommended that you use at least macOS 13 (Ventura) and Xcode
274+
14, but earlier versions may also work.
275275

276276
The standard macOS environment contains the basic tooling needed to build, but
277277
for external libraries a package manager is recommended. The JDK uses
@@ -337,7 +337,7 @@ issues.
337337
| Operating system | Toolchain version |
338338
| ------------------ | ------------------------------------------ |
339339
| Linux | gcc 11.2.0 |
340-
| macOS | Apple Xcode 10.1 (using clang 10.0.0) |
340+
| macOS | Apple Xcode 14.3.1 (using clang 14.0.3) |
341341
| Windows | Microsoft Visual Studio 2022 update 17.1.0 |
342342

343343
All compilers are expected to be able to compile to the C99 language standard,

make/RunTests.gmk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -868,7 +868,7 @@ define SetupRunJtregTestBody
868868
$$(RM) -r $$($1_TEST_RESULTS_DIR)
869869

870870
$1_COMMAND_LINE := \
871-
$$(JAVA) $$($1_JTREG_LAUNCHER_OPTIONS) \
871+
$$(JTREG_JAVA) $$($1_JTREG_LAUNCHER_OPTIONS) \
872872
-Dprogram=jtreg -jar $$(JT_HOME)/lib/jtreg.jar \
873873
$$($1_JTREG_BASIC_OPTIONS) \
874874
-testjdk:$$(JDK_UNDER_TEST) \

make/RunTestsPrebuilt.gmk

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ $(eval $(call SetupVariable,JT_HOME))
122122
$(eval $(call SetupVariable,JDK_IMAGE_DIR,$(OUTPUTDIR)/images/jdk))
123123
$(eval $(call SetupVariable,TEST_IMAGE_DIR,$(OUTPUTDIR)/images/test))
124124
$(eval $(call SetupVariable,SYMBOLS_IMAGE_DIR,$(OUTPUTDIR)/images/symbols,NO_CHECK))
125+
$(eval $(call SetupVariable,JTREG_JAVA,$(BOOT_JDK)/bin/java))
125126

126127
# Provide default values for tools that we need
127128
$(eval $(call SetupVariable,MAKE,make,NO_CHECK))
@@ -248,6 +249,7 @@ $(call CreateNewSpec, $(NEW_SPEC), \
248249
TOPDIR := $(TOPDIR), \
249250
OUTPUTDIR := $(OUTPUTDIR), \
250251
BOOT_JDK := $(BOOT_JDK), \
252+
JTREG_JAVA := $(FIXPATH) $(JTREG_JAVA), \
251253
JT_HOME := $(JT_HOME), \
252254
JDK_IMAGE_DIR := $(JDK_IMAGE_DIR), \
253255
JCOV_IMAGE_DIR := $(JCOV_IMAGE_DIR), \

make/autoconf/flags-cflags.m4

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -844,15 +844,20 @@ AC_DEFUN([FLAGS_SETUP_CFLAGS_CPU_DEP],
844844
]
845845
)
846846
if test "x$FILE_MACRO_CFLAGS" != x; then
847-
# Add -pathmap for all VS system include paths using Windows
848-
# full Long path name that is generated by the compiler
847+
# Add -pathmap for all VS system include paths using Windows
848+
# full Long path name that is generated by the compiler
849+
# Not enabled under WSL as there is no easy way to obtain the
850+
# Windows full long paths, thus reproducible WSL builds will
851+
# depend on building with the same VS toolchain install location.
852+
if test "x$OPENJDK_BUILD_OS_ENV" != "xwindows.wsl1" && test "x$OPENJDK_BUILD_OS_ENV" != "xwindows.wsl2"; then
849853
for ipath in ${$3SYSROOT_CFLAGS}; do
850854
if test "x${ipath:0:2}" == "x-I"; then
851855
ipath_path=${ipath#"-I"}
852856
UTIL_FIXUP_WIN_LONG_PATH(ipath_path)
853857
FILE_MACRO_CFLAGS="$FILE_MACRO_CFLAGS -pathmap:\"$ipath_path\"=vsi"
854858
fi
855859
done
860+
fi
856861
fi
857862
fi
858863

make/autoconf/lib-tests.m4

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,12 +227,48 @@ AC_DEFUN_ONCE([LIB_TESTS_SETUP_JTREG],
227227
UTIL_FIXUP_PATH(JT_HOME)
228228
AC_SUBST(JT_HOME)
229229
230+
# Specify a JDK for running jtreg. Defaults to the BOOT_JDK.
231+
AC_ARG_WITH(jtreg-jdk, [AS_HELP_STRING([--with-jdk],
232+
[path to JDK for running jtreg @<:@BOOT_JDK@:>@])])
233+
234+
AC_MSG_CHECKING([for jtreg jdk])
235+
if test "x${with_jtreg_jdk}" != x; then
236+
if test "x${with_jtreg_jdk}" = xno; then
237+
AC_MSG_RESULT([no, jtreg jdk not specified])
238+
elif test "x${with_jtreg_jdk}" = xyes; then
239+
AC_MSG_RESULT([not specified])
240+
AC_MSG_ERROR([--with-jtreg-jdk needs a value])
241+
else
242+
JTREG_JDK="${with_jtreg_jdk}"
243+
AC_MSG_RESULT([$JTREG_JDK])
244+
UTIL_FIXUP_PATH(JTREG_JDK)
245+
if test ! -f "$JTREG_JDK/bin/java"; then
246+
AC_MSG_ERROR([Could not find jtreg java at $JTREG_JDK/bin/java])
247+
fi
248+
fi
249+
else
250+
JTREG_JDK="${BOOT_JDK}"
251+
AC_MSG_RESULT([no, using BOOT_JDK])
252+
fi
253+
254+
JTREG_JAVA="$JTREG_JDK/bin/java"
255+
UTIL_FIXUP_PATH(JTREG_JAVA)
256+
JTREG_JAVA="$FIXPATH $JTREG_JAVA"
257+
AC_SUBST([JTREG_JAVA])
258+
259+
230260
# Verify jtreg version
231261
if test "x$JT_HOME" != x; then
262+
AC_MSG_CHECKING([jtreg jar existence])
263+
if test ! -f "$JT_HOME/lib/jtreg.jar"; then
264+
AC_MSG_ERROR([Could not find jtreg jar at $JT_HOME/lib/jtreg.jar])
265+
fi
266+
232267
AC_MSG_CHECKING([jtreg version number])
233268
# jtreg -version looks like this: "jtreg 6.1+1-19"
234269
# Extract actual version part ("6.1" in this case)
235-
jtreg_version_full=`$JAVA -jar $JT_HOME/lib/jtreg.jar -version | $HEAD -n 1 | $CUT -d ' ' -f 2`
270+
jtreg_version_full=$($JTREG_JAVA -jar $JT_HOME/lib/jtreg.jar -version | $HEAD -n 1 | $CUT -d ' ' -f 2)
271+
236272
jtreg_version=${jtreg_version_full/%+*}
237273
AC_MSG_RESULT([$jtreg_version])
238274

make/autoconf/spec.gmk.in

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -666,6 +666,8 @@ JAVA_FLAGS_SMALL:=@JAVA_FLAGS_SMALL@
666666
BUILDJDK_JAVA_FLAGS_SMALL:=@BUILDJDK_JAVA_FLAGS_SMALL@
667667
JAVA_TOOL_FLAGS_SMALL:=@JAVA_TOOL_FLAGS_SMALL@
668668

669+
JTREG_JAVA:=@JTREG_JAVA@
670+
669671
# The *_CMD variables are defined separately to be easily overridden in bootcycle-spec.gmk
670672
# for bootcycle-images build. Make sure to keep them in sync. Do not use the *_CMD
671673
# versions of the variables directly.

make/autoconf/util_paths.m4

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ AC_DEFUN([UTIL_FIXUP_PATH],
120120

121121
##############################################################################
122122
# Fixup path to be a Windows full long path
123+
# Note: Only supported with cygwin/msys2 (cygpath tool)
123124
AC_DEFUN([UTIL_FIXUP_WIN_LONG_PATH],
124125
[
125126
# Only process if variable expands to non-empty

make/conf/jib-profiles.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1081,7 +1081,7 @@ var getJibProfilesDependencies = function (input, common) {
10811081

10821082
var devkit_platform_revisions = {
10831083
linux_x64: "gcc11.2.0-OL6.4+1.0",
1084-
macosx: "Xcode12.4+1.1",
1084+
macosx: "Xcode14.3.1+1.0",
10851085
windows_x64: "VS2022-17.1.0+1.1",
10861086
linux_aarch64: input.build_cpu == "x64" ? "gcc11.2.0-OL7.6+1.1" : "gcc11.2.0-OL7.6+1.0",
10871087
linux_arm: "gcc8.2.0-Fedora27+1.0",

make/devkit/createMacosxDevkit.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,8 @@ for ex in $EXCLUDE_DIRS; do
106106
done
107107

108108
echo "Copying Xcode.app..."
109-
echo rsync -rlH $INCLUDE_ARGS $EXCLUDE_ARGS "$XCODE_APP/." $DEVKIT_ROOT/Xcode.app/
110-
rsync -rlH $INCLUDE_ARGS $EXCLUDE_ARGS "$XCODE_APP/." $DEVKIT_ROOT/Xcode.app/
109+
echo rsync -rlH $INCLUDE_ARGS $EXCLUDE_ARGS "$XCODE_APP/." $DEVKIT_ROOT/Xcode
110+
rsync -rlH $INCLUDE_ARGS $EXCLUDE_ARGS "$XCODE_APP/." $DEVKIT_ROOT/Xcode
111111

112112
################################################################################
113113

@@ -119,8 +119,8 @@ echo "Generating devkit.info..."
119119
rm -f $DEVKIT_ROOT/devkit.info
120120
echo-info "# This file describes to configure how to interpret the contents of this devkit"
121121
echo-info "DEVKIT_NAME=\"Xcode $XCODE_VERSION (devkit)\""
122-
echo-info "DEVKIT_TOOLCHAIN_PATH=\"\$DEVKIT_ROOT/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin:\$DEVKIT_ROOT/Xcode.app/Contents/Developer/usr/bin\""
123-
echo-info "DEVKIT_SYSROOT=\"\$DEVKIT_ROOT/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/$SDK_VERSION.sdk\""
122+
echo-info "DEVKIT_TOOLCHAIN_PATH=\"\$DEVKIT_ROOT/Xcode/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin:\$DEVKIT_ROOT/Xcode/Contents/Developer/usr/bin\""
123+
echo-info "DEVKIT_SYSROOT=\"\$DEVKIT_ROOT/Xcode/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/$SDK_VERSION.sdk\""
124124
echo-info "DEVKIT_EXTRA_PATH=\"\$DEVKIT_TOOLCHAIN_PATH\""
125125

126126
################################################################################

0 commit comments

Comments
 (0)