5 [freetype-devel@nongnu.org])
6 AM_INIT_AUTOMAKE([-Wall -Werror foreign])
15 AC_ARG_WITH(freetype-config,
16 [ --with-freetype-config=PROG Use FreeType configuration program PROG],
17 freetype_config=$withval,
20 if test "$freetype_config" = "yes"; then
21 AC_PATH_PROG(ft_config,
24 if test "$ft_config" = "no"; then
25 AC_MSG_ERROR([FreeType library is missing; see http://www.freetype.org/])
28 ft_config="$freetype_config"
31 FREETYPE_CPPFLAGS="`$ft_config --cflags`"
32 FREETYPE_LDFLAGS="`$ft_config --libs`"
34 AC_SUBST(FREETYPE_CPPFLAGS)
35 AC_SUBST(FREETYPE_LDFLAGS)
39 AC_MSG_CHECKING([whether FreeType version is 2.4.4 or higher])
40 old_CPPFLAGS="$CPPFLAGS"
41 CPPFLAGS=$FREETYPE_CPPFLAGS
45 #include FT_FREETYPE_H
46 #if (FREETYPE_MAJOR*1000 + FREETYPE_MINOR)*1000 + FREETYPE_PATCH < 2004004
47 #error Freetype version too low.
52 CPPFLAGS="$old_CPPFLAGS"],
53 [AC_MSG_ERROR([Need FreeType library version 2.4.4 or higher])])
56 AC_CONFIG_HEADERS([config.h])
57 AC_CONFIG_FILES([Makefile