summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac7
-rw-r--r--doc/mpc.texi2
-rw-r--r--tests/Makefile.am3
3 files changed, 5 insertions, 7 deletions
diff --git a/configure.ac b/configure.ac
index 41b3974..5560da3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -85,12 +85,9 @@ AC_ARG_ENABLE([logging],
)
AC_ARG_ENABLE([valgrind-tests],
[AC_HELP_STRING([--enable-valgrind-tests],
- [run checks through valgrind for static library (default = no)])],
+ [run checks through valgrind (default = no)])],
[case $enableval in
- yes) AS_IF([test "x$enable_shared" != "xno"],
- [AC_MSG_ERROR([Valgrind checks do not work with shared libraries; use --enable-valgrind-tests only with --disable-shared])],
- [gl_VALGRIND_TESTS]
- ) ;;
+ yes) gl_VALGRIND_TESTS ;;
no) ;;
*) AC_MSG_ERROR([Bad value for --enable-valgrind-tests: Use yes or no]) ;;
esac
diff --git a/doc/mpc.texi b/doc/mpc.texi
index 527689c..b593faf 100644
--- a/doc/mpc.texi
+++ b/doc/mpc.texi
@@ -164,8 +164,6 @@ specify an alternative installation location instead of
To enable checking for memory leaks using @command{valgrind} during
@code{make check}, add the parameter @code{--enable-valgrind-tests}.
-This can only be used on static libraries, so you need to pass
-@code{--disable-shared} at the same time.
If for debugging purposes you wish to log calls to GNU MPC functions from
within your code, add the parameter @samp{--enable-logging}.
diff --git a/tests/Makefile.am b/tests/Makefile.am
index e037ee6..d39ba8d 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -19,6 +19,9 @@
AM_CPPFLAGS = -I$(top_srcdir)/src
LDADD = libmpc-tests.la $(top_builddir)/src/libmpc.la
+# let libtool create an executable instead of a shell script
+# useful for tests with valgrind
+AM_LDFLAGS = -no-install
# LOADLIBES (documented in the "GNU make" manual and equivalent to LDLIBS)
# enables to compile a program foo.c in the test directory by simply doing
# "make foo".