This is the mail archive of the
cygwin-apps@cygwin.com
mailing list for the Cygwin project.
Re: setup.exe remove scripts [Was: Re: experimental texmf packages]
- From: "Robert Collins" <robert dot collins at itdomain dot com dot au>
- To: "Jan Nieuwenhuizen" <janneke at gnu dot org>
- Cc: <cygwin-apps at sources dot redhat dot com>
- Date: Thu, 3 Jan 2002 23:36:07 +1100
- Subject: Re: setup.exe remove scripts [Was: Re: experimental texmf packages]
- References: <m3bshtmxhb.fsf@appel.lilypond.org><878764062.20011128173421@nyckelpiga.de><m37ks9lgxi.fsf@appel.lilypond.org><4434079433.20011129221637@familiehaase.de><m3oflgy98n.fsf@appel.lilypond.org><9517228633.20011203135833@familiehaase.de><m3lmgkwgeu.fsf@appel.lilypond.org> <3C0D8535.D67735D1@ece.gatech.edu><m33d2pam3l.fsf@appel.lilypond.org><00d501c17d93$1936c990$0200a8c0@lifelesswks><m3zo4x7obb.fsf@appel.lilypond.org><m38zcdssxd.fsf@appel.lilypond.org><01a801c18036$3d447350$0200a8c0@lifelesswks><m3itbhqowz.fsf@appel.lilypond.org><027001c18040$c91651f0$0200a8c0@lifelesswks><m3wuzth3l1.fsf@appel.lilypond.org><04db01c18302$e66cae60$0200a8c0@lifelesswks><m3667ax540.fsf@appel.lilypond.org><105201c18604$ea001670$0200a8c0@lifelesswks><m366779lms.fsf@appel.lilypond.org><m3pu4s73f2.fsf@appel.lilypond.org><097401c1944b$de1aa230$0200a8c0@lifelesswks> <m3ell7pr6b.fsf@appel.lilypond.org>
Redirected to cygwin-apps.
----- Original Message -----
From: "Jan Nieuwenhuizen" <janneke@gnu.org>
Sent: Thursday, January 03, 2002 11:14 PM
Subject: Re: setup.exe remove scripts [Was: Re: experimental texmf
packages]
> "Robert Collins" <robert.collins@itdomain.com.au> writes:
>
> > Right, this is now in CVS> Sorry about the muckup.
>
> Ok, thanks, it's there.
>
> How should errors in postinstall scripts be handled? It is tempting
> to replace
>
> postinstall.cc:
> find (cygpath ("/etc/postinstall", 0),
run_script_in_etc_postinstall);
>
> with something vaguely like
>
> for (size_t n = 1; n <= db.packages.number (); n++)
> if (try_run_script ("/etc/postinstall/", name))
> warning ("postinstall of %s failed"
> "please examine or rerun /etc/postinstall/%s.sh
manually",
> name, name));
>
> But, afaik, there's no need for a package's postinstall script to be
> called '<pkg->name>.sh'? Should/can we enforce something like this?
We could, but there is a more general way that is more flexible and
equally effective:
The extraction process should note special files (ie anything in
/etc/postinstall) and associate that with the package object. This
solves postinstall script name guessing, and persistent storage of the
same solves removal script naming guesswork. As package files are
currently stored in gzipped flat file format, you can achieve the same
result for removal scripts by parsing the package file list.
Long term: This whole process need to be encapsulated in objects, and
then converted to a database (preferrable dpkg or rpm compatible).
Rob