diff options
author | joerg <joerg@pkgsrc.org> | 2006-09-22 21:53:56 +0000 |
---|---|---|
committer | joerg <joerg@pkgsrc.org> | 2006-09-22 21:53:56 +0000 |
commit | 716af82c157277616441a354915b214b97609789 (patch) | |
tree | db83b25b7768e178196b801eef79294cee44fa06 /mk/pkginstall | |
parent | 12a5b25dfd60c6edc39d87d387e37d8aa0ca77d7 (diff) | |
download | pkgsrc-716af82c157277616441a354915b214b97609789.tar.gz |
- Compute CHEKCK_FILES filter on the entries requested and keep it
as tight as possible. Files we don't handle shouldn't be skipped.
- fonts.alias is not created automatically, so don't remove it.
- create fonts.encoding with mkfontdir using -e X11_ENCODINGSDIR.
On platforms not following the X11R6 loayout this might need to
be overriden.
- Fix type1inst calls.
- Modify packages which installed fonts.alias before to actually
include it in the PLIST and bump the revisions accordingly.
- Modify xorg-fonts* packages to use FONTS_DIRS.* to build indices
at run time.
Discussed with wiz and jlam.
Diffstat (limited to 'mk/pkginstall')
-rw-r--r-- | mk/pkginstall/bsd.pkginstall.mk | 4 | ||||
-rw-r--r-- | mk/pkginstall/fonts | 18 |
2 files changed, 15 insertions, 7 deletions
diff --git a/mk/pkginstall/bsd.pkginstall.mk b/mk/pkginstall/bsd.pkginstall.mk index ab41bfc9b6b..c2daca46614 100644 --- a/mk/pkginstall/bsd.pkginstall.mk +++ b/mk/pkginstall/bsd.pkginstall.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkginstall.mk,v 1.14 2006/07/19 18:05:35 jlam Exp $ +# $NetBSD: bsd.pkginstall.mk,v 1.15 2006/09/22 21:53:58 joerg Exp $ # # This Makefile fragment is included by bsd.pkg.mk and implements the # common INSTALL/DEINSTALL scripts framework. To use the pkginstall @@ -700,6 +700,8 @@ USE_TOOLS+= mkfontdir:run FILES_SUBST+= MKFONTDIR=${TOOLS_PATH.mkfontdir:Q} .endif +FILES_SUBST+= X11_ENCODINGSDIR=${X11_ENCODINGSDIR:Q} + ${_INSTALL_FONTS_DATAFILE}: ${_PKG_SILENT}${_PKG_DEBUG}${MKDIR} ${.TARGET:H} ${_PKG_SILENT}${_PKG_DEBUG}${_FUNC_STRIP_PREFIX}; \ diff --git a/mk/pkginstall/fonts b/mk/pkginstall/fonts index e60dd268faf..e57a316c126 100644 --- a/mk/pkginstall/fonts +++ b/mk/pkginstall/fonts @@ -1,4 +1,4 @@ -# $NetBSD: fonts,v 1.2 2006/07/19 22:26:26 jlam Exp $ +# $NetBSD: fonts,v 1.3 2006/09/22 21:53:58 joerg Exp $ # # Generate a +FONTS script that updates font databases for the package. # @@ -37,6 +37,7 @@ TEST="@TEST@" TRUE="@TRUE@" TTMKFDIR="@TTMKFDIR@" TYPE1INST="@TYPE1INST@" +X11_ENCODINGSDIR="@X11_ENCODINGSDIR@" SELF=$0 @@ -74,19 +75,24 @@ ${SED} -n "/^\# FONTS: /{s/^\# FONTS: //;p;}" ${SELF} | ${SORT} -u | esac ( ${ECHO} " $dir ($font_type)" cd $dir + update_args= + post_update_cmd= case $font_type in [tT][tT][fF]) update_cmd="${TTMKFDIR}" ;; - [tT][yY][pP][eE]1) update_cmd="${TYPE1INST}; ${RM} type1inst.log" ;; - [xX]11) update_cmd="${MKFONTDIR}" ;; + [tT][yY][pP][eE]1) update_cmd="${TYPE1INST}" + post_update_cmd="${RM} type1inst.log" ;; + [xX]11) update_cmd="${MKFONTDIR}" + [ ! -z "${X11_ENCODINGSDIR}" ] && update_args="-e ${X11_ENCODINGSDIR}" ;; esac ${TEST} -f "$update_cmd" || update_cmd="${TRUE}" - $update_cmd >/dev/null + $update_cmd $update_args >/dev/null + $post_update_cmd # # Remove fonts databases if there are no fonts in the directory. - # We filter out the encodings.dir, fonts.{alias,dirs,scale}, and + # We filter out the encodings.dir, fonts.{dirs,scale}, and # Fontmap database files from the directory listing. # - ${FIND} . -type f | ${GREP} -v "/encodings.dir" | ${GREP} -v "/fonts\." | ${GREP} -v "/Fontmap" >/dev/null || ${RM} -f fonts.* Fontmap* + ${FIND} . -type f | ${GREP} -v "/encodings.dir" | ${GREP} -v "/fonts\.scale" | ${GREP} -v "/fonts\.dir" | ${GREP} -v "/Fontmap" >/dev/null || ${RM} -f fonts.dir fonts.scale Fontmap* encodings.dir > /dev/null ) done case "$printed_header" in |