Kernel Build errors

David O'Brien obrien at freebsd.org
Thu Dec 2 12:02:50 PST 2004


On Thu, Dec 02, 2004 at 12:02:46PM -0500, Egor Dmitrenkov wrote:
> > Well, I tried to compile GENERIC kernel for my Athlon64 and result was:
> > What should I do? Help plz...
> > --------------------
> > # cd /usr/src/sys/amd64/conf/
> > # config GENERIC
> > Kernel build directory is ../compile/GENERIC
> > Don't forget to do a ``make depend''
> > # cd ../compile/GENERIC
> > # make depend
..
> > -mpreferred-stack-boundary=2 -ffreestanding ../../../i386/i386/genassym.c
> > ../../../i386/i386/genassym.c:38:22: opt_apic.h: No such file or directory
> > In file included from ../../../sys/types.h:44,
> >                  from ../../../sys/param.h:61,
> >                  from ../../../i386/i386/genassym.c:42:
> > ./machine/endian.h: In function `__bswap64':
> > ./machine/endian.h:126: warning: right shift count >= width of type

Something is very weird -- you're trying to compile a 'i386' platform
file and not the proper 'amd64' platform file.

You show you're trying to build a 64-bit kernel (vs. 32-bit), but let me
ask that this is true just to be perfectly clear.


On Thu, Dec 02, 2004 at 12:34:05PM -0600, nmeverde at np.k12.mn.us wrote:
> > Stop in /usr/src/sys/amd64/compile/GENERIC.
> > #
> > --
 
Geez, could you *please* trim some of the uneeded _1030_ lines in the
original post when you follow up?!?

> is there a reason your building the kernel the old school way?
> read /usr/src/Makefile
> 
> try this:
> cd /usr/src/
> make TARGET_ARCH=amd64 buildkernel

Specifying 'TARGET_ARCH' isn't part of the 'new school way'.
Only specify 'TARGET_ARCH' when you are trying to do a cross build.

-- 
-- David  (obrien at FreeBSD.org)


More information about the freebsd-amd64 mailing list