Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Finish adding native-linux-riscv64 architecture support #112

Merged
merged 4 commits into from
Oct 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
162 changes: 142 additions & 20 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
java-version: 8
architecture: x64
- name: Build with Maven
run: mvn -B -ntp clean package --file pom.xml
run: mvn -B --show-version -ntp clean package --file pom.xml
- name: Upload the build
uses: actions/upload-artifact@v3
with:
Expand All @@ -44,7 +44,7 @@ jobs:
java-version: 11
architecture: x64
- name: Build with Maven
run: mvn -B -ntp clean package --file pom.xml
run: mvn -B --show-version -ntp --file pom.xml clean package

MacOS-x86_64-Build-JDK17:
runs-on: macos-latest
Expand All @@ -57,7 +57,7 @@ jobs:
java-version: 17
architecture: x64
- name: Build with Maven
run: mvn -B -ntp clean package --file pom.xml
run: mvn -B --show-version -ntp --file pom.xml clean package

Linux-x86_64-Build-JDK8:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -98,7 +98,7 @@ jobs:
restore-keys: |
${{ runner.os }}-pr-${{ env.cache-name }}-
${{ runner.os }}-pr-
- uses: uraimo/run-on-arch-action@v2.3.0
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
Expand All @@ -125,7 +125,7 @@ jobs:
run: |
export JAVA_HOME="/jdk"
chmod +x ./mvnw
./mvnw -B -ntp clean package
./mvnw -B --show-version -ntp clean package

- name: Upload the build
uses: actions/upload-artifact@v3
Expand All @@ -145,7 +145,7 @@ jobs:
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-
- uses: uraimo/run-on-arch-action@v2.3.0
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
Expand All @@ -172,7 +172,7 @@ jobs:
run: |
export JAVA_HOME="/jdk"
chmod +x ./mvnw
./mvnw -B -ntp clean package
./mvnw -B --show-version -ntp clean package

Linux-Aarch64-Build-JDK17:
runs-on: ubuntu-latest
Expand All @@ -186,7 +186,7 @@ jobs:
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-
- uses: uraimo/run-on-arch-action@v2.3.0
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
Expand Down Expand Up @@ -214,7 +214,7 @@ jobs:
export MAVEN_OPTS="-Djdk.lang.Process.launchMechanism=vfork"
export JAVA_HOME="/jdk"
chmod +x ./mvnw
./mvnw -B -ntp clean package
./mvnw -B --show-version -ntp clean package

Linux-ArmV7-Build-JDK8:
runs-on: ubuntu-latest
Expand All @@ -228,7 +228,7 @@ jobs:
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-
- uses: uraimo/run-on-arch-action@v2.3.0
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
Expand All @@ -255,7 +255,7 @@ jobs:
run: |
export JAVA_HOME="/jdk"
chmod +x ./mvnw
./mvnw -B -ntp clean package
./mvnw -B --show-version -ntp clean package

- name: Upload the build
uses: actions/upload-artifact@v3
Expand All @@ -275,7 +275,7 @@ jobs:
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-
- uses: uraimo/run-on-arch-action@v2.3.0
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
Expand All @@ -302,7 +302,7 @@ jobs:
run: |
export JAVA_HOME="/jdk"
chmod +x ./mvnw
./mvnw -B -ntp clean package
./mvnw -B --show-version -ntp clean package

Linux-s390x-Build-JDK8:
runs-on: ubuntu-latest
Expand All @@ -316,7 +316,7 @@ jobs:
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-
- uses: uraimo/run-on-arch-action@v2.3.0
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
Expand All @@ -339,7 +339,7 @@ jobs:

run: |
chmod +x ./mvnw
./mvnw -B -ntp clean package
./mvnw -B --show-version -ntp clean package

- name: Upload the build
uses: actions/upload-artifact@v3
Expand All @@ -359,7 +359,7 @@ jobs:
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-
- uses: uraimo/run-on-arch-action@v2.3.0
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
Expand All @@ -382,7 +382,129 @@ jobs:

run: |
chmod +x ./mvnw
./mvnw -B -ntp clean package
./mvnw -B --show-version -ntp clean package

Linux-riscv64-Build-JDK11:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
env:
cache-name: cache-m2-repository-${{ runner.os }}-jdk11-riscv64
with:
path: ~/.m2/repository
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-

- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
arch: riscv64
distro: ubuntu20.04

# Not required, but speeds up builds by storing container images in
# a GitHub package registry.
githubToken: ${{ github.token }}

# Mount the .m2/repository
dockerRunArgs: |
--platform linux/riscv64
--volume "/home/runner/.m2/repository/:/root/.m2/repository"
# Install dependencies
install: |
apt-get update
apt-get install -q -y curl gnupg2 autoconf automake libtool make tar git cmake build-essential openjdk-11-jdk

run: |
export MAVEN_OPTS="-Djdk.lang.Process.launchMechanism=vfork"
chmod +x ./mvnw
./mvnw -B --show-version -ntp clean package

- name: Upload the build
uses: actions/upload-artifact@v3
with:
name: Linux-riscv64-Build-JDK11
path: /home/runner/work/Brotli4j/

Linux-riscv64-Build-JDK17:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
env:
cache-name: cache-m2-repository-${{ runner.os }}-jdk17-riscv64
with:
path: ~/.m2/repository
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
arch: riscv64
distro: ubuntu20.04

# Not required, but speeds up builds by storing container images in
# a GitHub package registry.
githubToken: ${{ github.token }}

# Mount the .m2/repository
dockerRunArgs: |
--platform linux/riscv64
--volume "/home/runner/.m2/repository/:/root/.m2/repository"
# Install dependencies
install: |
apt-get update
apt-get install -q -y curl gnupg2 autoconf automake libtool make tar git cmake build-essential openjdk-17-jdk

run: |
export MAVEN_OPTS="-Djdk.lang.Process.launchMechanism=vfork"
chmod +x ./mvnw
./mvnw -B --show-version -ntp clean package

Linux-riscv64-Build-JDK21:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
env:
cache-name: cache-m2-repository-${{ runner.os }}-jdk21-riscv64
with:
path: ~/.m2/repository
key: ${{ runner.os }}-pr-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-pr-${{ matrix.arch }}-pr-${{ env.cache-name }}-pr-
- uses: uraimo/run-on-arch-action@v2.4.0
name: Run commands
id: runcmd
with:
arch: riscv64
distro: ubuntu22.04

# Not required, but speeds up builds by storing container images in
# a GitHub package registry.
githubToken: ${{ github.token }}

# Mount the .m2/repository
dockerRunArgs: |
--platform linux/riscv64
--volume "/home/runner/.m2/repository/:/root/.m2/repository"

# Install dependencies
install: |
apt-get update
apt-get install -q -y curl gnupg2 autoconf automake libtool make tar git cmake build-essential

curl -sL https://github.com/shyiko/jabba/raw/master/install.sh | bash && . ~/.jabba/jabba.sh
jabba install 21-custom=tgz+https://api.adoptium.net/v3/binary/latest/21/ea/linux/riscv64/jdk/hotspot/normal/eclipse?project=jdk -o /jdk

run: |
export JAVA_HOME="/jdk"
chmod +x ./mvnw
./mvnw -B --show-version -ntp clean package

Windows-x86_64-Build-JDK8:
runs-on: windows-latest
Expand All @@ -397,7 +519,7 @@ jobs:
- name: Enable Developer Command Prompt
uses: ilammy/msvc-dev-cmd@v1.12.0
- name: Build with Maven
run: mvn -B -ntp clean package --file pom.xml
run: mvn -B --show-version -ntp clean package --file pom.xml
- name: Upload the build
uses: actions/upload-artifact@v3
with:
Expand All @@ -418,7 +540,7 @@ jobs:
- name: Enable Developer Command Prompt
uses: ilammy/msvc-dev-cmd@v1.12.0
- name: Build with Maven
run: mvn -B -ntp clean package --file pom.xml
run: mvn -B --show-version -ntp --file pom.xml clean package

Windows-x86_64-Build-JDK17:
runs-on: windows-latest
Expand All @@ -433,4 +555,4 @@ jobs:
- name: Enable Developer Command Prompt
uses: ilammy/msvc-dev-cmd@v1.12.0
- name: Build with Maven
run: mvn -B -ntp clean package --file pom.xml
run: mvn -B --show-version -ntp --file pom.xml clean package
Loading