forked from WebAssembly/wasi-libc
-
Notifications
You must be signed in to change notification settings - Fork 22
75 lines (67 loc) · 2.04 KB
/
build_cxx_sysroot.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
name: Build C/C++ Sysroot
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: read
checks: write
jobs:
build_cxx_sysroot:
runs-on: ubuntu-latest
container:
image: archlinux:base-devel
options: --user root --workdir /
steps:
- name: Update and install dependencies
run: |
pacman -Syu --noconfirm
pacman -Sy --noconfirm coreutils nodejs npm wget git cmake ninja llvm14 clang14 rsync make lld wasmer cargo
ln -s usr/lib/llvm14/bin/clang-14 /usr/bin/clang
ln -s /usr/bin/llvm-ar-14 /usr/bin/llvm-ar
ln -s /usr/bin/llvm-nm-14 /usr/bin/llvm-nm
- name: Log tool versions
run: |
ls /usr/bin -alsh
echo XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
echo git
git --version
echo "##########################"
echo wasmer
wasmer -V
echo "##########################"
echo clang
clang -v
echo "##########################"
echo llvm-ar
llvm-ar -V
echo "##########################"
echo llvm-nm
llvm-nm -V
echo "##########################"
echo nodejs
node -v
echo "##########################"
echo npm
npm -v
- name: Checkout
uses: actions/checkout@v3
with:
submodules: true
- name: Build
run: |
git config --global --add safe.directory $(pwd)
./build32.sh
rm -rf /opt/wasix-sysroot
cp -r sysroot /opt/wasix-sysroot
cp .github/workflows/files/clang-wasix.cmake_toolchain /opt/wasix-sysroot/clang-wasix.cmake_toolchain
- name: Upload sysroot
if: ${{ !env.ACT }}
uses: actions/upload-artifact@v2
with:
name: wasix-sysroot
path: /opt/wasix-sysroot
- name: Run WASIX tests
run: |
TOOLCHAIN=/opt/wasix-sysroot/clang-wasix.cmake_toolchain ./test/wasix/run_tests.sh