From owner-freebsd-questions@FreeBSD.ORG Mon Apr 30 07:41:00 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8777916A402 for ; Mon, 30 Apr 2007 07:41:00 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id 1884813C4B8 for ; Mon, 30 Apr 2007 07:40:59 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1HiQVB-0003Of-IC for freebsd-questions@freebsd.org; Mon, 30 Apr 2007 09:40:53 +0200 Received: from detroit.slack.net ([69.31.82.90]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 30 Apr 2007 09:40:53 +0200 Received: from mark.evenson by detroit.slack.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 30 Apr 2007 09:40:53 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-questions@freebsd.org From: Mark Evenson Date: Mon, 30 Apr 2007 09:40:39 +0200 Lines: 44 Message-ID: References: <64c038660704292022w45b95a1en10521023bb9a3157@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: detroit.slack.net User-Agent: Thunderbird 2.0.0.0 (X11/20070423) In-Reply-To: <64c038660704292022w45b95a1en10521023bb9a3157@mail.gmail.com> Sender: news Subject: Re: Port dependency tool (if that's what you'd call it) X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Apr 2007 07:41:00 -0000 Modulok wrote: > I'm not quite sure how to put into word what I want, so bear with me. Is > there a tool in the base system which does something along these lines: > > 1. Look at the makefile of a given port as far as its RUN_DEPENDS and > BUILD_DEPENDS. > 2. Subtracting what I have already installed, provide me with information > about what would be fetched (and possibly installed) in an easy-to-digest > format, recursively (for all dependents of dependents ... and so on). > > If not part of the base system, is there a port which offers this > functionality? The standard ports for this kind of functionality are port-mgmt/portupgrade port-mgmt/portmaster 'portupgrade' is the older utility; 'portmaster' has recently come on the "scene", with slightly different aims. I use 'portupgrade' as I haven't really spent the time to learn about 'portmaster'. Once 'portupgrade' is installed, and you have built its database with 'pkgdb', you should be able to answer your second question via freebsd$ portupgrade --noexecute --upward-recursive PORTNAME where PORTNAME is the name of the port (qv. 'ports_glob' for how this is specified) to give you information on what needs to be updated. You might need to trim the output a bit to get the succinct list of dependencies that need updating, but the output of 'portupgrade' is quite regular so a little regexp'in in your preferred scripting language should bring you to the result you want. There may be other more direct routes to the information you seek, but this way will definitely work. -- "[T]his is not a disentanglement from, but a progressive knotting into."