Module Name: src Committed By: skrll Date: Sat Dec 1 08:20:55 UTC 2012
Modified Files: src/sys/sys: fcntl.h stat.h Log Message: Check for _NETBSD_SOURCE being defined wherever we check for _INCOMPLETE_XOPEN_C063 so that we expose the new POSIX extended API set recently added. To generate a diff of this commit: cvs rdiff -u -r1.43 -r1.44 src/sys/sys/fcntl.h cvs rdiff -u -r1.64 -r1.65 src/sys/sys/stat.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/sys/fcntl.h diff -u src/sys/sys/fcntl.h:1.43 src/sys/sys/fcntl.h:1.44 --- src/sys/sys/fcntl.h:1.43 Sun Nov 18 17:41:54 2012 +++ src/sys/sys/fcntl.h Sat Dec 1 08:20:55 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: fcntl.h,v 1.43 2012/11/18 17:41:54 manu Exp $ */ +/* $NetBSD: fcntl.h,v 1.44 2012/12/01 08:20:55 skrll Exp $ */ /*- * Copyright (c) 1983, 1990, 1993 @@ -115,7 +115,7 @@ #define O_DIRECTORY 0x00200000 /* fail if not a directory */ #define O_CLOEXEC 0x00400000 /* set close on exec */ #if (_POSIX_C_SOURCE - 0) >= 200809L || (_XOPEN_SOURCE - 0 >= 700) || \ - defined(_INCOMPLETE_XOPEN_C063) || defined(_KERNEL) + defined(_INCOMPLETE_XOPEN_C063) || defined(_NETBSD_SOURCE) #define O_SEARCH 0x00800000 /* skip search permission checks */ #endif #if defined(_NETBSD_SOURCE) @@ -292,7 +292,7 @@ struct flock { * Constants for X/Open Extended API set 2 (a.k.a. C063) */ #if (_POSIX_C_SOURCE - 0) >= 200809L || (_XOPEN_SOURCE - 0 >= 700) || \ - defined(_INCOMPLETE_XOPEN_C063) || defined(_KERNEL) + defined(_INCOMPLETE_XOPEN_C063) || defined(_NETBSD_SOURCE) #define AT_FDCWD -100 /* Use cwd for relative link target */ #define AT_EACCESS 0x100 /* Use euig/egid for access checks */ #define AT_SYMLINK_NOFOLLOW 0x200 /* Do not follow symlinks */ @@ -316,7 +316,8 @@ int posix_fadvise(int, off_t, off_t, int /* * X/Open Extended API set 2 (a.k.a. C063) */ -#if defined(_INCOMPLETE_XOPEN_C063) +#if (_POSIX_C_SOURCE - 0) >= 200809L || (_XOPEN_SOURCE - 0 >= 700) || \ + defined(_INCOMPLETE_XOPEN_C063) || defined(_NETBSD_SOURCE) int openat(int, const char *, int oflags, ...); #endif __END_DECLS Index: src/sys/sys/stat.h diff -u src/sys/sys/stat.h:1.64 src/sys/sys/stat.h:1.65 --- src/sys/sys/stat.h:1.64 Sat Nov 3 19:39:21 2012 +++ src/sys/sys/stat.h Sat Dec 1 08:20:55 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: stat.h,v 1.64 2012/11/03 19:39:21 christos Exp $ */ +/* $NetBSD: stat.h,v 1.65 2012/12/01 08:20:55 skrll Exp $ */ /*- * Copyright (c) 1982, 1986, 1989, 1993 @@ -244,7 +244,8 @@ int lchmod(const char *, mode_t); /* * X/Open Extended API set 2 (a.k.a. C063) */ -#if defined(_INCOMPLETE_XOPEN_C063) +#if (_POSIX_C_SOURCE - 0) >= 200809L || (_XOPEN_SOURCE - 0 >= 700) || \ + defined(_INCOMPLETE_XOPEN_C063) || defined(_NETBSD_SOURCE) int fstatat(int, const char *, struct stat *, int); int utimensat(int, const char *, const struct timespec *, int); #endif