mirror of
https://github.com/wolfpld/tracy.git
synced 2026-09-02 00:18:23 +00:00
88 lines
3.2 KiB
YAML
88 lines
3.2 KiB
YAML
name: windows
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
pull_request:
|
|
branches: [ master ]
|
|
workflow_dispatch:
|
|
workflow_call:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
concurrency:
|
|
group: windows-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
env:
|
|
CPM_SOURCE_CACHE: ${{ github.workspace }}/cpm-cache
|
|
|
|
jobs:
|
|
build-windows:
|
|
runs-on: windows-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Cache CPM packages
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: ${{ env.CPM_SOURCE_CACHE }}
|
|
key: ${{ runner.os }}-cpm-${{ hashFiles('**/vendor.cmake', '**/CMakeLists.txt') }}
|
|
restore-keys: ${{ runner.os }}-cpm-
|
|
- uses: microsoft/setup-msbuild@v2
|
|
- name: Trust git repo
|
|
run: git config --global --add safe.directory '*'
|
|
- name: Install meson
|
|
run: python -m pip install --upgrade meson
|
|
- name: Library (meson)
|
|
env:
|
|
CCACHE_DISABLE: '1'
|
|
run: |
|
|
$vs = & "C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" -latest -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath
|
|
foreach ($line in & cmd /c "`"$vs\VC\Auxiliary\Build\vcvarsall.bat`" x64 && set") {
|
|
if ($line -match '^([^=]+)=(.*)$') { [Environment]::SetEnvironmentVariable($matches[1], $matches[2], 'Process') }
|
|
}
|
|
meson setup -Dtracy_enable=true build-meson
|
|
meson compile -C build-meson
|
|
- name: Test application
|
|
uses: ./.github/actions/test-tracy
|
|
- name: Build profiler
|
|
run: |
|
|
cmake -B profiler/build -S profiler -DCMAKE_BUILD_TYPE=Release -DGIT_REV=${{ github.sha }}
|
|
cmake --build profiler/build --parallel 2 --config Release
|
|
- name: Build update
|
|
run: |
|
|
cmake -B update/build -S update -DCMAKE_BUILD_TYPE=Release -DGIT_REV=${{ github.sha }}
|
|
cmake --build update/build --parallel --config Release
|
|
- name: Build capture
|
|
run: |
|
|
cmake -B capture/build -S capture -DCMAKE_BUILD_TYPE=Release -DGIT_REV=${{ github.sha }}
|
|
cmake --build capture/build --parallel --config Release
|
|
- name: Build csvexport
|
|
run: |
|
|
cmake -B csvexport/build -S csvexport -DCMAKE_BUILD_TYPE=Release -DGIT_REV=${{ github.sha }}
|
|
cmake --build csvexport/build --parallel --config Release
|
|
- name: Build import
|
|
run: |
|
|
cmake -B import/build -S import -DCMAKE_BUILD_TYPE=Release -DGIT_REV=${{ github.sha }}
|
|
cmake --build import/build --parallel --config Release
|
|
- name: Build merge
|
|
run: |
|
|
cmake -B merge/build -S merge -DCMAKE_BUILD_TYPE=Release -DGIT_REV=${{ github.sha }}
|
|
cmake --build merge/build --parallel --config Release
|
|
- name: Package artifacts
|
|
run: |
|
|
mkdir bin
|
|
copy profiler\build\Release\tracy-profiler.exe bin
|
|
copy update\build\Release\tracy-update.exe bin
|
|
copy capture\build\Release\tracy-capture.exe bin
|
|
copy capture\build\Release\tracy-capture-daemon.exe bin
|
|
copy csvexport\build\Release\tracy-csvexport.exe bin
|
|
copy import\build\Release\tracy-import-chrome.exe bin
|
|
copy import\build\Release\tracy-import-fuchsia.exe bin
|
|
copy merge\build\Release\tracy-merge.exe bin
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: windows
|
|
path: bin
|