Debian上没有stdint.h文件

cer*_*cem 11 c embedded gcc arm stm32

我正在尝试使用Chibios.他们提供的示例代码似乎需要stdint.h文件.Makefile给出以下错误:

/usr/lib/gcc/arm-none-eabi/4.8/include/stdint.h:9:26: fatal error: stdint.h: No such file or directory
 # include_next <stdint.h>
                          ^
compilation terminated.
../../os/ports/GCC/ARMCMx/rules.mk:182: recipe for target 'build/obj/crt0.o' failed
make: *** [build/obj/crt0.o] Error 1
Run Code Online (Sandbox Code Playgroud)

我在网上找不到任何有用的东西.

pho*_*ord 13

#include_next用于让一个文件扩充另一个具有相同名称的文件.在这种情况下,似乎"另一个"不可用.

我在Linux Mint,gcc-arm-none-eabi中使用gcc-arm软件包尝试编译代码时遇到了同样的错误.我通过安装libnewlib-arm-none-eabi解决了这个问题:sudo apt-get install libnewlib-arm-none-eabi

  • 还有 Arch 上的“arm-none-eabi-newlib” (4认同)

gze*_*one 5

尝试这个:

apt-get install avr-libc
Run Code Online (Sandbox Code Playgroud)

嗯,我的答案不适合ARM,只是希望其他AVR用户在遇到相同问题时能获得帮助。


cer*_*cem 2

在 gcc-arm-embedded 团队(此处)的宝贵帮助下,我成功编译了 Chibios 演示程序。我从他们的启动板网站下载了 gcc-arm-none-eabi-4_8-2014q1,它工作得很好。

  • apt-get install libc6-dev 是我的解决方案。谢谢 (4认同)