Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 210662 - net-fs/samba-3.0.28 includes linux/inotify.h instead of sys/inotify.h leading to build failures with libcap-2.x
Summary: net-fs/samba-3.0.28 includes linux/inotify.h instead of sys/inotify.h leading...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's SAMBA Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-19 03:01 UTC by Florian Scandella
Modified: 2008-02-20 20:04 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Scandella 2008-02-19 03:01:41 UTC
samba includes <sys/capability.h> somewhere before <linux/inotify.h>. because capability.h defines _LINUX_TYPES_H <linux/types.h> never gets included and __s32, needed for inotify_event struct is not defined.



Reproducible: Always

Steps to Reproduce:
1. emerge sys-libs/libcap-2.06-r1
2. emerge net-fs/samba-3.0.28

or 
test.c:
--start
#include <sys/capability.h>
#include <linux/inotify.h>
--end

Actual Results:  
In file included from smbd/notify_inotify.c:33:
/usr/include/linux/inotify.h:19: error: expected specifier-qualifier-list before ‘__s32’
smbd/notify_inotify.c: In function ‘filter_match’:
smbd/notify_inotify.c:102: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:105: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:112: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:117: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:125: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c: In function ‘inotify_dispatch’:
smbd/notify_inotify.c:152: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:152: error: ‘struct inotify_event’ has no member named ‘len’
smbd/notify_inotify.c:152: error: ‘struct inotify_event’ has no member named ‘name’
smbd/notify_inotify.c:156: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:163: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:165: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:167: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:168: error: ‘struct inotify_event’ has no member named ‘cookie’
smbd/notify_inotify.c:168: error: ‘struct inotify_event’ has no member named ‘cookie’
smbd/notify_inotify.c:173: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:174: error: ‘struct inotify_event’ has no member named ‘cookie’
smbd/notify_inotify.c:182: error: ‘struct inotify_event’ has no member named ‘name’
smbd/notify_inotify.c:190: error: ‘struct inotify_event’ has no member named ‘wd’
smbd/notify_inotify.c:199: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:204: error: ‘struct inotify_event’ has no member named ‘mask’
smbd/notify_inotify.c:208: error: ‘struct inotify_event’ has no member named ‘wd’
smbd/notify_inotify.c: In function ‘inotify_handler’:
smbd/notify_inotify.c:250: error: ‘struct inotify_event’ has no member named ‘len’
smbd/notify_inotify.c:252: error: ‘struct inotify_event’ has no member named ‘len’
smbd/notify_inotify.c:255: error: ‘struct inotify_event’ has no member named ‘cookie’
The following command failed:
x86_64-pc-linux-gnu-gcc -I. -I/var/tmp/portage/net-fs/samba-3.0.28/work/samba-3.0.28/source  -mtune=k8 -march=k8 -O2 -fomit-frame-pointer -frename-registers -fweb -fgcse -fgcse-sm -fgcse-las -fgcse-after-reload -ftree-vectorize -g -pipe -D_SAMBA_BUILD_=3  -I/var/tmp/portage/net-fs/samba-3.0.28/work/samba-3.0.28/source/iniparser/src -Iinclude -I./include  -I. -I. -I./lib/replace -I./lib/talloc -I./tdb/include -I./libaddns -I./librpc -DHAVE_CONFIG_H  -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -DLDAP_DEPRECATED    -I/var/tmp/portage/net-fs/samba-3.0.28/work/samba-3.0.28/source/lib -D_SAMBA_BUILD_=3 -fPIC -c smbd/notify_inotify.c -o smbd/notify_inotify.o
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2008-02-19 08:00:10 UTC

*** This bug has been marked as a duplicate of bug 210527 ***
Comment 2 Tiziano Müller (RETIRED) gentoo-dev 2008-02-19 16:40:55 UTC
That's right. This isn't a duplicate.
Samba's inotify_* glibc is broken, upstream bug: https://bugzilla.samba.org/show_bug.cgi?id=5271

It should not include a kernel header but the corresponding glibc-header if possible.
Comment 3 Tiziano Müller (RETIRED) gentoo-dev 2008-02-20 20:04:07 UTC
Fixed in CVS. Please wait a couple of hours, resync and retry. Thanks.