build(core) remove fetch-tags #153
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Builds LWJGL and runs tests. | |
| # No artifacts are uploaded, see LWJGL-CI/lwjgl3 for that. | |
| name: LWJGL Build | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - master | |
| env: | |
| JAVA8_HOME: jdk8 | |
| JAVA_HOME: jdk8 | |
| ANT_OPTS: -Xmx1G | |
| LWJGL_BUILD_TYPE: nightly | |
| ZULU_BUILD: 94.0.17-ca-jdk8.0.492 | |
| ZULU_BUILD25: 34.17-ca-jdk25.0.3 | |
| ZULU_BUILD27: 0.27-beta-jdk27.0.0-beta.23 | |
| jobs: | |
| cache-kotlinc: | |
| name: Compile templates and cache kotlinc output | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 3 | |
| - name: Download JDK | |
| run: | | |
| mkdir jdk8 | |
| curl https://cdn.azul.com/zulu/bin/zulu8.${ZULU_BUILD}-linux_x64.tar.gz | tar xz -C jdk8 --strip-components 1 | |
| - name: Compile templates | |
| run: | | |
| git clone https://github.com/LWJGL-CI/OculusSDK.git ../OculusSDK | |
| ant -emacs compile-templates | |
| - name: Cache kotlinc output | |
| uses: actions/cache/save@v3 | |
| with: | |
| path: | | |
| bin/classes/generator | |
| bin/classes/templates | |
| key: cache-kotlinc-${{ github.sha }} | |
| enableCrossOsArchive: true | |
| linux: | |
| name: Linux | |
| needs: cache-kotlinc | |
| runs-on: ubuntu-latest | |
| container: | |
| image: almalinux:8 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| ARCH: [x64] | |
| include: | |
| - ARCH: x64 | |
| defaults: | |
| run: | |
| shell: bash | |
| steps: | |
| - name: Install git | |
| run: dnf -y install git | |
| - uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 3 | |
| - name: Install build dependencies # make is necessary for -flto=auto | |
| run: | | |
| dnf -y install epel-release wget | |
| dnf config-manager --set-enabled powertools | |
| dnf -y update | |
| dnf -y install gcc-toolset-15-gcc gcc-toolset-15-gcc-c++ ant awscli curl zstd make | |
| mkdir jdk8 | |
| mkdir jdk25 | |
| mkdir jdk27 | |
| curl -L https://cdn.azul.com/zulu/bin/zulu8.${ZULU_BUILD}-linux_x64.tar.gz | tar xz -C jdk8 --strip-components 1 | |
| curl -L https://cdn.azul.com/zulu/bin/zulu25.${ZULU_BUILD25}-linux_x64.tar.gz | tar xz -C jdk25 --strip-components 1 | |
| curl -L https://cdn.azul.com/zulu/bin/zulu27.${ZULU_BUILD27}-linux_x64.tar.gz | tar xz -C jdk27 --strip-components 1 | |
| - name: Install LWJGL dependencies | |
| run: | | |
| dnf -y install \ | |
| libX11-devel \ | |
| libXt-devel \ | |
| gtk3-devel \ | |
| dbus-devel | |
| - name: Restore kotlinc output | |
| uses: actions/cache/restore@v3 | |
| with: | |
| path: | | |
| bin/classes/generator | |
| bin/classes/templates | |
| key: cache-kotlinc-${{ github.sha }} | |
| enableCrossOsArchive: true | |
| fail-on-cache-miss: true | |
| - name: Generate bindings | |
| run: ant -emacs clean-generated generate | |
| - name: Build Java | |
| run: ant -emacs compile | |
| - name: Build native | |
| run: | | |
| source /opt/rh/gcc-toolset-15/enable || true | |
| ant -emacs compile-native -Dgcc.version.print=true | |
| - name: Run tests | |
| run: ant -emacs tests | |
| - name: Print test results | |
| run: cat bin/test/testng-results.xml | |
| if: failure() | |
| - name: Run tests (JDK 25) | |
| run: | | |
| source /opt/rh/gcc-toolset-15/enable || true | |
| JAVA_HOME=jdk25 ant -emacs tests -Dcore.java25=true | |
| JAVA_HOME=jdk25 ant -emacs tests -Dcore.java25=true -Djvmargs="--add-exports java.base/jdk.internal.misc=ALL-UNNAMED" | |
| JAVA_HOME=jdk25 ant -emacs tests -Dcore.java25=true -Djvmargs="-Dorg.lwjgl.system.memoryBackend=ffm" | |
| - name: Print test results | |
| run: cat bin/test/testng-results.xml | |
| if: failure() | |
| - name: Run tests (JDK 27) | |
| run: | | |
| source /opt/rh/gcc-toolset-15/enable || true | |
| JAVA_HOME=jdk27 ant -emacs tests -Dcore.java27=true | |
| JAVA_HOME=jdk27 ant -emacs tests -Dcore.java27=true -Djvmargs="--add-exports java.base/jdk.internal.misc=ALL-UNNAMED" | |
| JAVA_HOME=jdk27 ant -emacs tests -Dcore.java27=true -Djvmargs="-Dorg.lwjgl.system.memoryBackend=ffm" | |
| - name: Print test results | |
| run: cat bin/test/testng-results.xml | |
| if: failure() | |
| - name: Run demo with OpenJDK | |
| run: ant demo -Dclass=org.lwjgl.demo.util.lz4.HelloLZ4 | |
| - name: Build GraalVM Native Image | |
| run: | | |
| source /opt/rh/gcc-toolset-15/enable || true | |
| mkdir jdk-graalvm | |
| curl -L https://download.oracle.com/graalvm/25/latest/graalvm-jdk-25_linux-x64_bin.tar.gz | tar xz -C jdk-graalvm --strip-components 1 | |
| jdk-graalvm/bin/native-image -cp \ | |
| bin/classes/lwjgl/core/META-INF/versions/25:\ | |
| bin/classes/lwjgl/core/META-INF/versions/17:\ | |
| bin/classes/lwjgl/core/META-INF/versions/11:\ | |
| bin/classes/lwjgl/core:\ | |
| bin/classes/lwjgl/lz4:\ | |
| bin/classes/samples:\ | |
| modules/samples/src/test/resources:\ | |
| bin/libs/java/joml.jar:\ | |
| bin/libs/native:\ | |
| config/native-image \ | |
| org.lwjgl.demo.util.lz4.HelloLZ4 --verbose --no-fallback \ | |
| --add-exports java.base/jdk.internal.misc=ALL-UNNAMED \ | |
| --enable-native-access=ALL-UNNAMED | |
| - name: Run demo with GraalVM JIT | |
| run: JAVA_HOME=jdk-graalvm ant demo -Dclass=org.lwjgl.demo.util.lz4.HelloLZ4 | |
| - name: Run demo with GraalVM Native Image | |
| run: ./org.lwjgl.demo.util.lz4.hellolz4 | |
| linux-cross: | |
| name: Linux Cross | |
| needs: cache-kotlinc | |
| runs-on: ubuntu-22.04 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| ARCH: [arm32, arm64, ppc64le, riscv64] | |
| include: | |
| # ---- | |
| - ARCH: arm32 | |
| CROSS_ARCH: armhf | |
| TRIPLET: arm-linux-gnueabihf | |
| # ---- | |
| - ARCH: arm64 | |
| CROSS_ARCH: arm64 | |
| TRIPLET: aarch64-linux-gnu | |
| # ---- | |
| - ARCH: ppc64le | |
| CROSS_ARCH: ppc64el | |
| TRIPLET: powerpc64le-linux-gnu | |
| # ---- | |
| - ARCH: riscv64 | |
| CROSS_ARCH: riscv64 | |
| TRIPLET: riscv64-linux-gnu | |
| env: | |
| LWJGL_BUILD_ARCH: ${{matrix.ARCH}} | |
| defaults: | |
| run: | |
| shell: bash | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 3 | |
| - name: Install dependencies # make is necessary for -flto=auto | |
| run: | | |
| git config --global --add safe.directory $(pwd) | |
| DEBIAN_FRONTEND=noninteractive sudo apt-get -yq update | |
| DEBIAN_FRONTEND=noninteractive sudo apt-get -yq install ant awscli curl zstd make \ | |
| gcc-12-${{matrix.TRIPLET}} \ | |
| g++-12-${{matrix.TRIPLET}} \ | |
| libc6-dev-${{matrix.CROSS_ARCH}}-cross | |
| mkdir jdk8 | |
| curl -L https://cdn.azul.com/zulu/bin/zulu8.${ZULU_BUILD}-linux_x64.tar.gz | tar xz -C jdk8 --strip-components 1 | |
| - name: Prepare cross-compilation for ${{matrix.CROSS_ARCH}} | |
| run: | | |
| sudo grep 'deb ' /etc/apt/sources.list | sudo tee /etc/apt/sources.list.d/ports.list | |
| sudo sed -i 's/^deb /deb [arch=amd64] /' /etc/apt/sources.list | |
| sudo sed -i 's#^deb [^ ]\+#deb [arch=${{matrix.CROSS_ARCH}}] https://ports.ubuntu.com/ubuntu-ports/#' /etc/apt/sources.list.d/ports.list | |
| sudo dpkg --add-architecture ${{matrix.CROSS_ARCH}} | |
| sudo apt-get update || true | |
| - name: Install cross-compilation dependencies | |
| run: | | |
| DEBIAN_FRONTEND=noninteractive sudo apt-get -yq install \ | |
| libgtk-3-dev:${{matrix.CROSS_ARCH}} \ | |
| libatk-bridge2.0-dev:${{matrix.CROSS_ARCH}} \ | |
| libgdk-pixbuf2.0-dev:${{matrix.CROSS_ARCH}} \ | |
| libglu-dev:${{matrix.CROSS_ARCH}} \ | |
| libgl1-mesa-glx:${{matrix.CROSS_ARCH}} \ | |
| libx11-dev:${{matrix.CROSS_ARCH}} \ | |
| libxt-dev:${{matrix.CROSS_ARCH}} \ | |
| libdbus-1-dev:${{matrix.CROSS_ARCH}} | |
| - name: Restore kotlinc output | |
| uses: actions/cache/restore@v3 | |
| with: | |
| path: | | |
| bin/classes/generator | |
| bin/classes/templates | |
| key: cache-kotlinc-${{ github.sha }} | |
| enableCrossOsArchive: true | |
| fail-on-cache-miss: true | |
| - name: Generate bindings | |
| run: ant -emacs clean-generated generate | |
| - name: Build Java | |
| run: ant -emacs compile | |
| - name: Build native | |
| run: ant -emacs compile-native -Dgcc.version=12 -Dgcc.version.print=true -Dgcc.libpath.opengl=/usr/lib/${{matrix.TRIPLET}}/mesa | |
| freebsd-cross: | |
| name: FreeBSD Cross | |
| needs: cache-kotlinc | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 20 | |
| strategy: | |
| fail-fast: false | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 3 | |
| - name: Install dependencies | |
| run: | | |
| mkdir jdk8 | |
| curl -L https://cdn.azul.com/zulu/bin/zulu8.${ZULU_BUILD}-linux_x64.tar.gz | tar xz -C jdk8 --strip-components 1 | |
| - name: Restore kotlinc output | |
| uses: actions/cache/restore@v3 | |
| with: | |
| path: | | |
| bin/classes/generator | |
| bin/classes/templates | |
| key: cache-kotlinc-${{ github.sha }} | |
| enableCrossOsArchive: true | |
| fail-on-cache-miss: true | |
| - name: Generate bindings | |
| run: ant -emacs clean-generated generate | |
| - name: Build Java | |
| run: ant -emacs compile | |
| - name: Start VM | |
| uses: cross-platform-actions/action@v1.2.0 | |
| with: | |
| operating_system: freebsd | |
| architecture: x86-64 | |
| version: '14.3' | |
| memory: 8G | |
| environment_variables: ANT_OPTS LWJGL_BUILD_TYPE | |
| - name: Install build dependencies | |
| shell: cpa.sh {0} | |
| run: sudo pkg install -y openjdk8 apache-ant git | |
| - name: Install LWJGL dependencies | |
| shell: cpa.sh {0} | |
| run: sudo pkg install -y gtk3 dbus | |
| - name: Build native | |
| shell: cpa.sh {0} | |
| run: ant -emacs compile-native -Dclang.version.print=true | |
| - name: Run tests | |
| shell: cpa.sh {0} | |
| run: ant -emacs tests | |
| - name: Print test results | |
| run: cat bin/test/testng-results.xml | |
| if: failure() | |
| - name: Run demo with OpenJDK | |
| shell: cpa.sh {0} | |
| run: ant demo -Dclass=org.lwjgl.demo.util.lz4.HelloLZ4 | |
| macos: | |
| name: macOS | |
| needs: cache-kotlinc | |
| runs-on: macos-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| ARCH: [x64, arm64] | |
| include: | |
| - ARCH: x64 | |
| JDK: x64 | |
| - ARCH: arm64 | |
| JDK: aarch64 | |
| env: | |
| JAVA8_HOME: jdk8/Home | |
| JAVA_HOME: jdk8/Home | |
| LWJGL_BUILD_ARCH: ${{matrix.ARCH}} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 3 | |
| - name: Install dependencies | |
| run: | | |
| mkdir jdk8 | |
| mkdir jdk25 | |
| mkdir jdk27 | |
| curl -L https://cdn.azul.com/zulu/bin/zulu8.${ZULU_BUILD}-macosx_${{matrix.JDK}}.tar.gz | tar xz -C jdk8 --strip-components 2 | |
| curl -L https://cdn.azul.com/zulu/bin/zulu25.${ZULU_BUILD25}-macosx_${{matrix.JDK}}.tar.gz | tar xz -C jdk25 --strip-components 2 | |
| curl -L https://cdn.azul.com/zulu/bin/zulu27.${ZULU_BUILD27}-macosx_${{matrix.JDK}}.tar.gz | tar xz -C jdk27 --strip-components 2 | |
| - name: Restore kotlinc output | |
| uses: actions/cache/restore@v3 | |
| with: | |
| path: | | |
| bin/classes/generator | |
| bin/classes/templates | |
| key: cache-kotlinc-${{ github.sha }} | |
| enableCrossOsArchive: true | |
| fail-on-cache-miss: true | |
| - name: Generate bindings | |
| run: ant -emacs clean-generated generate | |
| - name: Build Java | |
| run: ant -emacs compile | |
| - name: Build native | |
| run: ant -emacs compile-native -Dclang.version.print=true | |
| - name: Run tests | |
| run: ant -emacs tests | |
| - name: Print test results | |
| run: cat bin/test/testng-results.xml | |
| if: failure() | |
| - name: Run tests (JDK25) | |
| run: | | |
| JAVA_HOME=jdk25/Home ant -emacs tests -Dcore.java25=true | |
| JAVA_HOME=jdk25/Home ant -emacs tests -Dcore.java25=true -Djvmargs="--add-exports java.base/jdk.internal.misc=ALL-UNNAMED" | |
| JAVA_HOME=jdk25/Home ant -emacs tests -Dcore.java25=true -Djvmargs="-Dorg.lwjgl.system.memoryBackend=ffm" | |
| - name: Print test results | |
| run: cat bin/test/testng-results.xml | |
| if: failure() | |
| - name: Run tests (JDK27) | |
| run: | | |
| JAVA_HOME=jdk27/Home ant -emacs tests -Dcore.java27=true | |
| JAVA_HOME=jdk27/Home ant -emacs tests -Dcore.java27=true -Djvmargs="--add-exports java.base/jdk.internal.misc=ALL-UNNAMED" | |
| JAVA_HOME=jdk27/Home ant -emacs tests -Dcore.java27=true -Djvmargs="-Dorg.lwjgl.system.memoryBackend=ffm" | |
| - name: Print test results | |
| run: cat bin/test/testng-results.xml | |
| if: failure() | |
| - name: Run demo with OpenJDK | |
| run: ant demo -Dclass=org.lwjgl.demo.util.lz4.HelloLZ4 | |
| - name: Build GraalVM Native Image | |
| run: | | |
| mkdir jdk-graalvm | |
| curl -L https://download.oracle.com/graalvm/25/latest/graalvm-jdk-25_macos-${{matrix.JDK}}_bin.tar.gz | tar xz -C jdk-graalvm --strip-components 2 | |
| jdk-graalvm/Home/bin/native-image -cp \ | |
| bin/classes/lwjgl/core/META-INF/versions/25:\ | |
| bin/classes/lwjgl/core/META-INF/versions/17:\ | |
| bin/classes/lwjgl/core/META-INF/versions/11:\ | |
| bin/classes/lwjgl/core:\ | |
| bin/classes/lwjgl/lz4:\ | |
| bin/classes/samples:\ | |
| modules/samples/src/test/resources:\ | |
| bin/libs/java/joml.jar:\ | |
| bin/libs/native:\ | |
| config/native-image \ | |
| org.lwjgl.demo.util.lz4.HelloLZ4 --verbose --no-fallback \ | |
| --add-exports java.base/jdk.internal.misc=ALL-UNNAMED \ | |
| --enable-native-access=ALL-UNNAMED | |
| - name: Run demo with GraalVM JIT | |
| run: JAVA_HOME=jdk-graalvm/Home ant demo -Dclass=org.lwjgl.demo.util.lz4.HelloLZ4 | |
| - name: Run demo with GraalVM Native Image | |
| run: ./org.lwjgl.demo.util.lz4.hellolz4 | |
| windows: | |
| name: Windows | |
| needs: cache-kotlinc | |
| runs-on: windows-2022 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| ARCH: [x86, x64, arm64] | |
| include: | |
| - ARCH: x86 | |
| MSVC_ARCH: amd64_x86 | |
| #MSVC_ARCH: x86 | |
| #VCTOOLS: x86.x64 | |
| - ARCH: x64 | |
| MSVC_ARCH: amd64 | |
| #VCTOOLS: x86.x64 | |
| - ARCH: arm64 | |
| MSVC_ARCH: amd64_arm64 | |
| #MSVC_ARCH: arm64 | |
| #VCTOOLS: ARM64 | |
| env: | |
| LWJGL_BUILD_ARCH: ${{matrix.ARCH}} | |
| defaults: | |
| run: | |
| shell: cmd | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 3 | |
| - name: Configure MSVC | |
| uses: ilammy/msvc-dev-cmd@v1 | |
| with: | |
| arch: ${{ matrix.MSVC_ARCH }} | |
| - name: Clone Oculus SDK | |
| run: git clone https://github.com/LWJGL-CI/OculusSDK.git ../OculusSDK | |
| if: contains(matrix.ARCH, 'arm') != true | |
| - name: Install dependencies | |
| run: | | |
| Invoke-WebRequest https://cdn.azul.com/zulu/bin/zulu8.$Env:ZULU_BUILD-win_x64.zip -OutFile jdk.zip | |
| Expand-Archive -Path jdk.zip -DestinationPath .\ | |
| Rename-Item zulu8.$Env:ZULU_BUILD-win_x64 jdk8 | |
| Invoke-WebRequest https://cdn.azul.com/zulu/bin/zulu25.$Env:ZULU_BUILD25-win_x64.zip -OutFile jdk25.zip | |
| Expand-Archive -Path jdk25.zip -DestinationPath .\ | |
| Rename-Item zulu25.$Env:ZULU_BUILD25-win_x64 jdk25 | |
| Invoke-WebRequest https://cdn.azul.com/zulu/bin/zulu27.$Env:ZULU_BUILD27-win_x64.zip -OutFile jdk27.zip | |
| Expand-Archive -Path jdk27.zip -DestinationPath .\ | |
| Rename-Item zulu27.$Env:ZULU_BUILD27-win_x64 jdk27 | |
| shell: pwsh | |
| # - name: Install Visual Studio 2026 Build Tools | |
| # shell: pwsh | |
| # run: | | |
| # choco install visualstudio2026buildtools --package-parameters "` | |
| # --add Microsoft.VisualStudio.Workload.VCTools ` | |
| # --add Microsoft.VisualStudio.Component.VC.Tools.${{matrix.VCTOOLS}} ` | |
| # --includeRecommended ` | |
| # --quiet" ` | |
| # -y ` | |
| # --ignore-package-exit-codes=3010 | |
| - name: Restore kotlinc output | |
| uses: actions/cache/restore@v3 | |
| with: | |
| path: | | |
| bin/classes/generator | |
| bin/classes/templates | |
| key: cache-kotlinc-${{ github.sha }} | |
| enableCrossOsArchive: true | |
| fail-on-cache-miss: true | |
| - name: Generate bindings | |
| run: ant -emacs clean-generated generate | |
| - name: Build Java | |
| run: ant -emacs compile | |
| - name: Switch to x86 JDK | |
| run: | | |
| Remove-Item -Recurse jdk8 | |
| Invoke-WebRequest https://cdn.azul.com/zulu/bin/zulu8.$Env:ZULU_BUILD-win_i686.zip -OutFile jdk.zip | |
| Expand-Archive -Path jdk.zip -DestinationPath .\ | |
| Rename-Item zulu8.$Env:ZULU_BUILD-win_i686 jdk8 | |
| shell: pwsh | |
| if: matrix.ARCH == 'x86' | |
| - name: Build native # TODO: remove old LLVM workaround, see https://github.com/actions/runner-images/issues/10001 | |
| #call "C:\Program Files (x86)\Microsoft Visual Studio\18\BuildTools\Common7\Tools\VsDevCmd.bat" -host_arch=amd64 -arch=${{matrix.MSVC_ARCH}} | |
| run: | | |
| set PATH=%PATH:C:\Program Files\LLVM\bin;=% | |
| ant -emacs compile-native -Dcl.version.print=true | |
| - name: Run tests | |
| run: ant -emacs tests | |
| if: contains(matrix.ARCH, 'arm') != true | |
| - name: Print test results | |
| run: type bin\test\testng-results.xml | |
| if: failure() | |
| - name: Run tests (JDK25) | |
| run: | | |
| set JAVA_HOME=jdk25 | |
| ant -emacs tests -Dcore.java25=true | |
| ant -emacs tests -Dcore.java25=true -Djvmargs="--add-exports java.base/jdk.internal.misc=ALL-UNNAMED" | |
| ant -emacs tests -Dcore.java25=true -Djvmargs="-Dorg.lwjgl.system.memoryBackend=ffm" | |
| if: matrix.ARCH == 'x64' | |
| - name: Print test results | |
| run: type bin\test\testng-results.xml | |
| if: failure() | |
| - name: Run tests (JDK27) | |
| run: | | |
| set JAVA_HOME=jdk27 | |
| ant -emacs tests -Dcore.java27=true | |
| ant -emacs tests -Dcore.java27=true -Djvmargs="--add-exports java.base/jdk.internal.misc=ALL-UNNAMED" | |
| ant -emacs tests -Dcore.java27=true -Djvmargs="-Dorg.lwjgl.system.memoryBackend=ffm" | |
| if: matrix.ARCH == 'x64' | |
| - name: Print test results | |
| run: type bin\test\testng-results.xml | |
| if: failure() | |
| - name: Run demo with OpenJDK | |
| run: ant demo -Dclass=org.lwjgl.demo.util.lz4.HelloLZ4 | |
| if: matrix.ARCH == 'x64' | |
| - name: Download GraalVM | |
| run: | | |
| Invoke-WebRequest https://download.oracle.com/graalvm/25/latest/graalvm-jdk-25_windows-x64_bin.zip -OutFile jdk-graalvm.zip | |
| Expand-Archive -Path jdk-graalvm.zip -DestinationPath .\ | |
| Get-ChildItem graalvm-jdk-25* | Rename-Item -newname jdk-graalvm | |
| shell: pwsh | |
| if: matrix.ARCH == 'x64' | |
| - name: Build GraalVM Native Image | |
| run: | | |
| jdk-graalvm\bin\native-image -cp ^ | |
| bin/classes/lwjgl/core/META-INF/versions/25;^ | |
| bin/classes/lwjgl/core/META-INF/versions/17;^ | |
| bin/classes/lwjgl/core/META-INF/versions/11;^ | |
| bin/classes/lwjgl/core;^ | |
| bin/classes/lwjgl/lz4;^ | |
| bin/classes/samples;^ | |
| modules/samples/src/test/resources;^ | |
| bin/libs/java/joml.jar;^ | |
| bin/libs/native;^ | |
| config/native-image ^ | |
| org.lwjgl.demo.util.lz4.HelloLZ4 --verbose --no-fallback ^ | |
| --add-exports java.base/jdk.internal.misc=ALL-UNNAMED ^ | |
| --enable-native-access=ALL-UNNAMED | |
| if: matrix.ARCH == 'x64' | |
| - name: Run demo with GraalVM JIT | |
| run: | | |
| set JAVA_HOME=jdk-graalvm | |
| ant demo -Dclass=org.lwjgl.demo.util.lz4.HelloLZ4 | |
| if: matrix.ARCH == 'x64' | |
| - name: Run demo with GraalVM Native Image | |
| run: org.lwjgl.demo.util.lz4.hellolz4.exe | |
| if: matrix.ARCH == 'x64' |