Subject: Unable to recompile the kernel after installing the sctp patch

From: "Mohit Gupta" <[email-masked]>
Date: Mon, 20 Oct 2003 22:00:59 -0700

Hi,

I installed the linux patch on my 2.4.18 kernel, and then tried to recompile the kernel but got an error. I installed the patch as said in the INSTALL file and then did a make mrproper, then make xconfig, make dep, make clear and then make bzImage. Is this a known issue or I am missing something. I am compiling the kernel for the first time please help me. Thanks for any help.

Mohit

I am including the output:

gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686   -DKBUILD_BASENAME=nfscache  -c -o nfscache.o nfscache.c
gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686   -DKBUILD_BASENAME=nfsxdr  -c -o nfsxdr.o nfsxdr.c
gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686   -DKBUILD_BASENAME=stats  -c -o stats.o stats.c
rm -f nfsd.o
ld -m elf_i386  -r -o nfsd.o nfssvc.o nfsctl.o nfsproc.o nfsfh.o vfs.o export.o
auth.o lockd.o nfscache.o nfsxdr.o stats.o
make[3]: Leaving directory `/usr/src/linux/fs/nfsd'
make[2]: Leaving directory `/usr/src/linux/fs/nfsd'
make -C partitions
make[2]: Entering directory `/usr/src/linux/fs/partitions'
make all_targets
make[3]: Entering directory `/usr/src/linux/fs/partitions'
gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686   -DKBUILD_BASENAME=check  -DEXPORT_SYMTAB -c check.c
In file included from /usr/src/linux/include/net/ip.h:36,
                 from /usr/src/linux/include/net/checksum.h:31,
                 from /usr/src/linux/include/linux/raid/md.h:34,
                 from check.c:21:
/usr/src/linux/include/net/snmp.h:230: redefinition of `struct sctp_mib'
In file included from /usr/src/linux/include/net/checksum.h:33,
                 from /usr/src/linux/include/linux/raid/md.h:34,
                 from check.c:21:
/usr/src/linux/include/asm/checksum.h:72:30: warning: multi-line string literals are deprecated
/usr/src/linux/include/asm/checksum.h:105:17: warning: multi-line string literals are deprecated
/usr/src/linux/include/asm/checksum.h:121:13: warning: multi-line string literals are deprecated
/usr/src/linux/include/asm/checksum.h:161:17: warning: multi-line string literals are deprecated
make[3]: *** [check.o] Error 1
make[3]: Leaving directory `/usr/src/linux/fs/partitions'
make[2]: *** [first_rule] Error 2
make[2]: Leaving directory `/usr/src/linux/fs/partitions'
make[1]: *** [_subdir_partitions] Error 2
make[1]: Leaving directory `/usr/src/linux/fs'
make: *** [_dir_fs] Error 2
[root@localhost linux]#

Mohit Gupta
Graduate Student
Computer Science Department
http://wwwcsif.cs.ucdavis.edu/~gupta/
(425) 239-2667

---

From: "Brian F. G. Bidulock" <[email-masked]>
Date: Tue, 21 Oct 2003 00:03:28 -0600

Mohit,

I don't know whose SCTP your are using, but gcc3 doesn't compile
a 2.4.18 kernel without modifications.  As it says in
/usr/src/linux-2.4/Documentation/Changes:

 The recommended compiler for the kernel is gcc 2.95.3 or .4, and it
 should be used when you need absolute stability. You may use gcc 3.0.x
 instead if you wish, although it may cause problems. Later  versions of gcc 
 have not received much testing for Linux kernel compilation, and there are 
 almost certainly bugs (mainly, but not exclusively, in the kernel) that
 will need to be fixed in order to use these compilers. In any case, using
 pgcc instead of egcs or plain gcc is just asking for trouble.

What is the result of gcc --version ?

Which SCTP patch are you using?

--brian

On Mon, 20 Oct 2003, Mohit Gupta wrote:

> 
>    Hi,
> 
> 
> 
>    I  installed  the  linux  patch on my 2.4.18 kernel, and then tried to
>    recompile  the  kernel but got an error. I installed the patch as said
>    in  the  INSTALL file and then did a make mrproper, then make xconfig,
>    make dep, make clear and then make bzImage. Is this a known issue or I
>    am  missing  something.  I  am compiling the kernel for the first time
>    please help me. Thanks for any help.
> 
> 
> 
> 
> 
>    Mohit
> 
> 
> 
>    gcc  -D__KERNEL__  -I/usr/src/linux/include  -Wall -Wstrict-prototypes
>    -Wno-trigraphs     -O2    -fomit-frame-pointer    -fno-strict-aliasing
>    -fno-common     -pipe     -mpreferred-stack-boundary=2     -march=i686
>    -DKBUILD_BASENAME=nfscache  -c -o nfscache.o nfscache.c
>    gcc  -D__KERNEL__  -I/usr/src/linux/include  -Wall -Wstrict-prototypes
>    -Wno-trigraphs     -O2    -fomit-frame-pointer    -fno-strict-aliasing
>    -fno-common     -pipe     -mpreferred-stack-boundary=2     -march=i686
>    -DKBUILD_BASENAME=nfsxdr  -c -o nfsxdr.o nfsxdr.c
>    gcc  -D__KERNEL__  -I/usr/src/linux/include  -Wall -Wstrict-prototypes
>    -Wno-trigraphs     -O2    -fomit-frame-pointer    -fno-strict-aliasing
>    -fno-common     -pipe     -mpreferred-stack-boundary=2     -march=i686
>    -DKBUILD_BASENAME=stats  -c -o stats.o stats.c
>    rm -f nfsd.o
>    gcc  -D__KERNEL__  -I/usr/src/linux/include  -Wall -Wstrict-prototypes
>    -Wno-trigraphs     -O2    -fomit-frame-pointer    -fno-strict-aliasing
>    -fno-common     -pipe     -mpreferred-stack-boundary=2     -march=i686
>    -DKBUILD_BASENAME=check  -DEXPORT_SYMTAB -c check.c
>    [1]http://wwwcsif.cs.ucdavis.edu/~gupta/
>    (425) 239-2667
> 
> References
> 
>    1. http://wwwcsif.cs.ucdavis.edu/~gupta/

-- 
Brian F. G. Bidulock    ¦ The reasonable man adapts himself to the ¦
[email-masked]    ¦ world; the unreasonable one persists in  ¦
http://www.openss7.org/ ¦ trying  to adapt the  world  to himself. ¦
                        ¦ Therefore  all  progress  depends on the ¦
                        ¦ unreasonable man. -- George Bernard Shaw ¦