diff options
Diffstat (limited to 'common')
-rw-r--r-- | common/check.mak | 6 | ||||
-rwxr-xr-x | common/extract-release-date-from-doap-file | 8 | ||||
-rw-r--r-- | common/gst.supp | 8 | ||||
-rw-r--r-- | common/m4/gst-args.m4 | 9 | ||||
-rw-r--r-- | common/m4/gst-glib2.m4 | 12 | ||||
-rw-r--r-- | common/m4/gst-package-release-datetime.m4 | 4 |
6 files changed, 32 insertions, 15 deletions
diff --git a/common/check.mak b/common/check.mak index 285876c..611546a 100644 --- a/common/check.mak +++ b/common/check.mak @@ -53,6 +53,7 @@ LOOPS ?= 10 $(VALGRIND_PATH) -q \ $(foreach s,$(SUPPRESSIONS),--suppressions=$(s)) \ --tool=memcheck --leak-check=full --trace-children=yes \ + --show-possibly-lost=no \ --leak-resolution=high --num-callers=20 \ ./$* 2>&1 | tee valgrind.log @if grep "==" valgrind.log > /dev/null 2>&1; then \ @@ -60,7 +61,7 @@ LOOPS ?= 10 exit 1; \ fi @rm valgrind.log - + # valgrind any given test and generate suppressions for it %.valgrind.gen-suppressions: % @$(TESTS_ENVIRONMENT) \ @@ -70,10 +71,11 @@ LOOPS ?= 10 $(VALGRIND_PATH) -q \ $(foreach s,$(SUPPRESSIONS),--suppressions=$(s)) \ --tool=memcheck --leak-check=full --trace-children=yes \ + --show-possibly-lost=no \ --leak-resolution=high --num-callers=20 \ --gen-suppressions=all \ ./$* 2>&1 | tee suppressions.log - + # valgrind torture any given test %.valgrind-torture: % @for i in `seq 1 $(LOOPS)`; do \ diff --git a/common/extract-release-date-from-doap-file b/common/extract-release-date-from-doap-file index f2bc418..f57e307 100755 --- a/common/extract-release-date-from-doap-file +++ b/common/extract-release-date-from-doap-file @@ -18,12 +18,12 @@ fi awk 'BEGIN {x=0} { -if ($0~"<release>") {x=1; chunk=""} +if ( $0 ~ /<release>/ ) {x=1; chunk=""} if (x==1) { - if ($0~"<revision>") { chunk = chunk $0 } - if ($0~"<created>") { chunk = chunk $0 } + if ($0 ~ /<revision>/) { chunk = chunk $0 } + if ($0 ~ /<created>/) { chunk = chunk $0 } } -if ($0~"</release>") {x=0; print chunk} +if ($0 ~ /<\/release>/) {x=0; print chunk} }' < "$2" | \ \ grep '<revision>'"$1"'</revision>' | \ diff --git a/common/gst.supp b/common/gst.supp index 05ecbb9..8a3617f 100644 --- a/common/gst.supp +++ b/common/gst.supp @@ -91,6 +91,14 @@ fun:pthread_create@@* } +{ + <tls> + Memcheck:Leak + fun:calloc + fun:allocate_dtv + fun:_dl_allocate_tls +} + # I get an extra stack entry on x86/dapper { <tls> diff --git a/common/m4/gst-args.m4 b/common/m4/gst-args.m4 index 4872e3c..b478c82 100644 --- a/common/m4/gst-args.m4 +++ b/common/m4/gst-args.m4 @@ -337,6 +337,7 @@ AC_DEFUN([AG_GST_ARG_ENABLE_BROKEN], dnl allow people (or build tools) to override default behaviour dnl for fatal compiler warnings +dnl Enable fatal warnings by default only for development versions AC_DEFUN([AG_GST_ARG_DISABLE_FATAL_WARNINGS], [ AC_ARG_ENABLE(fatal-warnings, @@ -349,5 +350,11 @@ AC_DEFUN([AG_GST_ARG_DISABLE_FATAL_WARNINGS], *) AC_MSG_ERROR(bad value ${enableval} for --disable-fatal-warnings) ;; esac ], - [FATAL_WARNINGS=$GST_GIT]) dnl Default value + [ + if test "x`expr $PACKAGE_VERSION_MINOR % 2`" = "x1" -a "x`expr $PACKAGE_VERSION_MICRO '<' 90`" = "x1"; then + FATAL_WARNINGS=yes + else + FATAL_WARNINGS=no + fi + ]) ]) diff --git a/common/m4/gst-glib2.m4 b/common/m4/gst-glib2.m4 index 9a3a923..0b92734 100644 --- a/common/m4/gst-glib2.m4 +++ b/common/m4/gst-glib2.m4 @@ -27,8 +27,8 @@ AC_DEFUN([AG_GST_GLIB_CHECK], dnl when using threading primitives) GLIB_EXTRA_CFLAGS="$GLIB_EXTRA_CFLAGS -DG_THREADS_MANDATORY" - dnl Define G_DISABLE_DEPRECATED for GIT versions - if test "x$PACKAGE_VERSION_NANO" = "x1" -o "x`expr $PACKAGE_VERSION_MINOR % 2`" = "x1"; then + dnl Define G_DISABLE_DEPRECATED for development versions + if test "x`expr $PACKAGE_VERSION_MINOR % 2`" = "x1" -a "x`expr $PACKAGE_VERSION_MICRO '<' 90`" = "x1"; then GLIB_EXTRA_CFLAGS="$GLIB_EXTRA_CFLAGS -DG_DISABLE_DEPRECATED" fi @@ -38,8 +38,8 @@ AC_DEFUN([AG_GST_GLIB_CHECK], [enable_gobject_cast_checks=auto]) if test "x$enable_gobject_cast_checks" = "xauto"; then - dnl For releases, turn off the cast checks - if test "x$PACKAGE_VERSION_NANO" = "x1" -o "x`expr $PACKAGE_VERSION_MINOR % 2`" = "x1"; then + dnl Turn on cast checks only for development versions + if test "x`expr $PACKAGE_VERSION_MINOR % 2`" = "x1" -a "x`expr $PACKAGE_VERSION_MICRO '<' 90`" = "x1"; then enable_gobject_cast_checks=yes else enable_gobject_cast_checks=no @@ -56,8 +56,8 @@ AC_DEFUN([AG_GST_GLIB_CHECK], [enable_glib_assertions=auto]) if test "x$enable_glib_assertions" = "xauto"; then - dnl For releases, turn off the assertions - if test "x$PACKAGE_VERSION_NANO" = "x1" -o "x`expr $PACKAGE_VERSION_MINOR % 2`" = "x1"; then + dnl Enable assertions only for development versions + if test "x`expr $PACKAGE_VERSION_MINOR % 2`" = "x1" -a "x`expr $PACKAGE_VERSION_MICRO '<' 90`" = "x1"; then enable_glib_assertions=yes else enable_glib_assertions=no diff --git a/common/m4/gst-package-release-datetime.m4 b/common/m4/gst-package-release-datetime.m4 index 126919b..bc885e3 100644 --- a/common/m4/gst-package-release-datetime.m4 +++ b/common/m4/gst-package-release-datetime.m4 @@ -33,7 +33,7 @@ AC_DEFUN([AG_GST_SET_PACKAGE_RELEASE_DATETIME], elif test "x$1" = "xyes"; then dnl AG_GST_SET_PACKAGE_RELEASE_DATETIME([no], ["YYYY-MM-DD"]) dnl AG_GST_SET_PACKAGE_RELEASE_DATETIME([no], [DOAP-FILE], [RELEASE-VERSION]) - if ( echo $1 | grep -e '^20[1-9][0-9]-[0-1][0-9]-[0-3][0-9]' >/dev/null ) ; then + if ( echo $1 | grep '^20[1-9][0-9]-[0-1][0-9]-[0-3][0-9]' >/dev/null ) ; then GST_PACKAGE_RELEASE_DATETIME=$1 else dnl we assume the .doap file contains the date as YYYY-MM-DD @@ -47,7 +47,7 @@ AC_DEFUN([AG_GST_SET_PACKAGE_RELEASE_DATETIME], fi fi dnl AG_GST_SET_PACKAGE_RELEASE_DATETIME([YYYY-MM-DD]) - elif ( echo $1 | grep -e '^20[1-9][0-9]-[0-1][0-9]-[0-3][0-9]' >/dev/null ) ; then + elif ( echo $1 | grep '^20[1-9][0-9]-[0-1][0-9]-[0-3][0-9]' >/dev/null ) ; then GST_PACKAGE_RELEASE_DATETIME=$1 else AC_MSG_WARN([SET_PACKAGE_RELEASE_DATETIME: invalid first argument]) |