Subrata Modak wrote: > On Fri, 2008-08-22 at 12:28 +0400, Andrew Vagin wrote: >> On Thu, Aug 21, 2008 at 08:15:20PM +0530, Subrata Modak wrote: >>> Hi Andrew, >>> >>> inotify01 is introducing compile error on the following x86_64 machine. >>> This is unexpected as cross compilation of it on other machines earlier >>> did not yield such failures. Can you please look in to this: >>> >>> >>> 1) Linux 2.6.16-1.2080_FC5 #1 SMP Tue Mar 28 03:38:47 EST 2006 x86_64 >>> x86_64 x86_64 GNU/Linux >>> >>> make[4]: Entering directory >>> `/root/subrata/ltp/ltp-intermediate-20080820/testcases/kernel/syscalls/inotify' >>> cc -Wall -I../../include -g -Wall -I../../../../include -Wall >>> inotify01.c -L../../../../lib -lltp -o inotify01 >>> inotify01.c:53:27: error: linux/inotify.h: No such file or directory >> inotify.h should be included from sys/inotify.h >> >> [EMAIL PROTECTED] ~]# rpm -qf /usr/include/linux/inotify.h >> kernel-headers-2.6.25.11-97.fc9.i386 >> [EMAIL PROTECTED] ~]# rpm -qf /usr/include/sys/inotify.h >> glibc-headers-2.8-3.i386 >> >> see the attached patch > > Yes, this solves the issue on 2.6.16-1.2080_FC5,x86_64. Thanks for this > patch. It is merged.
The patch breaks build on Debian Etch! The presence of the header file has to be checked before compilation. Please find the clipped output below. ------ [EMAIL PROTECTED]:ltp$ dpkg --list libc6 [clip] ii libc6 2.3.6.ds1-13 GNU C Library: Shared libraries [EMAIL PROTECTED]:ltp$ uname -a Linux toad 2.6.18-4-amd64 #1 SMP Mon Mar 26 11:36:53 CEST 2007 x86_64 GNU/Linux [EMAIL PROTECTED]:ltp$ make -j 16 [clip] make[4]: Entering directory `/home/vijaykumar/learning/git/ltp/testcases/kernel/syscalls/inotify' cc -Wall -I../../include -g -Wall -I../../../../include -Wall inotify01.c -L../../../../lib -lltp -o inotify01 cc -Wall -I../../include -g -Wall -I../../../../include -Wall inotify02.c -L../../../../lib -lltp -o inotify02 inotify02.c:56:25: error: sys/inotify.h: No such file or directory inotify02.c:91: error: invalid application of ‘sizeof’ to incomplete type ‘struct inotify_event’ inotify02.c: In function ‘main’: inotify02.c:139: error: ‘IN_ISDIR’ undeclared (first use in this function) inotify02.c:139: error: (Each undeclared identifier is reported only once inotify02.c:139: error: for each function it appears in.) inotify02.c:139: error: ‘IN_ATTRIB’ undeclared (first use in this function) inotify02.c:149: error: ‘IN_CREATE’ undeclared (first use in this function) inotify02.c:152: error: ‘IN_OPEN’ undeclared (first use in this function) inotify02.c:161: error: ‘IN_CLOSE_WRITE’ undeclared (first use in this function) inotify02.c:174: error: ‘IN_MOVED_FROM’ undeclared (first use in this function) inotify02.c:177: error: ‘IN_MOVED_TO’ undeclared (first use in this function) inotify02.c:205: error: ‘IN_DELETE’ undeclared (first use in this function) inotify02.c:239: error: invalid application of ‘sizeof’ to incomplete type ‘struct inotify_event’ inotify02.c:242: error: invalid application of ‘sizeof’ to incomplete type ‘struct inotify_event’ inotify02.c:253: error: dereferencing pointer to incomplete type inotify02.c:253: error: dereferencing pointer to incomplete type inotify02.c:254: error: dereferencing pointer to incomplete type inotify02.c:254: error: dereferencing pointer to incomplete type inotify02.c:255: error: dereferencing pointer to incomplete type inotify02.c:257: error: dereferencing pointer to incomplete type inotify02.c:259: error: dereferencing pointer to incomplete type inotify02.c:259: error: dereferencing pointer to incomplete type inotify02.c:262: error: dereferencing pointer to incomplete type inotify02.c:262: error: dereferencing pointer to incomplete type inotify02.c:263: error: dereferencing pointer to incomplete type inotify02.c:263: error: dereferencing pointer to incomplete type inotify02.c:264: error: dereferencing pointer to incomplete type inotify02.c:270: error: dereferencing pointer to incomplete type inotify02.c:270: error: dereferencing pointer to incomplete type inotify02.c:272: error: dereferencing pointer to incomplete type inotify02.c:272: error: dereferencing pointer to incomplete type inotify02.c:272: error: dereferencing pointer to incomplete type inotify02.c:275: error: dereferencing pointer to incomplete type inotify02.c:278: error: invalid application of ‘sizeof’ to incomplete type ‘struct inotify_event’ inotify02.c:278: error: dereferencing pointer to incomplete type inotify02.c: In function ‘setup’: inotify02.c:322: error: ‘IN_ALL_EVENTS’ undeclared (first use in this function) ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Ltp-list mailing list Ltp-list@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ltp-list