[tracker-miners/sam/debug-plain] build: Enable debug if --buildtype=plain
- From: Sam Thursfield <sthursfield src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker-miners/sam/debug-plain] build: Enable debug if --buildtype=plain
- Date: Tue, 1 Dec 2020 13:49:40 +0000 (UTC)
commit 40188e40d720a2c592432f064a49b01a998b8d05
Author: Sam Thursfield <sam afuera me uk>
Date: Tue Dec 1 14:49:27 2020 +0100
build: Enable debug if --buildtype=plain
meson.build | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
---
diff --git a/meson.build b/meson.build
index 2d598d200..38493407e 100644
--- a/meson.build
+++ b/meson.build
@@ -118,9 +118,17 @@ add_project_arguments('-DTRACKER_COMPILATION', language: 'c')
add_project_arguments('-DG_LOG_DOMAIN="Tracker"', language: 'c')
add_project_arguments('-DG_LOG_STRUCTURED=1', language: 'c')
-debug_cflags = []
-debug = get_option('debug')
+if get_option('buildtype') == 'plain'
+ # Default case is to allow TRACKER_DEBUG which is very useful for
+ # triaging user-reported issues.
+ # Use --buildtype=release to disable debug completely.
+ debug = 1
+else
+ debug = get_option('debug')
+endif
optimization = get_option('optimization')
+
+debug_cflags = []
if debug
debug_cflags += '-DG_ENABLE_DEBUG'
if optimization in ['0', 'g']
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]