forked from Archive/PX4-Autopilot
c6a2641507
The px4_os_add_flags defined in cmake/posix/px4_impl_posix.cmake did add (threading) libraries to added_exe_linker_flags, which subsequently end up in CMAKE_EXE_LINKER_FLAGS and then have no effect because those flags are passed to the linker before any of the object files and static libraries. Those libraries are already added correctly in the corresponding src/firmware/*/CMakeLists.txt files (for qurt, nuttx AND posix). I left in the non-library linker flag '-pthread' for the bebop board, although it seems very weird to me that this is needed (is it?). If that is needed then it seems weird to link manually (that is, src/firmware/*/CMakeLists.txt) with -lpthread. For linux/g++ -pthread is added to the CXXFLAGS as it should be: this causes the compiler to define _REENTRANT which is needed for (the interface of) certain libraries to become thread-safe. Offically one also can just pass -pthread to the linker, which then causes the right libraries to be linked, but just linking with -lpthread -lm -lrt works too. I ran into this while adding support for libcwd, which explicitly complains that _REENTRANT isn't defined when trying to link with the thread-safe version of libcwd (-lcwd_r) and then tells you to use -pthread. |
||
---|---|---|
Debug | ||
Documentation | ||
Images | ||
NuttX@93df871201 | ||
ROMFS | ||
Tools | ||
cmake | ||
integrationtests | ||
launch | ||
mavlink/include/mavlink | ||
misc/tones | ||
msg | ||
nuttx-configs | ||
posix-configs | ||
src | ||
test_data | ||
unittests | ||
.ackrc | ||
.gitignore | ||
.gitmodules | ||
.travis.yml | ||
.ycm_extra_conf.py | ||
CMakeLists.txt | ||
CONTRIBUTING.md | ||
Firmware.sublime-project | ||
LICENSE.md | ||
Makefile | ||
README.md | ||
Vagrantfile | ||
circle.yml | ||
eclipse.cproject | ||
eclipse.project | ||
package.xml |
README.md
PX4 Pro Drone Autopilot
This repository holds the PX4 Pro flight control solution for drones, with the main applications located in the src/modules directory. It also contains the PX4 Drone Middleware Platform, which provides drivers and middleware to run drones.
- Official Website: http://px4.io
- License: BSD 3-clause (see LICENSE.md)
- Supported airframes (more experimental are supported):
- Multicopters
- Fixed wing
- VTOL
- Releases
- Downloads
Users
Please refer to the user documentation and user forum for flying drones with the PX4 flight stack.
Developers
This repository contains code supporting these boards:
- Snapdragon Flight
- FMUv1.x
- FMUv2.x (Pixhawk, Pixhawk 2 and Pixfalcon)
- FMUv4.x (Pixhawk X and Pixracer)
- AeroCore (v1 and v2)
- STM32F4Discovery (basic support) Tutorial