diff options
Diffstat (limited to 'ci')
| -rwxr-xr-x | ci/setup-toolchain.sh | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ci/setup-toolchain.sh b/ci/setup-toolchain.sh index c832708..7aeaa42 100755 --- a/ci/setup-toolchain.sh +++ b/ci/setup-toolchain.sh @@ -12,10 +12,11 @@ dir=${TOOLCHAIN_DIR:-$HOME/toolchains} sdk="$dir/android-sdk" mkdir -p "$dir/dl" -# JDK 17 (Temurin). +# JDK (Temurin, exact pinned release; + must be %2B in the URL). if [ ! -x "$dir/jdk17/bin/java" ]; then - echo "setup: JDK $JDK_VERSION" - curl -fsSL "https://api.adoptium.net/v3/binary/latest/${JDK_VERSION}/ga/linux/x64/jdk/hotspot/normal/eclipse" -o "$dir/dl/jdk.tar.gz" + echo "setup: JDK $JDK_RELEASE" + rel=$(printf '%s' "$JDK_RELEASE" | sed 's/+/%2B/') + curl -fsSL "https://api.adoptium.net/v3/binary/version/jdk-${rel}/linux/x64/jdk/hotspot/normal/eclipse" -o "$dir/dl/jdk.tar.gz" mkdir -p "$dir/jdk17" tar xzf "$dir/dl/jdk.tar.gz" -C "$dir/jdk17" --strip-components=1 fi |