Skip to content

Commit 1cd89eb

Browse files
committed
Update runtimes workflow
1 parent e91d6d1 commit 1cd89eb

3 files changed

Lines changed: 36 additions & 0 deletions

File tree

.github/workflows/collect_runtimes.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
push:
55
paths:
66
- 'runtimes/*.squashfs'
7+
- 'runtimes/*.squashfs.md5'
78
workflow_dispatch:
89
workflow_run:
910
# The push trigger above doesn't fire for pushes made by the default
@@ -47,6 +48,14 @@ jobs:
4748
LOCAL_SET[$(basename "$f")]=1
4849
done
4950
51+
for m in $(find runtimes -maxdepth 1 -name '*.squashfs.md5' -type f | sort); do
52+
base=$(basename "$m" .md5) # <name>.squashfs.md5 -> <name>.squashfs
53+
if [ ! -f "runtimes/$base" ]; then
54+
echo "Release-hosted runtime (marker only, exempt from purge): $base"
55+
LOCAL_SET[$base]=1
56+
fi
57+
done
58+
5059
# Snapshot remote assets (name → size, name → id)
5160
RELEASE_ID=$(gh api repos/${GITHUB_REPOSITORY}/releases/tags/runtimes-latest --jq '.id')
5261
declare -A REMOTE_SIZES REMOTE_IDS
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
set -e
2+
3+
# Mono runtime build courtesy [JohnnyOnFlame](https://gist.github.com/JohnnyonFlame/df7ba61a5559de293680789e7f01fbdc#file-bonus2_readme-md),
4+
# which produces the same runtime PortMaster hosts
5+
6+
VERSION="${MONO_VERSION:-6.12.0.122}"
7+
ARCH=aarch64
8+
9+
wget "https://download.mono-project.com/sources/mono/mono-${VERSION}.tar.xz"
10+
tar xf "mono-${VERSION}.tar.xz"
11+
cp Makefile.optm "mono-${VERSION}/Makefile.optm"
12+
cd "mono-${VERSION}"
13+
14+
./autogen.sh \
15+
--with-ikvm-native=no \
16+
--with-csc=mcs \
17+
--enable-llvm \
18+
--disable-dependency-tracking \
19+
--with-mcs-build \
20+
--prefix="$(pwd)/built"
21+
make -j"$(nproc)"
22+
make install
23+
24+
cd built
25+
PATH="$(pwd)/bin:$(pwd)/../llvm/usr/bin:$PATH" MONO_PATH="$(pwd)/lib/mono" \
26+
make -f Makefile.optm -j"$(nproc)"
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
dc7145731bf17610c13c07d6e69de550

0 commit comments

Comments
 (0)