Skip to content

Commit

Permalink
Do not allow code with warnings to pass CI
Browse files Browse the repository at this point in the history
  • Loading branch information
npaun committed Aug 16, 2024
1 parent 299094f commit a671f25
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ build --@dawn//src/tint:tint_build_wgsl_writer=True
# Our dependencies (ICU, zlib, etc.) produce a lot of these warnings, so we disable them. Depending
# on the clang version, zlib either produces warnings for -Wdeprecated-non-prototype or does not
# have that option, so disable -Wunknown-warning-option there too.
build --per_file_copt='external/@-Wno-error'
build --per_file_copt='external/v8@-Wno-deprecated-declarations'
build --per_file_copt='external/com_googlesource_chromium_icu@-Wno-ambiguous-reversed-operator,-Wno-deprecated-declarations'
build --host_per_file_copt='external/com_googlesource_chromium_icu@-Wno-ambiguous-reversed-operator,-Wno-deprecated-declarations'
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,9 @@ jobs:
sudo apt-get install -y --no-install-recommends clang-16 lld-16 libunwind-16 libc++abi1-16 libc++1-16 libc++-16-dev libclang-rt-16-dev
echo "build:linux --action_env=CC=/usr/lib/llvm-16/bin/clang --action_env=CXX=/usr/lib/llvm-16/bin/clang++" >> .bazelrc
echo "build:linux --host_action_env=CC=/usr/lib/llvm-16/bin/clang --host_action_env=CXX=/usr/lib/llvm-16/bin/clang++" >> .bazelrc
echo "build:linux --copt='-Werror'" >> .bazelrc
echo "build:linux --copt='-Wno-error=#warnings'" >> .bazelrc
echo "build:linux --copt='-Wno-error=deprecated-declarations'" >> .bazelrc
sed -i -e "s%llvm-symbolizer%/usr/lib/llvm-16/bin/llvm-symbolizer%" .bazelrc
- name: Setup macOS
if: matrix.os.name == 'macOS'
Expand Down

0 comments on commit a671f25

Please # to comment.