-
Notifications
You must be signed in to change notification settings - Fork 0
84 lines (71 loc) · 2.93 KB
/
llvm.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: llvm
on:
push:
branches: ["master"]
pull_request:
branches: ["master"]
permissions:
contents: read
jobs:
build:
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
id: cache-llvm-16
with:
path: |
/usr/local/opt/llvm
/usr/local/Cellar/llvm/
key: ${{ runner.os }}-llvm-16
- uses: actions/cache@v3
with:
path: |
/Users/runner/.xmake
key: ${{ runner.os }}-xmake-${{ hashFiles('**/xmake.lua') }}
- uses: actions/cache@v3
with:
path: |
/usr/local/share/vcpkg
./vcpkg
key: ${{ runner.os }}-vcpkg-${{ hashFiles('**/xmake.lua') }}
- uses: actions/cache@v3
with:
key: ${{ runner.os }}-deno-${{ hashFiles('**/deps.ts') }}-${{ hashFiles('**/import_map.json') }}
path: |
~/.deno
~/Library/Caches/deno
- name: Install LLVM and Clang
if: ${{ steps.cache-llvm-16.outputs.cache-hit!= 'true' }}
run: brew install llvm@16
- name: install
run: |
brew install xmake python@3.11 six z3 zstd
brew install libtool automake
export LDFLAGS="-L/usr/local/opt/llvm/lib"
export CPPFLAGS="-I/usr/local/opt/llvm/include"
echo 'export PATH="/usr/local/opt/llvm/bin:$PATH"' >> /Users/runner/.bash_profile
- name: vcpkg-action
uses: johnwason/vcpkg-action@v4
with:
token: ${{ github.token }}
triplet: x64-osx-release
pkgs: "gtest cppunit"
- name: Setup Deno
uses: denoland/setup-deno@v1.1.0
with:
deno-version: v1.33.1
- run: deno task cache
- uses: xmake-io/github-action-setup-xmake@v1
with:
xmake-version: branch@dev
actions-cache-folder: ".xmake-cache"
- run: xmake l install.lua
- run: deno run -A xmake.ts --mode=test --group=test --toolchain=llvm --sdk=/usr/local/opt/llvm/
- run: xmake clean -a
- run: xmake f --toolchain=llvm --sdk=/usr/local/opt/llvm/ -y -v --project=. "--file=./xmake.lua"
- run: xmake build -v -y -w --project=. "--file=./xmake.lua"
- run: xmake clean -a
- run: xmake f --toolchain=llvm --sdk=/usr/local/opt/llvm/ -y -v --project=. "--file=./xmake.lua" --mode=test
- run: xmake build -v -y -w --project=. "--file=./xmake.lua" --group=test
- run: xmake run --group=test