[PATCH] configure.ac: use compatible check for dot version
hector.oron at gmail.com
hector.oron at gmail.com
Tue Mar 31 09:17:57 PDT 2015
From: Hector Oron <hector.oron at collabora.co.uk>
configure uses grep -P, which is not supported in old grep versions.
The proposed patch uses equivalent sed form instead.
Signed-off-by: Héctor Orón Martínez <hector.oron at collabora.co.uk>
---
configure.ac | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index b2e1418..3bf90ef 100644
--- a/configure.ac
+++ b/configure.ac
@@ -28,6 +28,7 @@ AM_SILENT_RULES([yes])
AC_PROG_CC
AC_PROG_CXX
AC_PROG_GREP
+AC_PROG_SED
# check if we have C++ compiler. This is hacky workaround,
# for a reason why it is this way see
@@ -141,7 +142,7 @@ if test "x$enable_documentation" = "xyes"; then
AC_MSG_ERROR([Documentation build requested but graphviz's dot not found. Install graphviz or disable the documentation using --disable-documentation])
fi
AC_MSG_CHECKING([for compatible dot version])
- dot_version=`$DOT -V 2>&1|$GREP -oP '(?<=version\W)@<:@0-9.@:>@*(?=\W(.*))'`
+ dot_version=`$DOT -V 2>&1|$SED -ne 's/.*version \([[0-9.]]*\) .*/\1/p'`
AS_VERSION_COMPARE([$dot_version], [2.26.0],
[AC_MSG_RESULT([no])
AC_MSG_ERROR([Graphviz dot $dot_version too old. Graphviz 2.26+ required for documentation build. Install required graphviz version or disable the documentation using --disable-documentation])],
--
2.1.4
More information about the wayland-devel
mailing list