You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by ig...@apache.org on 2011/06/02 16:43:21 UTC

svn commit: r1130582 - /trafficserver/traffic/trunk/configure.ac

Author: igalic
Date: Thu Jun  2 14:43:21 2011
New Revision: 1130582

URL: http://svn.apache.org/viewvc?rev=1130582&view=rev
Log:
[TS-815] make sure that a missing yacc/bison|flex/lex is *fatal* when building with wccp
Author: Arno Töll
Review: Igor Galić

Modified:
    trafficserver/traffic/trunk/configure.ac

Modified: trafficserver/traffic/trunk/configure.ac
URL: http://svn.apache.org/viewvc/trafficserver/traffic/trunk/configure.ac?rev=1130582&r1=1130581&r2=1130582&view=diff
==============================================================================
--- trafficserver/traffic/trunk/configure.ac (original)
+++ trafficserver/traffic/trunk/configure.ac Thu Jun  2 14:43:21 2011
@@ -469,8 +469,26 @@ AC_CHECK_TOOL(AR, ar, ar)
 AC_ISC_POSIX
 AS_IF([test "x$enable_wccp" = "xyes"],
   [
-    AC_PROG_YACC
+
+    # If flex is found, set output variable LEX to ‘flex’ 
+    # Otherwise set LEX to ‘lex’ 
+    # If neither variant is available, set LEX to ‘:’;
     AC_PROG_LEX
+    AS_IF([test "x$LEX" = "x:"  ],
+       AC_MSG_ERROR([Need flex when enabling WCCP])
+    )
+
+    # If bison is found, set output variable YACC to ‘bison -y’. 
+    # Otherwise, if byacc is found, set YACC to ‘byacc’. 
+    # Otherwise set YACC to ‘yacc’. 
+    AC_PROG_YACC
+    AS_IF([test "x$YACC" = "xyacc" ],
+	AC_CHECK_PROG([YACCBIN],[yacc],[yacc],[])
+	AS_IF([test "x$YACCBIN" = "x"],
+		AC_MSG_ERROR([Need at YACC when enabling WCCP])
+	)
+    )
+
   ]
 )