kernel compile problem
Nikolas Britton
freebsd at nbritton.org
Sat Jan 29 17:26:13 PST 2005
Mrad James Deane wrote:
> Hi,i have follow the freebsd handbook on how to compile a kernel but i
> have a problem :
> when compile : i have the following message :
> make:don't know how to make buildkernel.Stop
> i'm using freebsd 5.2.1 release and i have removed NoAtm=true on
> make.conf
> Plz help,
> Thanks
>
>
You are using the wrong procedure, buildkernel is used only when
building world (nevermind, I looked at the handbook, this is the "new
way"), I personally do it the "old way" and its never failed me:
cd /usr/src/sys/i386/conf
config MYKERNEL
cd ../compile/MYKERNEL
make depend && make && make install
It's only one more line then the new way, in fact I could do it all on
one line if I wanted:
cd /usr/src/sys/i386/conf && config MYKERNEL && cd ../compile/MYKERNEL
&& make depend && make && make install
You can do the same thing with the "new way" too:
cd /usr/src && make buildkernel KERNCONF=MYKERNEL && make installkernel
KERNCONF=MYKERNEL
if you set KERNCONF in /etc/make.conf you could leave that out, then you
would have this:
cd /usr/src && make buildkernel && make installkernel
If your wondering what "&&" does, it means do this and then do that but
only if the first command worked (has an exit status of zero, aka true).
The opposite would be "||", what that means is do this if the first
command failed (has an exit status of non-zero, aka false).
What Hexren said "you need to cd into /usr/src" is most likey true.
More information about the freebsd-newbies
mailing list