RE: [kbuild-devel] Re: [PATCH] [kbuild] Possibility to sanely link against off-directory .so

Kenn Humborg (kenn@bluetree.ie)
Thu, 7 Nov 2002 16:20:34 -0000


> Dear diary, on Thu, Nov 07, 2002 at 02:22:45PM CET, I got a letter,
> where Peter Samuelson <peter@cadcamlab.org> told me, that...
> > Remember, the whole point of HOSTCC is to support a build environment
> > different from the compile target - arbitrarily different, even.
>
> I'm a bit lost here - the kernel uses tons of gcc extensions -
> how is another
> compiler supposed to understand them? And if it is specifically
> extended to
> understand them, isn't it likely that it'll understand the
> -shared switch in
> gcc-like way as well?
>
> Or better, what other compiler is known to build a kernel than
> gcc? At least
> anything that doesn't define __GNUC__ should IMHO fail inside of
> init/main.c.
> And how likely is situation when someone want to configure a kernel with
> non-gcc compiler and actually build it with gcc?

When you're cross-compiling a kernel.

> I thought that the point of HOSTCC is to allow to use a
> non-standart version
> of gcc for kernel build.

Nope. It's mainly for cross-compilation. You want to compile the
kernel itself for your targer architecture, but the compilation tools
need to run on the build machine so need a different compiler.

The gcc/kgcc thing is only a convenient side effect.

Later,
Kenn

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/