From owner-freebsd-questions@FreeBSD.ORG Mon Apr 14 18:42:13 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2C42937B401 for ; Mon, 14 Apr 2003 18:42:13 -0700 (PDT) Received: from grumpy.dyndns.org (user-24-214-34-52.knology.net [24.214.34.52]) by mx1.FreeBSD.org (Postfix) with ESMTP id 58FDD43FB1 for ; Mon, 14 Apr 2003 18:42:12 -0700 (PDT) (envelope-from dkelly@grumpy.dyndns.org) Received: from grumpy.dyndns.org (localhost [127.0.0.1]) by grumpy.dyndns.org (8.12.9/8.12.9) with ESMTP id h3F1gABY036080 for ; Mon, 14 Apr 2003 20:42:11 -0500 (CDT) (envelope-from dkelly@grumpy.dyndns.org) Received: by grumpy.dyndns.org (8.12.9/8.12.9/Submit) id h3F1gAuc036079 for FreeBSD-Questions@FreeBSD.org; Mon, 14 Apr 2003 20:42:10 -0500 (CDT) From: David Kelly To: FreeBSD-Questions@FreeBSD.org Date: Mon, 14 Apr 2003 20:42:03 -0500 User-Agent: KMail/1.5.1 References: <3E9B5A56.2070609@yahoo-inc.com> <1050368712.69920.39.camel@shumai.marcuscom.com> <3E9B5D94.4070401@bigfoot.com> In-Reply-To: <3E9B5D94.4070401@bigfoot.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200304142042.03864.dkelly@HiWAAY.net> Subject: Re: how to find which package contains file? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 15 Apr 2003 01:42:13 -0000 On Monday 14 April 2003 08:17 pm, Erik Steffl wrote: > > > >If you have the package and file already installed on your system: > > > >pkg_info -W /path/to/file > > thanks but what about the situation described abovwe - when I am > trying to find which package to install when there's some file > missing? (usually a library but could be something else). Something like this (it will take a while so carefully select the RE you use for grep. "perllocal.pod" in this example): % find /usr/ports -name pkg-plist | xargs grep -l perllocal.pod /usr/ports/mail/p5-Mail-SpamAssassin/pkg-plist /usr/ports/astro/p5-Astro-Sunrise/pkg-plist /usr/ports/audio/p5-CDDB_get/pkg-plist /usr/ports/databases/p5-DBIx-XHTML_Table/pkg-plist /usr/ports/devel/autodia/pkg-plist [...] Interesting, /usr/local/lib/perllocal.pod exists but "pkg_info -W" doesn't know who is responsible. Likely cruft left over from portupgrades. -- David Kelly N4HHE, dkelly@hiwaay.net ===================================================================== The human mind ordinarily operates at only ten percent of its capacity -- the rest is overhead for the operating system.