Skip to content

Commit dba0894

Browse files
author
Alexander Batashev
authored
[CI] Disable -Werror by default (#5889)
Developers' host systems use different compilers, which have different warnings enabled by default. As a result, SYCL users who want to follow Get Started Guide often fail to compile the toolchain. This patch changes the behavior for `configure.py`: warnings are not treated as errors, unless `--werror` or `--ci-defaults` flags are passed to the script. CI will continue to require pull requests without warnings.
1 parent cb6cc98 commit dba0894

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

buildbot/configure.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def do_configure(args):
3333
libclc_gen_remangled_variants = 'OFF'
3434
sycl_build_pi_hip_platform = 'AMD'
3535
sycl_clang_extra_flags = ''
36-
sycl_werror = 'ON'
36+
sycl_werror = 'OFF'
3737
llvm_enable_assertions = 'ON'
3838
llvm_enable_doxygen = 'OFF'
3939
llvm_enable_sphinx = 'OFF'
@@ -42,7 +42,7 @@ def do_configure(args):
4242
sycl_enabled_plugins = ["opencl", "level_zero"]
4343

4444
sycl_enable_xpti_tracing = 'ON'
45-
xpti_enable_werror = 'ON'
45+
xpti_enable_werror = 'OFF'
4646

4747
# replace not append, so ARM ^ X86
4848
if args.arm:
@@ -75,9 +75,9 @@ def do_configure(args):
7575
sycl_build_pi_hip_platform = args.hip_platform
7676
sycl_enabled_plugins.append("hip")
7777

78-
if args.no_werror:
79-
sycl_werror = 'OFF'
80-
xpti_enable_werror = 'OFF'
78+
if args.werror or args.ci_defaults:
79+
sycl_werror = 'ON'
80+
xpti_enable_werror = 'ON'
8181

8282
if args.no_assertions:
8383
llvm_enable_assertions = 'OFF'
@@ -212,7 +212,7 @@ def main():
212212
parser.add_argument("--enable-esimd-emulator", action='store_true', help="build with ESIMD emulation support")
213213
parser.add_argument("--no-assertions", action='store_true', help="build without assertions")
214214
parser.add_argument("--docs", action='store_true', help="build Doxygen documentation")
215-
parser.add_argument("--no-werror", action='store_true', help="Don't treat warnings as errors")
215+
parser.add_argument("--werror", action='store_true', help="Don't treat warnings as errors")
216216
parser.add_argument("--shared-libs", action='store_true', help="Build shared libraries")
217217
parser.add_argument("--cmake-opt", action='append', help="Additional CMake option not configured via script parameters")
218218
parser.add_argument("--cmake-gen", default="Ninja", help="CMake generator")

0 commit comments

Comments
 (0)