Skip to content

build: don't require using Clang compiler. #230

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Feb 8, 2022
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
11 changes: 9 additions & 2 deletions .bazelrc
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
build --action_env=CC=clang
build --action_env=CXX=clang++
# Pass CC, CXX and PATH from the environment.
build --action_env=CC
build --action_env=CXX
build --action_env=PATH

# Use Clang compiler.
build:clang --action_env=BAZEL_COMPILER=clang
build:clang --action_env=CC=clang
build:clang --action_env=CXX=clang++

build --enable_platform_specific_config

Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/cpp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ jobs:
bazel build
--verbose_failures
--test_output=errors
--config=clang
-c opt
$(bazel query 'kind(was.*_rust_binary, //test/test_data/...)')

Expand Down Expand Up @@ -114,7 +115,7 @@ jobs:
os: ubuntu-20.04
arch: x86_64
action: test
flags: '--define crypto=system'
flags: --config=clang --define=crypto=system
- name: 'V8 on macOS/x86_64'
runtime: 'v8'
repo: 'v8'
Expand All @@ -127,6 +128,7 @@ jobs:
os: ubuntu-20.04
arch: x86_64
action: test
flags: --config=clang
- name: 'WAMR on macOS/x86_64'
runtime: 'wamr'
repo: 'com_github_bytecodealliance_wasm_micro_runtime'
Expand All @@ -139,19 +141,22 @@ jobs:
os: ubuntu-20.04
arch: x86_64
action: test
flags: --config=clang
- name: 'Wasmtime on Linux/aarch64'
runtime: 'wasmtime'
repo: 'com_github_bytecodealliance_wasmtime'
os: ubuntu-20.04
arch: aarch64
action: build
flags: --config=clang
run_under: docker run --rm --env HOME=$HOME --env USER=$(id -un) --volume "$HOME:$HOME" --workdir $(pwd) --user $(id -u):$(id -g) --platform linux/arm64 piotrsikora/build-tools:bazel-5.0.0-clang-13-gcc-11
- name: 'Wasmtime on Linux/s390x'
runtime: 'wasmtime'
repo: 'com_github_bytecodealliance_wasmtime'
os: ubuntu-20.04
arch: s390x
action: test
flags: --config=clang
run_under: docker run --rm --env HOME=$HOME --env USER=$(id -un) --volume "$HOME:$HOME" --workdir $(pwd) --user $(id -u):$(id -g) --platform linux/s390x piotrsikora/build-tools:bazel-5.0.0-clang-13-gcc-11
- name: 'Wasmtime on macOS/x86_64'
runtime: 'wasmtime'
Expand All @@ -165,6 +170,7 @@ jobs:
os: ubuntu-20.04
arch: x86_64
action: test
flags: --config=clang

steps:
- uses: actions/checkout@v2
Expand Down