From 83c02756c8f48fc54c6e2cf96edb9245d891396a Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 3 May 2023 11:53:40 -0400 Subject: Replace strict option with new meson warning level --- test/meson.build | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'test') diff --git a/test/meson.build b/test/meson.build index b22a925..02fb1b9 100644 --- a/test/meson.build +++ b/test/meson.build @@ -1,11 +1,9 @@ -# Copyright 2021 David Robillard +# Copyright 2021-2023 David Robillard # SPDX-License-Identifier: 0BSD OR ISC -reuse = find_program('reuse', required: false) - # Suppress some additional C warnings in tests test_c_args = [] -if get_option('strict') +if get_option('warning_level') == 'everything' if cc.get_id() == 'clang' test_c_args += [ '-Wno-float-equal', @@ -21,7 +19,7 @@ endif # Suppress some additional C++ warnings in tests test_cpp_args = [] -if get_option('strict') and is_variable('cpp') +if get_option('warning_level') == 'everything' and is_variable('cpp') if cpp.get_id() == 'clang' test_cpp_args += [ '-Wno-documentation', # Cairo @@ -34,8 +32,11 @@ if get_option('strict') and is_variable('cpp') endif # Check licensing metadata -if reuse.found() - test('REUSE', reuse, args: ['--root', pugl_src_root, 'lint'], suite: 'data') +if not meson.is_subproject() and get_option('lint') + reuse = find_program('reuse', required: false) + if reuse.found() + test('REUSE', reuse, args: ['--root', pugl_src_root, 'lint'], suite: 'data') + endif endif basic_exclusive_tests = [ -- cgit v1.2.1