Linux 4.1 Should Work With GCC 6, Future Versions Of GCC
Written by Michael Larabel in Linux Kernel on 16 April 2015 at 04:54 PM EDT. Add A Comment
With the new GNU Compiler Collection (GCC) versioning where they're going to be bumping the major version number every year, Linux kernel developers are now re-working the way they handle the compiler's quirks/changes within the kernel.

Up to now the Linux kernel had a compiler-gccX.h file for every major version of GCC (where X is the major version number) to handle various differences, but after accommodating GCC5 and now GCC 6.0 in development, kernel developers are working the way this is handled particularly as the GCC major releases aren't breaking key functionality these days.

Per this LKML thread, they're looking at merging the various GCC header files into a single compiler-gcc.h file to avoid having to trivially update the kernel every year for supporting the new compiler version.

Joe Perches published the patches today for making this compiler-gcc.h happen after communication from other developers. With the Linux 4.1 merge window still open, there's interest on the list in seeing this happen for Linux 4.1 so that there will be GCC6+ support baked in and developers can begin building the mainline kernel under GCC 6.0 snapshots.

After that, now if only the rest of the LLVMLinux patches were in a state to be mainlined so the Linux kernel could build cleanly off the Clang compiler... And the other big task of making the Linux kernel's code C11 compatible.
Related News
About The Author
Author picture

Michael Larabel is the principal author of and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and automated benchmarking software. He can be followed via Twitter or contacted via

Popular News This Week