cmake nuttx base .px4 file naming on elf binary

This commit is contained in:
Daniel Agar 2017-12-09 20:35:44 -05:00 committed by GitHub
parent df4ab8b59e
commit bc9a8e4432
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -57,7 +57,9 @@ if (config_romfs_root)
endif()
# create px4 file (combined firmware and metadata)
set(fw_file ${PX4_BINARY_DIR}/${BOARD}_${LABEL}.px4)
set(fw_file ${PX4_BINARY_DIR}/${FW_NAME})
string(REPLACE ".elf" ".px4" fw_file ${fw_file})
string(REPLACE "nuttx_" "" fw_file ${fw_file})
add_custom_command(OUTPUT ${BOARD}.bin
COMMAND ${OBJCOPY} -O binary ${PX4_BINARY_DIR}/${FW_NAME} ${BOARD}.bin