mirror of
https://github.com/wolfpld/tracy.git
synced 2025-03-20 07:40:02 +08:00
102 lines
3.2 KiB
YAML
102 lines
3.2 KiB
YAML
name: linux
|
|
|
|
on:
|
|
push:
|
|
branches: [master]
|
|
pull_request:
|
|
branches: [master]
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
build:
|
|
strategy:
|
|
matrix:
|
|
os: [ubuntu-latest, windows-latest, macos-latest]
|
|
runs-on: ${{ matrix.os }}
|
|
continue-on-error: true # Allow other platforms to build even if one fails
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install Linux Dependencies
|
|
if: startsWith(matrix.os, 'ubuntu')
|
|
run: sudo apt-get install -y libcapstone-dev libtbb-dev libglfw3-dev libgtk-3-dev
|
|
|
|
- name: Windows MSVC
|
|
if: startsWith(matrix.os, 'windows')
|
|
uses: microsoft/setup-msbuild@v2
|
|
|
|
- name: Install Windows Dependencies
|
|
if: startsWith(matrix.os, 'windows')
|
|
# run: ./vcpkg/install_vcpkg_dependencies.bat
|
|
run: echo "Windows dependencies"
|
|
|
|
- name: Install MacOS Dependencies
|
|
if: startsWith(matrix.os, 'macos')
|
|
run: brew install capstone tbb pkg-config glfw meson dbus
|
|
|
|
- name: Build Profiler
|
|
run: |
|
|
cmake -B build/profiler -S profiler -DLEGACY=ON -DTRACY_DOWNLOAD_FREETYPE=ON
|
|
cmake --build build/profiler --config Release --parallel
|
|
|
|
- name: Build Update
|
|
run: |
|
|
cmake -B build/update -S update
|
|
cmake --build build/update --config Release --parallel
|
|
|
|
- name: Build Capture
|
|
run: |
|
|
cmake -B build/capture -S capture
|
|
cmake --build build/capture --config Release --parallel
|
|
|
|
- name: Build Csv Export
|
|
run: |
|
|
cmake -B build/csvexport -S csvexport
|
|
cmake --build build/csvexport --config Release --parallel
|
|
|
|
- name: Build Import Chrome
|
|
run: |
|
|
cmake -B build/import-chrome -S import-chrome
|
|
cmake --build build/import-chrome --config Release --parallel
|
|
|
|
- name: Build Import Fuchsia
|
|
run: |
|
|
cmake -B build/import-fuchsia -S import-fuchsia
|
|
cmake --build build/import-fuchsia --config Release --parallel
|
|
|
|
- name: Find Artifacts
|
|
if: ${{ !startsWith(matrix.os, 'windows') }}
|
|
id: find_artifacts
|
|
run: |
|
|
mkdir bin
|
|
cp build/profiler/Tracy bin
|
|
cp build/update/update bin
|
|
cp build/capture/capture bin
|
|
cp build/csvexport/csvexport bin
|
|
cp build/import-chrome/import-chrome bin
|
|
cp build/import-fuchsia/import-fuchsia bin
|
|
zip -r ${{ matrix.os }}.zip bin
|
|
|
|
- name: Find Artifacts Windows
|
|
if: startsWith(matrix.os, 'windows')
|
|
id: find_artifacts_windows
|
|
run: |
|
|
mkdir bin
|
|
copy build\profiler\Release\Tracy.exe bin
|
|
copy build\update\Release\update.exe bin
|
|
copy build\capture\Release\capture.exe bin
|
|
copy build\csvexport\Release\csvexport.exe bin
|
|
copy build\import-chrome\Release\import-chrome.exe bin
|
|
copy build\import-fuchsia\Release\import-fuchsia.exe bin
|
|
Compress-Archive -Path bin/* -Destination ${{ matrix.os }}.zip
|
|
|
|
- name: Export Artifacts
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: ${{ matrix.os }}
|
|
path: |
|
|
${{ matrix.os }}.zip |