From 3abdc6ad25fbf4f197a755cef6d12c17ab36d8c3 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sat, 15 Oct 2022 09:43:22 +1100 Subject: [PATCH] waf: added --enable-gps-logging --- Tools/ardupilotwaf/boards.py | 8 ++++++++ wscript | 4 ++++ 2 files changed, 12 insertions(+) diff --git a/Tools/ardupilotwaf/boards.py b/Tools/ardupilotwaf/boards.py index c6cabdf880..de225319af 100644 --- a/Tools/ardupilotwaf/boards.py +++ b/Tools/ardupilotwaf/boards.py @@ -114,6 +114,14 @@ class Board: else: cfg.msg("Enabled firmware ID checking", 'no', color='YELLOW') + if cfg.options.enable_gps_logging: + env.DEFINES.update( + AP_GPS_DEBUG_LOGGING_ENABLED=1, + ) + cfg.msg("GPS Debug Logging", 'yes') + else: + cfg.msg("GPS Debug Logging", 'no', color='YELLOW') + # allow enable of custom controller for any board # enabled on sitl by default if (cfg.options.enable_custom_controller or self.get_name() == "sitl") and not cfg.options.no_gcs: diff --git a/wscript b/wscript index 4f28def78b..dd027602d0 100644 --- a/wscript +++ b/wscript @@ -247,6 +247,10 @@ submodules at specific revisions. default=False, help="Enables custom controller") + g.add_option('--enable-gps-logging', action='store_true', + default=False, + help="Enables GPS logging") + g = opt.ap_groups['linux'] linux_options = ('--prefix', '--destdir', '--bindir', '--libdir')