When I compile driver for a wifi module, it works well under kernel 2.6.x, after I upgrade my Ubuntu to 3.8.x, it can not be compiled anymore, the errors are all like this:
gcc -I/mlan -DLINUX -I/lib/modules/3.8.0-26-generic/build/include -DFPNUM='"62"' -DDEBUG_LEVEL1 -DPROC_DEBUG -DSTA_SUPPORT -DREASSOCIATION -DUAP_SUPPORT -DWIFI_DIRECT_SUPPORT -DMFG_CMD_SUPPORT -c -o mlanconfig.o mlanconfig.c In file included from /usr/include/linux/if.h:22:0, from mlanconfig.h:41, from mlanconfig.c:34: /lib/modules/3.8.0-26-generic/build/include/linux/types.h:14:26: error: conflicting types for ‘fd_set’ In file included from /usr/include/i386-linux-gnu/sys/types.h:219:0, from /usr/include/stdlib.h:314, from mlanconfig.h:37, from mlanconfig.c:34: /usr/include/i386-linux-gnu/sys/select.h:75:5: note: previous declaration of ‘fd_set’ was here
The error-compiled modules are apps included in the driver packages, but not the driver itself, so I guess it use the standard C library and the kernel library, which cause the conflicts.
The question is, first, I am confused what is /usr/include/i386-linux-gnu/ for, it doesn't exist under my 2.6.x system. Why there is no conflicts under the 2.6.x system, what has changed between the update.
Also, my system is 32-bit ubuntu 13.04 on a 64-bit arch machine, the $uname -m -p -i output i686 i686 i686, is there anything to do with this?