8266318: Switch to macos prefix for macOS bundles

Reviewed-by: prr, erikj, iris
This commit is contained in:
Mikael Vidstedt 2021-04-30 19:05:39 +00:00
parent 0544a732a4
commit 096e9e5d13
3 changed files with 17 additions and 19 deletions

View File

@ -1361,8 +1361,8 @@ jobs:
with: with:
name: transient_jdk-macos-x64${{ matrix.artifact }}_${{ needs.prerequisites.outputs.bundle_id }} name: transient_jdk-macos-x64${{ matrix.artifact }}_${{ needs.prerequisites.outputs.bundle_id }}
path: | path: |
jdk/build/macos-x64/bundles/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin${{ matrix.artifact }}.tar.gz jdk/build/macos-x64/bundles/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin${{ matrix.artifact }}.tar.gz
jdk/build/macos-x64/bundles/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin-tests${{ matrix.artifact }}.tar.gz jdk/build/macos-x64/bundles/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin-tests${{ matrix.artifact }}.tar.gz
macos_aarch64_build: macos_aarch64_build:
name: macOS aarch64 name: macOS aarch64
@ -1464,8 +1464,8 @@ jobs:
with: with:
name: transient_jdk-macos-aarch64${{ matrix.artifact }}_${{ needs.prerequisites.outputs.bundle_id }} name: transient_jdk-macos-aarch64${{ matrix.artifact }}_${{ needs.prerequisites.outputs.bundle_id }}
path: | path: |
jdk/build/macos-aarch64/bundles/jdk-${{ env.JDK_VERSION }}-internal+0_osx-aarch64_bin${{ matrix.artifact }}.tar.gz jdk/build/macos-aarch64/bundles/jdk-${{ env.JDK_VERSION }}-internal+0_macos-aarch64_bin${{ matrix.artifact }}.tar.gz
jdk/build/macos-aarch64/bundles/jdk-${{ env.JDK_VERSION }}-internal+0_osx-aarch64_bin-tests${{ matrix.artifact }}.tar.gz jdk/build/macos-aarch64/bundles/jdk-${{ env.JDK_VERSION }}-internal+0_macos-aarch64_bin-tests${{ matrix.artifact }}.tar.gz
macos_x64_test: macos_x64_test:
@ -1572,13 +1572,13 @@ jobs:
- name: Unpack jdk - name: Unpack jdk
run: | run: |
mkdir -p "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin${{ matrix.artifact }}" mkdir -p "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin${{ matrix.artifact }}"
tar -xf "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin${{ matrix.artifact }}.tar.gz" -C "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin${{ matrix.artifact }}" tar -xf "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin${{ matrix.artifact }}.tar.gz" -C "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin${{ matrix.artifact }}"
- name: Unpack tests - name: Unpack tests
run: | run: |
mkdir -p "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin-tests${{ matrix.artifact }}" mkdir -p "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin-tests${{ matrix.artifact }}"
tar -xf "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin-tests${{ matrix.artifact }}.tar.gz" -C "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin-tests${{ matrix.artifact }}" tar -xf "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin-tests${{ matrix.artifact }}.tar.gz" -C "${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin-tests${{ matrix.artifact }}"
- name: Install dependencies - name: Install dependencies
run: brew install make run: brew install make
@ -1588,13 +1588,13 @@ jobs:
- name: Find root of jdk image dir - name: Find root of jdk image dir
run: | run: |
imageroot=`find ${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin${{ matrix.artifact }} -name release -type f` imageroot=`find ${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin${{ matrix.artifact }} -name release -type f`
echo "imageroot=`dirname ${imageroot}`" >> $GITHUB_ENV echo "imageroot=`dirname ${imageroot}`" >> $GITHUB_ENV
- name: Run tests - name: Run tests
run: > run: >
JDK_IMAGE_DIR=${{ env.imageroot }} JDK_IMAGE_DIR=${{ env.imageroot }}
TEST_IMAGE_DIR=${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_osx-x64_bin-tests${{ matrix.artifact }} TEST_IMAGE_DIR=${HOME}/jdk-macos-x64${{ matrix.artifact }}/jdk-${{ env.JDK_VERSION }}-internal+0_macos-x64_bin-tests${{ matrix.artifact }}
BOOT_JDK=${HOME}/bootjdk/${BOOT_JDK_VERSION}/Contents/Home BOOT_JDK=${HOME}/bootjdk/${BOOT_JDK_VERSION}/Contents/Home
JT_HOME=${HOME}/jtreg JT_HOME=${HOME}/jtreg
gmake test-prebuilt gmake test-prebuilt

View File

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2021, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -480,9 +480,11 @@ AC_DEFUN([PLATFORM_SETUP_LEGACY_VARS_HELPER],
fi fi
# The new version string in JDK 9 also defined new naming of OS and ARCH for bundles # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles
# Macosx is osx and x86_64 is x64 # The macOS bundle name was revised in JDK 17
#
# macosx is macos and x86_64 is x64
if test "x$OPENJDK_$1_OS" = xmacosx; then if test "x$OPENJDK_$1_OS" = xmacosx; then
OPENJDK_$1_OS_BUNDLE="osx" OPENJDK_$1_OS_BUNDLE="macos"
else else
OPENJDK_$1_OS_BUNDLE="$OPENJDK_TARGET_OS" OPENJDK_$1_OS_BUNDLE="$OPENJDK_TARGET_OS"
fi fi

View File

@ -672,11 +672,7 @@ var getJibProfilesProfiles = function (input, common, data) {
["--with-jcov-input-jdk=" + input.get(name + ".jdk", "home_path")]); ["--with-jcov-input-jdk=" + input.get(name + ".jdk", "home_path")]);
}); });
//
// Define artifacts for profiles // Define artifacts for profiles
//
// Macosx bundles are named osx
// tar.gz.
var artifactData = { var artifactData = {
"linux-x64": { "linux-x64": {
platform: "linux-x64", platform: "linux-x64",
@ -685,11 +681,11 @@ var getJibProfilesProfiles = function (input, common, data) {
platform: "linux-x86", platform: "linux-x86",
}, },
"macosx-x64": { "macosx-x64": {
platform: "osx-x64", platform: "macos-x64",
jdk_subdir: "jdk-" + data.version + ".jdk/Contents/Home", jdk_subdir: "jdk-" + data.version + ".jdk/Contents/Home",
}, },
"macosx-aarch64": { "macosx-aarch64": {
platform: "osx-aarch64", platform: "macos-aarch64",
jdk_subdir: "jdk-" + data.version + ".jdk/Contents/Home", jdk_subdir: "jdk-" + data.version + ".jdk/Contents/Home",
}, },
"windows-x64": { "windows-x64": {