Add GitHub Workflow

This commit is contained in:
Zhuowei Zhang 2020-01-18 22:16:22 -05:00
parent 881689ead2
commit 60f37980aa
3 changed files with 42 additions and 1 deletions

24
.github/workflows/build.yml vendored Normal file
View File

@ -0,0 +1,24 @@
name: Build JDK for ARM
on: [push]
jobs:
build:
runs-on: ubuntu-18.04
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Build with CI build script
run: ./ci_build.sh
- name: Upload build output
uses: actions/upload-artifact@v1
with:
name: jre
path: jre.tar.xz

View File

@ -5,7 +5,11 @@ export FREETYPE_DIR=`pwd`/freetype-2.6.2/build_android-arm
export CUPS_DIR=`pwd`/cups-2.2.4
# My system's JDK is too old (7.0), so we add an Oracle boot JDK.
export PATH=`pwd`/jdk1.8.0_162/bin:$PATH
# Set "USE_SYSTEM_JDK_8=1" to use system jdk instead
if [ -z "$USE_SYSTEM_JDK_8" ]
then
export PATH=`pwd`/jdk1.8.0_162/bin:$PATH
fi
cd openjdk
rm -rf build

13
ci_build.sh Executable file
View File

@ -0,0 +1,13 @@
#!/bin/bash
set -e
# We have OpenJDK 8, good enough
export USE_SYSTEM_JDK_8=1
wget -nv -O android-ndk-r10e-linux-x86_64.zip "https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip"
./extractndk.sh
./getlibs.sh
./maketoolchain.sh
./clonejdk.sh
./buildlibs.sh
./buildjdk.sh
./removejdkdebuginfo.sh
./tarjdk.sh