aboutsummaryrefslogtreecommitdiff
path: root/fontconfig
diff options
context:
space:
mode:
Diffstat (limited to 'fontconfig')
-rw-r--r--fontconfig/Makefile.am36
-rw-r--r--fontconfig/conf.d/Makefile.am99
-rw-r--r--fontconfig/configure.in249
-rw-r--r--fontconfig/doc/fontconfig-user.sgml6
-rw-r--r--fontconfig/fonts.conf.in2
-rw-r--r--fontconfig/fonts.dtd2
-rw-r--r--fontconfig/src/Makefile.am2
-rw-r--r--fontconfig/src/fcxml.c27
8 files changed, 209 insertions, 214 deletions
diff --git a/fontconfig/Makefile.am b/fontconfig/Makefile.am
index 1b943672d..1738c3329 100644
--- a/fontconfig/Makefile.am
+++ b/fontconfig/Makefile.am
@@ -54,8 +54,11 @@ MAINTAINERCLEANFILES = \
pkgconfigdir=$(libdir)/pkgconfig
pkgconfig_DATA = fontconfig.pc
-configdir=$(CONFDIR)
-config_DATA=fonts.dtd
+baseconfigdir = $(BASECONFIGDIR)
+configdir = $(CONFIGDIR)
+
+xmldir = $(XMLDIR)
+xml_DATA = fonts.dtd
if CROSS_COMPILING
RUN_FC_CACHE_TEST=false
@@ -88,23 +91,24 @@ fonts.conf: fonts.conf.in Makefile
-e 's,@FC_CACHEDIR\@,$(FC_CACHEDIR),g' \
-e 's,@FC_DEFAULT_FONTS\@,$(FC_DEFAULT_FONTS),g' \
-e 's,@FC_FONTPATH\@,$(FC_FONTPATH),g' \
+ -e 's,@CONFIGDIR\@,$(CONFIGDIR),g' \
-e 's,@PACKAGE\@,$(PACKAGE),g' \
-e 's,@VERSION\@,$(VERSION),g' \
$(srcdir)/$@.in > $@.tmp && \
mv $@.tmp $@
install-data-local: fonts.conf
- $(mkinstalldirs) $(DESTDIR)$(configdir) $(DESTDIR)$(fc_cachedir)
- if [ -f $(DESTDIR)$(configdir)/fonts.conf ]; then \
- echo "backing up existing $(DESTDIR)$(configdir)/fonts.conf"; \
- mv $(DESTDIR)$(configdir)/fonts.conf $(DESTDIR)$(configdir)/fonts.conf.bak; \
+ $(mkinstalldirs) $(DESTDIR)$(baseconfigdir) $(DESTDIR)$(fc_cachedir)
+ if [ -f $(DESTDIR)$(baseconfigdir)/fonts.conf ]; then \
+ echo "backing up existing $(DESTDIR)$(baseconfigdir)/fonts.conf"; \
+ mv $(DESTDIR)$(baseconfigdir)/fonts.conf $(DESTDIR)$(baseconfigdir)/fonts.conf.bak; \
fi
if [ -f $(srcdir)/fonts.conf ]; then \
- echo " $(INSTALL_DATA) $(srcdir)/fonts.conf $(DESTDIR)$(configdir)/fonts.conf"; \
- $(INSTALL_DATA) $(srcdir)/fonts.conf $(DESTDIR)$(configdir)/fonts.conf; \
+ echo " $(INSTALL_DATA) $(srcdir)/fonts.conf $(DESTDIR)$(baseconfigdir)/fonts.conf"; \
+ $(INSTALL_DATA) $(srcdir)/fonts.conf $(DESTDIR)$(baseconfigdir)/fonts.conf; \
else if [ -f fonts.conf ]; then \
- echo " $(INSTALL_DATA) fonts.conf $(DESTDIR)$(configdir)/fonts.conf"; \
- $(INSTALL_DATA) fonts.conf $(DESTDIR)$(configdir)/fonts.conf; \
+ echo " $(INSTALL_DATA) fonts.conf $(DESTDIR)$(baseconfigdir)/fonts.conf"; \
+ $(INSTALL_DATA) fonts.conf $(DESTDIR)$(baseconfigdir)/fonts.conf; \
fi; fi
@(if $(RUN_FC_CACHE_TEST); then \
echo "fc-cache$(EXEEXT) -s -f -v"; \
@@ -119,14 +123,14 @@ install-data-local: fonts.conf
uninstall-local:
if [ -f $(srcdir)/fonts.conf ]; then \
- if cmp -s $(srcdir)/fonts.conf $(DESTDIR)$(configdir)/fonts.conf; then \
- echo " uninstall standard $(DESTDIR)$(configdir)/fonts.conf"; \
- $(RM) $(DESTDIR)$(configdir)/fonts.conf; \
+ if cmp -s $(srcdir)/fonts.conf $(DESTDIR)$(baseconfigdir)/fonts.conf; then \
+ echo " uninstall standard $(DESTDIR)$(baseconfigdir)/fonts.conf"; \
+ $(RM) $(DESTDIR)$(baseconfigdir)/fonts.conf; \
fi; \
else if [ -f fonts.conf ]; then \
- if cmp -s fonts.conf $(DESTDIR)$(configdir)/fonts.conf; then \
- echo " uninstall standard $(DESTDIR)$(configdir)/fonts.conf"; \
- $(RM) $(DESTDIR)$(configdir)/fonts.conf; \
+ if cmp -s fonts.conf $(DESTDIR)$(baseconfigdir)/fonts.conf; then \
+ echo " uninstall standard $(DESTDIR)$(baseconfigdir)/fonts.conf"; \
+ $(RM) $(DESTDIR)$(baseconfigdir)/fonts.conf; \
fi; \
fi; fi
diff --git a/fontconfig/conf.d/Makefile.am b/fontconfig/conf.d/Makefile.am
index 13f243bb3..93bf8d321 100644
--- a/fontconfig/conf.d/Makefile.am
+++ b/fontconfig/conf.d/Makefile.am
@@ -24,37 +24,6 @@
DOC_FILES= \
README
-CONF_FILES = \
- 10-autohint.conf \
- 10-no-sub-pixel.conf \
- 10-sub-pixel-bgr.conf \
- 10-sub-pixel-rgb.conf \
- 10-sub-pixel-vbgr.conf \
- 10-sub-pixel-vrgb.conf \
- 10-unhinted.conf \
- 11-lcdfilter-default.conf \
- 11-lcdfilter-legacy.conf \
- 11-lcdfilter-light.conf \
- 20-fix-globaladvance.conf \
- 20-unhint-small-vera.conf \
- 25-unhint-nonlatin.conf \
- 30-urw-aliases.conf \
- 30-metric-aliases.conf \
- 40-nonlatin.conf \
- 45-latin.conf \
- 49-sansserif.conf \
- 50-user.conf \
- 51-local.conf \
- 60-latin.conf \
- 65-fonts-persian.conf \
- 65-khmer.conf \
- 65-nonlatin.conf \
- 69-unifont.conf \
- 70-no-bitmaps.conf \
- 70-yes-bitmaps.conf \
- 80-delicious.conf \
- 90-synthetic.conf
-
CONF_LINKS = \
20-fix-globaladvance.conf \
20-unhint-small-vera.conf \
@@ -72,28 +41,56 @@ CONF_LINKS = \
80-delicious.conf \
90-synthetic.conf
-EXTRA_DIST = $(CONF_FILES) $(DOC_FILES)
+EXTRA_DIST = $(template_DATA) $(DOC_FILES)
-configdir=$(CONFDIR)
-confavaildir=$(configdir)/conf.avail
-confddir=$(configdir)/conf.d
+configdir=$(CONFIGDIR)
+config_DATA = $(DOC_FILES)
-confavail_DATA=$(CONF_FILES)
-confd_DATA=$(DOC_FILES)
+templatedir = $(TEMPLATEDIR)
+template_DATA = \
+ 10-autohint.conf \
+ 10-no-sub-pixel.conf \
+ 10-sub-pixel-bgr.conf \
+ 10-sub-pixel-rgb.conf \
+ 10-sub-pixel-vbgr.conf \
+ 10-sub-pixel-vrgb.conf \
+ 10-unhinted.conf \
+ 11-lcdfilter-default.conf \
+ 11-lcdfilter-legacy.conf \
+ 11-lcdfilter-light.conf \
+ 20-fix-globaladvance.conf \
+ 20-unhint-small-vera.conf \
+ 25-unhint-nonlatin.conf \
+ 30-urw-aliases.conf \
+ 30-metric-aliases.conf \
+ 40-nonlatin.conf \
+ 45-latin.conf \
+ 49-sansserif.conf \
+ 50-user.conf \
+ 51-local.conf \
+ 60-latin.conf \
+ 65-fonts-persian.conf \
+ 65-khmer.conf \
+ 65-nonlatin.conf \
+ 69-unifont.conf \
+ 70-no-bitmaps.conf \
+ 70-yes-bitmaps.conf \
+ 80-delicious.conf \
+ 90-synthetic.conf
install-data-local:
- mkdir -p ${DESTDIR}${confddir}
- @(echo cd ${DESTDIR}${confddir}; \
- cd ${DESTDIR}${confddir}; \
- for i in ${CONF_LINKS}; do \
- $(RM) $$i; \
- echo $(RM) $$i";" ln -s ../conf.avail/$$i .; \
- ln -s ../conf.avail/$$i .; \
- done)
+ mkdir -p $(DESTDIR)$(configdir)
+ @(echo cd $(DESTDIR)$(configdir); \
+ cd $(DESTDIR)$(configdir); \
+ for i in $(CONF_LINKS); do \
+ echo $(RM) $$i";" ln -s $(templatedir)/$$i .; \
+ $(RM) $$i; \
+ ln -s $(templatedir)/$$i .; \
+ done)
uninstall-local:
- @(echo cd ${DESTDIR}${confddir}; \
- cd ${DESTDIR}${confddir}; \
- for i in ${CONF_LINKS}; do \
- echo $(RM) $$i; \
- $(RM) $$i; \
- done)
+ @(echo cd $(DESTDIR)$(configdir); \
+ cd $(DESTDIR)$(configdir); \
+ for i in $(CONF_LINKS); do \
+ echo $(RM) $$i; \
+ $(RM) $$i; \
+ done)
diff --git a/fontconfig/configure.in b/fontconfig/configure.in
index e0aba1992..ea44c1422 100644
--- a/fontconfig/configure.in
+++ b/fontconfig/configure.in
@@ -63,6 +63,7 @@ AC_PROG_LN_S
AC_LIBTOOL_WIN32_DLL
AM_PROG_LIBTOOL
AC_PROG_MAKE_SET
+PKG_PROG_PKG_CONFIG
AC_MSG_CHECKING([for RM macro])
_predefined_rm=`make -p -f /dev/null 2>/dev/null|grep '^RM ='|sed -e 's/^RM = //'`
@@ -106,7 +107,11 @@ AM_CONDITIONAL(CROSS_COMPILING, test $cross_compiling = yes)
dnl ==========================================================================
-AC_ARG_WITH(arch, [ --with-arch=ARCH Force architecture to ARCH], arch="$withval", arch=auto)
+AC_ARG_WITH(arch,
+ [AC_HELP_STRING([--with-arch=ARCH],
+ [Force architecture to ARCH])],
+ ,
+ arch="$withval", arch=auto)
if test "x$arch" != xauto; then
AC_DEFINE_UNQUOTED([FC_ARCHITECTURE], "$arch", [Architecture prefix to use for cache file names])
@@ -166,20 +171,7 @@ AC_DEFINE_UNQUOTED(USE_ICONV,$use_iconv,[Use iconv.])
#
# Checks for FreeType
#
-
-AC_ARG_WITH(freetype-config, [ --with-freetype-config=PROG Use FreeType configuration program PROG], freetype_config=$withval, freetype_config=yes)
-
-if test "$freetype_config" = "yes"; then
- AC_PATH_PROG(ft_config,freetype-config,no)
- if test "$ft_config" = "no"; then
- AC_MSG_ERROR([You must have freetype installed; see http://www.freetype.org/])
- fi
-else
- ft_config="$freetype_config"
-fi
-
-FREETYPE_CFLAGS="`$ft_config --cflags`"
-FREETYPE_LIBS="`$ft_config --libs`"
+PKG_CHECK_MODULES(FREETYPE, freetype2)
AC_SUBST(FREETYPE_LIBS)
AC_SUBST(FREETYPE_CFLAGS)
@@ -202,123 +194,48 @@ LIBS="$fontconfig_save_libs"
#
# Check expat configuration
#
-
-AC_ARG_WITH(expat, [ --with-expat=DIR Use Expat in DIR], expat=$withval, expat=yes)
-AC_ARG_WITH(expat-includes, [ --with-expat-includes=DIR Use Expat includes in DIR], expat_includes=$withval, expat_includes=yes)
-AC_ARG_WITH(expat-lib, [ --with-expat-lib=DIR Use Expat library in DIR], expat_lib=$withval, expat_lib=yes)
-
if test "$enable_libxml2" != "yes"; then
- case "$expat" in
- no)
- ;;
- *)
- case "$expat_includes" in
- yes)
- case "$expat" in
- yes)
- ;;
- *)
- EXPAT_CFLAGS="-I$expat/include"
- ;;
- esac
- ;;
- no)
- EXPAT_CFLAGS=""
- ;;
- *)
- EXPAT_CFLAGS="-I$expat_includes"
- ;;
- esac
- case "$expat_lib" in
- yes)
- case "$expat" in
- yes)
- EXPAT_LIBS="-lexpat"
- ;;
- *)
- EXPAT_LIBS="-L$expat/lib -lexpat"
- ;;
- esac
- ;;
- no)
- ;;
- *)
- EXPAT_LIBS="-L$expat_lib -lexpat"
- ;;
- esac
-
- expatsaved_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $EXPAT_CFLAGS"
- expatsaved_LIBS="$LIBS"
- LIBS="$LIBS $EXPAT_LIBS"
-
- AC_CHECK_HEADER(expat.h)
- case "$ac_cv_header_expat_h" in
- no)
- AC_CHECK_HEADER(xmlparse.h)
- case "$ac_cv_header_xmlparse_h" in
- no)
- have_expat_header=no;
- ;;
- yes)
- HAVE_XMLPARSE_H=1
- AC_SUBST(HAVE_XMLPARSE_H)
- AC_DEFINE_UNQUOTED(HAVE_XMLPARSE_H,$HAVE_XMLPARSE_H,
+ # specify EXPAT_CFLAGS and/or EXPAT_LIBS if you like the old behavior
+ # with --with-expat-includes and --with-expat-lib.
+ PKG_CHECK_MODULES(EXPAT, expat)
+ expatsaved_CPPFLAGS="$CPPFLAGS"
+ expatsaved_LIBS="$LIBS"
+ CPPFLAGS="$CPPFLAGS $EXPAT_CFLAGS"
+ LIBS="$LIBS $EXPAT_LIBS"
+
+ AC_CHECK_HEADER(expat.h)
+ if test "$ac_cv_header_expat_h" = "no"; then
+ AC_CHECK_HEADER(xmlparse.h)
+ if test "$ac_cv_header_xmlparse_h" = "yes"; then
+ HAVE_XMLPARSE_H=1
+ AC_SUBST(HAVE_XMLPARSE_H)
+ AC_DEFINE_UNQUOTED(HAVE_XMLPARSE_H,$HAVE_XMLPARSE_H,
[Use xmlparse.h instead of expat.h])
- have_expat_header=yes
- ;;
- esac
- ;;
- yes)
- have_expat_header=yes
- ;;
- esac
- case "$have_expat_header" in
- no)
- expat=no
- ;;
- yes)
- AC_CHECK_FUNCS(XML_SetDoctypeDeclHandler)
- case "$ac_cv_func_XML_SetDoctypeDeclHandler" in
- yes)
- HAVE_EXPAT=1
- AC_SUBST(HAVE_EXPAT)
- AC_DEFINE_UNQUOTED(HAVE_EXPAT,$HAVE_EXPAT,
- [Found a useable expat library])
- ;;
- *)
- expat=no
- ;;
- esac
- ;;
- esac
- CPPFLAGS="$expatsaved_CPPFLAGS"
- LIBS="$expatsaved_LIBS"
- ;;
- esac
-
+ else
+ AC_MSG_ERROR([
+*** expat is required. or try to use --enable-libxml2])
+ fi
+ fi
+ AC_CHECK_FUNCS(XML_SetDoctypeDeclHandler)
+ if test "$ac_cv_func_XML_SetDoctypeDeclHandler" = "no"; then
+ AC_MSG_ERROR([
+*** expat is required. or try to use --enable-libxml2])
+ fi
+ CPPFLAGS="$expatsaved_CPPFLAGS"
+ LIBS="$expatsaved_LIBS"
+
AC_SUBST(EXPAT_CFLAGS)
AC_SUBST(EXPAT_LIBS)
-
- case "$expat" in
- no)
- EXPAT_CFLAGS=""
- EXPAT_LIBS=""
-
- AC_MSG_WARN([Cannot find usable expat library. Trying to use libxml2 as fallback.])
- ;;
- esac
fi
#
# Check libxml2 configuration
#
+AC_ARG_ENABLE(libxml2,
+ [AC_HELP_STRING([--enable-libxml2],
+ [Use libxml2 instead of Expat])])
-AC_ARG_ENABLE(libxml2, [ --enable-libxml2 Use libxml2 instead of Expat])
-
-PKG_PROG_PKG_CONFIG
-
-if test "$enable_libxml2" = "yes" -o "$expat" = "no"; then
+if test "$enable_libxml2" = "yes"; then
PKG_CHECK_MODULES([LIBXML2], [libxml-2.0 >= 2.6])
AC_DEFINE_UNQUOTED(ENABLE_LIBXML2,1,[Use libxml2 instead of Expat])
@@ -330,7 +247,10 @@ fi
# Set default font directory
#
-AC_ARG_WITH(default-fonts, [ --with-default-fonts=DIR Use fonts from DIR when config is busted], default_fonts="$withval", default_fonts=yes)
+AC_ARG_WITH(default-fonts,
+ [AC_HELP_STRING([--with-default-fonts=DIR],
+ [Use fonts from DIR when config is busted])],
+ default_fonts="$withval", default_fonts=yes)
case "$default_fonts" in
yes)
@@ -358,7 +278,10 @@ AC_SUBST(FC_DEFAULT_FONTS)
# with outline fonts; those with bitmaps can be added as desired in
# local.conf or ~/.fonts.conf
#
-AC_ARG_WITH(add-fonts, [ --with-add-fonts=DIR1,DIR2,...Find additional fonts in DIR1,DIR2,... ], add_fonts="$withval", add_fonts=yes)
+AC_ARG_WITH(add-fonts,
+ [AC_HELP_STRING([--with-add-fonts=DIR1,DIR2,...],
+ [Find additional fonts in DIR1,DIR2,... ])],
+ add_fonts="$withval", add_fonts=yes)
case "$add_fonts" in
yes)
@@ -409,7 +332,10 @@ AC_SUBST(FC_FONTPATH)
#
# Set default cache directory path
#
-AC_ARG_WITH(cache-dir, [ --with-cache-dir=DIR Use DIR to store cache files (default LOCALSTATEDIR/cache/fontconfig)], fc_cachedir="$withval", fc_cachedir=yes)
+AC_ARG_WITH(cache-dir,
+ [AC_HELP_STRING([--with-cache-dir=DIR],
+ [Use DIR to store cache files [default=LOCALSTATEDIR/cache/fontconfig]])],
+ fc_cachedir="$withval", fc_cachedir=yes)
case $fc_cachedir in
no|yes)
@@ -430,23 +356,72 @@ FC_FONTDATE=`LC_ALL=C date`
AC_SUBST(FC_FONTDATE)
-AC_ARG_WITH(confdir, [ --with-confdir=DIR Use DIR to store configuration files (default SYSCONFDIR/fonts)], confdir="$withval", confdir=yes)
-
#
-# Set CONFDIR and FONTCONFIG_PATH
+# Set configuration paths
#
-case "$confdir" in
+AC_ARG_WITH(templatedir,
+ [AC_HELP_STRING([--with-templatedir=DIR],
+ [Use DIR to store the configuration template files [default=DATADIR/fontconfig/conf.avail]])],
+ [templatedir="$withval"],
+ [templatedir=yes])
+AC_ARG_WITH(baseconfigdir,
+ [AC_HELP_STRING([--with-baseconfigdir=DIR],
+ [Use DIR to store the base configuration files [default=SYSCONFDIR/fonts]])],
+ [baseconfigdir="$withval"],
+ [baseconfigdir=yes])
+AC_ARG_WITH(configdir,
+ [AC_HELP_STRING([--with-configdir=DIR],
+ [Use DIR to store active configuration files [default=BASECONFIGDIR/conf.d]])],
+ [configdir="$withval"],
+ [configdir=yes])
+AC_ARG_WITH(xmldir,
+ [AC_HELP_STRING([--with-xmldir=DIR],
+ [Use DIR to store XML schema files [default=DATADIR/xml/fontconfig]])],
+ [xmldir="$withval"],
+ [xmldir=yes])
+
+case "$templatedir" in
no|yes)
- confdir='${sysconfdir}'/fonts
+ templatedir='${datadir}'/fontconfig/conf.avail
;;
*)
;;
esac
-AC_SUBST(confdir)
-CONFDIR=${confdir}
-AC_DEFINE_UNQUOTED(CONFDIR, "$CONFDIR",[Font configuration directory])
-AC_SUBST(CONFDIR)
+case "$baseconfigdir" in
+no|yes)
+ baseconfigdir='${sysconfdir}'/fonts
+ ;;
+*)
+ ;;
+esac
+case "$configdir" in
+no|yes)
+ configdir='${baseconfigdir}'/conf.d
+ ;;
+*)
+ ;;
+esac
+case "$xmldir" in
+no|yes)
+ xmldir='${datadir}'/xml/fontconfig
+ ;;
+*)
+ ;;
+esac
+
+TEMPLATEDIR=${templatedir}
+BASECONFIGDIR=${baseconfigdir}
+CONFIGDIR=${configdir}
+XMLDIR=${xmldir}
+AC_SUBST(templatedir)
+AC_SUBST(TEMPLATEDIR)
+AC_SUBST(baseconfigdir)
+AC_SUBST(BASECONFIGDIR)
+AC_SUBST(configdir)
+AC_SUBST(CONFIGDIR)
+AC_SUBST(xmldir)
+AC_SUBST(XMLDIR)
#
# Let people not build/install docs if they don't have docbook
@@ -468,7 +443,11 @@ if test x$HASDOCBOOK = xno; then
fi
fi
-AC_ARG_ENABLE(docs, [ --disable-docs Don't build and install documentation],,enable_docs=$default_docs)
+AC_ARG_ENABLE(docs,
+ [AC_HELP_STRING([--disable-docs],
+ [Don't build and install documentation])],
+ ,
+ enable_docs=$default_docs)
AM_CONDITIONAL(ENABLE_DOCS, test "x$enable_docs" = xyes)
diff --git a/fontconfig/doc/fontconfig-user.sgml b/fontconfig/doc/fontconfig-user.sgml
index d5da6c03a..14fdc79aa 100644
--- a/fontconfig/doc/fontconfig-user.sgml
+++ b/fontconfig/doc/fontconfig-user.sgml
@@ -392,8 +392,8 @@ build the fontconfig database.
<refsect2><title><literal>&lt;test qual="any" name="property" target="default" compare="eq"&gt;</literal></title><para>
This element contains a single value which is compared with the target
('pattern', 'font', 'scan' or 'default') property "property" (substitute any of the property names seen
-above). 'compare' can be one of "eq", "not_eq", "less", "less_eq", "more", or
-"more_eq". 'qual' may either be the default, "any", in which case the match
+above). 'compare' can be one of "eq", "not_eq", "less", "less_eq", "more", "more_eq", "contains" or
+"not_contains". 'qual' may either be the default, "any", in which case the match
succeeds if any value associated with the property matches the test value, or
"all", in which case all of the values associated with the property must
match the test value. When used in a &lt;match target="font"&gt; element,
@@ -510,7 +510,7 @@ elements. <literal>&lt;or&gt;</literal> and <literal>&lt;and&gt;</literal> are
</para>
</refsect2>
<refsect2>
- <title><literal>&lt;eq&gt;</literal>, <literal>&lt;not_eq&gt;</literal>, <literal>&lt;less&gt;</literal>, <literal>&lt;less_eq&gt;</literal>, <literal>&lt;more&gt;</literal>, <literal>&lt;more_eq&gt;</literal></title>
+ <title><literal>&lt;eq&gt;</literal>, <literal>&lt;not_eq&gt;</literal>, <literal>&lt;less&gt;</literal>, <literal>&lt;less_eq&gt;</literal>, <literal>&lt;more&gt;</literal>, <literal>&lt;more_eq&gt;</literal>, <literal>&lt;contains&gt;</literal>, <literal>&lt;not_contains</literal></title>
<para>
These elements compare two values, producing a boolean result.
</para></refsect2>
diff --git a/fontconfig/fonts.conf.in b/fontconfig/fonts.conf.in
index a17c01eeb..533381b9d 100644
--- a/fontconfig/fonts.conf.in
+++ b/fontconfig/fonts.conf.in
@@ -66,7 +66,7 @@
<!--
Load local system customization file
-->
- <include ignore_missing="yes">conf.d</include>
+ <include ignore_missing="yes">@CONFIGDIR@</include>
<!-- Font cache directory list -->
diff --git a/fontconfig/fonts.dtd b/fontconfig/fonts.dtd
index 5f072ee44..e1e8b7382 100644
--- a/fontconfig/fonts.dtd
+++ b/fontconfig/fonts.dtd
@@ -113,7 +113,7 @@
<!ATTLIST patelt
name CDATA #REQUIRED>
-<!ELEMENT alias (family*, prefer?, accept?, default?)>
+<!ELEMENT alias (test?, family*, prefer?, accept?, default?)>
<!ATTLIST alias
binding (weak|strong|same) "weak">
<!ELEMENT prefer (family)*>
diff --git a/fontconfig/src/Makefile.am b/fontconfig/src/Makefile.am
index fb30cd596..591fc1613 100644
--- a/fontconfig/src/Makefile.am
+++ b/fontconfig/src/Makefile.am
@@ -75,7 +75,7 @@ INCLUDES = \
$(EXPAT_CFLAGS) \
$(WARN_CFLAGS) \
-DFC_CACHEDIR='"$(FC_CACHEDIR)"' \
- -DFONTCONFIG_PATH='"$(CONFDIR)"'
+ -DFONTCONFIG_PATH='"$(BASECONFIGDIR)"'
EXTRA_DIST = makealias
diff --git a/fontconfig/src/fcxml.c b/fontconfig/src/fcxml.c
index c55debec1..b8701470c 100644
--- a/fontconfig/src/fcxml.c
+++ b/fontconfig/src/fcxml.c
@@ -1579,7 +1579,7 @@ FcParseAlias (FcConfigParse *parse)
FcExpr *family = 0, *accept = 0, *prefer = 0, *def = 0, *new = 0;
FcEdit *edit = 0, *next;
FcVStack *vstack;
- FcTest *test;
+ FcTest *test = NULL;
FcValueBinding binding;
if (!FcConfigLexBinding (parse, FcConfigGetAttribute (parse, "binding"), &binding))
@@ -1622,6 +1622,11 @@ FcParseAlias (FcConfigParse *parse)
def = vstack->u.expr;
vstack->tag = FcVStackNone;
break;
+ case FcVStackTest:
+ vstack->u.test->next = test;
+ test = vstack->u.test;
+ vstack->tag = FcVStackNone;
+ break;
default:
FcConfigMessage (parse, FcSevereWarning, "bad alias");
break;
@@ -1679,11 +1684,21 @@ FcParseAlias (FcConfigParse *parse)
}
if (edit)
{
- test = FcTestCreate (parse, FcMatchPattern,
- FcQualAny,
- (FcChar8 *) FC_FAMILY,
- FcOpEqual,
- family);
+ FcTest *t = FcTestCreate (parse, FcMatchPattern,
+ FcQualAny,
+ (FcChar8 *) FC_FAMILY,
+ FcOpEqual,
+ family);
+ if (test)
+ {
+ FcTest *p = test;
+
+ while (p->next)
+ p = p->next;
+ p->next = t;
+ }
+ else
+ test = t;
if (test)
if (!FcConfigAddEdit (parse->config, test, edit, FcMatchPattern))
FcTestDestroy (test);