mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-07-08 02:00:36 +08:00
cmake remove circular linking and reorganize
- px4_add_module now requires MAIN - px4_add_library doesn't automatically link
This commit is contained in:
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
bl_update.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
config.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
#include <drivers/drv_device.h>
|
||||
|
||||
#include "systemlib/systemlib.h"
|
||||
#include "systemlib/param/param.h"
|
||||
#include <parameters/param.h>
|
||||
|
||||
__EXPORT int config_main(int argc, char *argv[]);
|
||||
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
dumpfile.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
esc_calib.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -38,5 +38,4 @@ px4_add_module(
|
||||
SRCS
|
||||
hardfault_log.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
led_control.cpp
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -40,6 +40,5 @@ px4_add_module(
|
||||
SRCS
|
||||
mixer.cpp
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
mixer
|
||||
)
|
||||
@@ -42,4 +42,3 @@ px4_add_module(
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
motor_test.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
#include <nuttx/i2c/i2c_master.h>
|
||||
#include <nuttx/mtd/mtd.h>
|
||||
|
||||
#include "systemlib/perf_counter.h"
|
||||
#include <perf/perf_counter.h>
|
||||
|
||||
/************************************************************************************
|
||||
* Pre-processor Definitions
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
mtd.c
|
||||
24xxxx_mtd.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
|
||||
#include "systemlib/px4_macros.h"
|
||||
#include "systemlib/systemlib.h"
|
||||
#include "systemlib/param/param.h"
|
||||
#include <parameters/param.h>
|
||||
|
||||
#include <board_config.h>
|
||||
|
||||
|
||||
@@ -39,6 +39,5 @@ px4_add_module(
|
||||
SRCS
|
||||
nshterm.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -39,6 +39,4 @@ px4_add_module(
|
||||
SRCS
|
||||
param.cpp
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
@@ -58,10 +58,7 @@
|
||||
#include <arch/board/board.h>
|
||||
|
||||
#include "systemlib/systemlib.h"
|
||||
#include "systemlib/param/param.h"
|
||||
#if defined(FLASH_BASED_PARAMS)
|
||||
# include "systemlib/flashparams/flashparams.h"
|
||||
#endif
|
||||
#include <parameters/param.h>
|
||||
#include "systemlib/err.h"
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
perf.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
perf
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "systemlib/perf_counter.h"
|
||||
#include <perf/perf_counter.h>
|
||||
|
||||
__EXPORT int perf_main(int argc, char *argv[]);
|
||||
|
||||
|
||||
@@ -39,6 +39,5 @@ px4_add_module(
|
||||
SRCS
|
||||
pwm.cpp
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
|
||||
#include "systemlib/systemlib.h"
|
||||
#include "systemlib/err.h"
|
||||
#include "systemlib/param/param.h"
|
||||
#include <parameters/param.h>
|
||||
#include "drivers/drv_pwm_output.h"
|
||||
|
||||
static void usage(const char *reason);
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
reboot.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -37,6 +37,5 @@ px4_add_module(
|
||||
SRCS
|
||||
reflect.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -39,6 +39,5 @@ px4_add_module(
|
||||
SRCS
|
||||
sd_bench.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -87,8 +87,10 @@ px4_add_module(
|
||||
-Wno-missing-declarations
|
||||
-Wno-double-promotion
|
||||
-Wno-unknown-warning-option
|
||||
SRCS ${srcs}
|
||||
SRCS
|
||||
${srcs}
|
||||
DEPENDS
|
||||
platforms__common
|
||||
modules__mc_pos_control__mc_pos_control_tests
|
||||
git_ecl
|
||||
ecl
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
#include <math.h>
|
||||
|
||||
#include <systemlib/err.h>
|
||||
#include <systemlib/bson/tinybson.h>
|
||||
#include <parameters/tinybson/tinybson.h>
|
||||
|
||||
#include "tests_main.h"
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
#include <stdio.h>
|
||||
#include <stddef.h>
|
||||
#include <systemlib/err.h>
|
||||
#include <systemlib/perf_counter.h>
|
||||
#include <perf/perf_counter.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <drivers/drv_hrt.h>
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
#include <stddef.h>
|
||||
#include <unistd.h>
|
||||
#include <fcntl.h>
|
||||
#include <systemlib/perf_counter.h>
|
||||
#include <perf/perf_counter.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
#include <px4_getopt.h>
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
#include <stddef.h>
|
||||
#include <systemlib/err.h>
|
||||
#include <systemlib/systemlib.h>
|
||||
#include <systemlib/perf_counter.h>
|
||||
#include <perf/perf_counter.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <drivers/drv_hrt.h>
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
#include <px4_defines.h>
|
||||
#include <stdio.h>
|
||||
#include "systemlib/err.h"
|
||||
#include "systemlib/param/param.h"
|
||||
#include <parameters/param.h>
|
||||
#include "tests_main.h"
|
||||
|
||||
#define PARAM_MAGIC1 12345678
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
#include <px4_config.h>
|
||||
#include <px4_posix.h>
|
||||
|
||||
#include <systemlib/perf_counter.h>
|
||||
#include <perf/perf_counter.h>
|
||||
|
||||
#include "tests_main.h"
|
||||
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
top.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -51,7 +51,6 @@ px4_add_module(
|
||||
SRCS
|
||||
topic_listener.cpp
|
||||
DEPENDS
|
||||
platforms__common
|
||||
generate_topic_listener
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
tune_control.cpp
|
||||
DEPENDS
|
||||
platforms__common
|
||||
tunes
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
@@ -37,6 +37,5 @@ px4_add_module(
|
||||
SRCS
|
||||
usb_connected.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
|
||||
@@ -38,6 +38,5 @@ px4_add_module(
|
||||
SRCS
|
||||
ver.c
|
||||
DEPENDS
|
||||
platforms__common
|
||||
version
|
||||
)
|
||||
# vim: set noet ft=cmake fenc=utf-8 ff=unix :
|
||||
|
||||
Reference in New Issue
Block a user