Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 23 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -128,42 +128,54 @@ jobs:
run: bazel run //examples/google_benchmark_bazel:my_benchmark --//core:codspeed_mode=${{ matrix.codspeed-mode }}
token: ${{ secrets.CODSPEED_TOKEN }}

windows-cmake-build:
cmake-build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
codspeed-mode: ["off", "walltime"]
runs-on: windows-latest
runs-on: ${{ matrix.os }}
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: "recursive"

- name: Cache build
uses: actions/cache@v3
with:
path: examples/google_benchmark_cmake/build
key: ${{ runner.os }}-build-${{ matrix.codspeed-mode }}-${{ hashFiles('**/CMakeLists.txt') }}
key: ${{ runner.os }}-cmake-build-${{ matrix.codspeed-mode }}-${{ hashFiles('**/CMakeLists.txt') }}

- name: Create build directory
- name: Build benchmark example (Unix)
if: runner.os != 'Windows'
run: |
mkdir -p examples/google_benchmark_cmake/build
cd examples/google_benchmark_cmake/build
cmake -DCODSPEED_MODE=${{ matrix.codspeed-mode }} ..
make -j

- name: Build benchmark example (Windows)
if: runner.os == 'Windows'
run: |
if (-not (Test-Path examples\google_benchmark_cmake\build)) {
mkdir examples\google_benchmark_cmake\build
}
shell: pwsh

- name: Build benchmark example
run: |
cd examples\google_benchmark_cmake\build
cmake -DCODSPEED_MODE=${{ matrix.codspeed-mode }} ..
cmake --build . --config Release
shell: pwsh

windows-bazel-build:
bazel-build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
codspeed-mode: ["off", "walltime"]
runs-on: windows-latest
bazel-version: ["7.6.2", "8.4.2", "9.0.0-pre.20250921.2"]
runs-on: ${{ matrix.os }}
env:
USE_BAZEL_VERSION: ${{ matrix.bazel-version }}
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -182,4 +194,3 @@ jobs:
- name: Build benchmark example
run: |
bazel build //examples/google_benchmark_bazel:my_benchmark --//core:codspeed_mode=${{ matrix.codspeed-mode }}
shell: pwsh
2 changes: 2 additions & 0 deletions MODULE.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
bazel_dep(name = "rules_cc", version = "0.0.17")
bazel_dep(name = "bazel_skylib", version = "1.7.1")
bazel_dep(name = "platforms", version = "0.0.10")
bazel_dep(name = "instrument_hooks", version = "1.0.0")

git_override(
Expand Down
Loading
Loading