From 930f3b4aca18b3cc7d54f64167ff753df90994e9 Mon Sep 17 00:00:00 2001 From: Gustavo Sousa Date: Mon, 5 Jun 2017 11:00:27 -0300 Subject: [PATCH] build: boards: enable --upload option for linux boards Make it use rsync command. That's a workaround to allow user using --upload option, which in fact appends the 'rsync' to the command chain. A bad side-effect of this is that the build summary is output twice for a command like 'waf copter --upload'. --- Tools/ardupilotwaf/boards.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Tools/ardupilotwaf/boards.py b/Tools/ardupilotwaf/boards.py index 82a1504c29..81a56da827 100644 --- a/Tools/ardupilotwaf/boards.py +++ b/Tools/ardupilotwaf/boards.py @@ -269,6 +269,12 @@ class linux(Board): 'AP_HAL_Linux', ] + def build(self, bld): + super(linux, self).build(bld) + if bld.options.upload: + waflib.Options.commands.append('rsync') + # Avoid infinite recursion + bld.options.upload = False class minlure(linux): def configure_env(self, cfg, env):