X Strike Force X.Org X11 SVN commit: r2318 - in trunk/font/xfonts-utils/debian: . local
Author: vorlon
Date: 2006-06-12 05:09:28 -0400 (Mon, 12 Jun 2006)
New Revision: 2318
Modified:
trunk/font/xfonts-utils/debian/changelog
trunk/font/xfonts-utils/debian/local/update-fonts-dir
Log:
Update update-fonts-dir to operate on both the old and new font
paths, regardless of arguments passed, to allow automatic clean-up
of the old fonts.dir files. Closes: #372858.
Modified: trunk/font/xfonts-utils/debian/changelog
===================================================================
--- trunk/font/xfonts-utils/debian/changelog 2006-06-12 08:16:24 UTC (rev 2317)
+++ trunk/font/xfonts-utils/debian/changelog 2006-06-12 09:09:28 UTC (rev 2318)
@@ -1,3 +1,16 @@
+xfonts-utils (1:1.0.0-5) UNRELEASED; urgency=medium
+
+ * Urgency=medium to fix a bug that's been wreaking havoc on gtk1.2
+ users' fonts for a while now...
+ * Further fixes to update-fonts-scale to ensure we *remove* any
+ old files in the event that there are no longer fonts with which to
+ populate fonts.scale.
+ * Also update update-fonts-dir to operate on both the old and new font
+ paths, regardless of arguments passed, to allow automatic clean-up
+ of the old fonts.dir files. Closes: #372858.
+
+ -- Steve Langasek <vorlon@debian.org> Mon, 12 Jun 2006 00:23:34 -0700
+
xfonts-utils (1:1.0.0-4) unstable; urgency=low
[ Steve Langasek ]
Modified: trunk/font/xfonts-utils/debian/local/update-fonts-dir
===================================================================
--- trunk/font/xfonts-utils/debian/local/update-fonts-dir 2006-06-12 08:16:24 UTC (rev 2317)
+++ trunk/font/xfonts-utils/debian/local/update-fonts-dir 2006-06-12 09:09:28 UTC (rev 2318)
@@ -87,49 +87,47 @@
# Try to be clever about the argument; were we given an absolute path?
if expr "$1" : "/.*" >/dev/null 2>&1; then
# Yes; an absolute path to an X font directory was provided.
- XDIR=$1
+ XDIRS=$1
if [ -n "$X11R7_LAYOUT" ]; then
- ETCDIR=/etc/X11/fonts/X11R7/${XDIR##*/}
+ ETCDIR=/etc/X11/fonts/X11R7/${XDIRS##*/}
else
- ETCDIR=/etc/X11/fonts/${XDIR##*/}
+ ETCDIR=/etc/X11/fonts/${XDIRS##*/}
fi
- if [ "$XDIR" = "$ETCDIR" ]; then
+ if [ "$XDIRS" = "$ETCDIR" ]; then
# We were given an /etc directory as an argument.
die "path to X font directory must be used"
else
- warn "absolute path $XDIR was provided"
+ warn "absolute path $XDIRS was provided"
fi
else
# No; a relative path was provided -- assume we were given just the
# basename.
- if [ -n "$X11R7_LAYOUT" ]; then
- XDIR=/usr/share/fonts/X11/$1
- else
- XDIR=/usr/lib/X11/fonts/$1
- fi
+ XDIRS="/usr/share/fonts/X11/$1 /usr/lib/X11/fonts/$1"
fi
# Confirm that the directories to be operated on exist.
- VALID=yes
- if ! [ -d "$XDIR" ]; then
- warn "$XDIR does not exist or is not a directory"
- VALID=
- fi
- if [ -n "$VALID" ]; then
- # Use encoding directories if they are available.
- if [ -d "$ENCDIR" ] && [ -d "$ENCDIR/large" ]; then
- mkfontdir -e "$ENCDIR" -e "$ENCDIR/large" "$XDIR"
- else
- mkfontdir "$XDIR"
+ for XDIR in XDIRS; do
+ VALID=yes
+ if ! [ -d "$XDIR" ]; then
+ warn "$XDIR does not exist or is not a directory"
+ VALID=
fi
- # Are there any fonts in the font directory?
- if [ "$(head -n 1 "$XDIR/fonts.dir")" = "0" ]; then
- # There are no files to process; remove any generated files already
- # in the font directory.
- rm -f "$XDIR/fonts.dir" "$XDIR/encodings.dir"
- # Remove the font dirextory if it is empty.
- rmdir "$XDIR" >/dev/null 2>&1 || true
+ if [ -n "$VALID" ]; then
+ # Use encoding directories if they are available.
+ if [ -d "$ENCDIR" ] && [ -d "$ENCDIR/large" ]; then
+ mkfontdir -e "$ENCDIR" -e "$ENCDIR/large" "$XDIR"
+ else
+ mkfontdir "$XDIR"
+ fi
+ # Are there any fonts in the font directory?
+ if [ "$(head -n 1 "$XDIR/fonts.dir")" = "0" ]; then
+ # There are no files to process; remove any generated files already
+ # in the font directory.
+ rm -f "$XDIR/fonts.dir" "$XDIR/encodings.dir"
+ # Remove the font dirextory if it is empty.
+ rmdir "$XDIR" >/dev/null 2>&1 || true
+ fi
fi
- fi
+ done
shift
done
Reply to: