<div dir="ltr"><div>Merged in master, stable-2.6 and stable-2.5.</div><div><br></div><div>Thanks!</div><div>Jérémie</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 10, 2015 at 5:03 PM, Jonathan Rajotte <span dir="ltr"><<a href="mailto:jonathan.rajotte-julien@efficios.com" target="_blank">jonathan.rajotte-julien@efficios.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Signed-off-by: Jonathan Rajotte <<a href="mailto:jonathan.rajotte-julien@efficios.com">jonathan.rajotte-julien@efficios.com</a>><br>
---<br>
config/ax_prog_flex_version.m4 | 69 ++++++++++++++++++++++++++++++++++++++++++<br>
<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a> | 4 +++<br>
2 files changed, 73 insertions(+)<br>
create mode 100644 config/ax_prog_flex_version.m4<br>
<br>
diff --git a/config/ax_prog_flex_version.m4 b/config/ax_prog_flex_version.m4<br>
new file mode 100644<br>
index 0000000..da60e00<br>
--- /dev/null<br>
+++ b/config/ax_prog_flex_version.m4<br>
@@ -0,0 +1,69 @@<br>
+# ===========================================================================<br>
+# <a href="http://www.gnu.org/software/autoconf-archive/ax_prog_flex_version.html" rel="noreferrer" target="_blank">http://www.gnu.org/software/autoconf-archive/ax_prog_flex_version.html</a><br>
+# ===========================================================================<br>
+#<br>
+# SYNOPSIS<br>
+#<br>
+# AX_PROG_FLEX_VERSION([VERSION],[ACTION-IF-TRUE],[ACTION-IF-FALSE])<br>
+#<br>
+# DESCRIPTION<br>
+#<br>
+# Makes sure that flex version is greater or equal to the version<br>
+# indicated. If true the shell commands in ACTION-IF-TRUE are executed. If<br>
+# not the shell commands in commands in ACTION-IF-TRUE are executed. If<br>
+# not the shell commands in ACTION-IF-FALSE are run. Note if $FLEX is not<br>
+# set (for example by running AC_CHECK_PROG or AC_PATH_PROG) the macro<br>
+# will fail.<br>
+#<br>
+# Example:<br>
+#<br>
+# AC_PATH_PROG([FLEX],[flex])<br>
+# AX_PROG_FLEX_VERSION([2.5.39],[ ... ],[ ... ])<br>
+#<br>
+# This will check to make sure that the flex you have is at least version<br>
+# 2.5.39 or greater.<br>
+#<br>
+# NOTE: This macro uses the $FLEX variable to perform the check.<br>
+#<br>
+# LICENSE<br>
+#<br>
+# Copyright (c) 2015 Jonathan Rajotte-Julien <<a href="mailto:jonathan.rajotte-julien@efficios.com">jonathan.rajotte-julien@efficios.com</a>><br>
+#<br>
+# Copying and distribution of this file, with or without modification, are<br>
+# permitted in any medium without royalty provided the copyright notice<br>
+# and this notice are preserved. This file is offered as-is, without any<br>
+# warranty.<br>
+<br>
+#serial 1<br>
+<br>
+AC_DEFUN([AX_PROG_FLEX_VERSION],[<br>
+ AC_REQUIRE([AC_PROG_SED])<br>
+ AC_REQUIRE([AC_PROG_GREP])<br>
+<br>
+ AS_IF([test -n "$FLEX"],[<br>
+ ax_flex_version="$1"<br>
+<br>
+ AC_MSG_CHECKING([for flex version])<br>
+ changequote(<<,>>)<br>
+ flex_version=`$FLEX --version 2>&1 \<br>
+ | $SED -n -e '/flex /b inspect<br>
+b<br>
+: inspect<br>
+s/.* (\{0,1\}\([0-9]*\.[0-9]*\.[0-9]*\))\{0,1\}.*/\1/;p'`<br>
+ changequote([,])<br>
+ AC_MSG_RESULT($flex_version)<br>
+<br>
+ AC_SUBST([FLEX_VERSION],[$flex_version])<br>
+<br>
+ AX_COMPARE_VERSION([$flex_version],[ge],[$ax_flex_version],[<br>
+ :<br>
+ $2<br>
+ ],[<br>
+ :<br>
+ $3<br>
+ ])<br>
+ ],[<br>
+ AC_MSG_WARN([could not find flex])<br>
+ $3<br>
+ ])<br>
+])<br>
diff --git a/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a> b/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
index b274ead..b7af59a 100644<br>
--- a/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
+++ b/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
@@ -455,6 +455,10 @@ if test ! -f "$srcdir/src/lib/lttng-ctl/filter/filter-lexer.c"; then<br>
AC_MSG_ERROR([[flex not found and is required when building from git.<br>
Please install flex]])<br>
fi<br>
+ AC_PATH_PROG([FLEX],[flex])<br>
+ AX_PROG_FLEX_VERSION([2.5.35], [],[<br>
+ AC_MSG_ERROR([[Flex >= 2.5.35 is required when building from git]])<br>
+ ])<br>
fi<br>
<br>
CFLAGS="-Wall $CFLAGS -g -fno-strict-aliasing"<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.1.4<br>
<br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">Jérémie Galarneau<br>EfficiOS Inc.<br><a href="http://www.efficios.com" target="_blank">http://www.efficios.com</a></div>
</div>