I am used to using -std=c99
to enable c99 features when compiling application code.
Recently I have been following some basic kernel module examples, and added ccflags-y := -std=c99
to the makefile. However this resulted in 17K lines of errors when I tried to make. gnu99
works perfectly.
What is the difference between gnu99 and c99 that kernel code relies on?
The linux kernel uses a lot of GCC extensions i.e., the C language used in the kernel is not standards compliant, it is a superset which includes GCC extension. Hence GNU99 is the compiler option which needs to be passed.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With