From owner-svn-src-all@FreeBSD.ORG Thu Dec 2 20:43:51 2010 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 272A8106564A; Thu, 2 Dec 2010 20:43:51 +0000 (UTC) (envelope-from uqs@FreeBSD.org) Received: from acme.spoerlein.net (acme.spoerlein.net [IPv6:2a01:4f8:131:23c2::1]) by mx1.freebsd.org (Postfix) with ESMTP id 9C6028FC1E; Thu, 2 Dec 2010 20:43:50 +0000 (UTC) Received: from localhost (acme.spoerlein.net [IPv6:2a01:4f8:131:23c2::1]) by acme.spoerlein.net (8.14.4/8.14.4) with ESMTP id oB2Khn9A076631 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 2 Dec 2010 21:43:49 +0100 (CET) (envelope-from uqs@FreeBSD.org) Date: Thu, 2 Dec 2010 21:43:49 +0100 From: Ulrich Spoerlein To: Alexander Leidinger Message-ID: <20101202204349.GB3256@acme.spoerlein.net> Mail-Followup-To: Ulrich Spoerlein , Alexander Leidinger , src-committers@FreeBSD.org, svn-src-all@FreeBSD.org, svn-src-head@FreeBSD.org References: <201012021046.oB2Ak5EV000582@svn.freebsd.org> <20101202154522.76174hkekl2ct4pw@webmail.leidinger.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="IJpNTDwzlM2Ie8A6" Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20101202154522.76174hkekl2ct4pw@webmail.leidinger.net> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r216119 - head X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Dec 2010 20:43:51 -0000 --IJpNTDwzlM2Ie8A6 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, 02.12.2010 at 15:45:22 +0100, Alexander Leidinger wrote: > Quoting Ulrich Spoerlein (from Thu, 2 Dec 2010 > 10:46:05 +0000 (UTC)): > > > Author: uqs > > Date: Thu Dec 2 10:46:05 2010 > > New Revision: 216119 > > URL: http://svn.freebsd.org/changeset/base/216119 > > > > Log: > > Remove more duplicates. > > > > Just so that I can lookup the command for the next time: > > Can you please add it to OldFiles.inc instead, with a comment what it does? > > > for t in `make -V TARGETS universe`; do > > __MAKE_CONF=/dev/null make -f Makefile.inc1 -m $PWD/share/mk TARGET=$t \ > > -V OLD_FILES -V OLD_LIBS -V OLD_DIRS delete-old | \ > > xargs -n1|sort|uniq -c|egrep -v "^ *1 "; > > done > > While it does not matter for "-V OLD*", the spirit of the command is > more like the check-old target (which is including shared libs) than > the delete-old target (which does not delete shared libs but only > static libs). Using check-old would also remove the (wrong, but not > far fetched) fear of actually deleting something with this command. Something that bugs me more, is all the TARGET_ARCH conditionals in that file, that serve practically no purpose. If a file only existed on i386, and it has been removed on i386, there's no point in wrapping this under TARGET_ARCH=i386. The wrapping of all lib32 files for amd64 is a great example :/ The wrapping is only ever required, if some file has been removed from a set of arches, but must be retained on others. Anyway, please see attached. Uli --IJpNTDwzlM2Ie8A6 Content-Type: text/x-diff; charset=utf-8 Content-Disposition: attachment; filename="obsolete.diff" Content-Transfer-Encoding: 8bit commit 2c5b79ffde80760690baee61d30b0f533e511ca3 Author: Ulrich Spörlein Date: Thu Dec 2 21:23:58 2010 +0100 Document two more ways to find duplicates in the obsolete file list. Remove the only duplicate found by the optional files check. Fix typos, while here. Suggested by: netchild diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 0756547..e406532 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -22,16 +22,31 @@ # grep '+=' /usr/src/tools/build/mk/OptionalObsoleteFiles.inc | sort -u) | \ # sort | uniq -d # +# To find regular duplicates not dependant on optional components, you can +# also use something that will not give you false positives, e.g.: +# for t in `make -V TARGETS universe`; do +# __MAKE_CONF=/dev/null make -f Makefile.inc1 TARGET=$t \ +# -V OLD_FILES -V OLD_LIBS -V OLD_DIRS check-old | \ +# xargs -n1 | sort | uniq -d; +# done +# +# For optional components, you can use the following to see if some entries +# in OptionalObsoleteFiles.inc have been obsoleted by ObsoleteFiles.inc +# for o in tools/build/options/WITH*; do +# __MAKE_CONF=/dev/null make -f Makefile.inc1 -D${o##*/} \ +# -V OLD_FILES -V OLD_LIBS -V OLD_DIRS check-old | \ +# xargs -n1 | sort | uniq -d; +# done # 20101112: vgonel(9) has gone to private API a while ago OLD_FILES+=usr/share/man/man9/vgonel.9.gz # 20101112: removed gasp.info OLD_FILES+=usr/share/info/gasp.info.gz -# 20101109: headers moved to machine/ to x86/ +# 20101109: headers moved from machine/ to x86/ .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/machine/mptable.h .endif -# 20101101: headers moved to machine/ to x86/ +# 20101101: headers moved from machine/ to x86/ .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/machine/apicreg.h OLD_FILES+=usr/include/machine/mca.h diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc index 02a4ce3..db8251c 100644 --- a/tools/build/mk/OptionalObsoleteFiles.inc +++ b/tools/build/mk/OptionalObsoleteFiles.inc @@ -1869,7 +1869,6 @@ OLD_FILES+=usr/lib/libfl_p.a OLD_FILES+=usr/lib/libform_p.a OLD_FILES+=usr/lib/libformw_p.a OLD_FILES+=usr/lib/libftpio_p.a -OLD_FILES+=usr/lib/libg2c_p.a OLD_FILES+=usr/lib/libgcc_p.a OLD_FILES+=usr/lib/libgeom_p.a OLD_FILES+=usr/lib/libgnuregex_p.a --IJpNTDwzlM2Ie8A6--