Recommended compiler? - Re: [patch] kernel/module.c (plus gratuitous rant)

Linux Kernel Developer
2000-10-30T11:26:17Z

So which is the recommended compiler for each kernel version 2.2.x,
2.4.x(pre?) nowadays? I've pretty much kept gcc 2.7.2.3 around just for
compiling the kernel however now I hear you need egcs to compile 2.4? I
don't mind keeping 2.7.2.3 around in its own installation directory just for
the purpose of doing kernel work however from a previous post I've now got
the impression that egcs has become the recommended compiler? If I'm going
to keep a secondary compiler around (outside of gcc 2.95.2 which I still
hear is no good for kernel compiles) just for kernel work I'd prefer to use
my disk space on the recommended one.

>
> [Rusty]
> > > CC=gcc-2723 make 2.0 kernel
> > > CC=gcc-2723 make 2.2 kernel
> > > CC=egcs make 2.4 kernel
> >
> > No, environment doesn't override make variables by default. This
> > works on any shell:
> >
> > make CC=egcs <targets>
>
> If you're going to get pedantic, that won't work either -- since the
> makefiles in kernels 2.0 and 2.2 expect $(CC) to include some compiler
> flags. This was fixed somewhere in 2.3.3x.
>
> Peter
> -