From owner-freebsd-ports@FreeBSD.ORG Mon Sep 12 20:05:27 2011 Return-Path: Delivered-To: ports@FreeBSD.org Received: from mx2.freebsd.org (mx2.freebsd.org [IPv6:2001:4f8:fff6::35]) by hub.freebsd.org (Postfix) with ESMTP id B24DE1065670; Mon, 12 Sep 2011 20:05:27 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from 172-17-198-245.globalsuite.net (hub.freebsd.org [IPv6:2001:4f8:fff6::36]) by mx2.freebsd.org (Postfix) with ESMTP id 5263014EA99; Mon, 12 Sep 2011 20:05:27 +0000 (UTC) Message-ID: <4E6E6607.2030104@FreeBSD.org> Date: Mon, 12 Sep 2011 13:05:27 -0700 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:6.0.2) Gecko/20110912 Thunderbird/6.0.2 MIME-Version: 1.0 To: lev@FreeBSD.org References: <503309410.20110912205856@serebryakov.spb.ru> <865325899.20110912230621@serebryakov.spb.ru> <4E6E60C7.90304@FreeBSD.org> <181642832.20110912235833@serebryakov.spb.ru> In-Reply-To: <181642832.20110912235833@serebryakov.spb.ru> X-Enigmail-Version: undefined OpenPGP: id=1A1ABC84 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: ports@FreeBSD.org Subject: Re: Print +REQUIRED_BY as tree? X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Sep 2011 20:05:27 -0000 On 09/12/2011 12:58, Lev Serebryakov wrote: > How could I determine which ports are directly lined with libgcc from > gcc44? ldd? Yes, that's really the only answer. I have the following function which would work: old_libs () { local file nf; [ -e ~/old-lib-list ] && unlink ~/old-lib-list; cd /usr/local/ || { echo 'cd to /usr/local/ failed'; return 1 }; for file in `find GNUstep bin lib* sbin -type f 2>/dev/null`; do case "$file" in lib\/firefox* | lib\/linux-* | lib\/thunderbird*) continue ;; esac; if nf=`ldd -a $file 2>/dev/null | egrep "(not found|${1:-asjklssafjklasdfjkl})"`; then echo $file; echo $nf; echo ''; fi; done > ~/old-lib-list; cd -; if [ ! -s ~/old-lib-list ]; then echo 'Nothing found'; unlink ~/old-lib-list; fi } You could run old_libs and it would tell you which things are linked against it. Alternatively you could do the following with portmaster: portmaster -o lang/gcc45 gcc-4.4 portmaster -R -r gcc-4.5 hth, Doug -- Nothin' ever doesn't change, but nothin' changes much. -- OK Go Breadth of IT experience, and depth of knowledge in the DNS. Yours for the right price. :) http://SupersetSolutions.com/