2 AC_INIT([Cycript], [0.9], [saurik@saurik.com], [cycript], [http://www.cycript.org/])
3 AC_CONFIG_SRCDIR([Console.cpp])
5 BISON=`echo $YACC | $SED -e 's/ -y//'`
6 BISON_VERSION=`$BISON -V | $SED -e 's/^bison (GNU Bison) \(.*\)$/\1/p;d'`
7 ], [AC_MSG_ERROR([You need bison 2.4 or greater])])
9 AC_MSG_CHECKING([if bison is >= 2.4])
10 AX_COMPARE_VERSION([$BISON_VERSION], [ge], [2.4], [AC_MSG_RESULT([yes])], [
12 AC_MSG_ERROR([You need bison 2.4 or greater])
16 AC_MSG_CHECKING([for flex])
17 AS_IF([test "`echo \"$LEX\" | $SED 's/^.*\(flex\).*$/\1/'`" = "flex"], [
19 AC_SUBST([FLEX], [$LEX])
22 AC_MSG_ERROR([You need flex])
24 APR_FIND_APR([], [], [1], [1])
25 AS_CASE([$apr_found], [yes], [
26 AC_LIB_APPENDTOVAR([CPPFLAGS], [`$apr_config --includes`])
27 AC_SUBST([APR], [`$apr_config --link-ld`])
28 ], [AC_MSG_ERROR([You need apr])])
32 AS_CASE([$am_cv_func_iconv], [yes], [], [AC_MSG_ERROR([You need iconv])])
33 PKG_CHECK_MODULES([WEBKIT], [webkit-1.0], [WEBKIT=yes], [
34 PKG_CHECK_MODULES([WEBKIT], [WebKitGtk], [WEBKIT=yes], [WEBKIT=no])
36 AS_CASE([$WEBKIT], [yes], [
37 PKG_CHECK_MODULES([LIBFFI], [libffi])
38 ], [AC_MSG_WARN(No JavaScript engine!)])
40 AS_IF([test x$_cv_gnu_make_command = x], [AC_MSG_ERROR([You need GNU make])])