2013-01-02 02:28:09 -04:00
|
|
|
# PX4 build is via external build system
|
|
|
|
|
|
|
|
ifneq ($(PX4_ROOT),)
|
|
|
|
|
2013-01-20 17:22:02 -04:00
|
|
|
# install rc.APM from the AP_HAL_PX4/scripts directory as /etc/init.d/rc.APM
|
|
|
|
HAL_PX4_DIR = $(realpath $(MK_DIR)/../libraries/AP_HAL_PX4)
|
|
|
|
PX4_EXTERNAL_SCRIPTS = $(HAL_PX4_DIR)/scripts/rc.APM~init.d/rc.APM
|
|
|
|
|
2013-02-21 06:03:55 -04:00
|
|
|
# we use CURDIR instead of PWD to avoid a problem with MINGW32 on Windows
|
|
|
|
PX4_EXTERNAL = EXTERNAL_APPS=$(CURDIR) EXTERNAL_SCRIPTS=$(PX4_EXTERNAL_SCRIPTS)
|
2013-01-21 16:49:12 -04:00
|
|
|
PX4_MAKE = make -C $(PX4_ROOT) $(PX4_EXTERNAL) CONFIG_APM=y
|
2013-01-20 17:22:02 -04:00
|
|
|
|
|
|
|
|
2013-01-02 02:28:09 -04:00
|
|
|
px4:
|
2013-01-20 17:22:02 -04:00
|
|
|
$(PX4_MAKE)
|
2013-01-02 02:28:09 -04:00
|
|
|
|
2013-01-02 02:51:48 -04:00
|
|
|
px4-clean: clean
|
2013-01-20 17:22:02 -04:00
|
|
|
$(PX4_MAKE) clean
|
|
|
|
$(PX4_MAKE) configure_px4fmu
|
2013-01-02 02:28:09 -04:00
|
|
|
|
|
|
|
px4-upload:
|
2013-01-20 17:22:02 -04:00
|
|
|
$(PX4_MAKE) upload
|
2013-01-02 02:28:09 -04:00
|
|
|
|
2013-01-02 02:32:28 -04:00
|
|
|
else
|
|
|
|
|
|
|
|
px4:
|
|
|
|
$(error ERROR: You need to add PX4_ROOT to your config.mk)
|
|
|
|
|
2013-01-20 17:22:02 -04:00
|
|
|
px4-clean: px4
|
|
|
|
|
|
|
|
px4-upload: px4
|
|
|
|
|
2013-01-02 02:28:09 -04:00
|
|
|
endif
|