summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.com>2018-09-19 12:02:19 +0100
committerTim-Philipp Müller <tim@centricular.com>2018-09-19 12:02:19 +0100
commit29c7f958845369d5e452a05ca9a1390381a4cdeb (patch)
tree457d6b9bd7555d7696e64b869775592929521cc7 /meson.build
parent15c566cd35b7be8488ce3e81415ba5829dcc5ee8 (diff)
meson: add glib-checks option to disable API guards and such
We want this enabled by default, also in releases, but people may want to disable this for performance-critical workloads or on embedded devices.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build6
1 files changed, 6 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 78b7b1a49..b52c0cd1c 100644
--- a/meson.build
+++ b/meson.build
@@ -94,6 +94,12 @@ if glib_asserts.disabled() or (glib_asserts.auto() and not gst_version_is_dev)
add_project_arguments('-DG_DISABLE_ASSERT', language: 'c')
endif
+glib_checks = get_option('glib-checks')
+if glib_checks.disabled() or (glib_checks.auto() and not gst_version_is_dev)
+ message('Disabling GLib checks')
+ add_project_arguments('-DG_DISABLE_CHECKS', language: 'c')
+endif
+
cdata = configuration_data()
check_headers = [
['HAVE_DLFCN_H', 'dlfcn.h'],