Submitted By: Dan Nicholson Date: 2006-09-01 Initial Package Version: 2.3.6 Origin: udev-096, syscall functions generated by Alexander E. Patrakov Upstream Status: Added to syscall list in 2.4 Description: Adds inotify syscall functions for use in userspace. Minimal syscall functions borrowed from udev local implementation to provide system inotify support. Testcase: dovecot-1.0rc2, ./configure --with-notify=inotify diff -pNur glibc-2.3.6.orig/sysdeps/unix/sysv/linux/inotify.h glibc-2.3.6/sysdeps/unix/sysv/linux/inotify.h --- glibc-2.3.6.orig/sysdeps/unix/sysv/linux/inotify.h 1970-01-01 00:00:00.000000000 +0000 +++ glibc-2.3.6/sysdeps/unix/sysv/linux/inotify.h 2006-08-01 05:48:27.000000000 +0000 @@ -0,0 +1,31 @@ +/* + * Inode based directory notification for Linux + * + * Copyright (C) 2005 John McCutchan + */ + +#ifndef _SYS_INOTIFY_H +#define _SYS_INOTIFY_H + +#include +#include +#include + +extern long int syscall (long int __sysno, ...) __THROW; + +static inline int inotify_init(void) +{ + return syscall(__NR_inotify_init); +} + +static inline int inotify_add_watch(int fd, const char *name, uint32_t mask) +{ + return syscall(__NR_inotify_add_watch, fd, name, mask); +} + +static inline int inotify_rm_watch (int fd, uint32_t wd) +{ + return syscall(__NR_inotify_rm_watch, fd, wd); +} + +#endif /* _SYS_INOTIFY_H */