Skip to content

Add GraalVM native image compilation support #10

Add GraalVM native image compilation support

Add GraalVM native image compilation support #10

Workflow file for this run

name: Build Native Image
on:
push:
branches:
- 'main'
pull_request:
types: [opened, reopened, synchronize]
workflow_dispatch:
env:
GRAALVM_DISTRIBUTION: 'graalvm'
JAVA_VERSION: '21'
jobs:
build:
name: Build ${{ matrix.platform }}
runs-on: ${{ matrix.os }}
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
platform: linux-amd64
- os: ubuntu-24.04-arm
platform: linux-arm64
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup GraalVM
uses: graalvm/setup-graalvm@v1
with:
java-version: ${{ env.JAVA_VERSION }}
distribution: ${{ env.GRAALVM_DISTRIBUTION }}
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v4
- name: Build native image
run: |
chmod +x ./gradlew ./native/build.sh ./native/simulate.sh ./native/verify.py
./native/build.sh
- name: Package binary
run: |
tar -czf nextflow-lsp-${{ matrix.platform }}.tar.gz \
-C build/native/nativeCompile nextflow-lsp
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: nextflow-lsp-${{ matrix.platform }}
path: nextflow-lsp-${{ matrix.platform }}.tar.gz
retention-days: 7