error: C preprocessor fails sanity check

问题

bash 复制代码
./configure --prefix=/opt/mips_lib/libev --host=mipsel-openwrt-linux CC=mipsel-openwrt-linux-gcc

运行后提示

bash 复制代码
checking how to run the C preprocessor... mipsel-openwrt-linux-gcc --sysroot=/opt/mt7628/toolchain-mipsel_24kc_gcc-8.4.0_musl -I/opt/mt7628/toolchain-mipsel_24kc_gcc-8.4.0_musl/usr/include
configure: error: in `/opt/mips_lib/libev-4.19':
configure: error: C preprocessor "mipsel-openwrt-linux-gcc --sysroot=/opt/mt7628/toolchain-mipsel_24kc_gcc-8.4.0_musl -I/opt/mt7628/toolchain-mipsel_24kc_gcc-8.4.0_musl/usr/include" fails sanity check
See `config.log' for more details

解决

bash 复制代码
./configure --prefix=/opt/mips_lib/libev --host=mipsel-openwrt-linux CC=mipsel-openwrt-linux-gcc CPP='mipsel-openwrt-linux-g++ -E'

参考

配置:错误:C预处理器无法进行健全性检查

相关推荐
凌肖战7 分钟前
力扣上刷题之C语言实现(数组)
c语言·算法·leetcode
Jhxbdks1 小时前
C语言中的一些小知识(二)
c语言·开发语言·笔记
代码雕刻家1 小时前
数据结构-3.1.栈的基本概念
c语言·开发语言·数据结构
AlexMercer10121 小时前
【C++】二、数据类型 (同C)
c语言·开发语言·数据结构·c++·笔记·算法
Reese_Cool1 小时前
【C语言二级考试】循环结构设计
android·java·c语言·开发语言
zxctsclrjjjcph2 小时前
【C语言】常见的C语言概念
c语言·开发语言
m0_714590262 小时前
汇编(实现C语言程序的调用)
c语言·开发语言·汇编
重生之我在20年代敲代码5 小时前
strncpy函数的使用和模拟实现
c语言·开发语言·c++·经验分享·笔记
2401_858286118 小时前
52.【C语言】 字符函数和字符串函数(strcat函数)
c语言·开发语言
jiao0000110 小时前
数据结构——队列
c语言·数据结构·算法