diff options
Diffstat (limited to 'sysdeps/unix/sysv')
-rw-r--r-- | sysdeps/unix/sysv/irix4/getpriority.c | 4 | ||||
-rw-r--r-- | sysdeps/unix/sysv/irix4/setpriority.c | 4 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/alpha/bits/shm.h | 11 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/bits/shm.h | 11 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/bits/statvfs.h | 26 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/configure.in | 2 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/fstatvfs64.c | 4 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/getpriority.c | 6 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/internal_statvfs.c | 2 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/sparc/bits/shm.h | 11 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/statvfs64.c | 4 |
11 files changed, 48 insertions, 37 deletions
diff --git a/sysdeps/unix/sysv/irix4/getpriority.c b/sysdeps/unix/sysv/irix4/getpriority.c index 290573a65c..5203b42ac9 100644 --- a/sysdeps/unix/sysv/irix4/getpriority.c +++ b/sysdeps/unix/sysv/irix4/getpriority.c @@ -1,4 +1,4 @@ -/* Copyright (C) 1994, 1996, 1997 Free Software Foundation, Inc. +/* Copyright (C) 1994, 1996, 1997, 2000 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 @@ -29,7 +29,7 @@ extern int __sysmp __P ((int, ...)); int getpriority (which, who) enum __priority_which which; - int who; + id_t who; { switch (which) { diff --git a/sysdeps/unix/sysv/irix4/setpriority.c b/sysdeps/unix/sysv/irix4/setpriority.c index 5d6313ae1c..8e2c8ec943 100644 --- a/sysdeps/unix/sysv/irix4/setpriority.c +++ b/sysdeps/unix/sysv/irix4/setpriority.c @@ -1,4 +1,4 @@ -/* Copyright (C) 1994, 1996, 1997 Free Software Foundation, Inc. +/* Copyright (C) 1994, 1996, 1997, 2000 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 @@ -23,7 +23,7 @@ int setpriority (which, who, prio) enum __priority_which which; - int who; + id_t who; int prio; { switch (which) diff --git a/sysdeps/unix/sysv/linux/alpha/bits/shm.h b/sysdeps/unix/sysv/linux/alpha/bits/shm.h index 683a9b6726..acd479de57 100644 --- a/sysdeps/unix/sysv/linux/alpha/bits/shm.h +++ b/sysdeps/unix/sysv/linux/alpha/bits/shm.h @@ -20,7 +20,7 @@ # error "Never include <bits/shm.h> directly; use <sys/shm.h> instead." #endif -#include <sys/types.h> +#include <bits/types.h> /* Permission flag for shmget. */ #define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */ @@ -36,6 +36,9 @@ #define SHM_UNLOCK 12 /* unlock segment (root only) */ +/* Type to count number of attaches. */ +typedef unsigned long int shmatt_t; + /* Data structure describing a set of semaphores. */ struct shmid_ds { @@ -44,9 +47,9 @@ struct shmid_ds __time_t shm_atime; /* time of last shmat() */ __time_t shm_dtime; /* time of last shmdt() */ __time_t shm_ctime; /* time of last change by shmctl() */ - pid_t shm_cpid; /* pid of creator */ - pid_t shm_lpid; /* pid of last shmop */ - unsigned long int shm_nattch; /* number of current attaches */ + __pid_t shm_cpid; /* pid of creator */ + __pid_t shm_lpid; /* pid of last shmop */ + shmatt_t shm_nattch; /* number of current attaches */ unsigned long int __unused1; unsigned long int __unused2; }; diff --git a/sysdeps/unix/sysv/linux/bits/shm.h b/sysdeps/unix/sysv/linux/bits/shm.h index ca397e810f..8e4b8ac9e8 100644 --- a/sysdeps/unix/sysv/linux/bits/shm.h +++ b/sysdeps/unix/sysv/linux/bits/shm.h @@ -20,7 +20,7 @@ # error "Never include <bits/shm.h> directly; use <sys/shm.h> instead." #endif -#include <sys/types.h> +#include <bits/types.h> /* Permission flag for shmget. */ #define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */ @@ -36,6 +36,9 @@ #define SHM_UNLOCK 12 /* unlock segment (root only) */ +/* Type to count number of attaches. */ +typedef unsigned long int shmatt_t; + /* Data structure describing a set of semaphores. */ struct shmid_ds { @@ -47,9 +50,9 @@ struct shmid_ds unsigned long int __unused2; __time_t shm_ctime; /* time of last change by shmctl() */ unsigned long int __unused3; - pid_t shm_cpid; /* pid of creator */ - pid_t shm_lpid; /* pid of last shmop */ - unsigned long int shm_nattch; /* number of current attaches */ + __pid_t shm_cpid; /* pid of creator */ + __pid_t shm_lpid; /* pid of last shmop */ + shmatt_t shm_nattch; /* number of current attaches */ unsigned long int __unused4; unsigned long int __unused5; }; diff --git a/sysdeps/unix/sysv/linux/bits/statvfs.h b/sysdeps/unix/sysv/linux/bits/statvfs.h index fc63806848..c000e8a85a 100644 --- a/sysdeps/unix/sysv/linux/bits/statvfs.h +++ b/sysdeps/unix/sysv/linux/bits/statvfs.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1997, 1998 Free Software Foundation, Inc. +/* Copyright (C) 1997, 1998, 2000 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 @@ -44,7 +44,7 @@ struct statvfs __fsid_t f_fsid; unsigned long int f_flag; unsigned long int f_namemax; - int f_spare[6]; + int __f_spare[6]; }; #ifdef __USE_LARGEFILE64 @@ -61,7 +61,7 @@ struct statvfs64 __fsid_t f_fsid; unsigned long int f_flag; unsigned long int f_namemax; - int f_spare[6]; + int __f_spare[6]; }; #endif @@ -73,22 +73,24 @@ enum #define ST_RDONLY ST_RDONLY ST_NOSUID = 2, /* Ignore suid and sgid bits. */ #define ST_NOSUID ST_NOSUID +#ifdef __USE_GNU ST_NODEV = 4, /* Disallow access to device special files. */ -#define ST_NODEV ST_NODEV +# define ST_NODEV ST_NODEV ST_NOEXEC = 8, /* Disallow program execution. */ -#define ST_NOEXEC ST_NOEXEC +# define ST_NOEXEC ST_NOEXEC ST_SYNCHRONOUS = 16, /* Writes are synced at once. */ -#define ST_SYNCHRONOUS ST_SYNCHRONOUS +# define ST_SYNCHRONOUS ST_SYNCHRONOUS ST_MANDLOCK = 64, /* Allow mandatory locks on an FS. */ -#define ST_MANDLOCK ST_MANDLOCK +# define ST_MANDLOCK ST_MANDLOCK ST_WRITE = 128, /* Write on file/directory/symlink. */ -#define ST_WRITE ST_WRITE +# define ST_WRITE ST_WRITE ST_APPEND = 256, /* Append-only file. */ -#define ST_APPEND ST_APPEND +# define ST_APPEND ST_APPEND ST_IMMUTABLE = 512, /* Immutable file. */ -#define ST_IMMUTABLE ST_IMMUTABLE +# define ST_IMMUTABLE ST_IMMUTABLE ST_NOATIME = 1024, /* Do not update access times. */ -#define ST_NOATIME ST_NOATIME +# define ST_NOATIME ST_NOATIME ST_NODIRATIME /* Do not update directory access times. */ -#define ST_NODIRATIME ST_NODIRATIME +# define ST_NODIRATIME ST_NODIRATIME +#endif /* Use GNU. */ }; diff --git a/sysdeps/unix/sysv/linux/configure.in b/sysdeps/unix/sysv/linux/configure.in index 5cb5462950..9d17063761 100644 --- a/sysdeps/unix/sysv/linux/configure.in +++ b/sysdeps/unix/sysv/linux/configure.in @@ -62,7 +62,7 @@ fi # files. I.e., when the installation prefix is "/usr" we have to place # shared library objects and the configuration files on the root partition # in /lib and /etc. -if test "$prefix" = "/usr"; then +if test "$prefix" = "/usr" -o "$prefix" = "/usr/"; then # 64bit libraries on sparc go to /lib64 and not /lib if test "$machine" = "sparc/sparc64"; then libc_cv_slibdir="/lib64" diff --git a/sysdeps/unix/sysv/linux/fstatvfs64.c b/sysdeps/unix/sysv/linux/fstatvfs64.c index 8ede56eec3..bc2165e3ee 100644 --- a/sysdeps/unix/sysv/linux/fstatvfs64.c +++ b/sysdeps/unix/sysv/linux/fstatvfs64.c @@ -1,5 +1,5 @@ /* Return information about the filesystem on which FD resides. - Copyright (C) 1996, 1997, 1998 Free Software Foundation, Inc. + Copyright (C) 1996, 1997, 1998, 2000 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 @@ -41,7 +41,7 @@ fstatvfs64 (int fd, struct statvfs64 *buf) buf->f_fsid = buf32.f_fsid; buf->f_flag = buf32.f_flag; buf->f_namemax = buf32.f_namemax; - memcpy (buf->f_spare, buf32.f_spare, sizeof (buf32.f_spare)); + memcpy (buf->__f_spare, buf32.__f_spare, sizeof (buf32.__f_spare)); return 0; } diff --git a/sysdeps/unix/sysv/linux/getpriority.c b/sysdeps/unix/sysv/linux/getpriority.c index 9be8d3f70b..c420ff5ccf 100644 --- a/sysdeps/unix/sysv/linux/getpriority.c +++ b/sysdeps/unix/sysv/linux/getpriority.c @@ -1,5 +1,5 @@ /* getpriority for Linux. - Copyright (C) 1996, 1998 Free Software Foundation, Inc. + Copyright (C) 1996, 1998, 2000 Free Software Foundation, Inc. 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 @@ -22,7 +22,7 @@ #include <sysdep.h> #include <sys/syscall.h> -extern int __syscall_getpriority (int, int); +extern int __syscall_getpriority (int, id_t); /* The return value of __syscall_getpriority is biased by this value to avoid returning negative values. */ @@ -34,7 +34,7 @@ extern int __syscall_getpriority (int, int); priority. Priorities range from PRIO_MIN to PRIO_MAX. */ int -getpriority (enum __priority_which which, int who) +getpriority (enum __priority_which which, id_t who) { int res; diff --git a/sysdeps/unix/sysv/linux/internal_statvfs.c b/sysdeps/unix/sysv/linux/internal_statvfs.c index 2ea380d5cd..a6aec7d0f4 100644 --- a/sysdeps/unix/sysv/linux/internal_statvfs.c +++ b/sysdeps/unix/sysv/linux/internal_statvfs.c @@ -28,7 +28,7 @@ buf->f_ffree = fsbuf.f_ffree; buf->f_fsid = fsbuf.f_fsid; buf->f_namemax = fsbuf.f_namelen; - memset (buf->f_spare, '\0', 6 * sizeof (int)); + memset (buf->__f_spare, '\0', 6 * sizeof (int)); /* What remains to do is to fill the fields f_favail and f_flag. */ diff --git a/sysdeps/unix/sysv/linux/sparc/bits/shm.h b/sysdeps/unix/sysv/linux/sparc/bits/shm.h index e43de59fe1..6dc6011da4 100644 --- a/sysdeps/unix/sysv/linux/sparc/bits/shm.h +++ b/sysdeps/unix/sysv/linux/sparc/bits/shm.h @@ -20,7 +20,7 @@ # error "Never include <bits/shm.h> directly; use <sys/shm.h> instead." #endif -#include <sys/types.h> +#include <bits/types.h> #include <bits/wordsize.h> /* Permission flag for shmget. */ @@ -37,6 +37,9 @@ #define SHM_UNLOCK 12 /* unlock segment (root only) */ +/* Type to count number of attaches. */ +typedef unsigned long int shmatt_t; + /* Data structure describing a set of semaphores. */ struct shmid_ds { @@ -54,9 +57,9 @@ struct shmid_ds #endif __time_t shm_ctime; /* time of last change by shmctl() */ size_t shm_segsz; /* size of segment in bytes */ - pid_t shm_cpid; /* pid of creator */ - pid_t shm_lpid; /* pid of last shmop */ - unsigned long int shm_nattch; /* number of current attaches */ + __pid_t shm_cpid; /* pid of creator */ + __pid_t shm_lpid; /* pid of last shmop */ + shmatt_t shm_nattch; /* number of current attaches */ unsigned long int __unused1; unsigned long int __unused2; }; diff --git a/sysdeps/unix/sysv/linux/statvfs64.c b/sysdeps/unix/sysv/linux/statvfs64.c index d88bd5945b..9417b23247 100644 --- a/sysdeps/unix/sysv/linux/statvfs64.c +++ b/sysdeps/unix/sysv/linux/statvfs64.c @@ -1,5 +1,5 @@ /* Return information about the filesystem on which FILE resides. - Copyright (C) 1998 Free Software Foundation, Inc. + Copyright (C) 1998, 2000 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 @@ -42,7 +42,7 @@ statvfs64 (const char *file, struct statvfs64 *buf) buf->f_fsid = buf32.f_fsid; buf->f_flag = buf32.f_flag; buf->f_namemax = buf32.f_namemax; - memcpy (buf->f_spare, buf32.f_spare, sizeof (buf32.f_spare)); + memcpy (buf->__f_spare, buf32.__f_spare, sizeof (buf32.__f_spare)); return 0; } |