mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-28 10:46:33 +08:00
initial minimal PX4_ROS2 platform and px4_ros2_default build (#20689)
- new ROS2 platform in PX4 intended for creating configs that build and run entirely in ROS2 - PX4_CONFIG defaults to px4_ros2_default if no config specified and in a colcon workspace with ROS_VERSION=2 - currently doesn't do much other than allow you to build px4 msgs interface package
This commit is contained in:
@@ -64,10 +64,19 @@ function(px4_os_add_flags)
|
||||
${PX4_SOURCE_DIR}/platforms/nuttx/NuttX/apps/include
|
||||
)
|
||||
|
||||
# prevent using the toolchain's std c++ library
|
||||
add_compile_options($<$<COMPILE_LANGUAGE:CXX>:-nostdinc++>)
|
||||
|
||||
add_compile_options($<$<COMPILE_LANGUAGE:CXX>:-fno-sized-deallocation>)
|
||||
set(cxx_flags)
|
||||
list(APPEND cxx_flags
|
||||
-fno-exceptions
|
||||
-fno-rtti
|
||||
-fno-sized-deallocation
|
||||
-fno-threadsafe-statics
|
||||
-nostdinc++ # prevent using the toolchain's std c++ library
|
||||
)
|
||||
|
||||
foreach(flag ${cxx_flags})
|
||||
add_compile_options($<$<COMPILE_LANGUAGE:CXX>:${flag}>)
|
||||
endforeach()
|
||||
|
||||
add_compile_options($<$<COMPILE_LANGUAGE:C>:-Wbad-function-cast>)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user