query xft-config, if available

This commit is contained in:
eknauel 2003-11-24 07:08:53 +00:00
parent cf516d26c9
commit fff8292341
1 changed files with 12 additions and 3 deletions

View File

@ -45,9 +45,18 @@
dnl Compile with Xft support?
if test "$with_xft" = "yes"; then
LIBS="$LIBS -L${x_libraries}"
AC_CHECK_LIB(Xrender, XRenderQueryExtension, SCX_PREPEND(-lXrender, x_libraries))
AC_CHECK_LIB(Xft, XftFontOpen, SCX_PREPEND(-lXft, x_libraries))
AC_CHECKING([xft-config program])
AC_CHECK_PROG([XFT_CONFIG], [xft-config], "yes", "no", $PATH, [])
if test "$XFT_CONFIG" = "yes"; then
SCX_PREPEND(`xft-config --libs`, x_libraries)
SCX_PREPEND(`xft-config --cflags`, x_includes)
else
LIBS="$LIBS -L${x_libraries}"
AC_CHECK_LIB(Xrender, XRenderQueryExtension, SCX_PREPEND(-lXrender, x_libraries))
AC_CHECK_LIB(Xft, XftFontOpen, SCX_PREPEND(-lXft, x_libraries))
fi
AC_DEFINE([WITH_XFT], 1, [Define 1 if compiling with Xft support])
SCX_PREPEND(\$(XFT_OBJECTS), extra_objects)
AC_SUBST(load_xft_packages, yes)