wscript: Add a runtime scripting check flag

This commit is contained in:
Michael du Breuil 2018-11-03 14:59:08 -07:00 committed by WickedShell
parent fc5b8e479e
commit dcfc90b911
1 changed files with 14 additions and 4 deletions

18
wscript
View File

@ -124,6 +124,14 @@ submodules at specific revisions.
default=False, default=False,
help="Enable checking of math indexes") help="Enable checking of math indexes")
g.add_option('--enable-scripting', action='store_true',
default=False,
help="Enable onboard scripting engine")
g.add_option('--scripting-checks', action='store_true',
default=True,
help="Enable runtime scripting sanity checks")
g = opt.ap_groups['linux'] g = opt.ap_groups['linux']
linux_options = ('--prefix', '--destdir', '--bindir', '--libdir') linux_options = ('--prefix', '--destdir', '--bindir', '--libdir')
@ -169,10 +177,6 @@ configuration in order to save typing.
default=False, default=False,
help="Enable SFML graphics library") help="Enable SFML graphics library")
g.add_option('--enable-scripting', action='store_true',
default=False,
help="Enable onboard scripting engine")
g.add_option('--static', g.add_option('--static',
action='store_true', action='store_true',
default=False, default=False,
@ -269,6 +273,12 @@ def configure(cfg):
else: else:
cfg.end_msg('disabled', color='YELLOW') cfg.end_msg('disabled', color='YELLOW')
cfg.start_msg('Scripting runtime checks')
if cfg.options.scripting_checks:
cfg.end_msg('enabled')
else:
cfg.end_msg('disabled', color='YELLOW')
cfg.env.append_value('GIT_SUBMODULES', 'mavlink') cfg.env.append_value('GIT_SUBMODULES', 'mavlink')
cfg.env.prepend_value('INCLUDES', [ cfg.env.prepend_value('INCLUDES', [