[vte] build: Do not allow disabling asserts



commit 7df0f9a997a1cdffee31fe4d0d100f294c74abea
Author: Christian Persch <chpe src gnome org>
Date:   Sun Apr 28 15:02:23 2019 +0200

    build: Do not allow disabling asserts

 meson.build | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
---
diff --git a/meson.build b/meson.build
index c79c07f8..44a417ab 100644
--- a/meson.build
+++ b/meson.build
@@ -24,6 +24,7 @@ project(
     'c_std=gnu11',
     'cpp_std=gnu++17',
     'warning_level=0',
+    'b_ndebug=false',
   ],
   meson_version: '>= 0.49.0',
 )
@@ -87,7 +88,7 @@ vte_sysconfdir = get_option('sysconfdir')
 
 # Debug
 
-enable_debug = get_option('debugg') or get_option('buildtype').contains('debug')
+enable_debug = get_option('debugg') or get_option('debug') or get_option('buildtype').contains('debug')
 
 # Meson modules
 
@@ -218,6 +219,10 @@ if cxx.get_id() == 'gcc'
   assert(cxx.version().version_compare('>= 7.0'), 'needs G++ >= 7 for C++17 support')
 endif
 
+# Asserts must not be disabled
+
+assert(get_option('b_ndebug') == 'false', 'assertions may not be disabled')
+
 # Compiler flags
 
 compiler_flags_common = [


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]