diff --git a/meson.build b/meson.build index 0550f0cd8..c7c11f666 100644 --- a/meson.build +++ b/meson.build @@ -128,6 +128,7 @@ endif # Custom configuration. cgrouppattern = get_option('cgroup-pattern') +coverity = get_option('coverity-build') init_script = get_option('init-script') want_examples = get_option('examples') want_io_uring = get_option('io-uring-event-loop') @@ -137,6 +138,9 @@ want_tests = get_option('tests') want_tools = get_option('tools') srcconf.set_quoted('DEFAULT_CGROUP_PATTERN', cgrouppattern) +if coverity + srcconf.set('ENABLE_COVERITY_BUILD', 1) +endif dummy_config_data = configuration_data() dummy_config_data.set_quoted('DUMMY_VARIABLE', '1') diff --git a/meson_options.txt b/meson_options.txt index 6459cb7f9..ac07d246b 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -4,6 +4,9 @@ option('cgroup-pattern', type: 'string', value: '', description: 'CGroup pattern') +option('coverity-build', type: 'boolean', value: 'true', + description: 'build for coverity') + option('examples', type: 'boolean', value: 'true', description: 'build and install examples')