From 8ffcd88ef05274d2c6606b5cc39b7d93b3f78ef4 Mon Sep 17 00:00:00 2001 From: Titan Yuan Date: Sun, 23 Feb 2025 23:10:42 -0800 Subject: [PATCH] Add C++20 flag for Windows --- .bazelrc | 13 ++++++++++--- .github/workflows/ci.yaml | 4 ++-- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/.bazelrc b/.bazelrc index bacb65a..d1140b7 100644 --- a/.bazelrc +++ b/.bazelrc @@ -1,5 +1,12 @@ common --enable_bzlmod +common --enable_platform_specific_config -build --cxxopt=-std=c++20 -build --host_cxxopt=-std=c++20 -build --objccopt=-std=c++20 +build:linux --cxxopt=-std=c++20 +build:macos --cxxopt=-std=c++20 +build:windows --cxxopt=/std:c++20 +build:linux --host_cxxopt=-std=c++20 +build:macos --host_cxxopt=-std=c++20 +build:windows --host_cxxopt=/std:c++20 +build:linux --objccopt=-std=c++20 +build:macos --objccopt=-std=c++20 +build:windows --objccopt=/std:c++20 diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index cf6efc0..8506cdd 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -8,8 +8,8 @@ jobs: matrix: platform: - ubuntu-latest - - windows-latest - macos-latest + - windows-latest runs-on: ${{ matrix.platform }} steps: - uses: actions/checkout@v4 @@ -18,5 +18,5 @@ jobs: # - run: bazel test --test_output=errors //... - uses: actions/upload-artifact@v4 with: - name: plugins-${{ matrix.targetPlatform }} + name: plugins-${{ matrix.platform }} path: bazel-bin/plugins.tar.gz