dnl Process this file with autoconf to create configure. AC_INIT(ChangeLog) AM_INIT_AUTOMAKE(pango, 0.11) AM_CONFIG_HEADER(config.h) AC_PROG_CC AM_PROG_LIBTOOL changequote(,)dnl if test "x$GCC" = "xyes"; then case " $CFLAGS " in *[\ \ ]-Wall[\ \ ]*) ;; *) CFLAGS="$CFLAGS -Wall" ;; esac fi changequote([,])dnl AC_PATH_X if test x$no_x = xyes ; then AC_MSG_ERROR([X development libraries not found]) fi X_LIBS="-L$x_libraries -lX11" AC_SUBST(X_LIBS) AM_PATH_GLIB(1.3.1,, AC_MSG_ERROR([GLib 1.3.1 is required for building Pango]), gmodule gobject) AC_PATH_PROG(FRIBIDI_CONFIG, fribidi-config, no) if test x$FRIBIDI_CONFIG = xno ; then AC_MSG_ERROR([*** fribidi-config not found]) fi FRIBIDI_CFLAGS="`$FRIBIDI_CONFIG --cflags`" CFLAGS="$CFLAGS $FRIBIDI_CFLAGS" FRIBIDI_LIBS="`$FRIBIDI_CONFIG --libs`" AC_SUBST(FRIBIDI_LIBS) AC_SUBST(FRIBIDI_CFLAGS) AC_CHECK_LIB(fribidi, fribidi_map_range, :, AC_MSG_ERROR([*** libfribidi not found.]), $FRIBIDI_LIBS) AC_PATH_PROG(GLIB_CONFIG, glib-config, no) if test x$GLIB_CONFIG = xno ; then AC_MSG_ERROR([*** glib-config not found]) fi GLIB_CFLAGS="`$GLIB_CONFIG --cflags gmodule gobject`" CFLAGS="$CFLAGS $GLIB_CFLAGS" GLIB_LIBS="`$GLIB_CONFIG --libs gmodule gobject`" AC_SUBST(GLIB_LIBS) AC_SUBST(GLIB_CFLAGS) # # Checks for iconv # AC_ARG_WITH(libiconv, [ --with-libiconv Use the libiconv library ],,with_libiconv=maybe) found_iconv=no if ! test "x$with_libiconv" = "xyes" ; then # # Check in the C library # AC_CHECK_FUNC(iconv_open, with_libiconv=no; found_iconv=yes) fi if test "x$with_libiconv" != "xno" ; then # # Check for libiconv # AC_CHECK_LIB(iconv, libiconv_open, with_libiconv=yes; found_iconv=yes) fi if test "x$found_iconv" = "xno" ; then AC_MSG_ERROR([*** No iconv() implementation found in C library or libiconv]) fi UNICODE_CFLAGS= UNICODE_LIBS= if test "x$with_libiconv" = "xyes" ; then UNICODE_LIBS="-liconv" fi AC_SUBST(UNICODE_CFLAGS) AC_SUBST(UNICODE_LIBS) # # Allow building some or all modules included # AC_ARG_WITH(included_modules, [ --with-included-modules=MODULE1,MODULE2,... Build the given modules into Pango]) included_modules="" if ! test "x$with_included_modules" = xno || test "x$with_included_modules" = x ; then # If no modules specified, include all modules if test "x$with_included_modules" = xyes ; then included_modules="arabic,devanagari,basic,hangul,tamil,thai" else included_modules="$with_included_modules" fi fi INCLUDED_MODULES= IFS="${IFS= }"; pango_save_ifs="$IFS"; IFS="," for module in $included_modules; do INCLUDED_MODULES="$INCLUDED_MODULES \$(top_builddir)/modules/$module/libpango-$module.la" done IFS="$pango_save_ifs" AC_SUBST(INCLUDED_MODULES) AM_CONDITIONAL(INCLUDE_ARABIC,echo $included_modules | grep '\(^\|,\)arabic\($\|,\)' > /dev/null) AM_CONDITIONAL(INCLUDE_BASIC,echo $included_modules | grep '\(^\|,\)basic\($\|,\)' > /dev/null) AM_CONDITIONAL(INCLUDE_DEVANAGARI,echo $included_modules | grep '\(^\|,\)devanagari\($\|,\)' > /dev/null) AM_CONDITIONAL(INCLUDE_HANGUL,echo $included_modules | grep '\(^\|,\)hangul\($\|,\)' > /dev/null) AM_CONDITIONAL(INCLUDE_TAMIL,echo $included_modules | grep '\(^\|,\)tamil\($\|,\)' > /dev/null) AM_CONDITIONAL(INCLUDE_THAI,echo $included_modules | grep '\(^\|,\)thai\($\|,\)' > /dev/null) # # We use flockfile to implement pango_getline() - should be moved to GLib # AC_CHECK_FUNCS(flockfile) # # Check for Qt - which we use for building the viewer example, if # present # AC_ARG_WITH(qt, [ --with-qt=DIR Location where Qt is installed],,with_qt=yes) QTDIR= AC_MSG_CHECKING(For Qt location) if test "x$with_qt" = xyes ; then # Search for Qt in various possibly standard ocations for dir in /usr/lib/qt-2.1.0 /usr/lib/qt-2.0.1 /usr/lib/qt-2.0.0 /usr/lib/qt2 ; do if test -x $dir/bin/moc ; then QTDIR=$dir break fi done else if ! test "x$with_qt" = xno ; then if test -x $with_qt/bin/moc ; then QTDIR=$with_qt fi fi fi if test "x$QTDIR" = x ; then AC_MSG_RESULT(none) else AC_MSG_RESULT($QTDIR) AC_PROG_CXX fi AM_CONDITIONAL(BUILD_QT_TEST, ! test "x$QTDIR" = x) AC_SUBST(QTDIR) # # Check for gtkdoc # AC_CHECK_PROG(gtkdoc, gtkdoc-scan, yes, no) AM_CONDITIONAL(HAVE_GTK_DOC, test x$gtkdoc = xyes) AC_OUTPUT_COMMANDS([ cat > pango/module-defs.c <> pango/module-defs.c <> pango/module-defs.c <> pango/module-defs.c <> pango/module-defs.c <