@@ -69,6 +69,9 @@
/* Same for ino_t and ino64_t. */
# define __INO_T_MATCHES_INO64_T 1
+
+/* And for rlim_t and rlim64_t. */
+# define __RLIM_T_MATCHES_RLIM64_T 1
#endif
/* Number of descriptors that can fit in an `fd_set'. */
@@ -70,6 +70,9 @@
/* Same for ino_t and ino64_t. */
# define __INO_T_MATCHES_INO64_T 1
+/* And for rlim_t and rlim64_t. */
+#define __RLIM_T_MATCHES_RLIM64_T 1
+
/* Number of descriptors that can fit in an `fd_set'. */
#define __FD_SETSIZE 1024
@@ -66,6 +66,9 @@
for C type-checking purposes. */
#define __OFF_T_MATCHES_OFF64_T 1
+/* And for __rlim_t and __rlim64_t. */
+#define __RLIM_T_MATCHES_RLIM64_T 1
+
/* Number of descriptors that can fit in an `fd_set'. */
#define __FD_SETSIZE 1024
@@ -12,10 +12,6 @@ ifeq ($(subdir),signal)
sysdep_routines += sigrestorer
endif
-ifeq ($(subdir),resource)
-sysdep_routines += oldgetrlimit64
-endif
-
ifeq ($(subdir),stdlib)
gen-as-const-headers += ucontext_i.sym
endif
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/getrlimit64.c>
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/oldgetrlimit64.c>
@@ -70,6 +70,10 @@
/* Same for ino_t and ino64_t. */
# define __INO_T_MATCHES_INO64_T 1
+
+/* And for __rlim_t and __rlim64_t. */
+# define __RLIM_T_MATCHES_RLIM64_T 1
+
#endif
/* Number of descriptors that can fit in an `fd_set'. */
@@ -1,7 +1,5 @@
# File name Caller Syscall name # args Strong name Weak names
# rlimit APIs
-getrlimit - getrlimit i:ip __getrlimit getrlimit
-setrlimit - setrlimit i:ip __setrlimit setrlimit
prlimit64 EXTRA prlimit64 i:iipp prlimit64
fanotify_mark EXTRA fanotify_mark i:iiiiis fanotify_mark
new file mode 100644
@@ -0,0 +1,71 @@
+/* Linux getrlimit implementation (32 bits rlim_t).
+ Copyright (C) 2016 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
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library. If not, see
+ <http://www.gnu.org/licenses/>. */
+
+#include <errno.h>
+#include <sys/resource.h>
+#include <sys/types.h>
+#include <shlib-compat.h>
+
+#ifndef __RLIM_T_MATCHES_RLIM64_T
+
+/* The __NR_getrlimit compatibility implementation is required iff
+ __NR_getrlimit is also defined (meaning an old broken RLIM_INFINITY
+ definition). */
+# ifndef __NR_ugetrlimit
+# define __NR_ugetrlimit __NR_getrlimit
+# undef SHLIB_COMPAT
+# define SHLIB_COMPAT(a, b, c) 0
+# endif
+
+int
+__new_getrlimit (enum __rlimit_resource resource, struct rlimit *rlim)
+{
+# ifdef __NR_prlimit64
+ struct rlimit64 rlim64;
+ int res = INLINE_SYSCALL_CALL (prlimit64, 0, resource, NULL, &rlim64);
+ if (res == 0)
+ {
+ rlim->rlim_cur = rlim64.rlim_cur;
+ if (rlim->rlim_cur != rlim64.rlim_cur)
+ rlim->rlim_cur = RLIM_INFINITY;
+ rlim->rlim_max = rlim64.rlim_max;
+ if (rlim->rlim_max != rlim64.rlim_max)
+ rlim->rlim_max = RLIM_INFINITY;
+ }
+ if (res == 0 || errno != ENOSYS)
+ return res;
+# endif
+ return INLINE_SYSCALL_CALL (ugetrlimit, resource, rlim);
+}
+weak_alias (__new_getrlimit, __getrlimit)
+hidden_weak (__getrlimit)
+
+# if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_2)
+/* Back compatible 2Gig limited rlimit. */
+int
+__old_getrlimit (enum __rlimit_resource resource, struct rlimit *rlim)
+{
+ return INLINE_SYSCALL_CALL (getrlimit, resource, rlim);
+}
+compat_symbol (libc, __old_getrlimit, getrlimit, GLIBC_2_0);
+versioned_symbol (libc, __new_getrlimit, getrlimit, GLIBC_2_2);
+# else
+weak_alias (__new_getrlimit, getrlimit)
+# endif
+
+#endif /* __RLIM_T_MATCHES_RLIM64_T */
@@ -1,4 +1,5 @@
-/* Copyright (C) 2010-2016 Free Software Foundation, Inc.
+/* Linux getrlimit64 implementation (64 bits rlim_t).
+ Copyright (C) 2010-2016 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
@@ -16,29 +17,44 @@
<http://www.gnu.org/licenses/>. */
#include <errno.h>
-#include <sys/resource.h>
#include <sys/types.h>
-#include <sysdep.h>
-#include <kernel-features.h>
+#include <shlib-compat.h>
+
+/* Add this redirection so the strong_alias for __RLIM_T_MATCHES_RLIM64_T
+ linking getlimit64 to {__}getrlimit does not thrown a type error. */
+#undef getrlimit
+#undef __getrlimit
+#define getrlimit getrlimit_redirect
+#define __getrlimit __getrlimit_redirect
+#include <sys/resource.h>
+#undef getrlimit
+#undef __getrlimit
+
+# ifndef __NR_ugetrlimit
+# define __NR_ugetrlimit __NR_getrlimit
+# endif
/* Put the soft and hard limits for RESOURCE in *RLIMITS.
Returns 0 if successful, -1 if not (and sets errno). */
int
__getrlimit64 (enum __rlimit_resource resource, struct rlimit64 *rlimits)
{
-#ifdef __ASSUME_PRLIMIT64
- return INLINE_SYSCALL (prlimit64, 4, 0, resource, NULL, rlimits);
-#else
-# ifdef __NR_prlimit64
- int res = INLINE_SYSCALL (prlimit64, 4, 0, resource, NULL, rlimits);
+#ifdef __NR_prlimit64
+ int res = INLINE_SYSCALL_CALL (prlimit64, 0, resource, NULL, rlimits);
if (res == 0 || errno != ENOSYS)
return res;
-# endif
+#endif
+
+#ifdef __RLIM_T_MATCHES_RLIM64_T
+# define rlimits32 (*rlimits)
+#else
struct rlimit rlimits32;
+#endif
- if (__getrlimit (resource, &rlimits32) < 0)
+ if (INLINE_SYSCALL_CALL (ugetrlimit, resource, &rlimits32) < 0)
return -1;
+#ifndef __RLIM_T_MATCHES_RLIM64_T
if (rlimits32.rlim_cur == RLIM_INFINITY)
rlimits->rlim_cur = RLIM64_INFINITY;
else
@@ -47,12 +63,51 @@ __getrlimit64 (enum __rlimit_resource resource, struct rlimit64 *rlimits)
rlimits->rlim_max = RLIM64_INFINITY;
else
rlimits->rlim_max = rlimits32.rlim_max;
+#endif
return 0;
-#endif
}
libc_hidden_def (__getrlimit64)
-#ifndef getrlimit64
+
+#ifdef __RLIM_T_MATCHES_RLIM64_T
+/* If both rlim_t and rlimt64_t are essentially the same type we can use
+ alias both interfaces. */
+strong_alias (__getrlimit64, __GI_getrlimit)
+strong_alias (__getrlimit64, __GI___getrlimit)
+strong_alias (__getrlimit64, __getrlimit)
+weak_alias (__getrlimit64, getrlimit)
+/* And there is no need for compat symbols. */
+# undef SHLIB_COMPAT
+# define SHLIB_COMPAT(a, b, c) 0
+#endif
+
+#if SHLIB_COMPAT (libc, GLIBC_2_1, GLIBC_2_2)
+/* Back compatible 2Gig limited rlimit. */
+extern int __new_getrlimit (enum __rlimit_resource, struct rlimit *);
+
+int
+attribute_compat_text_section
+__old_getrlimit64 (enum __rlimit_resource resource, struct rlimit64 *rlimits)
+{
+ struct rlimit rlimits32;
+
+ if (__new_getrlimit (resource, &rlimits32) < 0)
+ return -1;
+
+ if (rlimits32.rlim_cur == RLIM_INFINITY)
+ rlimits->rlim_cur = RLIM64_INFINITY >> 1;
+ else
+ rlimits->rlim_cur = rlimits32.rlim_cur;
+ if (rlimits32.rlim_max == RLIM_INFINITY)
+ rlimits->rlim_max = RLIM64_INFINITY >> 1;
+ else
+ rlimits->rlim_max = rlimits32.rlim_max;
+
+ return 0;
+}
+versioned_symbol (libc, __getrlimit64, getrlimit64, GLIBC_2_2);
+compat_symbol (libc, __old_getrlimit64, getrlimit64, GLIBC_2_1);
+#else
weak_alias (__getrlimit64, getrlimit64)
libc_hidden_weak (getrlimit64)
#endif
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/getrlimit64.c>
@@ -31,8 +31,6 @@ shutdown - shutdown i:ii __shutdown shutdown
socket - socket i:iii __socket socket
socketpair - socketpair i:iiif __socketpair socketpair
-setrlimit - setrlimit i:ip __setrlimit setrlimit
-getrlimit - getrlimit i:ip __getrlimit getrlimit
prlimit64 EXTRA prlimit64 i:iipp __prlimit64 prlimit64@@GLIBC_2.17
fanotify_mark EXTRA fanotify_mark i:iiiiis __fanotify_mark fanotify_mark@@GLIBC_2.19
personality EXTRA personality Ei:i __personality personality
@@ -34,10 +34,6 @@ libpthread-sysdep_routines += libc-do-syscall
libpthread-shared-only-routines += libc-do-syscall
endif
-ifeq ($(subdir),resource)
-sysdep_routines += oldgetrlimit64
-endif
-
ifeq ($(subdir),stdlib)
gen-as-const-headers += ucontext_i.sym
endif
deleted file mode 100644
@@ -1,25 +0,0 @@
-/* Copyright (C) 1999-2016 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
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <http://www.gnu.org/licenses/>. */
-
-#define getrlimit64 __new_getrlimit64
-
-#include "../getrlimit64.c"
-
-#undef getrlimit64
-#include <shlib-compat.h>
-versioned_symbol (libc, __getrlimit64, getrlimit64, GLIBC_2_2);
-strong_alias (__getrlimit64, __GI_getrlimit64)
deleted file mode 100644
@@ -1,57 +0,0 @@
-/* Copyright (C) 1991-2016 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
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <http://www.gnu.org/licenses/>. */
-
-/* This is a compatibility file. If we don't build the libc with
- versioning don't compile this file. */
-#include <shlib-compat.h>
-#if SHLIB_COMPAT (libc, GLIBC_2_1, GLIBC_2_2)
-
-#include <errno.h>
-#include <sys/resource.h>
-#include <sys/types.h>
-
-extern int __new_getrlimit (enum __rlimit_resource, struct rlimit *);
-extern int __old_getrlimit64 (enum __rlimit_resource resource,
- struct rlimit64 *rlimits);
-
-
-/* Put the soft and hard limits for RESOURCE in *RLIMITS.
- Returns 0 if successful, -1 if not (and sets errno). */
-int
-attribute_compat_text_section
-__old_getrlimit64 (enum __rlimit_resource resource, struct rlimit64 *rlimits)
-{
- struct rlimit rlimits32;
-
- if (__new_getrlimit (resource, &rlimits32) < 0)
- return -1;
-
- if (rlimits32.rlim_cur == RLIM_INFINITY)
- rlimits->rlim_cur = RLIM64_INFINITY >> 1;
- else
- rlimits->rlim_cur = rlimits32.rlim_cur;
- if (rlimits32.rlim_max == RLIM_INFINITY)
- rlimits->rlim_max = RLIM64_INFINITY >> 1;
- else
- rlimits->rlim_max = rlimits32.rlim_max;
-
- return 0;
-}
-
-compat_symbol (libc, __old_getrlimit64, getrlimit64, GLIBC_2_1);
-
-#endif /* SHLIB_COMPAT */
@@ -18,8 +18,6 @@ setfsuid - setfsuid32 Ei:i setfsuid
modify_ldt EXTRA modify_ldt i:ipi __modify_ldt modify_ldt
vm86old EXTRA vm86old i:p __vm86old vm86@GLIBC_2.0
vm86 - vm86 i:ip __vm86 vm86@@GLIBC_2.3.4
-oldgetrlimit EXTRA getrlimit i:ip __old_getrlimit getrlimit@GLIBC_2.0
-setrlimit - setrlimit i:ip __setrlimit setrlimit@GLIBC_2.0 setrlimit@@GLIBC_2.2
waitpid - waitpid Ci:ipi __waitpid waitpid
prlimit64 EXTRA prlimit64 i:iipp prlimit64
@@ -18,7 +18,3 @@ sysdep-rtld-routines += m68k-vdso
sysdep-others += lddlibc4
install-bin += lddlibc4
endif
-
-ifeq ($(subdir),resource)
-sysdep_routines += oldgetrlimit64
-endif
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/getrlimit64.c>
deleted file mode 100644
@@ -1,4 +0,0 @@
-# File name Caller Syscall name Args Strong name Weak names
-
-oldgetrlimit EXTRA getrlimit i:ip __old_getrlimit getrlimit@GLIBC_2.0
-setrlimit - setrlimit i:ip __setrlimit setrlimit@GLIBC_2.0 setrlimit@@GLIBC_2.2
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/oldgetrlimit64.c>
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/getrlimit64.c>
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/oldgetrlimit64.c>
@@ -1,6 +1,2 @@
# See Makeconfig regarding the use of default-abi.
default-abi := 32
-
-ifeq ($(subdir),resource)
-sysdep_routines += oldgetrlimit64
-endif
@@ -3,10 +3,6 @@
chown - chown i:sii __chown chown@@GLIBC_2.1
lchown - lchown i:sii __lchown lchown@@GLIBC_2.0 chown@GLIBC_2.0
-# System calls with wrappers.
-oldgetrlimit EXTRA getrlimit i:ip __old_getrlimit getrlimit@GLIBC_2.0
-setrlimit - setrlimit i:ip __setrlimit setrlimit@GLIBC_2.0 setrlimit@@GLIBC_2.2
-
# Due to 64bit alignment there is a dummy second parameter
readahead - readahead i:iiiii __readahead readahead
deleted file mode 100644
@@ -1,3 +0,0 @@
-# File name Caller Syscall name # args Strong name Weak names
-
-getrlimit - ugetrlimit i:ip __getrlimit getrlimit getrlimit64 __getrlimit64
@@ -75,6 +75,9 @@
/* Same for ino_t and ino64_t. */
# define __INO_T_MATCHES_INO64_T 1
+
+/* And for __rlim_t and __rlim64_t. */
+# define __RLIM_T_MATCHES_RLIM64_T 1
#endif
/* Number of descriptors that can fit in an `fd_set'. */
@@ -10,10 +10,6 @@ ifeq ($(subdir),misc)
sysdep_headers += sys/elf.h
endif
-ifeq ($(subdir),resource)
-sysdep_routines += oldgetrlimit64
-endif
-
ifeq ($(subdir),elf)
ifeq (yes,$(build-shared))
# This is needed to support g++ v2 and v3.
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/getrlimit64.c>
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/oldgetrlimit64.c>
@@ -15,9 +15,6 @@ getgroups - getgroups32 i:ip __getgroups getgroups
setfsgid - setfsgid32 Ei:i setfsgid
setfsuid - setfsuid32 Ei:i setfsuid
-oldgetrlimit EXTRA getrlimit i:ip __old_getrlimit getrlimit@GLIBC_2.0
-setrlimit - setrlimit i:ip __setrlimit setrlimit@GLIBC_2.0 setrlimit@@GLIBC_2.2
-
prlimit64 EXTRA prlimit64 i:iipp prlimit64
fanotify_mark EXTRA fanotify_mark i:iiiiis fanotify_mark
personality EXTRA personality Ei:i __personality personality
new file mode 100644
@@ -0,0 +1,64 @@
+/* Linux setrlimit implementation (32 bits off_t).
+ Copyright (C) 2016 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
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library. If not, see
+ <http://www.gnu.org/licenses/>. */
+
+#include <errno.h>
+#include <sys/resource.h>
+#include <sys/types.h>
+#include <shlib-compat.h>
+
+#ifndef __RLIM_T_MATCHES_RLIM64_T
+
+/* The compatibility symbol is meant to match the old __NR_getrlimit syscall
+ (with broken RLIM_INFINITY definition). It should be provided iff
+ __NR_getrlimit and __NR_ugetrlimit are both defined. */
+# ifndef __NR_ugetrlimit
+# undef SHLIB_COMPAT
+# define SHLIB_COMPAT(a, b, c) 0
+# endif
+
+int
+__setrlimit (enum __rlimit_resource resource, const struct rlimit *rlim)
+{
+# ifdef __NR_prlimit64
+ struct rlimit64 rlim64;
+
+ if (rlim->rlim_cur == RLIM_INFINITY)
+ rlim64.rlim_cur = RLIM64_INFINITY;
+ else
+ rlim64.rlim_cur = rlim->rlim_cur;
+ if (rlim->rlim_max == RLIM_INFINITY)
+ rlim64.rlim_max = RLIM64_INFINITY;
+ else
+ rlim64.rlim_max = rlim->rlim_max;
+
+ int res = INLINE_SYSCALL_CALL (prlimit64, 0, resource, &rlim64, NULL);
+ if (res == 0 || errno != ENOSYS)
+ return res;
+# endif
+ return INLINE_SYSCALL_CALL (setrlimit, resource, rlim);
+}
+
+# if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_2)
+strong_alias (__setrlimit, __setrlimit_1)
+compat_symbol (libc, __setrlimit, setrlimit, GLIBC_2_0);
+versioned_symbol (libc, __setrlimit_1, setrlimit, GLIBC_2_2);
+# else
+weak_alias (__setrlimit, setrlimit)
+# endif
+
+#endif /* __RLIM_T_MATCHES_RLIM64_T */
@@ -1,4 +1,5 @@
-/* Copyright (C) 2010-2016 Free Software Foundation, Inc.
+/* Linux setrlimit64 implementation (64 bits off_t).
+ Copyright (C) 2010-2016 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
@@ -16,25 +17,30 @@
<http://www.gnu.org/licenses/>. */
#include <errno.h>
-#include <sys/resource.h>
#include <sys/types.h>
-#include <sysdep.h>
-#include <kernel-features.h>
+#include <shlib-compat.h>
+
+/* Add this redirection so the strong_alias for __RLIM_T_MATCHES_RLIM64_T
+ linking setlimit64 to {__}setrlimit does not thrown a type error. */
+#undef settrlimit
+#undef __sttrlimit
+#define setrlimit setrlimit_redirect
+#define __setrlimit __setrlimit_redirect
+#include <sys/resource.h>
+#undef setrlimit
+#undef __setrlimit
/* Set the soft and hard limits for RESOURCE to *RLIMITS.
Only the super-user can increase hard limits.
Return 0 if successful, -1 if not (and sets errno). */
int
-setrlimit64 (enum __rlimit_resource resource, const struct rlimit64 *rlimits)
+__setrlimit64 (enum __rlimit_resource resource, const struct rlimit64 *rlimits)
{
-#ifdef __ASSUME_PRLIMIT64
- return INLINE_SYSCALL (prlimit64, 4, 0, resource, rlimits, NULL);
-#else
-# ifdef __NR_prlimit64
- int res = INLINE_SYSCALL (prlimit64, 4, 0, resource, rlimits, NULL);
+#ifdef __NR_prlimit64
+ int res = INLINE_SYSCALL_CALL (prlimit64, 0, resource, rlimits, NULL);
if (res == 0 || errno != ENOSYS)
return res;
-# endif
+#endif
struct rlimit rlimits32;
if (rlimits->rlim_cur >= RLIM_INFINITY)
@@ -46,6 +52,11 @@ setrlimit64 (enum __rlimit_resource resource, const struct rlimit64 *rlimits)
else
rlimits32.rlim_max = rlimits->rlim_max;
- return __setrlimit (resource, &rlimits32);
-#endif
+ return INLINE_SYSCALL_CALL (setrlimit, resource, &rlimits32);
}
+weak_alias (__setrlimit64, setrlimit64)
+
+#ifdef __RLIM_T_MATCHES_RLIM64_T
+strong_alias (__setrlimit64, __setrlimit)
+weak_alias (__setrlimit64, setrlimit)
+#endif
deleted file mode 100644
@@ -1 +0,0 @@
-#include <sysdeps/unix/sysv/linux/i386/getrlimit64.c>
@@ -69,6 +69,9 @@
/* Same for ino_t and ino64_t. */
# define __INO_T_MATCHES_INO64_T 1
+
+/* And for __rlim_t and __rlim64_t. */
+# define __RLIM_T_MATCHES_RLIM64_T 1
#endif
/* Number of descriptors that can fit in an `fd_set'. */
new file mode 100644
@@ -0,0 +1,24 @@
+/* Linux getrlimit64 sparc32 implementation (64 bits rlim_t).
+ Copyright (C) 2016 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
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
+
+#include <shlib-compat.h>
+
+#undef SHLIB_COMPAT
+#define SHLIB_COMPAT(a,b,c) 0
+
+#include <sysdeps/unix/sysv/linux/getrlimit64.c>
@@ -4,8 +4,6 @@ chown - chown32 i:sii __chown chown
lchown - lchown32 i:sii __lchown lchown
fchown - fchown32 i:iii __fchown fchown
-setrlimit - setrlimit 2 __setrlimit setrlimit
-getrlimit - getrlimit 2 __getrlimit getrlimit
getegid - getegid32 Ei: __getegid getegid
geteuid - geteuid32 Ei: __geteuid geteuid
getgid - getgid32 Ei: __getgid getgid
@@ -26,7 +26,6 @@ getpmsg - getpmsg i:ipppp getpmsg
getppid - getppid Ei: __getppid getppid
getresuid - getresuid i:ppp getresuid
getresgid - getresgid i:ppp getresgid
-getrlimit - ugetrlimit i:ip __new_getrlimit __getrlimit getrlimit@@GLIBC_2.2
getsid - getsid i:i getsid
init_module EXTRA init_module 5 init_module
inotify_add_watch EXTRA inotify_add_watch i:isi inotify_add_watch
deleted file mode 100644
@@ -1 +0,0 @@
-/* getrlimit64 is the same as getrlimit. */
deleted file mode 100644
@@ -1 +0,0 @@
-/* setrlimit64 is the same as setrlimit. */
@@ -5,8 +5,6 @@ statfs - statfs i:sp __statfs statfs statfs64
mmap - mmap b:aniiii __mmap mmap __mmap64 mmap64
ftruncate - ftruncate i:ii __ftruncate ftruncate ftruncate64 __ftruncate64
truncate - truncate i:si truncate truncate64
-getrlimit - getrlimit i:ip __getrlimit getrlimit getrlimit64 __getrlimit64
-setrlimit - setrlimit i:ip __setrlimit setrlimit setrlimit64
readahead - readahead i:iii __readahead readahead
sendfile - sendfile i:iipi sendfile sendfile64
sync_file_range - sync_file_range Ci:iiii sync_file_range
@@ -81,6 +81,9 @@
/* Same for ino_t and ino64_t. */
# define __INO_T_MATCHES_INO64_T 1
+
+/* And for __rlim_t and __rlim64_t. */
+# define __RLIM_T_MATCHES_RLIM64_T 1
#endif
/* Number of descriptors that can fit in an `fd_set'. */