svn commit: trunk/uClibc: include libc/inet libc/inet/rpc libc/mis etc...
bernds at uclibc.org
bernds at uclibc.org
Wed Jun 4 14:02:56 UTC 2008
Author: bernds
Date: 2008-06-04 07:02:56 -0700 (Wed, 04 Jun 2008)
New Revision: 22213
Log:
This fixes a problem with the move of libc_hidden_proto to string.h.
The obsolete functions bcopy, index, etc. are not supposed to be used within
uClibc itself. Hence, there is no libc_hidden_def for them, but the previous
patch did not just move libc_hidden_protos, it also added new ones for the
legacy functions. As a result, programs which use these functions can no
longer link with uClibc.
This fixes it by removing the unnecessary libc_hidden_protos. I've also
removed all inclusions of <strings.h> from uClibc source files: since we
define _GNU_SOURCE, it is sufficient to include <string.h>. We then do not
need to duplicate the libc_hidden_proto block in <strings.h>.
Modified:
trunk/uClibc/include/string.h
trunk/uClibc/include/strings.h
trunk/uClibc/libc/inet/resolv.c
trunk/uClibc/libc/inet/rpc/ruserpass.c
trunk/uClibc/libc/misc/regex/regex.c
trunk/uClibc/libc/misc/time/time.c
trunk/uClibc/libc/misc/wchar/wchar.c
trunk/uClibc/libc/stdlib/realpath.c
trunk/uClibc/libc/string/ffs.c
trunk/uClibc/libc/string/strcasecmp.c
trunk/uClibc/libc/string/strncasecmp.c
Changeset:
Modified: trunk/uClibc/include/string.h
===================================================================
--- trunk/uClibc/include/string.h 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/include/string.h 2008-06-04 14:02:56 UTC (rev 22213)
@@ -503,13 +503,8 @@
libc_hidden_proto(__bzero)
#endif
#ifdef __USE_BSD
-# ifdef __UCLIBC_SUSV3_LEGACY__
-libc_hidden_proto(bcopy)
-libc_hidden_proto(bzero)
-libc_hidden_proto(bcmp)
-libc_hidden_proto(index)
-libc_hidden_proto(rindex)
-# endif
+/* No libc_hidden_proto for bcopy etc., since uClibc doesn't itself use the
+ legacy functions. */
libc_hidden_proto(ffs)
#if 0 /*def __USE_GNU*/
libc_hidden_proto(ffsl)
Modified: trunk/uClibc/include/strings.h
===================================================================
--- trunk/uClibc/include/strings.h 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/include/strings.h 2008-06-04 14:02:56 UTC (rev 22213)
@@ -92,23 +92,7 @@
#ifdef UCLIBC_INTERNAL
-/* In the same order and with the same defines */
-# ifdef __UCLIBC_SUSV3_LEGACY__
-libc_hidden_proto(bcopy)
-libc_hidden_proto(bzero)
-libc_hidden_proto(bcmp)
-libc_hidden_proto(index)
-libc_hidden_proto(rindex)
-# endif
-libc_hidden_proto(ffs)
-# if 0 /*def __USE_GNU*/
-libc_hidden_proto(ffsl)
-# ifdef __GNUC__
-libc_hidden_proto(ffsll)
-# endif
-# endif
-libc_hidden_proto(strcasecmp)
-libc_hidden_proto(strncasecmp)
+#error "<strings.h> should not be included from libc."
#endif
Modified: trunk/uClibc/libc/inet/resolv.c
===================================================================
--- trunk/uClibc/libc/inet/resolv.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/inet/resolv.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -136,7 +136,6 @@
#define __FORCE_GLIBC
#include <features.h>
#include <string.h>
-#include <strings.h>
#include <stdio.h>
#include <signal.h>
#include <errno.h>
Modified: trunk/uClibc/libc/inet/rpc/ruserpass.c
===================================================================
--- trunk/uClibc/libc/inet/rpc/ruserpass.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/inet/rpc/ruserpass.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -41,7 +41,6 @@
#include <stdlib.h>
#include <string.h>
#include <malloc.h>
-#include <strings.h>
#include <unistd.h>
/* Experimentally off - libc_hidden_proto(strcat) */
Modified: trunk/uClibc/libc/misc/regex/regex.c
===================================================================
--- trunk/uClibc/libc/misc/regex/regex.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/misc/regex/regex.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -36,7 +36,6 @@
#include <stdbool.h>
#include <stdint.h>
#include <string.h>
-#include <strings.h>
#include <stdlib.h>
#ifdef __UCLIBC_HAS_WCHAR__
#define RE_ENABLE_I18N
Modified: trunk/uClibc/libc/misc/time/time.c
===================================================================
--- trunk/uClibc/libc/misc/time/time.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/misc/time/time.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -133,7 +133,6 @@
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
-#include <strings.h>
#include <time.h>
#include <sys/time.h>
#include <limits.h>
Modified: trunk/uClibc/libc/misc/wchar/wchar.c
===================================================================
--- trunk/uClibc/libc/misc/wchar/wchar.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/misc/wchar/wchar.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -1191,7 +1191,6 @@
#include <iconv.h>
#include <string.h>
-#include <strings.h>
#include <endian.h>
#include <byteswap.h>
Modified: trunk/uClibc/libc/stdlib/realpath.c
===================================================================
--- trunk/uClibc/libc/stdlib/realpath.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/stdlib/realpath.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -14,7 +14,6 @@
#include <unistd.h>
#include <stdio.h>
#include <string.h>
-#include <strings.h>
#include <limits.h> /* for PATH_MAX */
#include <sys/param.h> /* for MAXPATHLEN */
#include <errno.h>
Modified: trunk/uClibc/libc/string/ffs.c
===================================================================
--- trunk/uClibc/libc/string/ffs.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/string/ffs.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -8,7 +8,6 @@
/* ffsl,ffsll */
#include "_string.h"
-#include <strings.h>
/* Experimentally off - libc_hidden_proto(ffs) */
Modified: trunk/uClibc/libc/string/strcasecmp.c
===================================================================
--- trunk/uClibc/libc/string/strcasecmp.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/string/strcasecmp.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -6,7 +6,6 @@
*/
#include "_string.h"
-#include <strings.h>
#include <ctype.h>
#include <locale.h>
Modified: trunk/uClibc/libc/string/strncasecmp.c
===================================================================
--- trunk/uClibc/libc/string/strncasecmp.c 2008-06-04 11:53:24 UTC (rev 22212)
+++ trunk/uClibc/libc/string/strncasecmp.c 2008-06-04 14:02:56 UTC (rev 22213)
@@ -6,7 +6,6 @@
*/
#include "_string.h"
-#include <strings.h>
#include <ctype.h>
#include <locale.h>
More information about the uClibc-cvs
mailing list