summaryrefslogtreecommitdiffstats
path: root/m4macros
diff options
context:
space:
mode:
authorAndrei Pavel <andrei@isc.org>2020-10-05 11:04:09 +0200
committerAndrei Pavel <andrei@isc.org>2020-10-12 15:59:09 +0200
commitf0d1b03b6bf49af48b403f1b6a020f266d8f45fa (patch)
tree40d07fc1f3146ae9daea58ffb0dbafd7ca106a84 /m4macros
parent[#1385] Wrapped new ChangeLog entry (2) (diff)
downloadkea-f0d1b03b6bf49af48b403f1b6a020f266d8f45fa.tar.xz
kea-f0d1b03b6bf49af48b403f1b6a020f266d8f45fa.zip
[#1451] allow linking with libgtest.so
Diffstat (limited to 'm4macros')
-rw-r--r--m4macros/ax_gtest.m415
1 files changed, 8 insertions, 7 deletions
diff --git a/m4macros/ax_gtest.m4 b/m4macros/ax_gtest.m4
index edd729dd90..b2f813aee3 100644
--- a/m4macros/ax_gtest.m4
+++ b/m4macros/ax_gtest.m4
@@ -135,15 +135,16 @@ 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/libgtest.a"; then
+ if test -f "$dir/lib/libgtest.a" || \
+ test -f "$dir/lib/libgtest.so"; then
+ GTEST_INCLUDES="-I$dir/include"
+ GTEST_LDFLAGS="-L$dir/lib"
+ GTEST_LDADD="-lgtest"
+ GTEST_FOUND="true"
+ break
+ else
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"
- GTEST_FOUND="true"
- break
fi
done
fi