[Pvfs2-users] building kmod on linux-2.6.22

ryuta suzu0037 at aem.umn.edu
Fri Aug 10 14:11:31 EDT 2007


What you suggested fixed configure check but "make kmod" still fails 
with the same error. It seems that CFLAGS=... does not take effect in 
src/kernel/linux-2.6/Makefile. I'm trying to hardwire the include path 
in Makefile to force the compiler.

ryuta

Murali Vilayannur wrote:
> Hi Ryuta,
> hmm.. that is weird. It is probably because gcc does not pick up
> stdarg.h from its location.
> Do you want to try and force gcc to include its default path which may
> be omitted  while building the kmods for some reason (perhaps due to
> -nostdinc or -isystem?)
> export CFLAGS=/usr/lib/gcc/i686-pc-linux-gnu/4.2.1/include
> and then redoing the configure and make kmod?
> I don't know..
> thanks,
> Murali
>
> On 8/10/07, ryuta <suzu0037 at aem.umn.edu> wrote:
>   
>>  Hi,
>>
>>  I've successfully built and installed pvfs-2.3.6 on Arch Linux with kernel
>> linux-2.6.22-ARCH, however, I encountered a problem building kernel
>> interface.
>>
>>  My configure option is
>>
>>      ./configure --enable-shared --with-kernel=/usr/src/linux-2.6.22-ARCH
>>
>>  If you see the attached config.log you can find most of kernel-related
>> checking complains on the failure of including one header file "stdarg.h".
>>
>>  Nonetheless, the PVFS2 Configuration Information displays 2.6.x kernel
>> module as configured, and sure enough, "make kmod" simply fails due to
>> compilation error as gcc cannot find "stdarg.h"
>>
>>  [root at oroppas pvfs-2.6.3]# make kmod
>>    CC [M]  /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.o
>>  In file included from ./include/linux/moduleparam.h:6,
>>                   from
>> /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-kernel.h:45,
>>                   from
>> /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.c:7:
>>  ./include/linux/kernel.h:10:20: error: stdarg.h: No such file or directory
>>  In file included from ./include/linux/moduleparam.h:6,
>>                   from
>> /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-kernel.h:45,
>>                   from
>> /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.c:7:
>>  ./include/linux/kernel.h:123: error: expected declaration specifiers or
>> '...' before 'va_list'
>>  ./include/linux/kernel.h:127: error: expected declaration specifiers or
>> '...' before 'va_list'
>>  ./include/linux/kernel.h:131: error: expected declaration specifiers or
>> '...' before 'va_list'
>>  ./include/linux/kernel.h:135: error: expected declaration specifiers or
>> '...' before 'va_list'
>>  ./include/linux/kernel.h:139: error: expected declaration specifiers or
>> '...' before 'va_list'
>>  ./include/linux/kernel.h:155: error: expected declaration specifiers or
>> '...' before 'va_list'
>>  In file included from
>> /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.c:7:
>>  /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-kernel.h:1267: error:
>> conflicting types for 'kzalloc'
>>  ./include/linux/slab_def.h:55: error: previous definition of 'kzalloc' was
>> here
>>  /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.c: In function
>> 'pvfs2_inode_removexattr':
>>  /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.c:1007: error:
>> 'XATTR_REPLACE' undeclared (first use in this function)
>>  /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.c:1007: error:
>> (Each undeclared identifier is reported only once
>>  /usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.c:1007: error:
>> for each function it appears in.)
>>  make[3]: *** [/usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6/pvfs2-utils.o]
>> Error 1
>>  make[2]: *** [_module_/usr/local/src/pvfs-2.6.3/src/kernel/linux-2.6] Error
>> 2
>>  make[1]: *** [default] Error 2
>>  make: *** [just_kmod] Error 2
>>
>>
>>
>>  On my installation, there are several "stdarg.h" just like most
>> installation
>>
>>      /usr/include/c++/4.2.1/tr1/stdarg.h
>>      /usr/lib/gcc/i686-pc-linux-gnu/4.2.1/include/stdarg.h
>>
>> /usr/lib/gcc/i686-pc-linux-gnu/4.2.1/install-tools/include/stdarg.h
>>      /usr/lib/klibc/include/stdarg.h
>>
>>  and gcc by default includes the path
>>
>>      /usr/lib/gcc/i686-pc-linux-gnu/4.2.1/include
>>
>>  as most gcc does on typical configuration.
>>
>>  I'm not quite sure if this issue caused by Arch Linux, GCC, or PVFS.
>>
>>  Any help will be greatly appreciated.
>>
>>  Thank you,
>>  Ryuta
>>
>> _______________________________________________
>> Pvfs2-users mailing list
>> Pvfs2-users at beowulf-underground.org
>> http://www.beowulf-underground.org/mailman/listinfo/pvfs2-users
>>
>>
>>
>>     


More information about the Pvfs2-users mailing list