mirror of https://github.com/ArduPilot/ardupilot
build: add --apstatedir for Linux boards
This is the --localstatedir that is found on other buildsystems/programs + the package directory. We could provide a --localstatedir instead to be similar to the others, but I thought it would be too confusing for the help message.
This commit is contained in:
parent
1e7ad72909
commit
2916a3f40c
|
@ -437,7 +437,10 @@ class linux(Board):
|
|||
|
||||
if self.with_uavcan:
|
||||
cfg.define('UAVCAN_EXCEPTIONS', 0)
|
||||
|
||||
|
||||
if cfg.options.apstatedir:
|
||||
cfg.define('AP_STATEDIR', cfg.options.apstatedir)
|
||||
|
||||
def build(self, bld):
|
||||
super(linux, self).build(bld)
|
||||
if bld.options.upload:
|
||||
|
|
7
wscript
7
wscript
|
@ -101,6 +101,13 @@ submodules at specific revisions.
|
|||
opt.parser.remove_option(k)
|
||||
g.add_option(option)
|
||||
|
||||
g.add_option('--apstatedir',
|
||||
action='store',
|
||||
default='',
|
||||
help='''Where to save data like parameters, log and terrain.
|
||||
This is the --localstatedir + ArduPilot's subdirectory [default:
|
||||
board-dependent, usually /var/lib/ardupilot]''')
|
||||
|
||||
g.add_option('--rsync-dest',
|
||||
dest='rsync_dest',
|
||||
action='store',
|
||||
|
|
Loading…
Reference in New Issue