diff --git a/meson.build b/meson.build index dfb4c6b..3dfe21d 100644 --- a/meson.build +++ b/meson.build @@ -50,6 +50,10 @@ if ['linux', 'cygwin', 'gnu'].contains(host_machine.system()) pre_args += '-DHAVE_PTHREAD' endif +if get_option('glibcxx_asserts') + pre_args += '-D_GLIBCXX_ASSERTIONS' +endif + # Check for GCC style atomics if cc.compiles('''#include int main() { diff --git a/meson_options.txt b/meson_options.txt new file mode 100644 index 0000000..cf87a71 --- /dev/null +++ b/meson_options.txt @@ -0,0 +1 @@ +option('glibcxx_asserts', type : 'boolean', value : false)