Aan*_*dev 5 c undefined-reference
我正在使用Eclipse Kepler进行构建,并已包含在内math.h.但是,我收到了一个错误
math.h
'对log10的未定义引用'.
还有类型uint8_t和unit32_t尚未解决.我既包括stdint.h和inttypes.h,只是可以肯定的,但没有成功.有人可以帮忙吗?
uint8_t
unit32_t
stdint.h
inttypes.h
Sou*_*osh 9
因为,头文件只提供函数的前向声明.实际的函数定义存在于("math")库中.您需要使用与数学库链接-lm.
-lm
参考:手册页的log10
log10
此外,AFAIK uint<N>_t也在场<stdint.h>.请检查代码中是否存在头文件本身和/或任何拼写错误(如unit32_t示例中所示).
uint<N>_t
<stdint.h>
归档时间:
11 年 前
查看次数:
10566 次
最近记录: