From ae2e1da93a40e5c83756e06edb610c9c022bf2ad Mon Sep 17 00:00:00 2001 From: David Sidrane Date: Mon, 31 Jul 2017 15:07:00 -1000 Subject: [PATCH] px4_impl_nuttx:PX4 does not used compressed defconfigs nor configure.sh The new upstream nuttx defconfig format is compressed. This will not work well for board configs that are out of the upstream NuttX tree. The reconstitution step will not replace all the non default settings. I.E. CONFIG_ARCH_BOARD_PX4xxxx and will remove setting that are not defined from the config/KConfig. Like CONFIG_ARCH_BOARD_PX4xxxx=y. Also the configure script will fail if run without and intervening make distclean The only 2 steps from configure that re needed are Copying the defconfig to .config and Make.defs --- cmake/nuttx/px4_impl_nuttx.cmake | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmake/nuttx/px4_impl_nuttx.cmake b/cmake/nuttx/px4_impl_nuttx.cmake index 71616272f1..c6abda403e 100644 --- a/cmake/nuttx/px4_impl_nuttx.cmake +++ b/cmake/nuttx/px4_impl_nuttx.cmake @@ -319,7 +319,8 @@ function(px4_nuttx_add_export) add_custom_command(OUTPUT ${nuttx_configure_stamp} ${nuttx_build_src}/nuttx/.config COMMAND ${CP} -rp ${PX4_SOURCE_DIR}/nuttx-configs/*.mk ${nuttx_build_src}/nuttx/ COMMAND ${CP} -rp ${PX4_SOURCE_DIR}/nuttx-configs/${CONFIG} ${nuttx_build_src}/nuttx/configs - COMMAND cd ${nuttx_build_src}/nuttx/tools && sh configure.sh ${CONFIG}/${config_nuttx_config} + COMMAND ${CP} ${nuttx_build_src}/nuttx/configs/${CONFIG}/${config_nuttx_config}/defconfig ${nuttx_build_src}/nuttx/.config + COMMAND ${CP} ${nuttx_build_src}/nuttx/configs/${CONFIG}/${config_nuttx_config}/Make.defs ${nuttx_build_src}/nuttx/ COMMAND cmake -E touch ${nuttx_configure_stamp} DEPENDS nuttx_patch_${CONFIG} ${nuttx-configs} WORKING_DIRECTORY ${PX4_BINARY_DIR}