From owner-freebsd-ports Sun Sep 10 9:37:14 2000 Delivered-To: freebsd-ports@freebsd.org Received: from bowhill.yi.org (bowhill.yi.org [216.122.158.78]) by hub.freebsd.org (Postfix) with ESMTP id D873C37B424; Sun, 10 Sep 2000 09:37:11 -0700 (PDT) Received: from localhost (kosmos@localhost) by bowhill.yi.org (8.11.0/8.11.0) with ESMTP id e8AGawc97572; Sun, 10 Sep 2000 09:36:59 -0700 (PDT) (envelope-from kosmos@bowhill.yi.org) Date: Sun, 10 Sep 2000 09:36:58 -0700 (PDT) From: kosmos To: Satoshi - Ports Wraith - Asami Cc: Steve Price , Will Andrews , FreeBSD Ports Subject: Re: PortsNG (was Re: Ports Options Paper) In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On 10 Sep 2000, Satoshi - Ports Wraith - Asami wrote: > * From: kosmos > > * How about an extended deinstall target (like: deinstall tree) that > * deletes orphaned dependencies of a port? > * > * Suppose FOO has dependencies BAR_1, BAR_2 and BAR_3. Another installed > * package, FOO_2 depends on BAR_2 and BAR_4. > * > * If I run this extended deinstall target on FOO, BAR_1 and BAR_3 get > * deinstalled too, becuase nothing else depends on them. BAR_2 gets > * left alone. > > Actually I added a "deinstall-depends" target that can be converted to > do exactly this if we take out the -f flag of pkg_delete. > > But I'm not sure if this is the right thing to do for ordinary users. > (I added it just for quick testing -- it's not even documented.) The > problem here is that we don't know whether the user wants BAR_1 to be > deleted or not. Maybe the user is using something in BAR_1 and didn't > realize typing "make deinstall-depends" from FOO would delete it. I hadn't thought of that. Maybe it should ask first :) Perhaps deinstall-depends could just generate a list of things it would deinstall. If the user was satisfied with the deletion list, he could pass a switch, like "make COMMIT=t deinstall-depends". There is another thing sort of wrong with this. If the user updates his ports collection and FOO changes it's version, deinstall-depends would not work anymore for that port. If he didn't know the package was updated, it deinstall-depends target would appear to be a broken feature. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message