From 657f0b1a2b2f7add3bc7dfc70b96588c00f2a050 Mon Sep 17 00:00:00 2001 From: Christian Stein Date: Thu, 1 Feb 2024 10:01:09 +0100 Subject: [PATCH 1/3] Support running on ARM64 machines Closes #63 Closes #64 Closes #71 --- CHANGELOG.md | 3 ++- action.yml | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 94b6ddf..732407a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,8 @@ This project uses tags and branches for [release management](https://docs.github ## [Unreleased] -_nothing noteworthy, yet_ +### Fixed +- Support running on ARM64 machines [#63](https://github.com/oracle-actions/setup-java/issues/63) ## [1.3.3] - 2024-01-29 ### Changed diff --git a/action.yml b/action.yml index 1e44309..fb5c2ba 100644 --- a/action.yml +++ b/action.yml @@ -47,6 +47,9 @@ runs: shell: bash run: | JAVA=$JAVA_HOME_17_X64/bin/java + if [ ! -d "$JAVA_HOME_17_X64" ]; then + JAVA=$JAVA_HOME_17_ARM64/bin/java + fi DOWNLOAD=$GITHUB_ACTION_PATH/src/Download.java if [ ! -z "${{ inputs.uri }}" ]; then $JAVA \ From 8e70b6771fda78fb78839004efbdf66671baf958 Mon Sep 17 00:00:00 2001 From: Christian Stein Date: Thu, 1 Feb 2024 10:05:00 +0100 Subject: [PATCH 2/3] Extend test workflow to include ARM-based runner --- .github/workflows/manual-uri.yml | 1 + .github/workflows/manual-website-release-version.yml | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/manual-uri.yml b/.github/workflows/manual-uri.yml index 836bebf..65d4f74 100644 --- a/.github/workflows/manual-uri.yml +++ b/.github/workflows/manual-uri.yml @@ -9,6 +9,7 @@ on: options: - 'ubuntu-latest' - 'macos-latest' + - 'macos-14' - 'windows-latest' uri: description: 'URI of JDK archive file to download' diff --git a/.github/workflows/manual-website-release-version.yml b/.github/workflows/manual-website-release-version.yml index 87afaa2..16e0b6b 100644 --- a/.github/workflows/manual-website-release-version.yml +++ b/.github/workflows/manual-website-release-version.yml @@ -32,7 +32,7 @@ jobs: fail-fast: false max-parallel: 3 matrix: - os: [ ubuntu-latest, macos-latest, windows-latest ] + os: [ ubuntu-latest, macos-latest, macos-14, windows-latest ] runs-on: ${{ matrix.os }} steps: - name: 'Check out repository' From 9f275b96ca3b876e556a3f20ebba0a37c6c2f2c2 Mon Sep 17 00:00:00 2001 From: Christian Stein Date: Thu, 1 Feb 2024 10:21:04 +0100 Subject: [PATCH 3/3] Fix path and print Java's version information --- action.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/action.yml b/action.yml index fb5c2ba..b3b6b62 100644 --- a/action.yml +++ b/action.yml @@ -48,8 +48,9 @@ runs: run: | JAVA=$JAVA_HOME_17_X64/bin/java if [ ! -d "$JAVA_HOME_17_X64" ]; then - JAVA=$JAVA_HOME_17_ARM64/bin/java + JAVA=$JAVA_HOME_17_arm64/bin/java fi + $JAVA --version DOWNLOAD=$GITHUB_ACTION_PATH/src/Download.java if [ ! -z "${{ inputs.uri }}" ]; then $JAVA \