Cmake build: do not change CMAKE_RUNTIME_OUTPUT_DIRECTORY if building with catkin

This commit is contained in:
TSC21
2018-12-12 18:30:07 +00:00
committed by Nuno Marques
parent c7eb21be86
commit a6121e1655
2 changed files with 12 additions and 1 deletions

View File

@@ -5,6 +5,12 @@ include_directories(${CMAKE_CURRENT_BINARY_DIR})
get_property(module_libraries GLOBAL PROPERTY PX4_MODULE_LIBRARIES)
# When building with catkin, do not change CMAKE_RUNTIME_OUTPUT_DIR from
# CMAKE_CURRENT_BINARY_DIR ''./platforms/posix' to './bin'
if (NOT CATKIN_DEVEL_PREFIX)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
endif()
set(PX4_SHELL_COMMAND_PREFIX "px4-")
add_definitions("-DPX4_SHELL_COMMAND_PREFIX=\"${PX4_SHELL_COMMAND_PREFIX}\"")