2

我坚持安装 SITL,我尝试了很多方法。请我不知道如何进行。

我按照 http://dev.ardupilot.com/wiki/sitl-nati ... _in_cygwin中的说明进行操作

我能够制作 px4-v2

路径在 .bashrc export PATH=$PATH:$HOME/ardupilot/Tools/autotest 中设置正确

但是, make sitl -j4 会产生以下错误:

$ make sitl -j4
%% libraries/AP_Common/c++.o
%% libraries/AP_Common/AP_Common.o
%% libraries/AP_Menu/AP_Menu.o
In file included from /home/Me/ardupilot/libraries/AP_Common/c++.cpp:9:0:
/home/Me/ardupilot/libraries/AP_HAL/AP_HAL.h:6:21: fatal error: stdbool.h: No such file or directory
compilation terminated.
C:/cygwin/home/Me/ardupilot/mk/build_rules.mk:27: recipe for target '/tmp/arducopter.build/libraries/AP_Common/c++.o' failed
make: *** [/tmp/arducopter.build/libraries/AP_Common/c++.o] Error 1
make: *** Waiting for unfinished jobs....
In file included from /home/Me/ardupilot/libraries/AP_Common/AP_Common.cpp:21:0:
/home/Me/ardupilot/libraries/AP_HAL/AP_HAL.h:6:21: fatal error: stdbool.h: No such file or directory
compilation terminated.
C:/cygwin/home/Me/ardupilot/mk/build_rules.mk:27: recipe for target '/tmp/arducopter.build/libraries/AP_Common/AP_Common.o' failed
make: *** [/tmp/arducopter.build/libraries/AP_Common/AP_Common.o] Error 1
// BUILDROOT=/tmp/arducopter.build HAL_BOARD=HAL_BOARD_SITL HAL_BOARD_SUBTYPE=HAL_BOARD_SUBTYPE_NONE TOOLCHAIN=NATIVE EXTRAFLAGS=-DGIT_VERSION="c52f16b8"
In file included from /home/Me/ardupilot/libraries/AP_Common/AP_Common.h:26:0,
                 from /home/Me/ardupilot/libraries/AP_Menu/AP_Menu.cpp:7:
/usr/include/stdlib.h:16:20: fatal error: stddef.h: No such file or directory
compilation terminated.
C:/cygwin/home/Me/ardupilot/mk/build_rules.mk:27: recipe for target '/tmp/arducopter.build/libraries/AP_Menu/AP_Menu.o' failed
make: *** [/tmp/arducopter.build/libraries/AP_Menu/AP_Menu.o] Error 1
4

2 回答 2

0

这样做比手动更容易使用 vagrant:http: //ardupilot.org/dev/docs/setting-up-sitl-using-vagrant.html

于 2016-03-25T23:25:25.433 回答
0

我使用 Ubuntu。下载代码并使用以下步骤运行它。

git clone https://github.com/ArduPilot/ardupilot.git 
cd ardupilot
https://github.com/ArduPilot/ardupilot.git
make sitl -j4
于 2022-01-23T14:24:09.270 回答