]> granicus.if.org Git - python/commitdiff
bpo-37437: Pass -Wno-unreachable-code when compiling expat. (GH-14470)
authorBenjamin Peterson <benjamin@python.org>
Sat, 29 Jun 2019 23:00:22 +0000 (16:00 -0700)
committerGitHub <noreply@github.com>
Sat, 29 Jun 2019 23:00:22 +0000 (16:00 -0700)
setup.py

index 86e9816dc7b6e3c807c907c824b8b8e483c938c6..e54d31f53338069bf80e22dcf3bf37bbc882d076 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -1608,9 +1608,9 @@ class PyBuildExt(build_ext):
 
             cc = sysconfig.get_config_var('CC').split()[0]
             ret = os.system(
-                      '"%s" -Werror -Wimplicit-fallthrough -E -xc /dev/null >/dev/null 2>&1' % cc)
+                      '"%s" -Werror -Wno-unreachable-code -E -xc /dev/null >/dev/null 2>&1' % cc)
             if ret >> 8 == 0:
-                extra_compile_args.append('-Wno-implicit-fallthrough')
+                extra_compile_args.append('-Wno-unreachable-code')
 
         self.add(Extension('pyexpat',
                            define_macros=define_macros,