Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 11 Jan 2009 14:45:24 -0700 (MST)
From:      "M. Warner Losh" <imp@bsdimp.com>
To:        sam@FreeBSD.org
Cc:        arch@FreeBSD.org
Subject:   Re: Quick hack to make fast kernel builds easier [really cross-build support]
Message-ID:  <20090111.144524.235773790.imp@bsdimp.com>
In-Reply-To: <496A65E1.5030309@freebsd.org>
References:  <20090111191251.GA74450@zim.MIT.EDU> <20090111.142350.1560738814.imp@bsdimp.com> <496A65E1.5030309@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
In message: <496A65E1.5030309@freebsd.org>
            Sam Leffler <sam@FreeBSD.org> writes:
: M. Warner Losh wrote:
: > In message: <20090111191251.GA74450@zim.MIT.EDU>
: >             David Schultz <das@FreeBSD.ORG> writes:
: > : On Sun, Jan 11, 2009, Ed Schouten wrote:
: > : > I often just run `make' in /usr/obj/...,
: > : > which also saves some typing, but unfortunately that doesn't work when
: > : > cross compiling.
: > : 
: > : Also, as far as I know, there's no convenient way to rebuild a
: > : single module for another architecture. I use the following script
: > : called 'arch' to set the appropriate environment variables, so if
: > : I've already run 'make universe' and I want to rebuild libc for
: > : sparc64, I say:
: > : 
: > :    cd /usr/src/lib/libc && arch sparc64 make
: > : 
: > : It would be nice if there were a better mechanism for this that's
: > : integrated into the build system.
: >
: > I do one of the following:
: >
: > (1) env TARGET=arm make buildworld -DNO_CLEAN
: >
: > or
: >
: > (2) env TARGET=arm make buildenv
: > $ cd lib/libc && make
: >
: > These both work out well enough in practice for me.  I've wanted a
: > target that was 'reworld' that just did an 'all' and maybe a few other
: > things, but I've never had the time to polish this up (had it in a
: > couple of trees that I lost due to disk failure).
: >
: > I do agree it would be nice if there was some way to do 'all' for a
: > subdirectory with a 'trust me, I know what I'm doing, so don't do all
: > that other stuff' flag.
: >
: >   
: I told das privately but will note publicly that:
: 
: tools/tools/nanobsd/gateworks
: 
: uses make buildenv to cross-build various bits.  At some point I want to 
: promote some of the shell code to be part of nanobsd but until we've got 
: something to deal with ports I'm in no hurry.

I've done similar things...

Cross building ports is a very interesting problem...

Warner



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090111.144524.235773790.imp>