diff options
| author | Ulrich Drepper <drepper@redhat.com> | 1999-08-18 07:53:35 +0000 |
|---|---|---|
| committer | Ulrich Drepper <drepper@redhat.com> | 1999-08-18 07:53:35 +0000 |
| commit | 219aa9e9f9677e2f50095433ca233abdef23a6b0 (patch) | |
| tree | b558f5684364dbc84b62e8db65d3c8a10b9c9900 | |
| parent | b43f26bbe8f09d0fce67d25549d04f7e19b589c1 (diff) | |
| download | glibc-219aa9e9f9677e2f50095433ca233abdef23a6b0.tar.xz glibc-219aa9e9f9677e2f50095433ca233abdef23a6b0.zip | |
Update.
1999-08-18 Ulrich Drepper <drepper@cygnus.com>
* Rules: When generating stdio_lim.h also rewrite IOV_MAX definition.
* stdio-common/stdio_lim.h.in: Add IOV_MAX template.
* include/bits/xopen_lim.h: Don't define IOV_MAX here, get it from
stdio_lim.h. Define LONG_BIT and WORD_BIT.
* include/features.h: Define __USE_XOPEN2K if _XOPEN_SOURCE == 600.
* libio/stdio.h: Don't declare cuserid and getopt for X/Open issue 6.
* misc/search.h: Don't define NULL.
* posix/sys/types.h: Define blksize_t if it hasn't happened.
Only define key_t and blkcnt_t if it hasn't happened before.
Define blksize_t if not happened before.
* io/sys/stat.h: Don't define pid_t. Define blkcnt_t and blksize_t.
* sysdeps/generic/bits/types.h: Define __blksize_t.
* sysdeps/unix/sysv/linux/alpha/bits/types.h: Likewise.
* sysdeps/unix/sysv/linux/bits/types.h: Likewise.
* sysdeps/unix/sysv/linux/mips/bits/types.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/bits/types.h: Likewise.
* sysdeps/unix/sysv/sysv4/solaris2/bits/types.h: Likewise.
* sysdeps/mach/hurd/bits/stat.h (struct stat): Use __blksize_t for
st_blksize member.
(struct stat64): Likewise.
* sysdeps/unix/bsd/bits/stat.h: Likewise.
* sysdeps/unix/bsd/osf/alpha/bits/stat.h: Likewise.
* sysdeps/unix/sysv/linux/alpha/bits/stat.h: Likewise.
* sysdeps/unix/sysv/linux/bits/stat.h: Likewise.
* sysdeps/unix/sysv/linux/mips/bits/stat.h: Likewise.
* sysdeps/unix/sysv/sysv4/i386/bist/stat.h: Likewise.
* sysdeps/unix/sysv/sysv4/solaris2/bits/stat.h: Likewise.
* stdlib/getsubopt.c: Correct type of second argument.
* stdlib/stdlib.h: Likewise.
* stdlib/monetary.h: Don't include sys/types.h. Define only size_t
and ssize_t.
* sysdeps/generic/putenv.c: Correct type of parameter.
* stdlib/stdlib.h: Likewise.
* sysdeps/generic/msgsnd.c: Correct type of second parameter.
* sysdeps/unix/sysv/linux/msgsnd.c: Likewise.
* sysvips/sys/msg.h: Likewise.
* sysdeps/generic/semop.c: Correct type of third parameter.
* sysdeps/unix/sysv/linux/semop.c: Likewise.
* sysvipc/sys/sem.h: Likewise. Don't include sys/types.h, define
size_t.
* sysdeps/generic/shmget.c: Correct type of second parameter.
* sysdeps/unix/sysv/linux/shmget.c: Likewise.
* sysvips/sys/shm.h: Likewise. Don't include unistd.h and sys/types.h.
Declare __getpagesize here.
* sysdeps/generic/bits/ipc.h: Include bits/types.h instead of
sys/types.h.
* sysdeps/gnu/bits/ipc.h: Likewise.
* sysdeps/unix/sysv/linux/alpha/bits/ipc.h: Likewise.
* sysdeps/unix/sysv/linux/mips/bits/ipc.h: Likewise.
* sysdeps/unix/sysv/linux/powerpc/bits/ipc.h: Likewise.
* sysvipc/sys/ipc.h: Define uid_t, gid_t, mode_t, and key_t if not
already done.
* sysdeps/unix/bsd/usleep.c: Correct type of parameter.
* debug/versions: Export __cyg_profile_func_enter and
__cyg_profile_func_exit.
* math/bits/mathcalls.h: Pretty print.
47 files changed, 281 insertions, 103 deletions
@@ -1,3 +1,76 @@ +1999-08-18 Ulrich Drepper <drepper@cygnus.com> + + * Rules: When generating stdio_lim.h also rewrite IOV_MAX definition. + * stdio-common/stdio_lim.h.in: Add IOV_MAX template. + * include/bits/xopen_lim.h: Don't define IOV_MAX here, get it from + stdio_lim.h. Define LONG_BIT and WORD_BIT. + + * include/features.h: Define __USE_XOPEN2K if _XOPEN_SOURCE == 600. + + * libio/stdio.h: Don't declare cuserid and getopt for X/Open issue 6. + + * misc/search.h: Don't define NULL. + + * posix/sys/types.h: Define blksize_t if it hasn't happened. + Only define key_t and blkcnt_t if it hasn't happened before. + Define blksize_t if not happened before. + * io/sys/stat.h: Don't define pid_t. Define blkcnt_t and blksize_t. + * sysdeps/generic/bits/types.h: Define __blksize_t. + * sysdeps/unix/sysv/linux/alpha/bits/types.h: Likewise. + * sysdeps/unix/sysv/linux/bits/types.h: Likewise. + * sysdeps/unix/sysv/linux/mips/bits/types.h: Likewise. + * sysdeps/unix/sysv/linux/sparc/bits/types.h: Likewise. + * sysdeps/unix/sysv/sysv4/solaris2/bits/types.h: Likewise. + * sysdeps/mach/hurd/bits/stat.h (struct stat): Use __blksize_t for + st_blksize member. + (struct stat64): Likewise. + * sysdeps/unix/bsd/bits/stat.h: Likewise. + * sysdeps/unix/bsd/osf/alpha/bits/stat.h: Likewise. + * sysdeps/unix/sysv/linux/alpha/bits/stat.h: Likewise. + * sysdeps/unix/sysv/linux/bits/stat.h: Likewise. + * sysdeps/unix/sysv/linux/mips/bits/stat.h: Likewise. + * sysdeps/unix/sysv/sysv4/i386/bist/stat.h: Likewise. + * sysdeps/unix/sysv/sysv4/solaris2/bits/stat.h: Likewise. + + * stdlib/getsubopt.c: Correct type of second argument. + * stdlib/stdlib.h: Likewise. + + * stdlib/monetary.h: Don't include sys/types.h. Define only size_t + and ssize_t. + + * sysdeps/generic/putenv.c: Correct type of parameter. + * stdlib/stdlib.h: Likewise. + + * sysdeps/generic/msgsnd.c: Correct type of second parameter. + * sysdeps/unix/sysv/linux/msgsnd.c: Likewise. + * sysvips/sys/msg.h: Likewise. + + * sysdeps/generic/semop.c: Correct type of third parameter. + * sysdeps/unix/sysv/linux/semop.c: Likewise. + * sysvipc/sys/sem.h: Likewise. Don't include sys/types.h, define + size_t. + + * sysdeps/generic/shmget.c: Correct type of second parameter. + * sysdeps/unix/sysv/linux/shmget.c: Likewise. + * sysvips/sys/shm.h: Likewise. Don't include unistd.h and sys/types.h. + Declare __getpagesize here. + + * sysdeps/generic/bits/ipc.h: Include bits/types.h instead of + sys/types.h. + * sysdeps/gnu/bits/ipc.h: Likewise. + * sysdeps/unix/sysv/linux/alpha/bits/ipc.h: Likewise. + * sysdeps/unix/sysv/linux/mips/bits/ipc.h: Likewise. + * sysdeps/unix/sysv/linux/powerpc/bits/ipc.h: Likewise. + * sysvipc/sys/ipc.h: Define uid_t, gid_t, mode_t, and key_t if not + already done. + + * sysdeps/unix/bsd/usleep.c: Correct type of parameter. + + * debug/versions: Export __cyg_profile_func_enter and + __cyg_profile_func_exit. + + * math/bits/mathcalls.h: Pretty print. + 1999-08-17 Ulrich Drepper <drepper@cygnus.com> * timezone/tst-timezone.c (tests): Update America/Sao_Paulo test @@ -191,26 +191,32 @@ $(stdio_lim:h=st): $(..)stdio-common/stdio_lim.h.in $(..)Rules \ echo '#include "$(..)posix/bits/posix1_lim.h"' | \ SUNPRO_DEPENDENCIES='$(@:st=dT) $@' \ $(CC) $(+includes) -E -dM -xc - -o $(@:st=hT) + echo '#include "$(..)misc/sys/uio.h"' | \ + SUNPRO_DEPENDENCIES='$(@:st=dT) $@' \ + $(CC) $(+includes) -E -dM -xc - | cat - >> $(@:st=hT) ifdef sed-remove-objpfx sed $(sed-remove-objpfx) $(@:st=dT) > $(@:st=dt) - mv -f $(@:st=dt) $(@:st=d) + cat $(@:st=dt) >> $(@:st=d) else - mv -f $(@:st=dT) $(@:st=d) + cat $(@:st=dT) >> $(@:st=d) endif - fopen_max=`sed -n 's/^#define OPEN_MAX //p' $(@:st=hT)`; \ - filename_max=`sed -n 's/^#define PATH_MAX //p' $(@:st=hT)`; \ + fopen_max=`sed -n 's/^#define OPEN_MAX //1p' $(@:st=hT)`; \ + filename_max=`sed -n 's/^#define PATH_MAX //1p' $(@:st=hT)`; \ + iov_max=`sed -n 's/^#define UIO_MAXIOV //p' $(@:st=hT)`; \ fopen_max=$${fopen_max:-16}; \ filename_max=$${filename_max:-1024}; \ + iov_max=$${iov_max:-_XOPEN_IOV_MAX}; \ sed -e "s/@FOPEN_MAX@/$$fopen_max/" \ -e "s/@FILENAME_MAX@/$$filename_max/" \ -e "s/@L_tmpnam@/$(L_tmpnam)/" \ -e "s/@TMP_MAX@/$(TMP_MAX)/" \ -e "s/@L_ctermid@/$(L_ctermid)/" \ -e "s/@L_cuserid@/$(L_cuserid)/" \ + -e "s/@IOV_MAX@/$$iov_max/" \ $< > $(@:st=h.new) $(move-if-change) $(@:st=h.new) $(@:st=h) # Remove these last so that they can be examined if something went wrong. - rm -f $(@:st=hT) $(@:st=dT) + rm -f $(@:st=hT) $(@:st=dT) $(@:st=dt) touch $@ # Get dependencies. ifndef no_deps diff --git a/bits/ipc.h b/bits/ipc.h index 58f419be1d..7e38fdf5ea 100644 --- a/bits/ipc.h +++ b/bits/ipc.h @@ -1,6 +1,5 @@ -/* Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc. +/* Copyright (C) 1995, 1996, 1997, 1999 Free Software Foundation, Inc. This file is part of the GNU C Library. - Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995. The GNU C Library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as @@ -21,7 +20,7 @@ # error "Never use <bits/ipc.h> directly; include <sys/ipc.h> instead." #endif -#include <sys/types.h> +#include <bits/types.h> /* Mode bits for `msgget', `semget', and `shmget'. */ #define IPC_CREAT 01000 /* create key if key does not exist */ diff --git a/bits/types.h b/bits/types.h index 8d2061235d..fd9818e15d 100644 --- a/bits/types.h +++ b/bits/types.h @@ -115,6 +115,9 @@ typedef struct typedef unsigned short int __ipc_pid_t; +/* Type to represent block size. */ +typedef unsigned int __blksize_t; + /* Types from the Large File Support interface. */ /* Type to count number os disk blocks. */ diff --git a/debug/Versions b/debug/Versions index 01d390eb9f..c2b6396d82 100644 --- a/debug/Versions +++ b/debug/Versions @@ -6,4 +6,8 @@ libc { # b* backtrace; backtrace_symbols; backtrace_symbols_fd; } + GLIBC_2.2 { + # These are to support some gcc features. + __cyg_profile_func_enter; __cyg_profile_func_exit; + } } diff --git a/include/bits/xopen_lim.h b/include/bits/xopen_lim.h index 9f22e44e25..607c50b678 100644 --- a/include/bits/xopen_lim.h +++ b/include/bits/xopen_lim.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1996, 1997 Free Software Foundation, Inc. +/* Copyright (C) 1996, 1997, 1999 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -31,6 +31,7 @@ #define _XOPEN_LIM_H 1 #define __need_FOPEN_MAX +#define __need_IOV_MAX #include <bits/stdio_lim.h> /* We do not provide fixed values for @@ -44,6 +45,9 @@ CHILD_MAX Maximum number of simultaneous processes per real user ID. + IOV_MAX Maximum number of `iovec' structures that one process has + available for use with `readv' or writev'. + OPEN_MAX Maximum number of files that one process can have open at anyone time. @@ -53,11 +57,6 @@ PASS_MAX Maximum number of significant bytes in a password. */ - -/* Maximum number of `iovec' structures that one process has available - for use with `readv' or writev'. */ -#define IOV_MAX _XOPEN_IOV_MAX - /* The number of streams that one process can have open at one time. */ #define STREAM_MAX FOPEN_MAX @@ -93,4 +92,25 @@ /* Default process priority. */ #define NZERO 20 + +/* Number of bits in a word of type `int'. */ +#if INT_MAX == 32767 +# define WORD_BIT 16 +#else +# if INT_MAX == 2147483647 +# define WORD_BIT 32 +# else +/* Safe assumption. */ +# define WORD_BIT 64 +# endif +#endif + +/* Number of bits in a word of type `long int'. */ +#if INT_MAX == 2147483647 +# define LONG_BIT 32 +#else +/* Safe assumption. */ +# define LONG_BIT 64 +#endif + #endif /* bits/xopen_lim.h */ diff --git a/include/features.h b/include/features.h index f04184ac12..1189e3ea79 100644 --- a/include/features.h +++ b/include/features.h @@ -125,7 +125,7 @@ # undef _POSIX_C_SOURCE # define _POSIX_C_SOURCE 199506L # undef _XOPEN_SOURCE -# define _XOPEN_SOURCE 500 +# define _XOPEN_SOURCE 600 # undef _XOPEN_SOURCE_EXTENDED # define _XOPEN_SOURCE_EXTENDED 1 # undef _LARGEFILE64_SOURCE @@ -182,11 +182,14 @@ #ifdef _XOPEN_SOURCE # define __USE_XOPEN 1 -# if (_XOPEN_SOURCE - 0) == 500 +# if (_XOPEN_SOURCE - 0) >= 500 # define __USE_XOPEN_EXTENDED 1 # define __USE_UNIX98 1 # undef _LARGEFILE_SOURCE # define _LARGEFILE_SOURCE 1 +# if (_XOPEN_SOURCE - 0) == 600 +# define __USE_XOPEN2K 1 +# endif # else # ifdef _XOPEN_SOURCE_EXTENDED # define __US |
