summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2011-05-30 15:41:27 +0100
committerSimon McVittie <simon.mcvittie@collabora.co.uk>2011-05-30 15:41:27 +0100
commit61f48c290176c007ff0aef6ca4d752491763e4b0 (patch)
tree0ab19b8e6fabbef832b688d9c7315dfacc9eb895 /configure.ac
parent0f320c5224fe39df44648ac75ecce9e0a01079d0 (diff)
Force a full rebuild for new gcc versions if gcov is enabled
This avoids a lot of "Version mismatch - expected 406p got 405*". Because we're changing the content of each file after preprocessing, it even defeats ccache, which is desirable here - otherwise we'd get old versions of the profiling code being resurrected from the cache. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=37060 Reviewed-by: Guillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac17
1 files changed, 4 insertions, 13 deletions
diff --git a/configure.ac b/configure.ac
index 27e8887..647c6fc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -226,20 +226,11 @@ CPPFLAGS=`echo "$CPPFLAGS" | sed -e 's/ +/ /g'`
changequote([,])dnl
if test x$enable_gcov = xyes; then
- ## so that config.h changes when you toggle gcov support
- AC_DEFINE_UNQUOTED(DBUS_GCOV_ENABLED, 1, [Defined if gcov is enabled to force a rebuild due to config.h changing])
-
- AC_MSG_CHECKING([for gcc 3.3 version of gcov file format])
- have_gcc33_gcov=no
- AC_RUN_IFELSE( [AC_LANG_PROGRAM( , [[ if (__GNUC__ >=3 && __GNUC_MINOR__ >= 3) exit (0); else exit (1); ]])],
- have_gcc33_gcov=yes)
- if test x$have_gcc33_gcov = xyes ; then
- AC_DEFINE_UNQUOTED(DBUS_HAVE_GCC33_GCOV, 1, [Defined if we have gcc 3.3 and thus the new gcov format])
- fi
- AC_MSG_RESULT($have_gcc33_gcov)
+ # so that config.h changes when you toggle gcov support
+ AC_DEFINE_UNQUOTED([DBUS_GCOV_ENABLED],
+ [__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__],
+ [Defined to the gcc version if gcov is enabled, to force a rebuild due to config.h changing])
fi
-AM_CONDITIONAL(DBUS_GCOV_ENABLED, test x$enable_gcov = xyes)
-
#### Various functions
AC_SEARCH_LIBS([socket], [socket])