Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 11 Sep 2007 14:28:01 +0930
From:      "cracker jack" <t41pad@googlemail.com>
To:        freebsd-questions@freebsd.org
Subject:   build and install a kernel to another mounted system
Message-ID:  <5a3499010709102158o4def6a84v3d2898e082abe0fa@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hi guys,

I hope I'm posting in the right place.
My situation is that I've got a laptop thats booted with a live-cd FreeSBIE.
My laptops HD (/dev/ad0s1a) is mounted on /tmp/fixed and I'm trying to
build and install
a kernel to that mounted filesystem, with home, tmp, var and usr
mounted on /tmp/fixed/home etc.

I've got the kernel sources extracted to /tmp/fixed/usr/src/ by the following:
# cd /path-to/6.2-RELEASE/src
# cat ssys.[a-d]* | tar -zxvf - -C /tmp/fixed/usr/src
# cat sbase.[a-d]* | tar -zxvf - -C /tmp/fixed/usr/src/

My custom kernel is in /tmp/fixed/root/kernels/CUSTOM, with a symlink
from /tmp/fixed/usr/src/sys/i386/conf/CUSTOM pointing to it.

But I'm getting errors when from /tmp/fixed/usr/src I run
# make buildkernel KERNCONF=CUSTOM

I've tried to run that under a chroot too:
# chroot /tmp/fixed
# setenv MAKEOBJDIRPREFIX /usr/obj2
# setenv DESTDIR /
# make buildkernel KERNCONF=CUSTOM

But I'm still getting errors, mainly with ACPI.

Is it possible to do what I'm looking at? ie build a custom kernel
using sources from a mounted filesystem, and install it to that
mounted filesystem?

Thanks plenty.



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