Cannot install kernel as user

Peter Jeremy PeterJeremy at optushome.com.au
Fri Jan 21 10:35:53 PST 2005


On Fri, 2005-Jan-21 08:59:35 -0700, Ryan Sommers wrote:
>> I thought about adding a flag such as NO_INSTALLCHOWN in both
>> kern.post.mk and kmod.mk.  What do you think of the idea ?
>>
>> I saw there are KMODOWN and KMODGRP in kmod.mk, but it seems there is
>> no similar facility in kern.post.mk.  Maybe it would be worth having
>> KERNOWN and KERNGRP as well.
>>
>> I can submit a patch if asked.

Yes please.

>I'm trying to think where this would be useful outside your particular
>situation. I'm not sure there is a lot of use.
>
>The official way to do what you are looking to do is to mount it the other
>way. On the build machine export the src/obj directories and mount them on
>the target machine. Then execute your make install from the target
>machine. Otherwise you run into problems like you are running into.
>Especially if you're running an install as a non-root user.

Except that this is only guaranteed to work if the build machine and
target machine are running the same kernel and the build machine's
userland is executable on the target machine.  (This is because the
first part of the buildworld builds tools against the current
userland).

As an example, if my build machine is a PIII (build with CPUTYPE=p3) then
I can't mount src/obj onto an i486 and run installworld - it will try to
execute non-i486 instructions.

-- 
Peter Jeremy


More information about the freebsd-current mailing list