PX4编译问题,编译出错 40C

尝试PX4编译时出错,error详见下图图片说明

之前一直有GCC和G++的问题,安装了最新版本的GCC工具链后之前的问题解决了,产生了新的问题

具体代码:
[2/655] Generating nuttx/include/nuttx/version.h, nuttx/include/nuttx/config.h
FAILED: cd /home/hu/src/Firmware/build/px4_fmu-v2_default/NuttX/nuttx && make --quiet --no-print-directory CONFIG_ARCH_BOARD_CUSTOM=y context > nuttx_context.log
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-exit.o): in function exit':
exit.c:(.text.exit+0x2c): undefined reference to
_exit'
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-fstatr.o): in function _fstat_r':
fstatr.c:(.text._fstat_r+0x20): undefined reference to
_fstat'
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-openr.o): in function _open_r':
openr.c:(.text._open_r+0x24): undefined reference to
_open'
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-sbrkr.o): in function _sbrk_r':
sbrkr.c:(.text._sbrk_r+0x18): undefined reference to
_sbrk'
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-writer.o): in function _write_r':
writer.c:(.text._write_r+0x24): undefined reference to
_write'
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-closer.o): in function _close_r':
closer.c:(.text._close_r+0x18): undefined reference to
_close'
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-isattyr.o): in function _isatty_r':
isattyr.c:(.text._isatty_r+0x18): undefined reference to
_isatty'
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-lseekr.o): in function _lseek_r':
lseekr.c:(.text._lseek_r+0x24): undefined reference to
_lseek'
/usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/bin/ld: /usr/bin/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/../../../../arm-none-eabi/lib/libc.a(lib_a-readr.o): in function _read_r':
readr.c:(.text._read_r+0x24): undefined reference to
_read'
collect2: error: ld returned 1 exit status
make[3]: *** [mkconfig] Error 1
make[2]: *** [tools/mkconfig] Error 2
FAILED: cd /home/hu/src/Firmware/build/px4_fmu-v2_default/external/Build/px4io_firmware && /usr/bin/cmake --build . && /usr/bin/cmake -E touch /home/hu/src/Firmware/build/px4_fmu-v2_default/external/Stamp/px4io_firmware/px4io_firmware-build
ninja: build stopped: subcommand failed.
Makefile:190: recipe for target 'px4_fmu-v2_default' failed
make[1]: *** [px4_fmu-v2_default] Error 1
make[1]: Leaving directory '/home/hu/src/Firmware'
Makefile:212: recipe for target 'px4fmu-v2_default' failed
make: *** [px4fmu-v2_default] Error 2

Kev_Cgxx
??|??|?? 楼主 问题解决了吗? 我也遇到了
10 个月之前 回复

1个回答

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问
相关内容推荐