2009/9/21 freeburn <<a href="mailto:hossain@finder-lbs.com">hossain@finder-lbs.com</a>>:<br>> have you ever compiled linux kernel by compilers other than gcc?<br>><br>> i had a argument with one my friend about "linux" vs "gnu/linux", then<br>
> this stuff suddenly came to our mind. i've always compiled linux kernel<br>> by gcc. i know in theory any c complier with necessary "lib"s should<br>> compile linux kernel. but is it practically possible? or have u ever<br>
> done it?<br><br>    It's not really possible. From "Documentation/HOWTO":<br><br><div style="margin-left: 40px;">The kernel is written using GNU C and the GNU toolchain.  While it<br>adheres to the ISO C89 standard, it uses a number of extensions that are<br>
not featured in the standard.  <font size="1">The kernel is a freestanding C<br>environment, with no reliance on the standard C library, so some<br>portions of the C standard are not supported.  Arbitrary long long<br>divisions and floating point are not allowed.</font>  It can sometimes be<br>
difficult to understand the assumptions the kernel has on the toolchain<br>and the extensions that it uses, and unfortunately there is no<br>definitive reference for them.  Please check the gcc info pages (`info<br>gcc`) for some information on them.<br>
<br></div>  The kernel can only be compiled with a (reasonably recent) gcc. There are<br>  some subtle points in the source where gcc (as a compiler: C->object) is<br>  needed and gnu ld is definitely needed to link the kernel.<br>
<br>      Loïc<br>