Skip to contentSkip to conversation

configure: Add flag to disable valgrind support.

PATCH In review Matt Turner 2 participants 3 messages Jun 22, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 configure: Add flag to disable valgrind support.

---
 configure.ac | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)
configure.ac +9 -1
index 78a0010..dd6c0ab 100644
@@ -403,7 +403,15 @@ else
 fi
 AM_CONDITIONAL([HAVE_MANPAGES_STYLESHEET], [test "x$HAVE_MANPAGES_STYLESHEET" = "xyes"])
 
-PKG_CHECK_MODULES(VALGRIND, [valgrind], [have_valgrind=yes], [have_valgrind=no])
+AC_ARG_ENABLE(valgrind,
+              AS_HELP_STRING([--disable-valgrind],
+                             [Disable valgrind support]),
+                             [use_valgrind=$enableval], [use_valgrind=yes])
+
+if test "x$use_valgrind" = "xyes"; then
+	PKG_CHECK_MODULES(VALGRIND, [valgrind], [have_valgrind=yes], [have_valgrind=no])
+fi
+
 if test "x$have_valgrind" = "xyes"; then
 	AC_DEFINE([HAVE_VALGRIND], 1, [Use valgrind intrinsics to suppress false warnings])
 fi
Signature · 6 lines
2.3.6

_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
#1 lore raw
Quoted 12 lines · Matt Turner
---
 configure.ac | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)
configure.ac +0 -0
index 78a0010..dd6c0ab 100644
@@ -403,7 +403,15 @@ else
 fi
 AM_CONDITIONAL([HAVE_MANPAGES_STYLESHEET], [test "x$HAVE_MANPAGES_STYLESHEET" = "xyes"])
 

configure.ac else · line 414

Quoted 10 lines
configure.ac +9 -1
-PKG_CHECK_MODULES(VALGRIND, [valgrind], [have_valgrind=yes], [have_valgrind=no])
+AC_ARG_ENABLE(valgrind,
+              AS_HELP_STRING([--disable-valgrind],
+                             [Disable valgrind support]),
+                             [use_valgrind=$enableval], [use_valgrind=yes])
+
+if test "x$use_valgrind" = "xyes"; then
+       PKG_CHECK_MODULES(VALGRIND, [valgrind], [have_valgrind=yes], [have_valgrind=no])
+fi
+

Any objections if we move this to "auto" rather than enabled by default (like we do with cairo) ? If you're ok I'll amend the patch before pushing.

-Emil
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel

#2 lore raw
Quoted 27 lines · Emil Velikov
Quoted 12 lines · Matt Turner
---
 configure.ac | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)
configure.ac +0 -0
index 78a0010..dd6c0ab 100644
@@ -403,7 +403,15 @@ else
 fi
 AM_CONDITIONAL([HAVE_MANPAGES_STYLESHEET], [test "x$HAVE_MANPAGES_STYLESHEET" = "xyes"])
 

configure.ac else · line 414

Quoted 10 lines
configure.ac +9 -1
-PKG_CHECK_MODULES(VALGRIND, [valgrind], [have_valgrind=yes], [have_valgrind=no])
+AC_ARG_ENABLE(valgrind,
+              AS_HELP_STRING([--disable-valgrind],
+                             [Disable valgrind support]),
+                             [use_valgrind=$enableval], [use_valgrind=yes])
+
+if test "x$use_valgrind" = "xyes"; then
+       PKG_CHECK_MODULES(VALGRIND, [valgrind], [have_valgrind=yes], [have_valgrind=no])
+fi
+

Any objections if we move this to "auto" rather than enabled by default (like we do with cairo) ? If you're ok I'll amend the patch before pushing.

Quoted 1 line

-Emil

Fine by me!

Thanks Emil.
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel