From 3bc20de8f635882571cf2d4754ade3a7155958ca Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Mon, 10 Jul 2023 22:38:02 +0300 Subject: [PATCH 24/24] Meson: Drop global -Werror from debug builds User is expected to explicitly control werror with meson's -Dwerror See osdn #48382 Signed-off-by: Marko Lindqvist --- doc/INSTALL.meson | 5 +++++ meson.build | 3 --- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/doc/INSTALL.meson b/doc/INSTALL.meson index 056499de67..3202b36922 100644 --- a/doc/INSTALL.meson +++ b/doc/INSTALL.meson @@ -85,6 +85,11 @@ debug (boolean): Whether debug version of Freeciv should be built. While this is generic option, some functionality in Freeciv depends on this setting. +werror (boolean): + Turn compiler warnings to hard errors. This is recommended for + any development builds of freeciv, to make sure that newly introduced + warnings get noticed. + default_library ('shared'/'static'/'both') In case of freeciv, this affects build of common libfreeciv library. The default is to build shared library, and as the binaries then diff --git a/meson.build b/meson.build index 24cdc463ee..e47fb0d1fe 100644 --- a/meson.build +++ b/meson.build @@ -97,9 +97,6 @@ endif if get_option('debug') priv_conf_data.set('FREECIV_DEBUG', 1) pub_conf_data.set('FREECIV_DEBUG', 1) - add_global_arguments( - '-Werror', - language: ['c', 'cpp']) add_global_arguments('-Wshadow', language: ['c']) if host_system == 'windows' # Qt headers have problems with dllimport attributes -- 2.40.1