diff options
author | David Robillard <d@drobilla.net> | 2020-07-15 20:43:23 +0200 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2020-07-17 15:42:20 +0200 |
commit | 049d5052aaf5033bc5a30ef7c21c8013d9804b58 (patch) | |
tree | 8ae562ba476154f4740a1081e6175beae9ca5e7d /wscript | |
parent | ef402d88b7a64e21c4f379937cadb2b6c4537011 (diff) | |
download | sord-049d5052aaf5033bc5a30ef7c21c8013d9804b58.tar.gz sord-049d5052aaf5033bc5a30ef7c21c8013d9804b58.tar.bz2 sord-049d5052aaf5033bc5a30ef7c21c8013d9804b58.zip |
Be explicit about warnings
Diffstat (limited to 'wscript')
-rw-r--r-- | wscript | 64 |
1 files changed, 63 insertions, 1 deletions
@@ -11,7 +11,7 @@ from waflib.extras import autowaf # major increment <=> incompatible changes # minor increment <=> compatible changes (additions) # micro increment <=> no interface changes -SORD_VERSION = '0.16.4' +SORD_VERSION = '0.16.5' SORD_MAJOR_VERSION = '0' # Mandatory waf variables @@ -58,6 +58,68 @@ def configure(conf): conf.env.BUILD_STATIC = (Options.options.static or Options.options.static_progs) + if Options.options.ultra_strict: + autowaf.add_compiler_flags(conf.env, '*', { + 'gcc': [ + '-Wno-cast-qual', + '-Wno-conversion', + '-Wno-padded', + '-Wno-sign-conversion', + '-Wno-stack-protector', + '-Wno-switch-enum', + '-Wno-unused-macros', + '-Wno-unused-parameter', + '-Wno-vla', + ], + 'clang': [ + '-Wno-cast-qual', + '-Wno-extra-semi-stmt', + '-Wno-format-nonliteral', + '-Wno-padded', + '-Wno-reserved-id-macro', + '-Wno-shorten-64-to-32', + '-Wno-sign-conversion', + '-Wno-switch-enum', + '-Wno-unused-macros', + '-Wno-unused-parameter', + '-Wno-vla', + ], + 'msvc': [ + '/wd4061', # enumerator in switch is not explicitly handled + '/wd4100', # unreferenced formal parameter + '/wd4200', # zero-sized array in struct/union + '/wd4244', # conversion with possible loss of data + '/wd4267', # conversion from size_t to a smaller type + '/wd4365', # signed/unsigned mismatch + '/wd4389', # '==': signed/unsigned mismatch + '/wd4514', # unreferenced inline function has been removed + '/wd4702', # unreachable code + '/wd4706', # assignment within conditional expression + '/wd4820', # padding added after construct + '/wd5045', # will insert Spectre mitigation for memory load + ], + }) + + autowaf.add_compiler_flags(conf.env, 'cxx', { + 'gcc': [ + '-Wno-effc++', + '-Wno-multiple-inheritance', + '-Wno-old-style-cast', + '-Wno-zero-as-null-pointer-constant', + ], + 'clang': [ + '-Wno-deprecated-copy-dtor', + '-Wno-implicit-float-conversion', + '-Wno-old-style-cast', + '-Wno-zero-as-null-pointer-constant', + ], + 'msvc': [ + '/wd4571', # catch semantics changed + '/wd4625', # copy constructor implicitly deleted + '/wd4626', # assignment opreator implicitly deleted + ], + }) + conf.check_pkg('serd-0 >= 0.30.0', uselib_store='SERD') conf.check_pkg('libpcre', uselib_store='PCRE', mandatory=False) |