linux cross-development (was: Re: /dev/null: No such file or directory)

Kris Kennaway kris at obsecurity.org
Wed Sep 20 13:04:42 PDT 2006


On Wed, Sep 20, 2006 at 09:24:42PM +0200, Alexander Leidinger wrote:
> Quoting Kris Kennaway <kris at obsecurity.org> (Wed, 20 Sep 2006 14:21:56 -0400):
> 
> 
> > OK, but under linux_base-8 it was enough to install the linux_devtools
> > and then chroot, in order to compile linux stuff; in fact this was
> > precisely the purpose of the linux_devtools port.
> > 
> > Hopefully this will be addressed soon, it would be a shame to lose
> > this functionality.  Is anyone working on it?
> 
> Nobody is working on it and the linux base port diverged here since -8
> (let's call it a little shift in what to expect from it since Trevor
> maintained them).
> 
> A chroot will not work as expected:
> ---snip---
> REMOVE_DIRS=            boot dev home initrd root tmp var/log var/run var/tmp \
>                         usr/local usr/tmp
> REMOVE_FILES=           bin/df bin/su etc/exports etc/group etc/localtime \
>                         etc/motd etc/passwd etc/printcap etc/services \
>                         etc/protocols
> ---snip---
> 
> We rely on the fallthrough to the FreeBSD files. The same applies to
> e.g. fonts.conf in the linux-fontconfig (or linuxfreetype?) port.
> 
> For the gtk/X11 port I'm not sure if we already did the fallthrough for
> the icons.
> 
> Any ideas how to provide a chroot while not losing the fallthrough if
> not chrooted (and we try to identify other files/dirs where we want a
> fallthrough)?

Actually none of these seem to be critical for typical compilation
needs, except for /dev and /tmp.  The former you'll have to mount
devfs to supply (in principle linux_devtools can do this
automatically, by startup script), and you can make linux_devtools
create a /compat/linux/tmp to handle that problem too (it's not ideal
to have it use a private /tmp, but not a big deal either).

Kris

P.S. I'm not sure that falling through some of the etc/ files will
DTRT, since Linux may require a different file format.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-emulation/attachments/20060920/e67387a0/attachment.pgp


More information about the freebsd-emulation mailing list