From owner-freebsd-ports@FreeBSD.ORG Sat Feb 7 00:25:03 2004 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6499016A4CE; Sat, 7 Feb 2004 00:25:03 -0800 (PST) Received: from obsecurity.dyndns.org (adsl-64-165-226-221.dsl.lsan03.pacbell.net [64.165.226.221]) by mx1.FreeBSD.org (Postfix) with ESMTP id 22FE143D1D; Sat, 7 Feb 2004 00:25:03 -0800 (PST) (envelope-from kris@obsecurity.org) Received: by obsecurity.dyndns.org (Postfix, from userid 1000) id C156466D51; Sat, 7 Feb 2004 00:25:02 -0800 (PST) Date: Sat, 7 Feb 2004 00:25:02 -0800 From: Kris Kennaway To: ports@FreeBSD.org, knu@FreeBSD.org Message-ID: <20040207082502.GA67113@xor.obsecurity.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="5mCyUwZo2JvN/JJP" Content-Disposition: inline User-Agent: Mutt/1.4.1i Subject: Differences between 'make index' and 'portsdb -U' X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 Feb 2004 08:25:03 -0000 --5mCyUwZo2JvN/JJP Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I've been looking at index builds a fair bit recently, and I've noticed a number of problems with both 'make index' and 'portsdb -U' (part of portupgrade). 1) 'make index' doesn't quote whitespace in COMMENT entries, but 'portsdb -U' does. There is probably some missing quoting in the perl script in the 'describe' target of bsd.port.mk, or the make_index script. The first line is from portsdb, the second from 'make index'; notice the additional space after the period in the comment. -lrzsz-0.12.20_1|/usr/ports/comms/lrzsz|/usr/local|Receive/Send files via X= /Y/ZMODEM protocol. (unrestrictive)|/usr/ports/comms/lrzsz/pkg-descr|dinoe= x@FreeBSD.org|comms|||http://www.ohse.de/uwe/software/lrzsz.html +lrzsz-0.12.20_1|/usr/ports/comms/lrzsz|/usr/local|Receive/Send files via X= /Y/ZMODEM protocol. (unrestrictive)|/usr/ports/comms/lrzsz/pkg-descr|dinoex= @FreeBSD.org|comms|||http://www.ohse.de/uwe/software/lrzsz.html =20 2) portsdb -U tries to build the index using 'make -j3'. This causes the output from the child make processes to sometimes overlap, generating corrupted INDEX entries and errors (I tried a similar optimization for 'make index', but encountered the same problem. I think it might be related to printing lines over a certain length). 3) portsdb -U doesn't record PATCH_DEPENDS entries, 'make index' does. 4) portsdb -U doesn't accept (valid) dependency lines like the following (from p5-XML-Xerces): BUILD_DEPENDS=3D ${NONEXISTENT}:${PORTSDIR}/textproc/xerces-c2:"configure = TRANSCODER=3Dnative" This gives a spurious error during the build: p5-XML-Xerces-2.3.0.4_2:"" non-existent -- dependency list incomplete 5) portsdb -U is now about 10% slower than 'make index', because it uses a custom makefile to recurse through the tree, and doesn't make use of the optimizations recently added to bsd.port.mk. The portsdb method may once have been an optimization relative to b.p.m, but it is not any longer. citusc17# /usr/bin/time make index Generating INDEX-5 - please wait.. Done. 3282.09 real 2334.77 user 658.47 sys citusc17# /usr/bin/time portsdb -U Updating the ports index ... p5-XML-Xerces-2.3.0.4_2:"" non-existent -- dep= endency list incomplete done 3591.99 real 2269.40 user 1075.79 sys Modulo the cosmetic bug #1 above, this all counts in favour of using 'make index' to build your indexes, and against using 'portsdb -U' until these problems are resolved. It would probably be best to just change portsdb to call 'make index' internally for the index builds. Kris --5mCyUwZo2JvN/JJP Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFAJKDeWry0BWjoQKURAnQJAJ9zc0K5xw17GoU32bO4ZYJSYjIqZQCfTFV1 aswWiS0nzdl9TOHtEaznx/c= =o1nQ -----END PGP SIGNATURE----- --5mCyUwZo2JvN/JJP--