2014-02-12 Joseph Myers <joseph@codesourcery.com>
+ * include/features.h (__USE_BSD): Remove macro definitions.
+ (__USE_SVID): Likewise.
+ (_BSD_SOURCE): Likewise.
+ (_SVID_SOURCE): Likewise.
+ [!defined _BSD_SOURCE && !defined _SVID_SOURCE]: Remove condition
+ from definition of _DEFAULT_SOURCE.
+ [_BSD_SOURCE || _SVID_SOURCE]: Change condition to
+ [_DEFAULT_SOURCE].
+ * bits/fcntl.h [__USE_BSD]: Change condition to [__USE_MISC].
+ * bits/mman.h [__USE_BSD]: Likewise.
+ * bits/termios.h [__USE_BSD]: Likewise.
+ * bits/waitstatus.h [__USE_BSD]: Likewise.
+ * ctype/ctype.h [__USE_SVID]: Likewise.
+ * dirent/dirent.h [__USE_BSD]: Likewise.
+ * grp/grp.h [__USE_SVID]: Likewise.
+ [__USE_BSD]: Likewise.
+ * inet/netinet/igmp.h [__USE_BSD]: Likewise.
+ * io/fcntl.h [__USE_BSD]: Likewise.
+ * io/ftw.h [__USE_BSD]: Likewise.
+ * io/sys/stat.h [__USE_BSD]: Likewise.
+ * libio/bits/stdio-ldbl.h [__USE_BSD]: Likewise.
+ * libio/bits/stdio2.h [__USE_BSD]: Likewise.
+ * libio/stdio.h [__USE_SVID]: Likewise.
+ [__USE_BSD]: Likewise.
+ * math/math.h [__USE_SVID]: Likewise.
+ [__USE_BSD]: Likewise.
+ * misc/bits/syslog-ldbl.h [__USE_BSD]: Likewise.
+ * misc/bits/syslog.h [__USE_BSD]: Likewise.
+ * misc/search.h [__USE_SVID]: Likewise.
+ * misc/sys/mman.h [__USE_BSD]: Likewise.
+ * misc/sys/syslog.h [__USE_BSD]: Likewise.
+ * misc/sys/uio.h [__USE_BSD]: Likewise.
+ * posix/bits/unistd.h [__USE_BSD]: Likewise.
+ * posix/glob.h [__USE_BSD]: Likewise.
+ * posix/regex.h [__USE_BSD]: Likewise.
+ * posix/sys/types.h [__USE_BSD]: Likewise.
+ [__USE_SVID]: Likewise.
+ * posix/sys/utsname.h [__USE_SVID]: Likewise.
+ * posix/sys/wait.h [__USE_BSD]: Likewise.
+ [__USE_SVID]: Likewise.
+ * posix/unistd.h [__USE_BSD]: Likewise.
+ [__USE_SVID]: Likewise.
+ * pwd/pwd.h [__USE_SVID]: Likewise.
+ * resolv/netdb.h [__USE_BSD]: Likewise.
+ * setjmp/setjmp.h [__USE_BSD]: Likewise.
+ * signal/signal.h [__USE_BSD]: Likewise.
+ [__USE_SVID]: Likewise.
+ * socket/sys/socket.h [__USE_BSD]: Likewise.
+ * stdlib/fmtmsg.h [__USE_SVID]: Likewise.
+ * stdlib/stdlib.h [__USE_BSD]: Likewise.
+ [__USE_SVID]: Likewise.
+ * string/bits/string2.h [__USE_BSD]: Likewise.
+ [__USE_SVID]: Likewise.
+ * string/bits/string3.h [__USE_BSD]: Likewise.
+ * string/endian.h [__USE_BSD]: Likewise.
+ * string/string.h [__USE_SVID]: Likewise.
+ [__USE_BSD]: Likewise.
+ * string/strings.h [__USE_BSD]: Likewise.
+ * sysdeps/generic/netinet/ip.h [__USE_BSD]: Likewise.
+ * sysdeps/gnu/netinet/ip_icmp.h [__USE_BSD]: Likewise.
+ * sysdeps/mach/hurd/bits/fcntl.h [__USE_BSD]: Likewise.
+ * sysdeps/mach/hurd/bits/stat.h [__USE_BSD]: Likewise.
+ * sysdeps/unix/sysv/linux/alpha/bits/mman.h [__USE_BSD]: Likewise.
+ * sysdeps/unix/sysv/linux/alpha/bits/termios.h [__USE_BSD]:
+ Likewise.
+ * sysdeps/unix/sysv/linux/bits/fcntl-linux.h [__USE_BSD]:
+ Likewise.
+ * sysdeps/unix/sysv/linux/bits/mman-linux.h [__USE_BSD]: Likewise.
+ * sysdeps/unix/sysv/linux/bits/sys_errlist.h [__USE_BSD]:
+ Likewise.
+ * sysdeps/unix/sysv/linux/bits/termios.h [__USE_BSD]: Likewise.
+ * sysdeps/unix/sysv/linux/mips/bits/termios.h [__USE_BSD]:
+ Likewise.
+ * sysdeps/unix/sysv/linux/netinet/if_ether.h [__USE_BSD]:
+ Likewise.
+ * sysdeps/unix/sysv/linux/netinet/if_fddi.h [__USE_BSD]: Likewise.
+ * sysdeps/unix/sysv/linux/netinet/if_tr.h [__USE_BSD]: Likewise.
+ * sysdeps/unix/sysv/linux/powerpc/bits/termios.h [__USE_BSD]:
+ Likewise.
+ * sysdeps/unix/sysv/linux/sparc/bits/termios.h [__USE_BSD]:
+ Likewise.
+ * sysdeps/x86/bits/string.h [__USE_BSD]: Likewise.
+ * sysvipc/sys/ipc.h [__USE_SVID]: Likewise.
+ * termios/termios.h [__USE_BSD]: Likewise.
+ * time/sys/time.h [__USE_BSD]: Likewise.
+ * time/time.h [__USE_BSD]: Likewise.
+ [__USE_SVID]: Likewise.
+
* Makefile (subdir_targets): Remove subdir_lint.out.
* stdio-common/Makefile (do-tst-unbputc): Remove target.
#define O_APPEND 0x0008 /* Writes append to the file. */
#define O_NONBLOCK 0x0004 /* Non-blocking I/O. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define O_NDELAY O_NONBLOCK
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Bits in the file status flags returned by F_GETFL.
These are all the O_* flags, plus FREAD and FWRITE, which are
independent bits set by which of O_RDONLY, O_WRONLY, and O_RDWR, was
#define F_SETFD 2 /* Set file descriptor flags. */
#define F_GETFL 3 /* Get file status flags. */
#define F_SETFL 4 /* Set file status flags. */
-#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_UNIX98 || defined __USE_XOPEN2K8
#define F_GETOWN 5 /* Get owner (receiver of SIGIO). */
#define F_SETOWN 6 /* Set owner (receiver of SIGIO). */
#endif
/* Flags contain mapping type, sharing type and options. */
/* Mapping type (must choose one and only one of these). */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define MAP_FILE 0x0001 /* Mapped from a file or device. */
# define MAP_ANON 0x0002 /* Allocated from anonymous virtual memory. */
# define MAP_TYPE 0x000f /* Mask for type field. */
#endif
/* Sharing types (must choose one and only one of these). */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define MAP_COPY 0x0020 /* Virtual copy of region at mapping time. */
#endif
#define MAP_SHARED 0x0010 /* Share changes. */
/* Other flags. */
#define MAP_FIXED 0x0100 /* Map address must be exactly as requested. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define MAP_NOEXTEND 0x0200 /* For MAP_FILE, don't change file size. */
# define MAP_HASSEMPHORE 0x0400 /* Region may contain semaphores. */
# define MAP_INHERIT 0x0800 /* Region is retained after exec. */
#endif
/* Advice to `madvise'. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define MADV_NORMAL 0 /* No further special treatment. */
# define MADV_RANDOM 1 /* Expect random page references. */
# define MADV_SEQUENTIAL 2 /* Expect sequential page references. */
#endif /* __USE_MISC || __USE_XOPEN */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# ifdef MDMBUF
# undef MDMBUF
# undef PENDIN
# endif
-#endif /* __USE_BSD */
+#endif /* __USE_MISC */
#ifdef ECHO
# undef ECHO
#define ICRNL (1 << 8) /* Map CR to NL on input. */
#define IXON (1 << 9) /* Enable start/stop output control. */
#define IXOFF (1 << 10) /* Enable start/stop input control. */
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_MISC || defined __USE_UNIX98
# define IXANY (1 << 11) /* Any character will restart after stop. */
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define IMAXBEL (1 << 13) /* Ring bell when input queue is full. */
#endif
#ifdef __USE_GNU
/* Output modes. */
tcflag_t c_oflag;
#define OPOST (1 << 0) /* Perform output processing. */
-#if defined __USE_BSD || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
# define ONLCR (1 << 1) /* Map NL to CR-NL on output. */
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define OXTABS TAB3 /* Expand tabs to spaces. */
# define ONOEOT (1 << 3) /* Discard EOT (^D) on output. */
#endif
-#if defined __USE_BSD || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
# define OCRNL (1 << 4) /* Map CR to NL. */
# define ONOCR (1 << 5) /* Discard CR's when on column 0. */
# define ONLRET (1 << 6) /* Move to column 0 on NL. */
/* Control modes. */
tcflag_t c_cflag;
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define CIGNORE (1 << 0) /* Ignore these control flags. */
#endif
#define CSIZE (CS5|CS6|CS7|CS8) /* Number of bits per byte (mask). */
#define PARODD (1 << 13) /* Odd parity instead of even. */
#define HUPCL (1 << 14) /* Hang up on last close. */
#define CLOCAL (1 << 15) /* Ignore modem status lines. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define CRTSCTS (1 << 16) /* RTS/CTS flow control. */
# define CRTS_IFLOW CRTSCTS /* Compatibility. */
# define CCTS_OFLOW CRTSCTS /* Compatibility. */
/* Local modes. */
tcflag_t c_lflag;
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define ECHOKE (1 << 0) /* Visual erase for KILL. */
#endif
#define _ECHOE (1 << 1) /* Visual erase for ERASE. */
#define ECHO _ECHO
#define _ECHONL (1 << 4) /* Echo NL even if ECHO is off. */
#define ECHONL _ECHONL
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define ECHOPRT (1 << 5) /* Hardcopy visual erase. */
# define ECHOCTL (1 << 6) /* Echo control characters as ^X. */
#endif
#define ISIG _ISIG
#define _ICANON (1 << 8) /* Do erase and kill processing. */
#define ICANON _ICANON
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define ALTWERASE (1 << 9) /* Alternate WERASE algorithm. */
#endif
#define _IEXTEN (1 << 10) /* Enable DISCARD and LNEXT. */
#define EXTPROC (1 << 11) /* External processing. */
#define _TOSTOP (1 << 22) /* Send SIGTTOU for background output. */
#define TOSTOP _TOSTOP
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define FLUSHO (1 << 23) /* Output being flushed (state). */
# define NOKERNINFO (1 << 25) /* Disable VSTATUS. */
# define PENDIN (1 << 29) /* Retype pending input (state). */
/* Control characters. */
#define VEOF 0 /* End-of-file character [ICANON]. */
#define VEOL 1 /* End-of-line character [ICANON]. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define VEOL2 2 /* Second EOL character [ICANON]. */
#endif
#define VERASE 3 /* Erase character [ICANON]. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define VWERASE 4 /* Word-erase character [ICANON]. */
#endif
#define VKILL 5 /* Kill-line character [ICANON]. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define VREPRINT 6 /* Reprint-line character [ICANON]. */
#endif
#define VINTR 8 /* Interrupt character [ISIG]. */
#define VQUIT 9 /* Quit character [ISIG]. */
#define VSUSP 10 /* Suspend character [ISIG]. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define VDSUSP 11 /* Delayed suspend character [ISIG]. */
#endif
#define VSTART 12 /* Start (X-ON) character [IXON, IXOFF]. */
#define VSTOP 13 /* Stop (X-OFF) character [IXON, IXOFF]. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define VLNEXT 14 /* Literal-next character [IEXTEN]. */
# define VDISCARD 15 /* Discard character [IEXTEN]. */
#endif
#define VMIN 16 /* Minimum number of bytes read at once [!ICANON]. */
#define VTIME 17 /* Time-out value (tenths of a second) [!ICANON]. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define VSTATUS 18 /* Status character [ICANON]. */
#endif
#define NCCS 20 /* Value duplicated in <hurd/tioctl.defs>. */
#define TCSANOW 0 /* Change immediately. */
#define TCSADRAIN 1 /* Change when pending output is written. */
#define TCSAFLUSH 2 /* Flush pending input before changing. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define TCSASOFT 0x10 /* Flag: Don't alter hardware state. */
#endif
#define __WCOREFLAG 0x80
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# include <endian.h>
extern int isctype (int __c, int __mask) __THROW;
#endif
-#if defined __USE_SVID || defined __USE_MISC || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN
/* Return nonzero iff C is in the ASCII set
(i.e., is no more than 7 bits wide). */
# define toupper(c) __tobody (c, toupper, *__ctype_toupper_loc (), (c))
# endif /* Optimizing gcc */
-# if defined __USE_SVID || defined __USE_MISC || defined __USE_XOPEN
+# if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN
# define isascii(c) __isascii (c)
# define toascii(c) __toascii (c)
# define __isblank_l(c,l) __isctype_l((c), _ISblank, (l))
-# if defined __USE_SVID || defined __USE_MISC
+# if defined __USE_MISC || defined __USE_MISC
# define __isascii_l(c,l) ((l), __isascii (c))
# define __toascii_l(c,l) ((l), __toascii (c))
# endif
# define isblank_l(c,l) __isblank_l ((c), (l))
-# if defined __USE_SVID || defined __USE_MISC
+# if defined __USE_MISC || defined __USE_MISC
# define isascii_l(c,l) __isascii_l ((c), (l))
# define toascii_l(c,l) __toascii_l ((c), (l))
# endif
#include <bits/dirent.h>
-#if (defined __USE_BSD || defined __USE_MISC) && !defined d_fileno
+#if (defined __USE_MISC || defined __USE_MISC) && !defined d_fileno
# define d_ino d_fileno /* Backward compatibility. */
#endif
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* File types for `d_type'. */
enum
{
/* Rewind DIRP to the beginning of the directory. */
extern void rewinddir (DIR *__dirp) __THROW __nonnull ((1));
-#if defined __USE_BSD || defined __USE_MISC || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN
# include <bits/types.h>
/* Seek to position POS on DIRP. */
extern long int telldir (DIR *__dirp) __THROW __nonnull ((1));
#endif
-#if defined __USE_BSD || defined __USE_MISC || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN2K8
/* Return the file descriptor used by DIRP. */
extern int dirfd (DIR *__dirp) __THROW __nonnull ((1));
# define dirfd(dirp) _DIR_dirfd (dirp)
# endif
-# if defined __USE_BSD || defined __USE_MISC
+# if defined __USE_MISC || defined __USE_MISC
# ifndef MAXNAMLEN
/* Get the definitions of the POSIX.1 limits. */
# include <bits/posix1_lim.h>
#endif /* Use BSD or misc or XPG7. */
-#if defined __USE_BSD || defined __USE_MISC
+#if defined __USE_MISC || defined __USE_MISC
/* Read directory entries from FD into BUF, reading at most NBYTES.
Reading starts at offset *BASEP, and *BASEP is updated with the new
position after reading. Returns the number of bytes read; zero when at
};
-#if defined __USE_SVID || defined __USE_GNU
+#if defined __USE_MISC || defined __USE_GNU
# define __need_FILE
# include <stdio.h>
#endif
-#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Rewind the group-file stream.
This function is a possible cancellation point and therefore not
extern void setgrent (void);
#endif
-#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED \
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN_EXTENDED \
|| defined __USE_XOPEN2K8
/* Close the group-file stream.
extern struct group *getgrent (void);
#endif
-#ifdef __USE_SVID
+#ifdef __USE_MISC
/* Read a group entry from STREAM.
This function is not part of POSIX and therefore no official
char *__restrict __buffer, size_t __buflen,
struct group **__restrict __result);
-# ifdef __USE_SVID
+# ifdef __USE_MISC
/* Read a group entry from STREAM. This function is not standardized
an probably never will.
#endif /* POSIX or reentrant */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define __need_size_t
# include <stddef.h>
__USE_LARGEFILE Define correct standard I/O things.
__USE_LARGEFILE64 Define LFS things with separate names.
__USE_FILE_OFFSET64 Define 64bit interface as default.
- __USE_BSD Define 4.3BSD things.
- __USE_SVID Define SVID things.
- __USE_MISC Define things common to BSD and System V Unix.
+ __USE_MISC Define things from 4.3BSD or System V Unix.
__USE_ATFILE Define *at interfaces and AT_* constants for them.
__USE_GNU Define GNU extensions.
__USE_REENTRANT Define reentrant/thread-safe *_r functions.
#undef __USE_LARGEFILE
#undef __USE_LARGEFILE64
#undef __USE_FILE_OFFSET64
-#undef __USE_BSD
-#undef __USE_SVID
#undef __USE_MISC
#undef __USE_ATFILE
#undef __USE_GNU
# define _LARGEFILE64_SOURCE 1
# undef _DEFAULT_SOURCE
# define _DEFAULT_SOURCE 1
-# undef _BSD_SOURCE
-# define _BSD_SOURCE 1
-# undef _SVID_SOURCE
-# define _SVID_SOURCE 1
# undef _ATFILE_SOURCE
# define _ATFILE_SOURCE 1
#endif
/* If nothing (other than _GNU_SOURCE and _DEFAULT_SOURCE) is defined,
- define _DEFAULT_SOURCE, _BSD_SOURCE and _SVID_SOURCE. */
+ define _DEFAULT_SOURCE. */
#if (defined _DEFAULT_SOURCE \
|| (!defined __STRICT_ANSI__ \
&& !defined _ISOC99_SOURCE \
&& !defined _POSIX_SOURCE && !defined _POSIX_C_SOURCE \
- && !defined _XOPEN_SOURCE \
- && !defined _BSD_SOURCE && !defined _SVID_SOURCE))
+ && !defined _XOPEN_SOURCE))
# undef _DEFAULT_SOURCE
# define _DEFAULT_SOURCE 1
-# undef _BSD_SOURCE
-# define _BSD_SOURCE 1
-# undef _SVID_SOURCE
-# define _SVID_SOURCE 1
#endif
/* This is to enable the ISO C11 extension. */
# define __USE_FILE_OFFSET64 1
#endif
-#if defined _BSD_SOURCE || defined _SVID_SOURCE
+#if defined _DEFAULT_SOURCE
# define __USE_MISC 1
#endif
-#ifdef _BSD_SOURCE
-# define __USE_BSD 1
-#endif
-
-#ifdef _SVID_SOURCE
-# define __USE_SVID 1
-#endif
-
#ifdef _ATFILE_SOURCE
# define __USE_ATFILE 1
#endif
#include <sys/cdefs.h>
#include <sys/types.h>
-#ifdef __USE_BSD
+#ifdef __USE_MISC
#include <netinet/in.h>
# define S_ISUID __S_ISUID /* Set user ID on execution. */
# define S_ISGID __S_ISGID /* Set group ID on execution. */
-# if defined __USE_BSD || defined __USE_MISC || defined __USE_XOPEN
+# if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN
/* Save swapped text after use (sticky bit). This is pretty well obsolete. */
# define S_ISVTX __S_ISVTX
# endif
FTW_NS, /* Unstatable file. */
#define FTW_NS FTW_NS
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
FTW_SL, /* Symbolic link. */
# define FTW_SL FTW_SL
#include <bits/stat.h>
-#if defined __USE_BSD || defined __USE_MISC || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN
# define S_IFMT __S_IFMT
# define S_IFDIR __S_IFDIR
# define S_IFCHR __S_IFCHR
# ifdef __S_IFLNK
# define S_IFLNK __S_IFLNK
# endif
-# if (defined __USE_BSD || defined __USE_MISC || defined __USE_UNIX98) \
+# if (defined __USE_MISC || defined __USE_MISC || defined __USE_UNIX98) \
&& defined __S_IFSOCK
# define S_IFSOCK __S_IFSOCK
# endif
# define S_ISLNK(mode) __S_ISTYPE((mode), __S_IFLNK)
#endif
-#if defined __USE_BSD && !defined __S_IFLNK
+#if defined __USE_MISC && !defined __S_IFLNK
# define S_ISLNK(mode) 0
#endif
-#if (defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K) \
+#if (defined __USE_MISC || defined __USE_UNIX98 || defined __USE_XOPEN2K) \
&& defined __S_IFSOCK
# define S_ISSOCK(mode) __S_ISTYPE((mode), __S_IFSOCK)
#elif defined __USE_XOPEN2K
#define S_ISUID __S_ISUID /* Set user ID on execution. */
#define S_ISGID __S_ISGID /* Set group ID on execution. */
-#if defined __USE_BSD || defined __USE_MISC || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN
/* Save swapped text after use (sticky bit). This is pretty well obsolete. */
# define S_ISVTX __S_ISVTX
#endif
/* Read, write, and execute by owner. */
#define S_IRWXU (__S_IREAD|__S_IWRITE|__S_IEXEC)
-#if defined __USE_MISC && defined __USE_BSD
+#if defined __USE_MISC && defined __USE_MISC
# define S_IREAD S_IRUSR
# define S_IWRITE S_IWUSR
# define S_IEXEC S_IXUSR
#define S_IRWXO (S_IRWXG >> 3)
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Macros for common mode bit masks. */
# define ACCESSPERMS (S_IRWXU|S_IRWXG|S_IRWXO) /* 0777 */
# define ALLPERMS (S_ISUID|S_ISGID|S_ISVTX|S_IRWXU|S_IRWXG|S_IRWXO)/* 07777 */
# endif
#endif
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K
# ifndef __USE_FILE_OFFSET64
/* Get file attributes about FILE and put them in BUF.
If FILE is a symbolic link, do not follow it. */
extern int chmod (const char *__file, __mode_t __mode)
__THROW __nonnull ((1));
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Set file access permissions for FILE to MODE.
If FILE is a symbolic link, this affects the link itself
rather than its target. */
#endif
/* Set file access permissions of the file FD is open on to MODE. */
-#if defined __USE_BSD || defined __USE_POSIX
+#if defined __USE_MISC || defined __USE_POSIX
extern int fchmod (int __fd, __mode_t __mode) __THROW;
#endif
/* Create a device file named PATH, with permission and special bits MODE
and device number DEV (which can be constructed from major and minor
device numbers with the `makedev' macro above). */
-#if defined __USE_MISC || defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN_EXTENDED
extern int mknod (const char *__path, __mode_t __mode, __dev_t __dev)
__THROW __nonnull ((1));
return __xstat (_STAT_VER, __path, __statbuf);
}
-# if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+# if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
__extern_inline int
__NTH (lstat (const char *__path, struct stat *__statbuf))
{
}
# endif
-# if defined __USE_MISC || defined __USE_BSD
+# if defined __USE_MISC || defined __USE_MISC
__extern_inline int
__NTH (mknod (const char *__path, __mode_t __mode, __dev_t __dev))
{
return __xstat64 (_STAT_VER, __path, __statbuf);
}
-# if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+# if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
__extern_inline int
__NTH (lstat64 (const char *__path, struct stat64 *__statbuf))
{
#endif
__END_NAMESPACE_STD
-#if defined __USE_BSD || defined __USE_ISOC99 || defined __USE_UNIX98
+#if defined __USE_MISC || defined __USE_ISOC99 || defined __USE_UNIX98
__BEGIN_NAMESPACE_C99
__LDBL_REDIR_DECL (snprintf)
__LDBL_REDIR_DECL (vsnprintf)
#if __USE_FORTIFY_LEVEL > 0 && defined __fortify_function
__LDBL_REDIR_DECL (__sprintf_chk)
__LDBL_REDIR_DECL (__vsprintf_chk)
-# if defined __USE_BSD || defined __USE_ISOC99 || defined __USE_UNIX98
+# if defined __USE_MISC || defined __USE_ISOC99 || defined __USE_UNIX98
__LDBL_REDIR_DECL (__snprintf_chk)
__LDBL_REDIR_DECL (__vsnprintf_chk)
# endif
__bos (__s), __fmt, __ap);
}
-#if defined __USE_BSD || defined __USE_ISOC99 || defined __USE_UNIX98
+#if defined __USE_MISC || defined __USE_ISOC99 || defined __USE_UNIX98
extern int __snprintf_chk (char *__restrict __s, size_t __n, int __flag,
size_t __slen, const char *__restrict __format,
/* The opaque type of streams. This is the definition used elsewhere. */
typedef struct _IO_FILE FILE;
__END_NAMESPACE_STD
-#if defined __USE_LARGEFILE64 || defined __USE_SVID || defined __USE_POSIX \
- || defined __USE_BSD || defined __USE_ISOC99 || defined __USE_XOPEN \
+#if defined __USE_LARGEFILE64 || defined __USE_MISC || defined __USE_POSIX \
+ || defined __USE_MISC || defined __USE_ISOC99 || defined __USE_XOPEN \
|| defined __USE_POSIX2
__USING_NAMESPACE_STD(FILE)
#endif
#endif
-#if defined __USE_SVID || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
/* Default path prefix for `tempnam' and `tmpnam'. */
# define P_tmpdir "/tmp"
#endif
#endif
-#if defined __USE_SVID || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
/* Generate a unique temporary filename using up to five characters of PFX
if it is not NULL. The directory to put this file in is searched for
as follows: First the environment variable "TMPDIR" is checked.
int __modes, size_t __n) __THROW;
__END_NAMESPACE_STD
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* If BUF is NULL, make STREAM unbuffered.
Else make it use SIZE bytes of BUF for buffering. */
extern void setbuffer (FILE *__restrict __stream, char *__restrict __buf,
_G_va_list __arg) __THROWNL;
__END_NAMESPACE_STD
-#if defined __USE_BSD || defined __USE_ISOC99 || defined __USE_UNIX98
+#if defined __USE_MISC || defined __USE_ISOC99 || defined __USE_UNIX98
__BEGIN_NAMESPACE_C99
/* Maximum chars of output to write in MAXLEN. */
extern int snprintf (char *__restrict __s, size_t __maxlen,
#endif /* Use POSIX or MISC. */
-#if defined __USE_SVID || defined __USE_MISC \
+#if defined __USE_MISC || defined __USE_MISC \
|| (defined __USE_XOPEN && !defined __USE_XOPEN2K)
/* Get a word (int) from STREAM. */
extern int getw (FILE *__stream);
#endif
-#if (defined __USE_POSIX2 || defined __USE_SVID || defined __USE_BSD || \
+#if (defined __USE_POSIX2 || defined __USE_MISC || defined __USE_MISC || \
defined __USE_MISC)
/* Create a new stream connected to a pipe running the given command.
#endif
-#ifdef __USE_SVID
+#ifdef __USE_MISC
/* In SVID error handling, `matherr' is called with this description
of the exceptional condition.
/* Some useful constants. */
-#if defined __USE_BSD || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
# define M_E 2.7182818284590452354 /* e */
# define M_LOG2E 1.4426950408889634074 /* log_2 e */
# define M_LOG10E 0.43429448190325182765 /* log_10 e */
__LDBL_REDIR_DECL (syslog)
-#ifdef __USE_BSD
+#ifdef __USE_MISC
__LDBL_REDIR_DECL (vsyslog)
#endif
#if __USE_FORTIFY_LEVEL > 0 && defined __fortify_function
__LDBL_REDIR_DECL (__syslog_chk)
-# ifdef __USE_BSD
+# ifdef __USE_MISC
__LDBL_REDIR_DECL (__vsyslog_chk)
# endif
#endif
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
extern void __vsyslog_chk (int __pri, int __flag, const char *__fmt,
__gnuc_va_list __ap)
__attribute__ ((__format__ (__printf__, 3, 0)));
__BEGIN_DECLS
-#if defined __USE_SVID || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Prototype structure for a linked-list data structure.
This is the type used by the `insque' and `remque' functions. */
__THROW. */
extern int msync (void *__addr, size_t __len, int __flags);
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Advise the system about particular usage patterns the program follows
for the region starting at ADDR and extending LEN bytes. */
extern int madvise (void *__addr, size_t __len, int __advice) __THROW;
extern void syslog (int __pri, const char *__fmt, ...)
__attribute__ ((__format__ (__printf__, 2, 3)));
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Generate a log message using FMT and using arguments pointed to by AP.
This function is not part of POSIX and therefore no official
__wur;
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# ifndef __USE_FILE_OFFSET64
/* Read data from file descriptor FD at the given position OFFSET
without change the file pointer, and put the result in the buffers
+2014-02-12 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/hppa/bits/mman.h [__USE_BSD]: Change
+ condition to [__USE_MISC].
+
2014-02-10 Joseph Myers <joseph@codesourcery.com>
* sysdeps/unix/sysv/linux/hppa/umount.c: Move to
#endif
/* Advice to "madvise" */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define MADV_NORMAL 0 /* No further special treatment */
# define MADV_RANDOM 1 /* Expect random page references */
# define MADV_SEQUENTIAL 2 /* Expect sequential page references */
# endif
#endif
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K
extern ssize_t __readlink_chk (const char *__restrict __path,
char *__restrict __buf, size_t __len,
size_t __buflen)
return __getcwd_alias (__buf, __size);
}
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
extern char *__getwd_chk (char *__buf, size_t buflen)
__THROW __nonnull ((1)) __wur;
extern char *__REDIRECT_NTH (__getwd_warn, (char *__buf), getwd)
#endif
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_MISC || defined __USE_UNIX98
extern int __gethostname_chk (char *__buf, size_t __buflen, size_t __nreal)
__THROW __nonnull ((1));
extern int __REDIRECT_NTH (__gethostname_alias, (char *__buf, size_t __buflen),
#endif
-#if defined __USE_BSD || (defined __USE_XOPEN && !defined __USE_UNIX98)
+#if defined __USE_MISC || (defined __USE_XOPEN && !defined __USE_UNIX98)
extern int __getdomainname_chk (char *__buf, size_t __buflen, size_t __nreal)
__THROW __nonnull ((1)) __wur;
extern int __REDIRECT_NTH (__getdomainname_alias, (char *__buf,
#define GLOB_NOESCAPE (1 << 6)/* Backslashes don't quote metacharacters. */
#define GLOB_PERIOD (1 << 7)/* Leading `.' can be matched by metachars. */
-#if !defined __USE_POSIX2 || defined __USE_BSD || defined __USE_GNU
+#if !defined __USE_POSIX2 || defined __USE_MISC || defined __USE_GNU
# define GLOB_MAGCHAR (1 << 8)/* Set in gl_flags if any metachars seen. */
# define GLOB_ALTDIRFUNC (1 << 9)/* Use gl_opendir et al functions. */
# define GLOB_BRACE (1 << 10)/* Expand "{a,b}" to "a" "b". */
regoff_t *__starts, regoff_t *__ends);
#endif /* Use GNU */
-#if defined _REGEX_RE_COMP || (defined _LIBC && defined __USE_BSD)
+#if defined _REGEX_RE_COMP || (defined _LIBC && defined __USE_MISC)
# ifndef _CRAY
/* 4.2 bsd compatibility. */
extern char *re_comp (const char *);
#include <bits/types.h>
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# ifndef __u_char_defined
typedef __u_char u_char;
typedef __u_short u_short;
# define __pid_t_defined
#endif
-#if (defined __USE_SVID || defined __USE_XOPEN || defined __USE_XOPEN2K8) \
+#if (defined __USE_MISC || defined __USE_XOPEN || defined __USE_XOPEN2K8) \
&& !defined __id_t_defined
typedef __id_t id_t;
# define __id_t_defined
# define __ssize_t_defined
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
typedef __caddr_t caddr_t;
# endif
#endif
-#if (defined __USE_SVID || defined __USE_XOPEN) && !defined __key_t_defined
+#if (defined __USE_MISC || defined __USE_XOPEN) && !defined __key_t_defined
typedef __key_t key_t;
# define __key_t_defined
#endif
#define __BIT_TYPES_DEFINED__ 1
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* In BSD <sys/types.h> is expected to define BYTE_ORDER. */
# include <endian.h>
#endif
};
-#ifdef __USE_SVID
+#ifdef __USE_MISC
/* Note that SVID assumes all members have the same size. */
# define SYS_NMLN _UTSNAME_LENGTH
#endif
bits to `waitpid', `wait3', and `wait4'. */
# include <bits/waitflags.h>
-# ifdef __USE_BSD
+# ifdef __USE_MISC
/* Lots of hair to allow traditional BSD use of `union wait'
as well as POSIX.1 use of `int' for the status word. */
# endif
#endif /* <stdlib.h> not included. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define WCOREFLAG __WCOREFLAG
# define WCOREDUMP(status) __WCOREDUMP (__WAIT_INT (status))
# define W_EXITCODE(ret, sig) __W_EXITCODE (ret, sig)
#endif
/* The following values are used by the `waitid' function. */
-#if defined __USE_SVID || defined __USE_XOPEN || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_XOPEN || defined __USE_XOPEN2K8
typedef enum
{
P_ALL, /* Wait for any child. */
__THROW. */
extern __pid_t wait (__WAIT_STATUS __stat_loc);
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Special values for the PID argument to `waitpid' and `wait4'. */
# define WAIT_ANY (-1) /* Any process. */
# define WAIT_MYPGRP 0 /* Any process in my process group. */
__THROW. */
extern __pid_t waitpid (__pid_t __pid, int *__stat_loc, int __options);
-#if defined __USE_SVID || defined __USE_XOPEN || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_XOPEN || defined __USE_XOPEN2K8
# ifndef __id_t_defined
# include <bits/types.h>
typedef __id_t id_t;
int __options);
#endif
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* This being here makes the prototypes valid whether or not
we have already included <sys/resource.h> to define `struct rusage'. */
struct rusage;
struct rusage * __usage) __THROWNL;
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* PID is like waitpid. Other args are like wait3. */
extern __pid_t wait4 (__pid_t __pid, __WAIT_STATUS __stat_loc, int __options,
struct rusage *__usage) __THROWNL;
# endif
#endif
-#if defined __USE_BSD || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
# ifndef __socklen_t_defined
typedef __socklen_t socklen_t;
# define __socklen_t_defined
# endif
#endif
-#if defined __USE_BSD && !defined L_SET
+#if defined __USE_MISC && !defined L_SET
/* Old BSD names for the same constants; just for compatibility. */
# define L_SET SEEK_SET
# define L_INCR SEEK_CUR
extern unsigned int sleep (unsigned int __seconds);
#if (defined __USE_XOPEN_EXTENDED && !defined __USE_XOPEN2K8) \
- || defined __USE_BSD
+ || defined __USE_MISC
/* Set an alarm to go off (generating a SIGALRM signal) in VALUE
microseconds. If INTERVAL is nonzero, when the alarm goes off, the
timer is reset to go off every INTERVAL microseconds thereafter.
extern int chown (const char *__file, __uid_t __owner, __gid_t __group)
__THROW __nonnull ((1)) __wur;
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
/* Change the owner and group of the file that FD is open on. */
extern int fchown (int __fd, __uid_t __owner, __gid_t __group) __THROW __wur;
/* Change the process's working directory to PATH. */
extern int chdir (const char *__path) __THROW __nonnull ((1)) __wur;
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
/* Change the process's working directory to the one FD is open on. */
extern int fchdir (int __fd) __THROW __wur;
#endif
#endif
#if (defined __USE_XOPEN_EXTENDED && !defined __USE_XOPEN2K8) \
- || defined __USE_BSD
+ || defined __USE_MISC
/* Put the absolute pathname of the current working directory in BUF.
If successful, return BUF. If not, put an error message in
BUF and return NULL. BUF should be at least PATH_MAX bytes long. */
If PGID is zero, the process ID of the process is used. */
extern int setpgid (__pid_t __pid, __pid_t __pgid) __THROW;
-#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Both System V and BSD have `setpgrp' functions, but with different
calling conventions. The BSD function is the same as POSIX.1 `setpgid'
(above). The System V function takes no arguments and puts the calling
if not, the effective user ID is set to UID. */
extern int setuid (__uid_t __uid) __THROW __wur;
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Set the real user ID of the calling process to RUID,
and the effective user ID of the calling process to EUID. */
extern int setreuid (__uid_t __ruid, __uid_t __euid) __THROW __wur;
#endif
-#if defined __USE_BSD || defined __USE_XOPEN2K
+#if defined __USE_MISC || defined __USE_XOPEN2K
/* Set the effective user ID of the calling process to UID. */
extern int seteuid (__uid_t __uid) __THROW __wur;
#endif /* Use BSD. */
if not, the effective group ID is set to GID. */
extern int setgid (__gid_t __gid) __THROW __wur;
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Set the real group ID of the calling process to RGID,
and the effective group ID of the calling process to EGID. */
extern int setregid (__gid_t __rgid, __gid_t __egid) __THROW __wur;
#endif
-#if defined __USE_BSD || defined __USE_XOPEN2K
+#if defined __USE_MISC || defined __USE_XOPEN2K
/* Set the effective group ID of the calling process to GID. */
extern int setegid (__gid_t __gid) __THROW __wur;
#endif /* Use BSD. */
extern __pid_t fork (void) __THROWNL;
#if (defined __USE_XOPEN_EXTENDED && !defined __USE_XOPEN2K8) \
- || defined __USE_BSD
+ || defined __USE_MISC
/* Clone the calling process, but without copying the whole address space.
The calling process is suspended until the new process exits or is
replaced by a call to `execve'. Return -1 for errors, 0 to the new process,
with a terminal, zero if not. */
extern int isatty (int __fd) __THROW;
-#if defined __USE_BSD \
+#if defined __USE_MISC \
|| (defined __USE_XOPEN_EXTENDED && !defined __USE_UNIX98)
/* Return the index into the active-logins file (utmp) for
the controlling terminal. */
__THROW __nonnull ((2, 4)) __wur;
#endif
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K
/* Make a symbolic link to FROM named TO. */
extern int symlink (const char *__from, const char *__to)
__THROW __nonnull ((1, 2)) __wur;
extern int getlogin_r (char *__name, size_t __name_len) __nonnull ((1));
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Set the login name returned by `getlogin'. */
extern int setlogin (const char *__name) __THROW __nonnull ((1));
#endif
#endif
-#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K
+#if defined __USE_MISC || defined __USE_UNIX98 || defined __USE_XOPEN2K
/* Put the name of the current host in no more than LEN bytes of NAME.
The result is null-terminated if LEN is large enough for the full
name and the terminator. */
#endif
-#if defined __USE_BSD || (defined __USE_XOPEN && !defined __USE_UNIX98)
+#if defined __USE_MISC || (defined __USE_XOPEN && !defined __USE_UNIX98)
/* Set the name of the current host to NAME, which is LEN bytes long.
This call is restricted to the super-user. */
extern int sethostname (const char *__name, size_t __len)
#endif /* Use BSD || X/Open. */
-#if defined __USE_BSD || (defined __USE_XOPEN && !defined __USE_XOPEN2K)
+#if defined __USE_MISC || (defined __USE_XOPEN && !defined __USE_XOPEN2K)
/* Make PATH be the root directory (the starting point for absolute paths).
This call is restricted to the super-user. */
extern int chroot (const char *__path) __THROW __nonnull ((1)) __wur;
#endif
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Return identifier for the current host. */
extern long int gethostid (void);
extern void sync (void) __THROW;
-# if defined __USE_BSD || !defined __USE_XOPEN2K
+# if defined __USE_MISC || !defined __USE_XOPEN2K
/* Return the number of bytes in a page. This is the system's page size,
which is not necessarily the same as the hardware page size. */
extern int getpagesize (void) __THROW __attribute__ ((__const__));
#endif /* Use BSD || X/Open Unix. */
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
/* Truncate FILE to LENGTH bytes. */
# ifndef __USE_FILE_OFFSET64
#endif /* Use BSD || X/Open Unix || POSIX 2008. */
-#if defined __USE_BSD || defined __USE_POSIX199309 \
+#if defined __USE_MISC || defined __USE_POSIX199309 \
|| defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K
/* Truncate the file FD is open on to LENGTH bytes. */
};
-#if defined __USE_SVID || defined __USE_GNU
+#if defined __USE_MISC || defined __USE_GNU
# define __need_FILE
# include <stdio.h>
#endif
-#if defined __USE_SVID || defined __USE_MISC || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Rewind the password-file stream.
This function is a possible cancellation point and therefore not
extern struct passwd *getpwent (void);
#endif
-#ifdef __USE_SVID
+#ifdef __USE_MISC
/* Read an entry from STREAM.
This function is not part of POSIX and therefore no official
other reentrant functions so the chances are good this is what the
POSIX people would choose. */
-# if defined __USE_SVID || defined __USE_MISC
+# if defined __USE_MISC || defined __USE_MISC
/* This function is not part of POSIX and therefore no official
cancellation point. But due to similarity with an POSIX interface
or due to the implementation it is a cancellation point and
struct passwd **__restrict __result);
-# ifdef __USE_SVID
+# ifdef __USE_MISC
/* Read an entry from STREAM. This function is not standardized and
probably never will.
#endif /* misc */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Call `rshd' at port RPORT on remote machine *AHOST to execute CMD.
The local user is LOCUSER, on the remote machine the command is
executed as REMUSER. In *FD2P the descriptor to the socket for the
__END_NAMESPACE_STD
-#if defined __USE_BSD || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
/* Same. Usually `_longjmp' is used with `_setjmp', which does not save
the signal mask. But it is how ENV was saved that determines whether
`longjmp' restores the mask; `_longjmp' is just an alias. */
handler, or SIG_ERR on error.
By default `signal' has the BSD semantic. */
__BEGIN_NAMESPACE_STD
-#ifdef __USE_BSD
+#ifdef __USE_MISC
extern __sighandler_t signal (int __sig, __sighandler_t __handler)
__THROW;
#else
extern int kill (__pid_t __pid, int __sig) __THROW;
#endif /* Use POSIX. */
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Send SIG to all processes in process group PGRP.
If PGRP is zero, send SIG to all processes in
the current process's process group. */
extern int raise (int __sig) __THROW;
__END_NAMESPACE_STD
-#ifdef __USE_SVID
+#ifdef __USE_MISC
/* SVID names for the same things. */
extern __sighandler_t ssignal (int __sig, __sighandler_t __handler)
__THROW;
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* None of the following functions should be used anymore. They are here
only for compatibility. A single word (`int') is not guaranteed to be
enough to hold a complete signal mask and therefore these functions
#endif
/* 4.4 BSD uses the name `sig_t' for this. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
typedef __sighandler_t sig_t;
#endif
#endif /* Use POSIX. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Names of the signals. This variable exists only for compatibility.
Use `strsignal' instead (see <string.h>). */
#endif /* use BSD. */
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
# define __need_size_t
# include <stddef.h>
`struct msghdr', and `struct linger' types. */
#include <bits/socket.h>
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* This is the 4.3 BSD `struct sockaddr' format, which is used as wire
format in the grotty old 4.3 `talk' protocol. */
struct osockaddr
int __severity, const char *__text,
const char *__action, const char *__tag);
-#ifdef __USE_SVID
+#ifdef __USE_MISC
/* Add or remove severity level. */
extern int addseverity (int __severity, const char *__string) __THROW;
#endif
# include <bits/waitflags.h>
# include <bits/waitstatus.h>
-# ifdef __USE_BSD
+# ifdef __USE_MISC
/* Lots of hair to allow traditional BSD use of `union wait'
as well as POSIX.1 use of `int' for the status word. */
__THROW __nonnull ((1));
__END_NAMESPACE_STD
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Convert a string to a quadword integer. */
__extension__
extern long long int strtoq (const char *__restrict __nptr,
#endif /* Optimizing and Inlining. */
-#if defined __USE_SVID || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Convert N to base 64 using the digits "./0-9A-Za-z", least-significant
digit first. Returns a pointer to static storage overwritten by the
next call. */
#endif /* Use SVID || extended X/Open. */
-#if defined __USE_SVID || defined __USE_XOPEN_EXTENDED || defined __USE_BSD
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED || defined __USE_MISC
# include <sys/types.h> /* we need int32_t... */
/* These are the functions that actually do things. The `random', `srandom',
#endif
-#if defined __USE_SVID || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
/* System V style 48-bit random number generator functions. */
/* Return non-negative, double-precision floating-point value in [0.0,1.0). */
extern void cfree (void *__ptr) __THROW;
#endif /* Use misc. */
-#if defined __USE_GNU || defined __USE_BSD || defined __USE_MISC
+#if defined __USE_GNU || defined __USE_MISC || defined __USE_MISC
# include <alloca.h>
#endif /* Use GNU, BSD, or misc. */
#if (defined __USE_XOPEN_EXTENDED && !defined __USE_XOPEN2K) \
- || defined __USE_BSD
+ || defined __USE_MISC
/* Allocate SIZE bytes on a page boundary. The storage cannot be freed. */
extern void *valloc (size_t __size) __THROW __attribute_malloc__ __wur;
#endif
__THROW __nonnull ((1)) __wur;
#endif
-#if defined __USE_SVID || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
/* The SVID says this is in <stdio.h>, but this seems a better place. */
/* Put STRING, which is of the form "NAME=VALUE", in the environment.
If there is no `=', remove NAME from the environment. */
extern int putenv (char *__string) __THROW __nonnull ((1));
#endif
-#if defined __USE_BSD || defined __USE_XOPEN2K
+#if defined __USE_MISC || defined __USE_XOPEN2K
/* Set NAME to VALUE in the environment.
If REPLACE is nonzero, overwrite an existing value. */
extern int setenv (const char *__name, const char *__value, int __replace)
# endif
#endif
-#if defined __USE_BSD || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_XOPEN2K8
/* Create a unique temporary directory from TEMPLATE.
The last six characters of TEMPLATE must be "XXXXXX";
they are replaced with a string that makes the directory name unique.
__THROW __nonnull ((1)) __wur;
#endif
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Return the canonical absolute name of file NAME. If RESOLVED is
null, the result is malloc'd; otherwise, if the canonical name is
PATH_MAX chars or more, returns null with `errno' set to
#if (defined __USE_XOPEN_EXTENDED && !defined __USE_XOPEN2K8) \
- || defined __USE_SVID
+ || defined __USE_MISC
/* Convert floating point numbers to strings. The returned values are
valid only until another call to the same function. */
__END_NAMESPACE_STD
-#ifdef __USE_SVID
+#ifdef __USE_MISC
/* Determine whether the string value of RESPONSE matches the affirmation
or negative response expression as specified by the LC_MESSAGES category
in the program's current locale. Returns 1 if affirmative, 0 if
extern int getpt (void);
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Put the 1 minute, 5 minute and 15 minute load averages into the first
NELEM elements of LOADAVG. Return the number written (never more than
three, but may be less than NELEM), or -1 if an error occurred. */
}
return __retval;
}
-# ifdef __USE_BSD
+# ifdef __USE_MISC
# define strsep(s, reject) __strsep (s, reject)
# endif
#endif
__retval; })) \
: __strdup (s)))
-# if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+# if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN_EXTENDED
# define strdup(s) __strdup (s)
# endif
# endif
# undef mempcpy
# undef stpcpy
# endif
-# ifdef __USE_BSD
+# ifdef __USE_MISC
# undef bcopy
# undef bzero
# endif
return __builtin___memset_chk (__dest, __ch, __len, __bos0 (__dest));
}
-#ifdef __USE_BSD
+#ifdef __USE_MISC
__fortify_function void
__NTH (bcopy (const void *__src, void *__dest, size_t __len))
{
# define __FLOAT_WORD_ORDER __BYTE_ORDER
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define LITTLE_ENDIAN __LITTLE_ENDIAN
# define BIG_ENDIAN __BIG_ENDIAN
# define PDP_ENDIAN __PDP_ENDIAN
#endif
-#if defined __USE_BSD && !defined __ASSEMBLER__
+#if defined __USE_MISC && !defined __ASSEMBLER__
/* Conversion interfaces. */
# include <bits/byteswap.h>
/* Copy no more than N bytes of SRC to DEST, stopping when C is found.
Return the position in DEST one byte past where C was copied,
or NULL if C was not found in the first N bytes of SRC. */
-#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN
extern void *memccpy (void *__restrict __dest, const void *__restrict __src,
int __c, size_t __n)
__THROW __nonnull ((1, 2));
__locale_t __l) __THROW __nonnull ((2, 4));
#endif
-#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED \
+#if defined __USE_MISC || defined __USE_MISC || defined __USE_XOPEN_EXTENDED \
|| defined __USE_XOPEN2K8
/* Duplicate S, returning an identical malloc'd string. */
extern char *strdup (const char *__s)
the namespace rules does not allow this. */
extern void __bzero (void *__s, size_t __n) __THROW __nonnull ((1));
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Copy N bytes of SRC to DEST (like memmove, but args reversed). */
extern void bcopy (const void *__src, void *__dest, size_t __n)
__THROW __nonnull ((1, 2));
__THROW __attribute_pure__ __nonnull ((1, 2, 4));
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Return the next DELIM-delimited token from *STRINGP,
terminating it with a '\0', and update *STRINGP to point past it. */
extern char *strsep (char **__restrict __stringp,
#define _STRINGS_H 1
/* We don't need and should not read this file if <string.h> was already
- read. The one exception being that if __USE_BSD isn't defined, then
+ read. The one exception being that if __USE_MISC isn't defined, then
these aren't defined in string.h, so we need to define them here. */
-#if !defined _STRING_H || !defined __USE_BSD
+#if !defined _STRING_H || !defined __USE_MISC
# include <features.h>
# define __need_size_t
/*The options start here. */
};
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/*
* Copyright (c) 1982, 1986, 1993
* The Regents of the University of California. All rights reserved.
#endif
u_int32_t data[9];
};
-#endif /* __USE_BSD */
+#endif /* __USE_MISC */
#define IPVERSION 4 /* IP version number */
#define IP_MAXPACKET 65535 /* maximum packet size */
#define ICMP_EXC_FRAGTIME 1 /* Fragment Reass time exceeded */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/*
* Copyright (c) 1982, 1986, 1993
* The Regents of the University of California. All rights reserved.
(type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || \
(type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY)
-#endif /* __USE_BSD */
+#endif /* __USE_MISC */
__END_DECLS
fail with EAGAIN. */
#define O_NONBLOCK 0x0008 /* Non-blocking open or non-blocking I/O. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define O_NDELAY O_NONBLOCK /* Deprecated. */
#endif
#define O_NOCTTY 0 /* Don't assign a controlling terminal. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Bits in the file status flags returned by F_GETFL. */
# define FREAD O_RDONLY
# define FWRITE O_WRONLY
#define F_SETFD 2 /* Set file descriptor flags. */
#define F_GETFL 3 /* Get file status flags. */
#define F_SETFL 4 /* Set file status flags. */
-#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_UNIX98 || defined __USE_XOPEN2K8
# define F_GETOWN 5 /* Get owner (receiver of SIGIO). */
# define F_SETOWN 6 /* Set owner (receiver of SIGIO). */
#endif
#endif
/* Default file creation mask (umask). */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define CMASK 0022
#endif
#undef MS_INVALIDATE
#define MS_INVALIDATE 4
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# undef MADV_DONTNEED
# define MADV_DONTNEED 6
#endif
#define ICRNL 0000400
#define IXON 0001000
#define IXOFF 0002000
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* POSIX.1 doesn't want these... */
# define IXANY 0004000
# define IUCLC 0010000
# define __F_GETOWN 9
#endif
-#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
+#if defined __USE_MISC || defined __USE_UNIX98 || defined __USE_XOPEN2K8
# define F_SETOWN __F_SETOWN /* Get owner (process receiving SIGIO). */
# define F_GETOWN __F_GETOWN /* Set owner (process receiving SIGIO). */
#endif
# define F_SHLCK 8 /* or 4 */
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Operations for BSD flock, also used by the kernel implementation. */
# define LOCK_SH 1 /* Shared lock. */
# define LOCK_EX 2 /* Exclusive lock. */
/* Define some more compatibility macros to be backward compatible with
BSD systems which did not managed to hide these kernel macros. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define FAPPEND O_APPEND
# define FFSYNC O_FSYNC
# define FASYNC O_ASYNC
#endif
/* Advice to `madvise'. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define MADV_NORMAL 0 /* No further special treatment. */
# define MADV_RANDOM 1 /* Expect random page references. */
# define MADV_SEQUENTIAL 2 /* Expect sequential page references. */
/* sys_errlist and sys_nerr are deprecated. Use strerror instead. */
-#ifdef __USE_BSD
+#ifdef __USE_MISC
extern int sys_nerr;
extern const char *const sys_errlist[];
#endif
# define PENDIN 0040000
#endif
#define IEXTEN 0100000
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define EXTPROC 0200000
#endif
#endif
#define TOSTOP 0100000 /* Send SIGTTOU for background output. */
#define ITOSTOP TOSTOP
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define EXTPROC 0200000
#endif
/* Get definitions from kernel header file. */
#include <linux/if_ether.h>
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/*
* Copyright (c) 1982, 1986, 1993
* The Regents of the University of California. All rights reserved.
}
__END_DECLS
-#endif /* __USE_BSD */
+#endif /* __USE_MISC */
#endif /* netinet/if_ether.h */
#include <linux/if_fddi.h>
-#ifdef __USE_BSD
+#ifdef __USE_MISC
struct fddi_header {
u_int8_t fddi_fc; /* Frame Control (FC) value */
#define TR_RCF_BROADCAST_MASK 0xC000
#define TR_MAXRIFLEN 18
-#ifdef __USE_BSD
+#ifdef __USE_MISC
struct trn_hdr
{
# define PENDIN 0x20000000
#endif
#define IEXTEN 0x00000400
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define EXTPROC 0x10000000
#endif
# define PENDIN 0x00004000
#endif
#define IEXTEN 0x00008000
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# define EXTPROC 0x00010000
#endif
# endif
-# if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+# if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Find the first occurrence of C in S. This is the BSD name. */
# define _HAVE_STRING_ARCH_index 1
# define index(s, c) \
# endif
-# if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+# if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
/* Find the last occurrence of C in S. This is the BSD name. */
# define _HAVE_STRING_ARCH_rindex 1
# define rindex(s, c) \
/* Bit find functions. We define only the i686 version since for the other
processors gcc generates good code. */
-# if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+# if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
# ifdef __i686__
# define _HAVE_STRING_ARCH_ffs 1
# define ffs(word) (__builtin_constant_p (word) \
#include <features.h>
-#if !defined __USE_SVID && !defined __USE_XOPEN && __GNUC__ >= 2
+#if !defined __USE_MISC && !defined __USE_XOPEN && __GNUC__ >= 2
# warning "Files using this header must be compiled with _GNU_SOURCE or _XOPEN_SOURCE"
#endif
`cc_t', `speed_t', and all the macros specifying the flag bits. */
#include <bits/termios.h>
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Compare a character C to a value VAL from the `c_cc' array in a
`struct termios'. If VAL is _POSIX_VDISABLE, no character can match it. */
# define CCEQ(val, c) ((c) == (val) && (val) != _POSIX_VDISABLE)
/* Set the input baud rate stored in *TERMIOS_P to SPEED. */
extern int cfsetispeed (struct termios *__termios_p, speed_t __speed) __THROW;
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Set both the input and output baud rates in *TERMIOS_OP to SPEED. */
extern int cfsetspeed (struct termios *__termios_p, speed_t __speed) __THROW;
#endif
const struct termios *__termios_p) __THROW;
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Set *TERMIOS_P to indicate raw mode. */
extern void cfmakeraw (struct termios *__termios_p) __THROW;
#endif
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
# include <sys/ttydefaults.h>
#endif
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Structure crudely representing a timezone.
This is obsolete and should never be used. */
struct timezone
extern int gettimeofday (struct timeval *__restrict __tv,
__timezone_ptr_t __tz) __THROW __nonnull ((1));
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Set the current time of day and timezone information.
This call is restricted to the super-user. */
extern int settimeofday (const struct timeval *__tv,
extern int utimes (const char *__file, const struct timeval __tvp[2])
__THROW __nonnull ((1));
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Same as `utimes', but does not follow symbolic links. */
extern int lutimes (const char *__file, const struct timeval __tvp[2])
__THROW __nonnull ((1));
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Convenience macros for operations on timevals.
NOTE: `timercmp' does not work for >= or <=. */
# define timerisset(tvp) ((tvp)->tv_sec || (tvp)->tv_usec)
/* Returned by `time'. */
typedef __time_t time_t;
__END_NAMESPACE_STD
-#if defined __USE_POSIX || defined __USE_MISC || defined __USE_SVID
+#if defined __USE_POSIX || defined __USE_MISC || defined __USE_MISC
__USING_NAMESPACE_STD(time_t)
#endif
int tm_yday; /* Days in year.[0-365] */
int tm_isdst; /* DST. [-1/0/1]*/
-# ifdef __USE_BSD
+# ifdef __USE_MISC
long int tm_gmtoff; /* Seconds east of UTC. */
const char *tm_zone; /* Timezone abbreviation. */
# else
extern void tzset (void) __THROW;
# endif
-# if defined __USE_SVID || defined __USE_XOPEN
+# if defined __USE_MISC || defined __USE_XOPEN
extern int daylight;
extern long int timezone;
# endif
-# ifdef __USE_SVID
+# ifdef __USE_MISC
/* Set the system time to *WHEN.
This call is restricted to the superuser. */
extern int stime (const time_t *__when) __THROW;