-
Notifications
You must be signed in to change notification settings - Fork 1
84 lines (73 loc) · 3.23 KB
/
graalvm.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: JMurmel Native Image builds
on:
push:
paths-ignore:
- CHANGES
- Dockerfile
- Dockerfile.distroless
- "**.md"
- "**.txt"
- "**.html"
- "**.lisp"
- "**.completions"
- "scribbles/**"
env:
JAVA_VERSION: 23
permissions:
contents: read
jobs:
build:
name: JMurmel Native on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, ubuntu-20.04]
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: graalvm/setup-graalvm@557ffcf459751b4d92319ee255bf3bec9b73964c # v1
with:
distribution: 'graalvm'
java-version: ${{ env.JAVA_VERSION }}
github-token: ${{ secrets.GITHUB_TOKEN }}
native-image-job-reports: 'true'
- name: Restore Maven repo
id: restore-maven
uses: actions/cache/restore@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-graalvm-maven-${{ hashFiles('**/pom.xml') }}
- name: Build JMurmel
run: |
mvn -V -B clean package -pl lambda "-Djavac.target=${{ env.JAVA_VERSION }}" -DskipTests
mvn -V -B clean package -f graalvm/pom.xml "-Djavac.target=${{ env.JAVA_VERSION }}" -DskipTests
- name: Run native image Windows
if: runner.os == 'Windows'
run: |
copy samples.murmel-mlib\mlib.lisp .
native-image --no-fallback --initialize-at-build-time=io.github.jmurmel --initialize-at-run-time=io.github.jmurmel.InstallDir -H:IncludeResources="META-INF/.*" -H:ReflectionConfigurationFiles=./graalvm/src/main/graalvm/reflectconfig -H:DynamicProxyConfigurationFiles=./graalvm/src/main/graalvm/proxyconfig -H:SerializationConfigurationFiles=./graalvm/src/main/graalvm/serializationconfig -cp ./graalvm/target/unsupported.jar -jar ./lambda/target/jmurmel.jar
./jmurmel --version
- name: Run native image Linux
if: runner.os == 'Linux'
run: |
cp samples.murmel-mlib/mlib.lisp .
native-image --gc=G1 --no-fallback --initialize-at-build-time=io.github.jmurmel --initialize-at-run-time=io.github.jmurmel.InstallDir -H:IncludeResources="META-INF/.*" -H:ReflectionConfigurationFiles=./graalvm/src/main/graalvm/reflectconfig -H:DynamicProxyConfigurationFiles=./graalvm/src/main/graalvm/proxyconfig -H:SerializationConfigurationFiles=./graalvm/src/main/graalvm/serializationconfig -cp ./graalvm/target/unsupported.jar -jar ./lambda/target/jmurmel.jar
./jmurmel --version
- name: Save Maven repo
id: cache-maven
uses: actions/cache/save@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
with:
path: ~/.m2/repository
key: ${{ steps.restore-maven.outputs.cache-primary-key }}
- name: Upload binaries, mlib and docs
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: jmurmel-native-${{ runner.os }}-${{ runner.arch }}
path: |
jmurmel
jmurmel.exe
mlib.lisp
murmel-langref.md
mlib.md
murmel-langref.html
mlib.html
LICENSE