Add pkgconfig control file and fontconfig-config script
This commit is contained in:
parent
1c20b1cc0b
commit
2eafe0904d
17
INSTALL
17
INSTALL
|
@ -1,3 +1,14 @@
|
|||
The configuration files (fonts.conf, fonts.dtd) go in a new directory
|
||||
/etc/fonts, the install step doesn't current create this directory or copy
|
||||
the config files.
|
||||
You can build fontconfig with either autoconf or imake.
|
||||
|
||||
For autoconf:
|
||||
|
||||
$ sh cvscompile.sh --sysconfdir=/etc --prefix=/usr
|
||||
|
||||
For imake:
|
||||
$ xmkmf -a
|
||||
|
||||
These should both generate valid Makefiles, in either case:
|
||||
|
||||
$ make
|
||||
$ make install
|
||||
|
||||
|
|
33
Imakefile
33
Imakefile
|
@ -1,4 +1,4 @@
|
|||
XCOMM $XFree86$
|
||||
XCOMM $XFree86: xc/lib/fontconfig/Imakefile,v 1.3 2002/05/21 17:08:41 keithp Exp $
|
||||
|
||||
#define IHaveSubdirs
|
||||
#define PassCDebugFlags
|
||||
|
@ -7,12 +7,20 @@ LINTSUBDIRS=src fc-cache fc-list
|
|||
|
||||
SUBDIRS=fontconfig $(LINTSUBDIRS)
|
||||
|
||||
FONTCONFIG_REVISION=1
|
||||
|
||||
#ifndef FontconfigDir
|
||||
#define FontconfigDir /etc/fonts
|
||||
#endif
|
||||
|
||||
FONTCONFIGDIR=FontconfigDir
|
||||
|
||||
SUBSTVARS=prefix=$(PROJECTROOT) \
|
||||
exec_prefix=$(BINDIR) \
|
||||
libdir=$(USRLIBDIR) \
|
||||
includedir=$(INCROOT) \
|
||||
PACKAGE_VERSION=$(SOFONTCONFIGREV).$(FONTCONFIG_REVISION)
|
||||
|
||||
MakeSubdirs($(SUBDIRS))
|
||||
DependSubdirs($(SUBDIRS))
|
||||
MakeLintLibSubdirs($(LINTSUBDIRS))
|
||||
|
@ -29,3 +37,26 @@ fonts.conf: fonts.conf.in
|
|||
|
||||
clean::
|
||||
RemoveFile(fonts.conf)
|
||||
|
||||
all:: fontconfig-config.script
|
||||
|
||||
fontconfig-config.script: fontconfig-config.in
|
||||
RemoveFile($@)
|
||||
sh config/config-subst $(SUBSTVARS) < $< > $@
|
||||
|
||||
InstallScript(fontconfig-config,$(BINDIR))
|
||||
|
||||
clean::
|
||||
RemoveFile(fontconfig-config.script)
|
||||
|
||||
all:: fontconfig.pc
|
||||
|
||||
fontconfig.pc: fontconfig.pc.in
|
||||
RemoveFile($@)
|
||||
sh config/config-subst $(SUBSTVARS) < $< > $@
|
||||
|
||||
InstallNonExecFile(fontconfig.pc,$(USRLIBDIR)/pkgconfig)
|
||||
|
||||
clean::
|
||||
RemoveFile(fontconfig.pc)
|
||||
|
||||
|
|
18
Makefile.in
18
Makefile.in
|
@ -1,5 +1,5 @@
|
|||
#
|
||||
# $XFree86$
|
||||
# $XFree86: xc/lib/fontconfig/Makefile.in,v 1.2 2002/05/21 17:48:15 keithp Exp $
|
||||
#
|
||||
# Copyright © 2002 Keith Packard, member of The XFree86 Project, Inc.
|
||||
#
|
||||
|
@ -22,7 +22,9 @@
|
|||
# PERFORMANCE OF THIS SOFTWARE.
|
||||
#
|
||||
|
||||
DEPTH = .
|
||||
TOPDIR = .
|
||||
|
||||
include $(TOPDIR)/config/Makedefs
|
||||
|
||||
DIRS = src fc-cache fc-list fontconfig
|
||||
|
||||
|
@ -50,3 +52,15 @@ $(CONFDIR)/fonts.dtd:: fonts.dtd
|
|||
clean::
|
||||
rm -f fonts.conf
|
||||
|
||||
install:: $(BINDIR)/fontconfig-config
|
||||
|
||||
$(BINDIR)/fontconfig-config: fontconfig-config
|
||||
$(INSTALL_SCRIPT) $< $(BINDIR)
|
||||
|
||||
install:: $(LIBDIR)/pkgconfig $(LIBDIR)/pkgconfig/fontconfig.pc
|
||||
|
||||
$(LIBDIR)/pkgconfig:
|
||||
mkdir -p $@
|
||||
|
||||
$(LIBDIR)/pkgconfig/fontconfig.pc: fontconfig.pc
|
||||
$(INSTALL_DATA) $< $(LIBDIR)/pkgconfig
|
||||
|
|
13
README
13
README
|
@ -1,2 +1,15 @@
|
|||
Fontconfig
|
||||
Font configuration and customization library
|
||||
Version 1.0.1
|
||||
2002-5-23
|
||||
|
||||
This is the first public release of fontconfig, a font configuration and
|
||||
customization library. Fontconfig is designed to locate fonts within the
|
||||
system and select them according to requirements specified by applications.
|
||||
|
||||
Fontconfig is not a rasterization library, nor does it impose a particular
|
||||
rasterization library on the application. The X-specific library
|
||||
'Xft' uses fontconfig along with freetype to specify and rasterize fonts.
|
||||
|
||||
Keith Packard
|
||||
keithp@keithp.com
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
#!/bin/sh
|
||||
exprs=""
|
||||
for i in ${1+"$@"}; do
|
||||
var="`echo $i | sed 's/=.*$//'`"
|
||||
val="`echo $i | sed 's/^[^=]*=//'`"
|
||||
exprs="$exprs -e s;@$var@;$val;"
|
||||
done
|
||||
sed $exprs
|
18
configure.in
18
configure.in
|
@ -1,5 +1,5 @@
|
|||
dnl
|
||||
dnl $XFree86: xc/lib/fontconfig/configure.in,v 1.2 2002/05/21 17:08:42 keithp Exp $
|
||||
dnl $XFree86: xc/lib/fontconfig/configure.in,v 1.3 2002/05/21 17:48:15 keithp Exp $
|
||||
dnl
|
||||
dnl Copyright © 2002 Keith Packard, member of The XFree86 Project, Inc.
|
||||
dnl
|
||||
|
@ -50,6 +50,7 @@ PACKAGE_VERSION=1.0.1
|
|||
PACKAGE_MAJOR=`echo $PACKAGE_VERSION | awk -F . '{ print $1 }'`
|
||||
PACKAGE_MINOR=`echo $PACKAGE_VERSION | awk -F . '{ print $2 }'`
|
||||
PACKAGE_REVISION=`echo $PACKAGE_VERSION | awk -F . '{ print $3 }'`
|
||||
AC_SUBST(PACKAGE_VERSION)
|
||||
AC_SUBST(PACKAGE_MAJOR)
|
||||
AC_SUBST(PACKAGE_MINOR)
|
||||
AC_SUBST(PACKAGE_REVISION)
|
||||
|
@ -119,20 +120,20 @@ esac
|
|||
|
||||
case "$freetype_includes" in
|
||||
no)
|
||||
freetype_includes=""
|
||||
FREETYPE_CFLAGS=""
|
||||
;;
|
||||
yes)
|
||||
case "$ft_config" in
|
||||
no)
|
||||
freetype_includes=""
|
||||
FREETYPE_CFLAGS=""
|
||||
;;
|
||||
*)
|
||||
freetype_includes="`$ft_config --cflags`"
|
||||
FREETYPE_CFLAGS="`$ft_config --cflags`"
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
*)
|
||||
freetype_includes="-I$freetype_includes"
|
||||
FREETYPE_CFLAGS="-I$freetype_includes"
|
||||
;;
|
||||
esac
|
||||
|
||||
|
@ -158,7 +159,7 @@ esac
|
|||
saved_LIBS="$LIBS"
|
||||
LIBS="$LIBS $freetype_lib"
|
||||
saved_CPPFLAGS="$CPPFLAGS"
|
||||
CPPFLAGS="$CPPFLAGS $freetype_includes"
|
||||
CPPFLAGS="$CPPFLAGS $FREETYPE_CFLAGS"
|
||||
AC_CHECK_HEADERS(freetype/freetype.h)
|
||||
|
||||
case "$ac_cv_header_freetype_freetype_h" in
|
||||
|
@ -175,6 +176,7 @@ yes)
|
|||
;;
|
||||
yes)
|
||||
AC_DEFINE(HAVE_FREETYPE)
|
||||
AC_SUBST(FREETYPE_CFLAGS)
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
|
@ -373,5 +375,7 @@ AC_OUTPUT([Makefile
|
|||
src/Makefile
|
||||
fc-cache/Makefile
|
||||
fc-list/Makefile
|
||||
fontconfig/Makefile])
|
||||
fontconfig/Makefile
|
||||
fontconfig.pc
|
||||
fontconfig-config])
|
||||
|
||||
|
|
|
@ -0,0 +1,94 @@
|
|||
#! /bin/sh
|
||||
|
||||
prefix=@prefix@
|
||||
exec_prefix=@exec_prefix@
|
||||
libdir=@libdir@
|
||||
includedir=@includedir@
|
||||
version=@PACKAGE_VERSION@
|
||||
|
||||
usage()
|
||||
{
|
||||
cat <<EOF
|
||||
Usage: fontconfig-config [OPTIONS] [LIBRARIES]
|
||||
Options:
|
||||
[--prefix[=DIR]]
|
||||
[--exec-prefix[=DIR]]
|
||||
[--version]
|
||||
[--libs]
|
||||
[--cflags]
|
||||
EOF
|
||||
exit $1
|
||||
}
|
||||
|
||||
if test $# -eq 0 ; then
|
||||
usage 1 1>&2
|
||||
fi
|
||||
|
||||
while test $# -gt 0 ; do
|
||||
case "$1" in
|
||||
-*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
|
||||
*) optarg= ;;
|
||||
esac
|
||||
|
||||
case $1 in
|
||||
--prefix=*)
|
||||
prefix=$optarg
|
||||
local_prefix=yes
|
||||
;;
|
||||
--prefix)
|
||||
echo_prefix=yes
|
||||
;;
|
||||
--exec-prefix=*)
|
||||
exec_prefix=$optarg
|
||||
exec_prefix_set=yes
|
||||
local_prefix=yes
|
||||
;;
|
||||
--exec-prefix)
|
||||
echo_exec_prefix=yes
|
||||
;;
|
||||
--version)
|
||||
echo $version
|
||||
exit 0
|
||||
;;
|
||||
--cflags)
|
||||
echo_cflags=yes
|
||||
;;
|
||||
--libs)
|
||||
echo_libs=yes
|
||||
;;
|
||||
*)
|
||||
usage 1 1>&2
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
done
|
||||
|
||||
if test "$local_prefix" = "yes" ; then
|
||||
if test "$exec_prefix_set" != "yes" ; then
|
||||
exec_prefix=$prefix
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "$echo_prefix" = "yes" ; then
|
||||
echo $prefix
|
||||
fi
|
||||
|
||||
if test "$echo_exec_prefix" = "yes" ; then
|
||||
echo $exec_prefix
|
||||
fi
|
||||
|
||||
if test "$echo_cflags" = "yes" ; then
|
||||
cflags="-I${includedir}"
|
||||
echo $cflags
|
||||
fi
|
||||
|
||||
if test "$echo_libs" = "yes" ; then
|
||||
libs="-lfontconfig"
|
||||
if test "${libdir}" != "/usr/lib" ; then
|
||||
echo -L${libdir} $libs
|
||||
else
|
||||
echo $libs
|
||||
fi
|
||||
fi
|
||||
|
||||
# EOF
|
|
@ -0,0 +1,11 @@
|
|||
prefix=@prefix@
|
||||
exec_prefix=@exec_prefix@
|
||||
libdir=@libdir@
|
||||
includedir=@includedir@
|
||||
|
||||
Name: Fontconfig
|
||||
Description: Font configuration and customization library
|
||||
Version: @PACKAGE_VERSION@
|
||||
Requires: freetype2
|
||||
Libs: -L${libdir} -lfontconfig
|
||||
Cflags: -I${includedir}
|
Loading…
Reference in New Issue