From 8c59795d72c6920ed7ad8a08195a90d8b1fdb107 Mon Sep 17 00:00:00 2001 From: Tungstend <74163103+Tungstend@users.noreply.github.com> Date: Sun, 10 Mar 2024 02:22:25 +0800 Subject: [PATCH] Fix jre21 build for Android x86 (#23) * Update tarjdk.sh * Update buildjdk.sh * Update clonejdk.sh * Update build.yml * Update buildjdk.sh * Update buildjdk.sh --- .github/workflows/build.yml | 2 +- buildjdk.sh | 1 + clonejdk.sh | 2 +- tarjdk.sh | 2 +- 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3e0fa9e2..c2f4ffeb 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,4 @@ -name: Build OpenJDK 17 for Android and iOS +name: Build OpenJDK 21 for Android and iOS on: push: diff --git a/buildjdk.sh b/buildjdk.sh index f1215da9..cbdb8367 100755 --- a/buildjdk.sh +++ b/buildjdk.sh @@ -31,6 +31,7 @@ if [ "$BUILD_IOS" != "1" ]; then platform_args="--with-toolchain-type=gcc \ --with-freetype-include=$FREETYPE_DIR/include/freetype2 \ --with-freetype-lib=$FREETYPE_DIR/lib \ + --build=x86_64-unknown-linux-gnu \ " AUTOCONF_x11arg="--x-includes=$ANDROID_INCLUDE/X11" AUTOCONF_EXTRA_ARGS+="OBJCOPY=$OBJCOPY \ diff --git a/clonejdk.sh b/clonejdk.sh index 50fdb7e4..81e9abb9 100755 --- a/clonejdk.sh +++ b/clonejdk.sh @@ -1,4 +1,4 @@ #!/bin/bash set -e -git clone --depth 1 https://github.com/openjdk/jdk21u openjdk +git clone --branch jdk21.0.1 --depth 1 https://github.com/openjdk/jdk21u openjdk diff --git a/tarjdk.sh b/tarjdk.sh index b0ea254a..89f37c40 100755 --- a/tarjdk.sh +++ b/tarjdk.sh @@ -5,7 +5,7 @@ set -e if [ "$BUILD_IOS" != "1" ]; then unset AR AS CC CXX LD OBJCOPY RANLIB STRIP CPPFLAGS LDFLAGS -git clone https://github.com/termux/termux-elf-cleaner || true +git clone --depth 1 -b 'v2.2.0' https://github.com/termux/termux-elf-cleaner || true cd termux-elf-cleaner autoreconf --install bash configure