On Wed, Nov 10, 2004 at 11:14:09AM -0600, Timur Tabi wrote:
I have a driver that needs to be compilable with as many different kernel versions as possible.
Heh, good luck.
Actually, I've made some really good progress on this front. Maybe I'll write an article for Linux Journal.
Don't use -Wall. See the linux-kernel archives for previous attempts at doing this. As you've found out, many kernel header files don't like that warning level.
Well, I haven't found anything in the archives, but I did look at the 2.6 kbuild Makefile, and I found this:
CFLAGS := -Wall -Wstrict-prototypes -Wno-trigraphs \ -fno-strict-aliasing -fno-common
So it looks like -Wall is okay for 2.6 kernels, but not 2.4 kernels?
-- Timur Tabi Staff Software Engineer timur.tabi@xxxxxxxxxxx
-- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/