1AC_INIT(README) 2AM_INIT_AUTOMAKE(harfbuzz, 0.1) 3AC_PROG_CC 4AC_PROG_CXX 5AM_PROG_LIBTOOL 6PKG_PROG_PKG_CONFIG 7AM_CONFIG_HEADER(config.h) 8 9if test "x$ac_compiler_gnu" = xyes; then 10 CFLAGS="$CFLAGS -Wall -W -pedantic -ansi" 11 CXXFLAGS="$CXXFLAGS -Wall -W" 12fi 13 14AC_PATH_PROG(ft_config,freetype-config,no) 15if test "$ft_config" = "no"; then 16 AC_MSG_ERROR([You must have freetype installed; see http://www.freetype.org/]) 17fi 18 19FREETYPE_CFLAGS="`$ft_config --cflags`" 20FREETYPE_LIBS="`$ft_config --libs`" 21 22AC_SUBST(FREETYPE_LIBS) 23AC_SUBST(FREETYPE_CFLAGS) 24 25AC_ARG_ENABLE(qt, AS_HELP_STRING([--disable-qt], [Build Qt support (default: auto)]), [QT=$enableval], [QT=auto]) 26 27if test "x$QT" = xauto; then 28 PKG_CHECK_MODULES(QT, [QtGui >= 4.3], [QT=yes], [QT=no]) 29fi 30if test "x$QT" = xyes; then 31 PKG_CHECK_MODULES(QT_GUI, [QtGui >= 4.3]) 32 PKG_CHECK_MODULES(QT_QTEST, [QtTest >= 4.3]) 33 34 _PKG_CONFIG(QT_INCDIR, [variable=includedir], [QtGui >= 4.3]) 35 QT_GUI_CFLAGS="$QT_GUI_CFLAGS -I$pkg_cv_QT_INCDIR/../Qt" 36 37 AC_SUBST(QT_GUI_CFLAGS) 38 AC_SUBST(QT_GUI_LIBS) 39 AC_SUBST(QT_QTEST_CFLAGS) 40 AC_SUBST(QT_QTEST_LIBS) 41 42 _PKG_CONFIG(QT_MOC, [variable=moc_location], [QtGui >= 4.3]) 43 QT_MOC=$pkg_cv_QT_MOC 44 AC_SUBST(QT_MOC) 45fi 46AM_CONDITIONAL(QT, [test "x$QT" = xyes]) 47 48AC_OUTPUT([ 49Makefile 50src/Makefile 51tests/Makefile 52tests/linebreaking/Makefile 53tests/shaping/Makefile 54]) 55