【发布时间】:2012-12-20 21:06:11
【问题描述】:
我正在尝试使用自动工具将 Google 测试框架添加到我的应用中。 但是我遇到了一些奇怪的错误。 在configure.ac中:
AC_CHECK_HEADER([gtest/gtest.h], [AC_DEFINE([HAVE_GTEST_H], 1)])
但在日志中我得到了:
...
checking for limits.h... yes
checking gtest/gtest.h usability... no
checking gtest/gtest.h presence... no
checking for gtest/gtest.h... no
config.log:
configure:3276: checking gtest/gtest.h presence
configure:3276: gcc -E conftest.c
In file included from conftest.c:19:0:
/usr/include/gtest/gtest.h:54:18: fatal error: limits: No such file or directory
compilation terminated.
两个文件都存在。据我所知 /usr/include 是默认包含。
【问题讨论】:
-
显然是 gcc 中的一个错误! 所以,我的猜测是文件实际上并不存在,或者无法从您使用的帐户中读取...
标签: c++ autotools googletest