From owner-freebsd-arch@FreeBSD.ORG Tue Sep 16 16:26:21 2008 Return-Path: Delivered-To: arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BE29A1065677 for ; Tue, 16 Sep 2008 16:26:21 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (cl-162.ewr-01.us.sixxs.net [IPv6:2001:4830:1200:a1::2]) by mx1.freebsd.org (Postfix) with ESMTP id 4440E8FC1A for ; Tue, 16 Sep 2008 16:26:21 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (localhost [127.0.0.1]) by lor.one-eyed-alien.net (8.14.3/8.14.2) with ESMTP id m8GGR8UP035235; Tue, 16 Sep 2008 11:27:08 -0500 (CDT) (envelope-from brooks@lor.one-eyed-alien.net) Received: (from brooks@localhost) by lor.one-eyed-alien.net (8.14.3/8.14.3/Submit) id m8GGR79l035234; Tue, 16 Sep 2008 11:27:07 -0500 (CDT) (envelope-from brooks) Date: Tue, 16 Sep 2008 11:27:07 -0500 From: Brooks Davis To: Sam Leffler Message-ID: <20080916162707.GA35096@lor.one-eyed-alien.net> References: <48CF1979.90507@errno.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="GvXjxJ+pjyke8COw" Content-Disposition: inline In-Reply-To: <48CF1979.90507@errno.com> User-Agent: Mutt/1.5.17 (2007-11-01) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (lor.one-eyed-alien.net [127.0.0.1]); Tue, 16 Sep 2008 11:27:08 -0500 (CDT) Cc: arch@freebsd.org Subject: Re: the more build knobs bikeshed X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Sep 2008 16:26:21 -0000 --GvXjxJ+pjyke8COw Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Sep 15, 2008 at 07:27:05PM -0700, Sam Leffler wrote: > Here is a patch against HEAD to add several knew MK_* knobs that can be= =20 > used to trim the build for small-footprint applications: >=20 > http://www.freebsd.org/~sam/build.patch >=20 > With these changes I can build a nanobsd image for x86 or arm that is <1/= 2=20 > the size you can get otherwise (using just the standard knobs). If you d= o=20 > not use the knobs you should get exactly what you're used to getting. >=20 > My goal in doing this is to make nanobsd more useful for building embedde= d=20 > packages without bypassing the build process to purge stuff. This is sti= ll=20 > a LONG way from small enough to fit in many applications but seems like a= =20 > useful start. >=20 > FWIW I chose knobs using two criteria: >=20 > 1. Does it save an appreciable amount of space. > 2. Does it remove applications that you really don't want to be present. >=20 > I'm sure folks will wonder about some choices. One can also argue that= =20 > some of the groups I've added are wrong and/or we should have individual= =20 > knobs for each application. >=20 > Separate issues that I intend to work on: >=20 > 1. Build time is way too long; paring down the target config should also= =20 > reduce the build time but it does not because things like MK_TOOLCHAIN=20 > cannot be used when building; only when installing. > 2. Some applications that you want are hugely bloated and may benefit fro= m=20 > some TLC. bind comes to mind where I can crunchgen all the bits into a= =20 > single binary but when built normally you get multiple huge executables. > 3. Cross-build and package; I can use nanobsd to build arm images but the= =20 > packaging facilities are inadequate. I've got a start on default setups= =20 > for some boards/packages and would like to see this grow into a library= =20 > that people can use for reference and/or extend. >=20 > Anyway, I'm interested in getting the above patch committed so looking f= or=20 > constructive comments. I haven't included the files that go under=20 > src/tools/build/options (I've done them already). I also have mods for= =20 > RELENG_7 that I've been using for a while. Looks generally good to me. Some of us at AsiaBSDCon noted that most of usr.sbin isn't useful on most system so this is a good step forward. One minor dependency nit is that freebsd-update depends on portsnap at the moment because both use phttpget which resides in usr.sbin/portsnap/phttpget. It should probably move to libexec/phttpget. -- Brooks --GvXjxJ+pjyke8COw Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.8 (FreeBSD) iD8DBQFIz95aXY6L6fI4GtQRAn7qAJ4oEEfThlTlIv/Z4ddHEwS45BMUPQCfUDSM YAreGYkcPv2Go8DXIMMlxAU= =NEOQ -----END PGP SIGNATURE----- --GvXjxJ+pjyke8COw--