Skip to content

Commit 5920033

Browse files
committed
use zig to build xmake bundle
1 parent e553279 commit 5920033

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

.github/workflows/linux.yml

+24
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,25 @@ jobs:
3333
sudo apt install -y ruby ruby-dev rubygems build-essential llvm libc++-dev
3434
sudo apt install -y libgl1-mesa-dev libglu1-mesa-dev
3535
clang --version
36+
xrepo install zig
3637
3738
- name: Tests
3839
run: |
3940
xmake lua -v -D tests/run.lua
4041
xrepo --version
4142
43+
- name: Artifact
44+
run: |
45+
cd core
46+
xrepo env -b zig xmake f --embed=y --toolchain=zig --cross=x86_64-linux-gnu.2.29 -c
47+
xmake
48+
cp build/xmake ../artifacts/xmake-bundle
49+
cd ..
50+
- uses: actions/upload-artifact@v4
51+
with:
52+
name: xmake-bundle.linux.x86_64
53+
path: artifacts/xmake-bundle
54+
4255
- name: Publish
4356
if: github.event.action == 'published'
4457
env:
@@ -57,3 +70,14 @@ jobs:
5770
scripts/makeppa bionic # 18.04
5871
scripts/makeppa xenial # 16.04
5972
scripts/makeppa trusty # 14.04
73+
74+
- name: Publish bundle binary
75+
if: github.event.action == 'published'
76+
uses: actions/[email protected]
77+
env:
78+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
79+
with:
80+
upload_url: ${{ github.event.release.upload_url }}
81+
asset_path: artifacts/xmake-bundle
82+
asset_name: xmake-bundle-${{ steps.tagName.outputs.tag }}.linux.x86_64
83+
asset_content_type: application/zip

0 commit comments

Comments
 (0)