updated to dietlibc 0.24 + many cleanups git-svn-id: http://www.rocklinux.org/svn/rock-linux/trunk@2098 c5f82cb5-29bc-0310-9cd0-bff59a50e3bcrocklinux
@ -1,46 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/adds_vasprintf_c.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
diff -u -rduN dietlibc-0.22.orig/libugly/vasprintf.c dietlibc-0.22/libugly/vasprintf.c
|
|||
--- dietlibc-0.22.orig/libugly/vasprintf.c 1969-12-31 21:00:00.000000000 -0300
|
|||
+++ dietlibc-0.22/libugly/vasprintf.c 2003-11-15 00:33:36.000000000 -0300
|
|||
@@ -0,0 +1,20 @@
|
|||
+#define _GNU_SOURCE
|
|||
+#include <stdarg.h>
|
|||
+#include <sys/types.h>
|
|||
+#include <stdlib.h>
|
|||
+#include <stdio.h>
|
|||
+#include "dietwarning.h"
|
|||
+
|
|||
+int vasprintf(char **s, const char *format, va_list ap)
|
|||
+{
|
|||
+ int n;
|
|||
+ va_list arg_ptr;
|
|||
+ va_copy(arg_ptr,ap);
|
|||
+ n=vsnprintf(0,1000000,format,arg_ptr);
|
|||
+ va_end(arg_ptr);
|
|||
+ if ((*s=malloc(n+1))) {
|
|||
+ n=vsnprintf(*s,n+1,format,ap);
|
|||
+ return n;
|
|||
+ }
|
|||
+ return -1;
|
|||
+}
|
|||
@ -1,67 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/byteswap_h.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
e2fsprogs >_< |
|||
|
|||
--- /dev/null Thu Jan 1 00:00:00 1970
|
|||
+++ ./include/byteswap.h Sat Jan 11 01:24:51 2003
|
|||
@@ -0,0 +1,40 @@
|
|||
+/* Copyright (C) 1997 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, write to the Free
|
|||
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
|||
+ 02111-1307 USA. */
|
|||
+
|
|||
+#ifndef _BYTESWAP_H
|
|||
+#define _BYTESWAP_H 1
|
|||
+
|
|||
+/* Get the machine specific, optimized definitions. */
|
|||
+#include <byteswap_prot.h>
|
|||
+
|
|||
+
|
|||
+/* The following definitions must all be macros since otherwise some
|
|||
+ of the possible optimizations are not possible. */
|
|||
+
|
|||
+/* Return a value with all bytes in the 16 bit argument swapped. */
|
|||
+#define bswap_16(x) __bswap_16 (x)
|
|||
+
|
|||
+/* Return a value with all bytes in the 32 bit argument swapped. */
|
|||
+#define bswap_32(x) __bswap_32 (x)
|
|||
+
|
|||
+#if defined __GNUC__ && __GNUC__ >= 2
|
|||
+/* Return a value with all bytes in the 64 bit argument swapped. */
|
|||
+# define bswap_64(x) __bswap_64 (x)
|
|||
+#endif
|
|||
+
|
|||
+#endif /* byteswap.h */
|
|||
@ -1,29 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/errno-h.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
|
|||
needed by sysvinit |
|||
|
|||
--- ./include/sys/errno.h.orig Tue May 28 02:27:39 2002
|
|||
+++ ./include/sys/errno.h Tue May 28 02:27:25 2002
|
|||
@@ -0,0 +1 @@
|
|||
+#include <errno.h>
|
|||
@ -1,29 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/fcntl-h.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
|
|||
needed by sysvinit |
|||
|
|||
--- ./include/sys/fcntl.h.orig Tue May 28 04:23:33 2002
|
|||
+++ ./include/sys/fcntl.h Tue May 28 04:23:21 2002
|
|||
@@ -0,0 +1 @@
|
|||
+#include <fcntl.h>
|
|||
@ -1,33 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/overwrite-xopt.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
--- ./diet.c.orig 2003-02-02 17:39:47.000000000 +0100
|
|||
+++ ./diet.c 2003-02-02 17:47:42.000000000 +0100
|
|||
@@ -272,6 +272,8 @@
|
|||
} |
|||
*dest++=argv[i]; |
|||
} |
|||
+ /* Overwrite -xfoobar from original command line. */
|
|||
+ *dest++="-xnone";
|
|||
#ifndef __DYN_LIB |
|||
if (compile || _link) *dest++=a; |
|||
#else |
|||
@ -0,0 +1 @@ |
|||
[ "$pkg_dietlibc_useit" = 1 ] && var_append flistdel "|" "var/tmp" |
|||
@ -0,0 +1 @@ |
|||
[ "$pkg_dietlibc_useit" = 1 ] && var_append flistdel "|" "var/tmp" |
|||
@ -0,0 +1,12 @@ |
|||
--- linux-2.4.22/scripts/mkdep.c.orig 2003-09-20 20:54:57.000000000 +0200
|
|||
+++ linux-2.4.22/scripts/mkdep.c 2003-09-20 20:55:43.000000000 +0200
|
|||
@@ -38,7 +38,9 @@
|
|||
#include <string.h> |
|||
#include <unistd.h> |
|||
|
|||
+#ifndef __dietlibc__
|
|||
#include <sys/fcntl.h> |
|||
+#endif
|
|||
#include <sys/mman.h> |
|||
#include <sys/stat.h> |
|||
#include <sys/types.h> |
|||
@ -0,0 +1,21 @@ |
|||
--- linux-2.4.22/scripts/mkdep.c.orig 2003-09-20 20:54:57.000000000 +0200
|
|||
+++ linux-2.4.22/scripts/mkdep.c 2003-09-20 20:55:43.000000000 +0200
|
|||
@@ -38,7 +38,9 @@
|
|||
#include <string.h> |
|||
#include <unistd.h> |
|||
|
|||
+#ifndef __dietlibc__
|
|||
#include <sys/fcntl.h> |
|||
+#endif
|
|||
#include <sys/mman.h> |
|||
#include <sys/stat.h> |
|||
#include <sys/types.h> |
|||
--- linux-2.4.22/lib/gen_crc32table.c.orig 2003-09-20 21:51:19.000000000 +0200
|
|||
+++ linux-2.4.22/lib/gen_crc32table.c 2003-09-20 21:51:48.000000000 +0200
|
|||
@@ -1,3 +1,6 @@
|
|||
+#ifdef __dietlibc__
|
|||
+#define _GNU_SOURCE
|
|||
+#endif
|
|||
#include <stdio.h> |
|||
#include "crc32defs.h" |
|||
#include <sys/types.h> |
|||
@ -0,0 +1,13 @@ |
|||
Yes I know that patch is suboptimal. It should do for now ;) |
|||
|
|||
--- perl-5.8.0/ext/Errno/Errno_pm.PL.orig 2003-09-20 18:41:01.000000000 +0200
|
|||
+++ perl-5.8.0/ext/Errno/Errno_pm.PL 2003-09-20 18:41:31.000000000 +0200
|
|||
@@ -109,7 +109,7 @@
|
|||
) { |
|||
# Some Linuxes have weird errno.hs which generate |
|||
# no #file or #line directives |
|||
- $file{'/usr/include/errno.h'} = 1;
|
|||
+ $file{'/usr/dietlibc/include/errno.h'} = 1;
|
|||
} elsif ($^O eq 'MacOS') { |
|||
# note that we are only getting the GUSI errno's here ... |
|||
# we might miss out on compiler-specific ones |
|||
@ -0,0 +1 @@ |
|||
[ "$pkg_dietlibc_useit" = 1 ] && var_append flistdel "|" "var/tmp" |
|||
@ -0,0 +1,2 @@ |
|||
[ "$pkg_dietlibc_useit" = 1 ] && var_append confopt " " "-U usenm -D d_localtime_r -D libc=/usr/dietlibc/lib-i386" |
|||
[ "$pkg_dietlibc_useit" = 1 ] && var_append flistdel "|" "var/tmp" |
|||
@ -1,26 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/poll_h.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
--- /dev/null Thu Jan 1 00:00:00 1970
|
|||
+++ ./include/poll.h Mon Jan 6 21:27:16 2003
|
|||
@@ -0,0 +1 @@
|
|||
+#include <sys/poll.h>
|
|||
@ -1,112 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/stdio_ext_h.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
--- /dev/null Thu Jan 1 00:00:00 1970
|
|||
+++ ./include/stdio_ext.h Mon Jan 6 20:23:12 2003
|
|||
@@ -0,0 +1,87 @@
|
|||
+/* Functions to access FILE structure internals.
|
|||
+ Copyright (C) 2000, 2001 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, write to the Free
|
|||
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
|||
+ 02111-1307 USA. */
|
|||
+
|
|||
+/* This header contains the same definitions as the header of the same name
|
|||
+ on Sun's Solaris OS. */
|
|||
+
|
|||
+#ifndef _STDIO_EXT_H
|
|||
+#define _STDIO_EXT_H 1
|
|||
+
|
|||
+#include <stdio.h>
|
|||
+
|
|||
+enum
|
|||
+{
|
|||
+ /* Query current state of the locking status. */
|
|||
+ FSETLOCKING_QUERY = 0,
|
|||
+#define FSETLOCKING_QUERY FSETLOCKING_QUERY
|
|||
+ /* The library protects all uses of the stream functions, except for
|
|||
+ uses of the *_unlocked functions, by calls equivalent to flockfile(). */
|
|||
+ FSETLOCKING_INTERNAL,
|
|||
+#define FSETLOCKING_INTERNAL FSETLOCKING_INTERNAL
|
|||
+ /* The user will take care of locking. */
|
|||
+ FSETLOCKING_BYCALLER
|
|||
+#define FSETLOCKING_BYCALLER FSETLOCKING_BYCALLER
|
|||
+};
|
|||
+
|
|||
+
|
|||
+__BEGIN_DECLS
|
|||
+
|
|||
+/* Return the size of the buffer of FP in bytes currently in use by
|
|||
+ the given stream. */
|
|||
+extern size_t __fbufsize (FILE *__fp);
|
|||
+
|
|||
+
|
|||
+/* Return non-zero value iff the stream FP is opened readonly, or if the
|
|||
+ last operation on the stream was a read operation. */
|
|||
+extern int __freading (FILE *__fp);
|
|||
+
|
|||
+/* Return non-zero value iff the stream FP is opened write-only or
|
|||
+ append-only, or if the last operation on the stream was a write
|
|||
+ operation. */
|
|||
+extern int __fwriting (FILE *__fp);
|
|||
+
|
|||
+
|
|||
+/* Return non-zero value iff stream FP is not opened write-only or
|
|||
+ append-only. */
|
|||
+extern int __freadable (FILE *__fp);
|
|||
+
|
|||
+/* Return non-zero value iff stream FP is not opened read-only. */
|
|||
+extern int __fwritable (FILE *__fp);
|
|||
+
|
|||
+
|
|||
+/* Return non-zero value iff the stream FP is line-buffered. */
|
|||
+extern int __flbf (FILE *__fp);
|
|||
+
|
|||
+
|
|||
+/* Discard all pending buffered I/O on the stream FP. */
|
|||
+extern void __fpurge (FILE *__fp);
|
|||
+
|
|||
+/* Return amount of output in bytes pending on a stream FP. */
|
|||
+extern size_t __fpending (FILE *__fp);
|
|||
+
|
|||
+/* Flush all line-buffered files. */
|
|||
+extern void _flushlbf (void);
|
|||
+
|
|||
+
|
|||
+/* Set locking status of stream FP to TYPE. */
|
|||
+extern int __fsetlocking (FILE *__fp, int __type);
|
|||
+
|
|||
+__END_DECLS
|
|||
+
|
|||
+#endif /* stdio_ext.h */
|
|||
@ -1,92 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/strnlen.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
--- /dev/null Thu Jan 1 00:00:00 1970
|
|||
+++ ./lib/strnlen.c Fri Jan 10 23:54:35 2003
|
|||
@@ -0,0 +1,57 @@
|
|||
+#include <endian.h>
|
|||
+#include "dietfeatures.h"
|
|||
+#include <string.h>
|
|||
+
|
|||
+#ifdef WANT_SMALL_STRING_ROUTINES
|
|||
+size_t strnlen(const char *s, size_t maxlen) {
|
|||
+ register size_t i;
|
|||
+ if (!maxlen) return 0;
|
|||
+ if (!s) return 0;
|
|||
+ for (i=0; *s && i<maxlen; ++s) ++i;
|
|||
+ return i;
|
|||
+}
|
|||
+#else
|
|||
+static const unsigned long magic = 0x01010101;
|
|||
+
|
|||
+size_t strnlen(const char *s, size_t maxlen)
|
|||
+{
|
|||
+ const char *t = s;
|
|||
+ const char *u = s + maxlen;
|
|||
+ unsigned long word;
|
|||
+
|
|||
+ if (!s) return 0;
|
|||
+
|
|||
+ /* Byte compare up until word boundary */
|
|||
+ for (; ((unsigned long) t & 3); t++)
|
|||
+ if (!*t) {
|
|||
+ if (t>u) t = u;
|
|||
+ return t - s;
|
|||
+ }
|
|||
+
|
|||
+ /* Word compare */
|
|||
+ do {
|
|||
+ if (t>u) return maxlen;
|
|||
+ word = *((unsigned long *) t); t += 4;
|
|||
+ word = (word - magic) &~ word;
|
|||
+ word &= (magic << 7);
|
|||
+ } while (word == 0);
|
|||
+
|
|||
+#if BYTE_ORDER == LITTLE_ENDIAN
|
|||
+ /* word & 0x80808080 == word */
|
|||
+ word = (word - 1) & (magic << 10);
|
|||
+ word += (word << 8) + (word << 16);
|
|||
+ t += word >> 26;
|
|||
+#else
|
|||
+ if ((word & 0x80800000) == 0) {
|
|||
+ word <<= 16;
|
|||
+ t += 2;
|
|||
+ }
|
|||
+ if ((word & 0x80000000) == 0) t += 1;
|
|||
+#endif
|
|||
+ if (t-4 > u) {
|
|||
+ return maxlen;
|
|||
+ } else {
|
|||
+ return ((const char *) t) - 4 - s;
|
|||
+ }
|
|||
+}
|
|||
+#endif
|
|||
--- ./include/string.h~ Mon Jul 8 20:30:53 2002
|
|||
+++ ./include/string.h Sat Jan 11 00:03:10 2003
|
|||
@@ -35,6 +35,7 @@
|
|||
int strncasecmp(const char *s1, const char *s2, size_t n) __THROW __pure__; |
|||
|
|||
size_t strlen(const char *s) __THROW __pure__; |
|||
+size_t strnlen(const char *s, size_t maxlen) __THROW __pure__;
|
|||
|
|||
char *strstr(const char *haystack, const char *needle) __THROW __pure__; |
|||
|
|||
@ -1,76 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/ulimit_h.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
|
|||
needed by sysvinit |
|||
|
|||
--- ./include/ulimit.h.orig Wed Jul 31 00:06:08 2002
|
|||
+++ ./include/ulimit.h Wed Jul 31 00:05:59 2002
|
|||
@@ -0,0 +1,48 @@
|
|||
+/* Copyright (C) 1997, 1998, 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
|
|||
+ 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, write to the Free
|
|||
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
|||
+ 02111-1307 USA. */
|
|||
+
|
|||
+#ifndef _ULIMIT_H
|
|||
+#define _ULIMIT_H 1
|
|||
+
|
|||
+#include <features.h>
|
|||
+
|
|||
+/* Constants used as the first parameter for `ulimit'. They denote limits
|
|||
+ which can be set or retrieved using this function. */
|
|||
+enum
|
|||
+{
|
|||
+ UL_GETFSIZE = 1, /* Return limit on the size of a file,
|
|||
+ in units of 512 bytes. */
|
|||
+#define UL_GETFSIZE UL_GETFSIZE
|
|||
+ UL_SETFSIZE, /* Set limit on the size of a file to
|
|||
+ second argument. */
|
|||
+#define UL_SETFSIZE UL_SETFSIZE
|
|||
+ __UL_GETMAXBRK, /* Return the maximum possible address
|
|||
+ of the data segment. */
|
|||
+ __UL_GETOPENMAX /* Return the maximum number of files
|
|||
+ that the calling process can open.*/
|
|||
+};
|
|||
+
|
|||
+
|
|||
+__BEGIN_DECLS
|
|||
+
|
|||
+/* Control process limits according to CMD. */
|
|||
+extern long int ulimit (int __cmd, ...) __THROW;
|
|||
+
|
|||
+__END_DECLS
|
|||
+
|
|||
+#endif /* ulimit.h */
|
|||
@ -1,38 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/unistd_h.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
that is really strange ... this define creates conflicting types between |
|||
(f)truncate and (f)truncate64 can be seen in curl ... |
|||
|
|||
--- ./include/unistd.h~ Sat Apr 19 17:25:19 2003
|
|||
+++ ./include/unistd.h Sat Apr 19 20:06:52 2003
|
|||
@@ -123,8 +123,8 @@
|
|||
#if defined _FILE_OFFSET_BITS && _FILE_OFFSET_BITS == 64 |
|||
#define open open64 |
|||
#define creat creat64 |
|||
-#define truncate truncate64
|
|||
-#define ftruncate ftruncate64
|
|||
+/*#define truncate truncate64
|
|||
+#define ftruncate ftruncate64*/
|
|||
#define getdents getdents64 |
|||
#endif |
|||
|
|||
@ -1,94 +0,0 @@ |
|||
# --- ROCK-COPYRIGHT-NOTE-BEGIN --- |
|||
# |
|||
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|||
# Please add additional copyright information _after_ the line containing |
|||
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by |
|||
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|||
# |
|||
# ROCK Linux: rock-src/package/base/dietlibc/values_h.patch |
|||
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|||
# |
|||
# This program is free software; you can redistribute it and/or modify |
|||
# it under the terms of the GNU General Public License as published by |
|||
# the Free Software Foundation; either version 2 of the License, or |
|||
# (at your option) any later version. A copy of the GNU General Public |
|||
# License can be found at Documentation/COPYING. |
|||
# |
|||
# Many people helped and are helping developing ROCK Linux. Please |
|||
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|||
# file for details. |
|||
# |
|||
# --- ROCK-COPYRIGHT-NOTE-END --- |
|||
|
|||
--- /dev/null Thu Jan 1 00:00:00 1970
|
|||
+++ ./include/values.h Mon Jan 6 20:01:54 2003
|
|||
@@ -0,0 +1,69 @@
|
|||
+/* Old compatibility names for <limits.h> and <float.h> constants.
|
|||
+ Copyright (C) 1995, 1996, 1997 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, write to the Free
|
|||
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
|||
+ 02111-1307 USA. */
|
|||
+
|
|||
+/* This interface is obsolete. New programs should use
|
|||
+ <limits.h> and/or <float.h> instead of <values.h>. */
|
|||
+
|
|||
+#ifndef _VALUES_H
|
|||
+#define _VALUES_H 1
|
|||
+
|
|||
+#include <features.h>
|
|||
+
|
|||
+#include <limits.h>
|
|||
+
|
|||
+#define _TYPEBITS(type) (sizeof (type) * CHAR_BIT)
|
|||
+
|
|||
+#define CHARBITS _TYPEBITS (char)
|
|||
+#define SHORTBITS _TYPEBITS (short int)
|
|||
+#define INTBITS _TYPEBITS (int)
|
|||
+#define LONGBITS _TYPEBITS (long int)
|
|||
+#define PTRBITS _TYPEBITS (char *)
|
|||
+#define DOUBLEBITS _TYPEBITS (double)
|
|||
+#define FLOATBITS _TYPEBITS (float)
|
|||
+
|
|||
+#define MINSHORT SHRT_MIN
|
|||
+#define MININT INT_MIN
|
|||
+#define MINLONG LONG_MIN
|
|||
+
|
|||
+#define MAXSHORT SHRT_MAX
|
|||
+#define MAXINT INT_MAX
|
|||
+#define MAXLONG LONG_MAX
|
|||
+
|
|||
+#define HIBITS MINSHORT
|
|||
+#define HIBITL MINLONG
|
|||
+
|
|||
+
|
|||
+#include <float.h>
|
|||
+
|
|||
+#define MAXDOUBLE DBL_MAX
|
|||
+#define MAXFLOAT FLT_MAX
|
|||
+#define MINDOUBLE DBL_MIN
|
|||
+#define MINFLOAT FLT_MIN
|
|||
+#define DMINEXP DBL_MIN_EXP
|
|||
+#define FMINEXP FLT_MIN_EXP
|
|||
+#define DMAXEXP DBL_MAX_EXP
|
|||
+#define FMAXEXP FLT_MAX_EXP
|
|||
+
|
|||
+
|
|||
+#ifdef __USE_MISC
|
|||
+/* Some systems define this name instead of CHAR_BIT or CHARBITS. */
|
|||
+# define BITSPERBYTE CHAR_BIT
|
|||
+#endif
|
|||
+
|
|||
+#endif /* values.h */
|
|||