This is the mail archive of the cygwin-xfree@cygwin.com mailing list for the Cygwin XFree86 project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Can Not Install Font Packages


On Mon, 20 Oct 2003, Harold L Hunt II wrote:

> Igor,
>
> Igor Pechtchanski wrote:
>
> > Well, I was thinking of /etc/postinstall or /etc/preremove as the location
> > for these files anyway...  Frankly, I didn't think of checking the scripts
> > themselves - this might work just as well, and eliminates the need for
> > extra files.
>
> Heh heh... my laziness comes in handy.
>
>  > The only thing is that this constrains the package names for
> > X fonts, so if a new one is added, its package name will either have to
> > follow the same pattern or be added to the lists in all the other
> > packages, whereas with the separate files, we control the names...
>
> I don't think there has been a new font package in over 5 years, or
> possibly longer.  In any case, there will not be a new font package
> added within a major release, only between major releases, so this
> should be a non-issue.  When a major release is made the font packages
> all get replaced, so we could freshen the scripts at that point if need be.
> [snip]
>
> Harold

Great.  So the postinstall and preremove code will look something like
this:
-------------------------- Begin fonts-preremove.sh --------------------------
#!/bin/sh

FONTDIR=/usr/X11R6/lib/X11/fonts
ALLSCRIPTS="`echo /etc/preremove/XFree86-f*.sh`"

# Check if we're the last script running, and if so, umount the fonts dir
if [ "$ALLSCRIPTS" == "$0" ]; then
  umount -s $FONTDIR 2>/dev/null || umount -u $FONTDIR
fi
------------- Note: cutting here may damage your screen surface --------------

BTW, the postinstall scripts should be fixed, too, as they won't unmount
the system-mounted fonts directory (see below).  HTH,
	Igor

--- XFree86-fnts.sh~    2003-08-01 00:41:22.000000000 -0400
+++ XFree86-fnts.sh     2003-10-20 17:44:42.536752000 -0400
@@ -8,7 +8,7 @@ FONTDIR=/usr/X11R6/lib/X11/fonts
 # Unmounting will cause the root mount or /usr mount to
 # be used to resolve the path to /usr/X11R6/lib/X11/fonts,
 # which should point to the actual fonts directory.
-umount -u $FONTDIR 2>/dev/null
+umount -s $FONTDIR 2>/dev/null || umount -u $FONTDIR 2>/dev/null

 # Get the path to the actual fonts directory
 WFONTDIR=`cygpath -w $FONTDIR`

-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha@cs.nyu.edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor@watson.ibm.com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"I have since come to realize that being between your mentor and his route
to the bathroom is a major career booster."  -- Patrick Naughton


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]