From owner-freebsd-ports Fri Jan 31 09:36:59 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id JAA02865 for ports-outgoing; Fri, 31 Jan 1997 09:36:59 -0800 (PST) Received: from Sisyphos.MI.Uni-Koeln.DE (Sisyphos.MI.Uni-Koeln.DE [134.95.212.10]) by freefall.freebsd.org (8.8.5/8.8.5) with SMTP id JAA02848; Fri, 31 Jan 1997 09:36:39 -0800 (PST) Received: from x14.mi.uni-koeln.de (annexr3-10.slip.Uni-Koeln.DE) by Sisyphos.MI.Uni-Koeln.DE with SMTP id AA05236 (5.67b/IDA-1.5); Fri, 31 Jan 1997 18:36:36 +0100 Received: (from se@localhost) by x14.mi.uni-koeln.de (8.8.5/8.6.9) id SAA02920; Fri, 31 Jan 1997 18:36:07 +0100 (CET) Message-Id: <19970131183447.YM13263@x14.mi.uni-koeln.de> Date: Fri, 31 Jan 1997 18:34:47 +0100 From: se@freebsd.org (Stefan Esser) To: asami@vader.cs.berkeley.edu (Satoshi Asami) Cc: ports@freebsd.org, committers@freebsd.org Subject: Re: review request: pkgdir handling improved References: <199701310821.AAA09630@silvia.HIP.Berkeley.EDU> X-Mailer: Mutt 0.59-PL19 Mime-Version: 1.0 In-Reply-To: <199701310821.AAA09630@silvia.HIP.Berkeley.EDU>; from Satoshi Asami on Jan 31, 1997 00:21:02 -0800 Sender: owner-ports@freebsd.org X-Loop: FreeBSD.org Precedence: bulk On Jan 31, asami@vader.cs.berkeley.edu (Satoshi Asami) wrote: > Please review. Highlights: > > (1) Moved /var/db/pkg/${PKGNAME} existence check to beginning of > install target and make the failure fatal (and also suggest a > workaround in case pkg_delete doesn't work). Hmmm, no, I don't like this! Re-installing a port of the same revision is most often necessary because of interface changes (kernel structs or wtmp, for example). The new install will just overwrite existing files in place, and nothing needs to be done to register that package anew. (Although there surely exists the possibility, that the port has been modified to conform to a different directory tree layout, as happened for WWW related ports, a few weeks ago.) I do care much more for the case of an upgraded port being installed without the previous version having been removed. This may be a bad idea, since a later pkg_delete of the old port may throw away files from the new one. My proposal would be to have TWO pkg_delete modes: One that deletes everything (including log files created in some /var sub-directory), while the other one does keep log files and possibly config files intact. (Files must be tagged as PRECIOUS in the PLIST, if they are to be kept in the "partial delete" case. The "partial delete" function could be used before the install, and could both remove a previous release, or an earlier compile of the same release of a port. I thoght we once discussed the addition of MD5 checksums to +CONTENTS files, to be sure the file to be deleted was not locally updated in the mean-time ? But even this does not protect against a pkg_delete of an old release removing vital files required for the new one, that did not change between these two releases (and thus kept their MD5) ... Regards, STefan