macOS下arm编译缺少stdint.h等问题

问题

通过brew安装的 arm-none-eabi-gcc 编译工程时出现大量类似错误如下:

cpp 复制代码
/opt/homebrew/Cellar/arm-none-eabi-gcc/13.2.0/lib/gcc/arm-none-eabi/13.2.0/include/stdint.h:9:16: fatal error: stdint.h: No such file or directory

问题原因

不能使用arm-none-eabi-gcc安装编译工具链。

解决方案

打开终端输入命令,先删除brew安装的gcc环境,再安装gcc-arm-embedded环境:

bash 复制代码
brew uninstall arm-none-eabi-gcc
brew autoremove
brew install --cask gcc-arm-embedded
相关推荐
琉-璃1 小时前
Mac M2安装VUE3
macos
GilgameshJSS2 小时前
STM32H743-ARM例程11-PWM
c语言·arm开发·stm32·嵌入式硬件·学习
2501_915909063 小时前
App Store 上架完整流程解析,iOS 应用发布步骤、ipa 文件上传工具、TestFlight 测试与苹果审核经验
android·macos·ios·小程序·uni-app·cocoa·iphone
2501_916008893 小时前
iOS 26 全景揭秘,新界面、功能创新、兼容挑战与各种工具在新版系统中的定位
android·macos·ios·小程序·uni-app·cocoa·iphone
SkylerHu3 小时前
MacOS 使用ssh2-python报错ImportError: dlopen ... _libssh2_channel_direct_tcpip_ex
python·macos·ssh2
阿正的梦工坊3 小时前
Mac电脑解决 npm 和 Yarn 安装时的证书过期问题
前端·macos·npm
学不动CV了12 小时前
FreeRTOS---任务级和中断级临界区管理使用的理解与源码分析
c语言·arm开发·stm32·单片机·嵌入式硬件·51单片机
月盈缺13 小时前
学习嵌入式的第四十二天——ARM——UART
arm开发·学习
GilgameshJSS14 小时前
STM32H743-ARM例程10-WWDG
c语言·arm开发·stm32·单片机·嵌入式硬件
海上飞猪16 小时前
【MacOS】Warp安装使用教程
macos