Commit cbba4ee6 authored by Francis Dupont's avatar Francis Dupont

[master] Merged trac5057 (configure vs gtest-1.8.0)

parents 28ce6245 72961fc6
......@@ -1226,6 +1226,9 @@ if test "x$enable_gtest" = "xyes" ; then
AC_MSG_ERROR([no gtest source but it was selected])
fi
else
if test ! -d $GTEST_SOURCE/src -a -d $GTEST_SOURCE/googletest; then
GTEST_SOURCE=$GTEST_SOURCE/googletest
fi
AC_CHECK_FILES([$GTEST_SOURCE/src/gtest-all.cc]
[$GTEST_SOURCE/src/gtest_main.cc],
[have_gtest_source=yes],
......@@ -1264,6 +1267,10 @@ if test "x$enable_gtest" = "xyes" ; then
GTEST_FOUND="false"
for dir in $GTEST_PATHS; do
if test -f "$dir/include/gtest/gtest.h"; then
if ! test -f "$dir/lib/libgtests.a"; then
AC_MSG_WARN([Found Google Test include but not the library in $dir.])
continue
fi
GTEST_INCLUDES="-I$dir/include"
GTEST_LDFLAGS="-L$dir/lib"
GTEST_LDADD="-lgtest"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment