[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: compiling xfsdump: `SYS_getdents64' undeclared



Hi Stephan -

This should be defined in bits/syscall.h.  From sys/syscall.h:

/* The Linux kernel header file defines macros `__NR_<name>', but some
   programs expect the traditional form `SYS_<name>'.  So in building libc
   we scan the kernel's list and produce <bits/syscall.h> with macros for
   all the `SYS_' names.  */

So it's probably your older glibc that's causing the problem.

You could either add

#define SYS_getdents64 __NR_getdents64

to /usr/include/bits/syscall.h

or replace SYS_getdents64 with __NR_getdents64 in xfsdump.

...I think.  ;-)

-Eric


On Fri, 2002-03-15 at 14:36, Stephan Austermühle wrote:
> Hi,
> 
> while trying to compile xfsdump 2.0.0 on my system (Kernel 2.4.18-xfs,
> glibc 2.1.3) the compiler aborts with an error:
> 
> 	=== dump ===
> 	gcc -O1 -g -DDEBUG -funsigned-char -Wall -DDUMP -DRMT -DBASED -DDOSOCKS -DINVCONVFIX -DSIZEEST -DPIPEINVFIX -DEXTATTR -DDMEXTATTR -I/usr/include/xfs -I/usr/include/attr '-DVERSION="2.0.0"' -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -DXFS_BIG_FILES=1 -DXFS_BIG_FILESYSTEMS=1 -I/usr/include/xfs -I/usr/include/attr  -c -o getdents.o getdents.c
> 	getdents.c: In function `getdents_wrap':
> 	getdents.c:152: `SYS_getdents64' undeclared (first use in this function)
> 	getdents.c:152: (Each undeclared identifier is reported only once
> 	getdents.c:152: for each function it appears in.)
> 	make[1]: *** [getdents.o] Error 1
> 	make: *** [default] Error 2
> 
> Maybe someone can help me fixing this problem. Please let me know if
> any information is missing.
> 
> Thanks in advance,
> 
> Stephan
-- 
Eric Sandeen      XFS for Linux     http://oss.sgi.com/projects/xfs
sandeen@sgi.com   SGI, Inc.