summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorTrond Norbye <trond.norbye@gmail.com>2012-09-01 14:31:17 +0200
committerTrond Norbye <trond.norbye@gmail.com>2012-09-01 14:31:23 +0200
commitad27588391e4f5f85f07f9d734334ade4cc5dbb0 (patch)
tree94f51b09c1e9e591eba514c65d015153a2d96915 /configure.ac
parent890dfb75ed40e59bf3e46904431a5c27824e0b7e (diff)
downloadmemcached-ad27588391e4f5f85f07f9d734334ade4cc5dbb0.tar.gz
Issue 286: --disable-coverage drops "-pthread" option
-pthread was added as part of setting up the gcov options
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac8
1 files changed, 3 insertions, 5 deletions
diff --git a/configure.ac b/configure.ac
index 9915a46..0e1cea7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -49,6 +49,8 @@ AC_DEFUN([DETECT_SUNCC],
])
DETECT_SUNCC([CFLAGS="-mt $CFLAGS"], [])
+AS_IF([test "$ICC" = "yes" -o "$GCC" = "yes"],
+ [CFLAGS="$CFLAGS -pthread"])
if test "$ICC" = "no"; then
AC_PROG_CC_C99
@@ -140,11 +142,7 @@ AC_ARG_ENABLE(coverage,
[AS_HELP_STRING([--disable-coverage],[Disable code coverage])])
if test "x$enable_coverage" != "xno"; then
- if test "$ICC" = "yes"
- then
- dnl ICC trying to be gcc, but not well
- CFLAGS="$CFLAGS -pthread"
- elif test "$GCC" = "yes"
+ if test "$GCC" = "yes" -a "$ICC" != "yes"
then
CFLAGS="$CFLAGS -pthread"
AC_PATH_PROG([PROFILER], [gcov], "no", [$PATH])