Bug 18012 - kernel compile problem
kernel compile problem
Product: Red Hat Linux
Classification: Retired
Component: kernel (Show other bugs)
i386 Linux
high Severity high
: ---
: ---
Assigned To: Michael K. Johnson
Depends On:
  Show dependency treegraph
Reported: 2000-10-01 06:33 EDT by Need Real Name
Modified: 2008-05-01 11:37 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2000-10-01 14:31:29 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Need Real Name 2000-10-01 06:33:04 EDT
If I recompile the kernel that is shipped with redhat 7 I get the uptime to 1 on my celeron 633Mhz 
I have a intel 815 motherboard. Precompiled kernel that ships with RH7 seems to work.

I have downloaded the kernel 2.2.17 from kernel.org
Unpacked it to /usr/src/linux-2.2.17
ln -s linux-2.2.17 linux
make mrpproper
make menuconfig
make dep
make bzImage

I get a lot of warning messages and then:

 tmp/ccpi52Qj.s:877: Warning: using `%eax' instead of `%ax' due to `l' suffix
/tmp/ccpi52Qj.s:957: Warning: using `%eax' instead of `%ax' due to `l' suffix
/tmp/ccpi52Qj.s:958: Warning: using `%eax' instead of `%ax' due to `l' suffix
cc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe -fno-strength-reduce 
-m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=686   -c -o init_task.o init_task.c
make[1]: Leaving directory `/usr/src/linux-2.2.17/arch/i386/kernel'
make -C  arch/i386/mm
make[1]: Entering directory `/usr/src/linux-2.2.17/arch/i386/mm'
make all_targets
make[2]: Entering directory `/usr/src/linux-2.2.17/arch/i386/mm'
cc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe -fno-strength-reduce 
-m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=686   -c -o init.o init.c
cc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe -fno-strength-reduce 
-m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=686   -c -o fault.o fault.c
cc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe -fno-strength-reduce 
-m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=686   -c -o ioremap.o ioremap.c
cc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe -fno-strength-reduce 
-m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=686   -c -o extable.o extable.c
rm -f mm.o
ld -m elf_i386  -r -o mm.o  init.o fault.o ioremap.o extable.o
make[2]: Leaving directory `/usr/src/linux-2.2.17/arch/i386/mm'
make[1]: Leaving directory `/usr/src/linux-2.2.17/arch/i386/mm'
make -C  arch/i386/lib
make[1]: Entering directory `/usr/src/linux-2.2.17/arch/i386/lib'
make all_targets
make[2]: Entering directory `/usr/src/linux-2.2.17/arch/i386/lib'
cc -D__KERNEL__ -I/usr/src/linux/include -D__ASSEMBLY__  -traditional -c checksum.S -o checksum.o
checksum.S:231: badly punctuated parameter list in #define
checksum.S:237: badly punctuated parameter list in #define
make[2]: *** [checksum.o] Error 1
make[2]: Leaving directory `/usr/src/linux-2.2.17/arch/i386/lib'
make[1]: *** [first_rule] Error 2
make[1]: Leaving directory `/usr/src/linux-2.2.17/arch/i386/lib'
make: *** [_dir_arch/i386/lib] Error 2
[root@transmetawww  linux]# 

Hope to get a fix

Comment 1 Michael McTernan 2000-10-01 14:31:27 EDT

I get the same problem.  I couldn't compile the kernel from the Redhat 7.0 CD 
(1), and so downloaded 2.2.17 from kernel.org and got exactly the same output.

Please fix this as I need to add some things to my kernel configuration and 
can't at the moment.

Comment 2 Alan Cox 2000-10-01 17:44:09 EDT
Its in the docs - you need to use kgcc not the gcc 2.96. The vanilla kernel has
problems that make
it break under the newer compiler.

Edit the top Makefile and set CC to use kgcc (or pick up a current 2.2.18pre)
Comment 3 Harvey Modlin 2000-10-05 04:03:56 EDT
Well, I get the same error msg and as a result get no bzImage -- with or 
without the "export CC=kgcc" before the make.
Comment 4 Harvey Modlin 2000-10-05 05:03:35 EDT
Aha. Found the problem! I really did forget to do the 'make mrproper' first! So 
with makr mrproper and 'export CC=kgcc', the kernel compiled just fine (thank 
you!) and the outcome was the bzImage file I wanted. Yippee! Thanks again.
Comment 5 Joel J. Garrett 2001-01-07 23:32:19 EST
Would somebody mind posting the proper order?

I tried doing the following sequence:

make mrproper
make xconfig
export CC=kgcc
make dep
make bzImage

and ended up with exactly the same errors that you all have been talking about
while trying to build the 2.2.17 kernel sources that you've all talked about
getting from www.kernel.org

Where should I be doing the export and the 'make mrproper' ?

Note You need to log in before you can comment on or make changes to this bug.