Skip to content

Commit

Permalink
Jenkins archive nuttx bin file
Browse files Browse the repository at this point in the history
  • Loading branch information
dagar authored and LorenzMeier committed May 31, 2018
1 parent 35963ab commit 6ca0784
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 11 deletions.
4 changes: 2 additions & 2 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@ def createBuildNode(String docker_repo, String target) {
sh('make ' + target)
sh('ccache -s')
sh('make sizes')
archiveArtifacts(allowEmptyArchive: true, artifacts: 'build/**/*.px4, build/**/*.elf', fingerprint: true, onlyIfSuccessful: true)
archiveArtifacts(allowEmptyArchive: true, artifacts: 'build/**/*.px4, build/**/*.elf, build/**/*.bin', fingerprint: true, onlyIfSuccessful: true)
sh('make distclean')
}
}
Expand All @@ -735,7 +735,7 @@ def createBuildNodeDockerLogin(String docker_repo, String docker_credentials, St
sh('make ' + target)
sh('ccache -s')
sh('make sizes')
archiveArtifacts(allowEmptyArchive: true, artifacts: 'build/**/*.px4, build/**/*.elf', fingerprint: true, onlyIfSuccessful: true)
archiveArtifacts(allowEmptyArchive: true, artifacts: 'build/**/*.px4, build/**/*.elf, build/**/*.bin', fingerprint: true, onlyIfSuccessful: true)
sh('make distclean')
}
}
Expand Down
2 changes: 1 addition & 1 deletion cmake/configs/nuttx_esc35-v1_default.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ add_definitions(
)

px4_nuttx_make_uavcan_bootloadable(BOARD ${BOARD}
BIN ${PX4_BINARY_DIR}/platforms/nuttx/esc35-v1.bin
BIN ${PX4_BINARY_DIR}/esc35-v1.bin
HWNAME ${uavcanblid_name}
HW_MAJOR ${uavcanblid_hw_version_major}
HW_MINOR ${uavcanblid_hw_version_minor}
Expand Down
2 changes: 1 addition & 1 deletion cmake/configs/nuttx_px4cannode-v1_default.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ add_definitions(
)

px4_nuttx_make_uavcan_bootloadable(BOARD ${BOARD}
BIN ${PX4_BINARY_DIR}/platforms/nuttx/px4cannode-v1.bin
BIN ${PX4_BINARY_DIR}/px4cannode-v1.bin
HWNAME ${uavcanblid_name}
HW_MAJOR ${uavcanblid_hw_version_major}
HW_MINOR ${uavcanblid_hw_version_minor}
Expand Down
2 changes: 1 addition & 1 deletion cmake/configs/nuttx_px4esc-v1_default.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ add_definitions(
)

px4_nuttx_make_uavcan_bootloadable(BOARD ${BOARD}
BIN ${PX4_BINARY_DIR}/platforms/nuttx/px4esc-v1.bin
BIN ${PX4_BINARY_DIR}/px4esc-v1.bin
HWNAME ${uavcanblid_name}
HW_MAJOR ${uavcanblid_hw_version_major}
HW_MINOR ${uavcanblid_hw_version_minor}
Expand Down
2 changes: 1 addition & 1 deletion cmake/configs/nuttx_s2740vc-v1_default.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ include(configs/uavcan_board_ident/s2740vc-v1)

# N.B. this would be uncommented when there is an APP
#px4_nuttx_make_uavcan_bootloadable(BOARD ${BOARD}
# BIN ${PX4_BINARY_DIR}/platforms/nuttx/s2740vc-v1.bin
# BIN ${PX4_BINARY_DIR}/s2740vc-v1.bin
# HWNAME ${uavcanblid_name}
# HW_MAJOR ${uavcanblid_hw_version_major}
# HW_MINOR ${uavcanblid_hw_version_minor}
Expand Down
9 changes: 4 additions & 5 deletions platforms/nuttx/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ list(APPEND nuttx_libs
nuttx_apps
nuttx_arch
nuttx_binfmt
nuttx_binfmt
nuttx_c
nuttx_configs
nuttx_cxx
Expand Down Expand Up @@ -120,8 +119,8 @@ 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_REL}/${FW_NAME} ${BOARD}.bin
add_custom_command(OUTPUT ${PX4_BINARY_DIR_REL}/${BOARD}.bin
COMMAND ${OBJCOPY} -O binary ${PX4_BINARY_DIR_REL}/${FW_NAME} ${PX4_BINARY_DIR_REL}/${BOARD}.bin
DEPENDS ${FW_NAME}
)

Expand All @@ -136,8 +135,8 @@ if (TARGET parameters_xml AND TARGET airframes_xml)
--git_identity ${PX4_SOURCE_DIR}
--parameter_xml ${PX4_BINARY_DIR}/parameters.xml
--airframe_xml ${PX4_BINARY_DIR}/airframes.xml
--image ${BOARD}.bin > ${fw_file}
DEPENDS ${BOARD}.bin parameters_xml airframes_xml
--image ${PX4_BINARY_DIR}/${BOARD}.bin > ${fw_file}
DEPENDS ${PX4_BINARY_DIR}/${BOARD}.bin parameters_xml airframes_xml
COMMENT "Creating ${fw_file}"
)

Expand Down

0 comments on commit 6ca0784

Please sign in to comment.