From 3f8a2afdc8c944e30367ee73e0f01ad133645b7a Mon Sep 17 00:00:00 2001 From: Tommaso Pecorella Date: Wed, 20 Jan 2021 20:26:37 +0000 Subject: [PATCH] build: partially rev. a455a427 (-Wno-parentheses) This fixes #339. "-Wno-parentheses" is still needed by GTK+3.22 --- src/config-store/wscript | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/config-store/wscript b/src/config-store/wscript index f0a3f6463..4e3e143d3 100644 --- a/src/config-store/wscript +++ b/src/config-store/wscript @@ -30,6 +30,13 @@ def configure(conf): conf.env['ENABLE_GTK'], "library 'gtk+-3 >= 3.22' not found") + # Bug 2936 and #340 -Wparentheses issue for gcc >= 8 + # This have to be kept until we can bump the minimum GTK version to 3.24 + if conf.env['ENABLE_GTK']: + if conf.env['CXX_NAME'] in ['gcc']: + if tuple(map(int, conf.env['CC_VERSION'])) >= gcc_version_gtkplus_warning_issue: + conf.env.append_value('CXXFLAGS', '-Wno-parentheses') + have_libxml2 = conf.check_cfg(package='libxml-2.0 >= 2.7', args=['--cflags', '--libs'], uselib_store='LIBXML2', mandatory=False)