From 00c36aa7a621250503e1dfd1ee451026b32c5e00 Mon Sep 17 00:00:00 2001 From: seaubot Date: Wed, 20 Sep 2023 22:50:12 +0000 Subject: [PATCH] chore: sync with ecsact_common --- bazel/BUILD.bazel | 4 ++++ bazel/common.bazelrc | 3 --- bazel/copts.bzl | 5 ++++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/bazel/BUILD.bazel b/bazel/BUILD.bazel index e69de29..c9e1c55 100644 --- a/bazel/BUILD.bazel +++ b/bazel/BUILD.bazel @@ -0,0 +1,4 @@ +config_setting( + name = "compiler_emscripten", + flag_values = {"@bazel_tools//tools/cpp:compiler": "emscripten"}, +) diff --git a/bazel/common.bazelrc b/bazel/common.bazelrc index 1bb6433..ebb4c3e 100644 --- a/bazel/common.bazelrc +++ b/bazel/common.bazelrc @@ -1,6 +1,3 @@ -# This file is maintained by ecsact-dev/ecsact_common -# If changes are required please make them there - startup --windows_enable_symlinks common --enable_bzlmod common --registry=https://raw.githubusercontent.com/ecsact-dev/bazel_registry/main diff --git a/bazel/copts.bzl b/bazel/copts.bzl index 8ddeb95..2a49358 100644 --- a/bazel/copts.bzl +++ b/bazel/copts.bzl @@ -1,7 +1,10 @@ load("@bazel_skylib//lib:selects.bzl", "selects") -# Ecsact repositories currently only support clang and cl +# Ecsact repositories currently only support clang, cl, and emscripten copts = selects.with_or({ + (Label("//bazel:compiler_emscripten")): [ + "-std=c++20", + ], ("@rules_cc//cc/compiler:clang"): [ "-std=c++2b", "-fexperimental-library",