@@ -2,82 +2,39 @@ name: build
22
33on :
44 push :
5- branches : [ master ]
5+ branches : [master]
66 pull_request :
7- branches : [ master ]
8-
9- env :
10- CPM_SOURCE_CACHE : ${{ github.workspace }}/cpm-cache
7+ branches : [master]
118
129jobs :
1310 build :
1411 strategy :
1512 matrix :
16- os : [ windows-latest, macos-15 ]
13+ os : [ubuntu-latest, windows-latest, macos-latest ]
1714
1815 runs-on : ${{ matrix.os }}
1916 continue-on-error : true
2017 steps :
21- - uses : actions/checkout@v4
22- - if : startsWith(matrix.os, 'windows')
23- uses : microsoft/setup-msbuild@v2
24- - if : startsWith(matrix.os, 'windows')
25- uses : actions/setup-python@v2
26- with :
27- python-version : ' 3.x'
28- - if : startsWith(matrix.os, 'windows')
29- run : pip install meson ninja
30- - if : startsWith(matrix.os, 'macos')
31- name : Install macos dependencies
32- run : brew install pkg-config glfw meson
33- - name : Trust git repo
34- run : git config --global --add safe.directory '*'
35- - name : Profiler GUI
36- run : |
37- cmake -B profiler/build -S profiler -DCMAKE_BUILD_TYPE=Release -DGIT_REV=${{ github.sha }}
38- cmake --build profiler/build --parallel --config Release
39- - name : Update utility
40- run : |
41- cmake -B update/build -S update -DCMAKE_BUILD_TYPE=Release
42- cmake --build update/build --parallel --config Release
43- - name : Capture utility
44- run : |
45- cmake -B capture/build -S capture -DCMAKE_BUILD_TYPE=Release
46- cmake --build capture/build --parallel --config Release
47- - name : Csvexport utility
48- run : |
49- cmake -B csvexport/build -S csvexport -DCMAKE_BUILD_TYPE=Release
50- cmake --build csvexport/build --parallel --config Release
51- - name : Import utilities
52- run : |
53- cmake -B import/build -S import -DCMAKE_BUILD_TYPE=Release
54- cmake --build import/build --parallel --config Release
55- - if : ${{ !startsWith(matrix.os, 'windows') }}
56- name : Library
57- run : meson setup -Dprefix=$GITHUB_WORKSPACE/bin/lib build && meson compile -C build && meson install -C build
58- - if : ${{ !startsWith(matrix.os, 'windows') }}
59- name : Find Artifacts
60- id : find_artifacts
61- run : |
62- mkdir -p bin
63- cp profiler/build/tracy-profiler bin
64- cp update/build/tracy-update bin
65- cp capture/build/tracy-capture bin
66- cp csvexport/build/tracy-csvexport bin
67- cp import/build/tracy-import-chrome bin
68- cp import/build/tracy-import-fuchsia bin
69- - if : startsWith(matrix.os, 'windows')
70- name : Find Artifacts
71- id : find_artifacts_windows
72- run : |
73- mkdir bin
74- copy profiler\build\Release\tracy-profiler.exe bin
75- copy update\build\Release\tracy-update.exe bin
76- copy capture\build\Release\tracy-capture.exe bin
77- copy csvexport\build\Release\tracy-csvexport.exe bin
78- copy import\build\Release\tracy-import-chrome.exe bin
79- copy import\build\Release\tracy-import-fuchsia.exe bin
80- - uses : actions/upload-artifact@v4
81- with :
82- name : ${{ matrix.os }}
83- path : bin
18+ - uses : actions/checkout@v4
19+
20+ - name : Set up Zig
21+ uses : mlugg/setup-zig@v2
22+
23+ - name : Build (linux)
24+ if : matrix.os == 'ubuntu-latest'
25+ run : |
26+ zig build -Doptimize=ReleaseFast -Dno-fileselector -fno-sys=libxkbcommon -Dxkb-config-root="" -Dx-locale-root=""
27+ zig build -Doptimize=ReleaseFast -Dno-fileselector -Dlegacy
28+
29+ - name : Build (macOS)
30+ if : matrix.os == 'macos-latest'
31+ run : zig build -Doptimize=ReleaseFast -Dno-fileselector
32+
33+ - name : Build (windows)
34+ if : matrix.os == 'windows-latest'
35+ run : zig build -Doptimize=ReleaseFast
36+
37+ - uses : actions/upload-artifact@v4
38+ with :
39+ name : ${{ matrix.os }}
40+ path : zig-out
0 commit comments