Browse Source

Split up wstring.c and use attribute_hidden

Peter S. Mazinger 19 years ago
parent
commit
76cad786c8
54 changed files with 1118 additions and 91 deletions
  1. 32 14
      libc/string/Makefile.in
  2. 14 0
      libc/string/memchr.c
  3. 16 0
      libc/string/memcmp.c
  4. 14 0
      libc/string/memcpy.c
  5. 14 0
      libc/string/memmove.c
  6. 14 0
      libc/string/mempcpy.c
  7. 14 0
      libc/string/memset.c
  8. 14 0
      libc/string/stpcpy.c
  9. 14 0
      libc/string/stpncpy.c
  10. 14 0
      libc/string/strcat.c
  11. 16 0
      libc/string/strchr.c
  12. 14 0
      libc/string/strchrnul.c
  13. 19 0
      libc/string/strcmp.c
  14. 14 0
      libc/string/strcpy.c
  15. 14 0
      libc/string/strcspn.c
  16. 19 0
      libc/string/strdup.c
  17. 18 0
      libc/string/strlcpy.c
  18. 14 0
      libc/string/strlen.c
  19. 14 0
      libc/string/strncat.c
  20. 14 0
      libc/string/strncmp.c
  21. 14 0
      libc/string/strncpy.c
  22. 14 0
      libc/string/strnlen.c
  23. 14 0
      libc/string/strpbrk.c
  24. 16 0
      libc/string/strrchr.c
  25. 14 0
      libc/string/strspn.c
  26. 14 0
      libc/string/strstr.c
  27. 19 0
      libc/string/strtok_r.c
  28. 15 0
      libc/string/wcpcpy.c
  29. 15 0
      libc/string/wcpncpy.c
  30. 15 0
      libc/string/wcscat.c
  31. 15 0
      libc/string/wcschr.c
  32. 15 0
      libc/string/wcschrnul.c
  33. 20 0
      libc/string/wcscmp.c
  34. 15 0
      libc/string/wcscpy.c
  35. 15 0
      libc/string/wcscspn.c
  36. 20 0
      libc/string/wcsdup.c
  37. 17 0
      libc/string/wcslcpy.c
  38. 15 0
      libc/string/wcslen.c
  39. 15 0
      libc/string/wcsncat.c
  40. 15 0
      libc/string/wcsncmp.c
  41. 15 0
      libc/string/wcsncpy.c
  42. 15 0
      libc/string/wcsnlen.c
  43. 15 0
      libc/string/wcspbrk.c
  44. 15 0
      libc/string/wcsrchr.c
  45. 15 0
      libc/string/wcsspn.c
  46. 17 0
      libc/string/wcsstr.c
  47. 20 0
      libc/string/wcstok.c
  48. 15 0
      libc/string/wmemchr.c
  49. 15 0
      libc/string/wmemcmp.c
  50. 15 0
      libc/string/wmemcpy.c
  51. 15 0
      libc/string/wmemmove.c
  52. 15 0
      libc/string/wmempcpy.c
  53. 15 0
      libc/string/wmemset.c
  54. 288 77
      libc/string/wstring.c

+ 32 - 14
libc/string/Makefile.in

@@ -10,23 +10,17 @@
 include $(top_srcdir)libc/string/generic/Makefile.in
 
 MSRC:=wstring.c
-MOBJ:=	basename.o bcopy.o bzero.o dirname.o ffs.o memccpy.o memchr.o memcmp.o \
-	memcpy.o memmove.o mempcpy.o memrchr.o 	memset.o rawmemchr.o stpcpy.o \
-	stpncpy.o strcasecmp.o strcasestr.o strcat.o strchrnul.o strchr.o \
-	strcmp.o strcpy.o strcspn.o strdup.o strlen.o strncasecmp.o strncat.o \
-	strncmp.o strncpy.o strndup.o strnlen.o strpbrk.o strrchr.o strsep.o \
-	strspn.o strstr.o strtok.o strtok_r.o strerror.o __xpg_strerror_r.o \
+MOBJ:=	basename.o bcopy.o bzero.o dirname.o ffs.o memccpy.o \
+	memrchr.o rawmemchr.o strcasecmp.o strcasestr.o \
+	strncasecmp.o strndup.o strsep.o \
+	strtok.o strerror.o __xpg_strerror_r.o \
 	_string_syserrmsgs.o __glibc_strerror_r.o \
 	_string_syssigmsgs.o sys_siglist.o strsignal.o psignal.o \
-	 __xpg_basename.o strlcat.o strlcpy.o sys_errlist.o memmem.o
+	 __xpg_basename.o strlcat.o sys_errlist.o memmem.o
 
 MOBJW:=
 ifeq ($(UCLIBC_HAS_WCHAR),y)
-MOBJW:=	wcscasecmp.o wcscat.o wcschrnul.o wcschr.o wcscmp.o wcscpy.o wcscspn.o \
-	wcsdup.o wcslen.o wcsncasecmp.o wcsncat.o wcsncmp.o wcsncpy.o \
-	wcsnlen.o wcspbrk.o wcsrchr.o wcsspn.o wcsstr.o wcstok.o wmemchr.o \
-	wmemcmp.o wmemcpy.o wmemmove.o wmempcpy.o wmemset.o wcpcpy.o wcpncpy.o \
-	__wcslcpy.o \
+MOBJW:=	wcscasecmp.o wcsncasecmp.o \
 	wcsxfrm.o strxfrm.o # wcscoll strcoll.o
 endif
 
@@ -56,6 +50,30 @@ endif
 STRING_DIR:=$(top_srcdir)libc/string
 STRING_OUT:=$(top_builddir)libc/string
 
+STRING_WSRC:=$(filter-out $(STRING_DIR)/wstring.c,$(wildcard $(STRING_DIR)/w*.c))
+STRING_CSRC:=$(filter-out $(STRING_DIR)/wstring.c $(STRING_WSRC),$(wildcard $(STRING_DIR)/*.c))
+
+ifeq ($(UCLIBC_HAS_STRING_ARCH_OPT),y)
+ifneq ($(strip $(STRING_ARCH_OBJS)),)
+MOBJ:=$(filter-out $(notdir $(STRING_ARCH_OBJS)),$(MOBJ))
+STRING_CSRC:=$(filter-out $(patsubst %.o,$(STRING_DIR)/%.c,$(notdir $(STRING_ARCH_OBJS))),$(STRING_CSRC))
+STRING_WSRC:=$(filter-out $(patsubst %.o,$(STRING_DIR)/%.c,$(notdir $(STRING_ARCH_OBJS))),$(STRING_WSRC))
+endif
+endif
+
+ifeq ($(UCLIBC_HAS_STRING_GENERIC_OPT),y)
+ifneq ($(strip $(STRING_GENERIC_OBJS)),)
+MOBJ:=$(filter-out $(notdir $(STRING_GENERIC_OBJS)),$(MOBJ))
+STRING_CSRC:=$(filter-out $(patsubst %.o,$(STRING_DIR)/%.c,$(notdir $(STRING_GENERIC_OBJS))),$(STRING_CSRC))
+STRING_WSRC:=$(filter-out $(patsubst %.o,$(STRING_DIR)/%.c,$(notdir $(STRING_GENERIC_OBJS))),$(STRING_WSRC))
+endif
+endif
+
+
+STRING_COBJ:=$(patsubst $(STRING_DIR)/%.c,$(STRING_OUT)/%.o,$(STRING_CSRC))
+ifeq ($(UCLIBC_HAS_WCHAR),y)
+STRING_WOBJ:=$(patsubst $(STRING_DIR)/%.c,$(STRING_OUT)/%.o,$(STRING_WSRC))
+endif
 STRING_MSRC:=$(patsubst %.c,$(STRING_DIR)/%.c,$(MSRC))
 STRING_MOBJ:=$(patsubst %.o,$(STRING_OUT)/%.o,$(MOBJ))
 STRING_MOBJW:=$(patsubst %.o,$(STRING_OUT)/%.o,$(MOBJW))
@@ -65,7 +83,7 @@ STRING_MOBJWx:=$(patsubst %.o,$(STRING_OUT)/%.o,$(MOBJWx))
 STRING_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(STRING_MOBJ))))
 
 STRING_Wx:=$(STRING_MOBJW) $(STRING_MOBJx) $(STRING_MOBJWx)
-STRING_OBJS:=$(STRING_MOBJ) $(STRING_Wx)
+STRING_OBJS:=$(STRING_COBJ) $(STRING_WOBJ) $(STRING_MOBJ) $(STRING_Wx)
 
 $(STRING_MOBJ): $(STRING_MSRC)
 	$(compile.m)
@@ -95,7 +113,7 @@ libc-a-y+=$(STRING_OBJS)
 libc-so-y+=$(STRING_OBJS:.o=.os)
 
 CFLAGS-multi-y+=$(STRING_DEF)
-libc-multi-y+=$(STRING_MSRC)
+libc-multi-y+=$(STRING_MSRC) $(STRING_CSRC) $(STRING_WSRC)
 libc-nomulti-y+=$(STRING_Wx)
 
 objclean-y+=string_objclean

+ 14 - 0
libc/string/memchr.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memchr
+#define Wmemchr __memchr
+
+#include "wstring.c"
+
+strong_alias(__memchr, memchr)
+
+#undef L_memchr

+ 16 - 0
libc/string/memcmp.c

@@ -0,0 +1,16 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memcmp
+#define Wmemcmp __memcmp
+
+#include "wstring.c"
+
+strong_alias(__memcmp, memcmp)
+
+weak_alias(memcmp, bcmp)
+
+#undef L_memcmp

+ 14 - 0
libc/string/memcpy.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memcpy
+#define Wmemcpy __memcpy
+
+#include "wstring.c"
+
+strong_alias(__memcpy, memcpy)
+
+#undef L_memcpy

+ 14 - 0
libc/string/memmove.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memmove
+#define Wmemmove __memmove
+
+#include "wstring.c"
+
+strong_alias(__memmove, memmove)
+
+#undef L_memmove

+ 14 - 0
libc/string/mempcpy.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_mempcpy
+#define Wmempcpy __mempcpy
+
+#include "wstring.c"
+
+strong_alias(__mempcpy, mempcpy)
+
+#undef L_mempcpy

+ 14 - 0
libc/string/memset.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memset
+#define Wmemset __memset
+
+#include "wstring.c"
+
+strong_alias(__memset, memset)
+
+#undef L_memset

+ 14 - 0
libc/string/stpcpy.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_stpcpy
+#define Wstpcpy __stpcpy
+
+#include "wstring.c"
+
+strong_alias(__stpcpy, stpcpy)
+
+#undef L_stpcpy

+ 14 - 0
libc/string/stpncpy.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_stpncpy
+#define Wstpncpy __stpncpy
+
+#include "wstring.c"
+
+strong_alias(__stpncpy, stpncpy)
+
+#undef L_stpncpy

+ 14 - 0
libc/string/strcat.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strcat
+#define Wstrcat __strcat
+
+#include "wstring.c"
+
+strong_alias(__strcat, strcat)
+
+#undef L_strcat

+ 16 - 0
libc/string/strchr.c

@@ -0,0 +1,16 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strchr
+#define Wstrchr __strchr
+
+#include "wstring.c"
+
+strong_alias(__strchr, strchr)
+
+weak_alias(strchr, index)
+
+#undef L_strchr

+ 14 - 0
libc/string/strchrnul.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strchrnul
+#define Wstrchrnul __strchrnul
+
+#include "wstring.c"
+
+strong_alias(__strchrnul, strchrnul)
+
+#undef L_strchrnul

+ 19 - 0
libc/string/strcmp.c

@@ -0,0 +1,19 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strcmp
+#define Wstrcmp __strcmp
+
+#include "wstring.c"
+
+strong_alias(__strcmp, strcmp)
+
+#ifdef __LOCALE_C_ONLY
+weak_alias(__strcmp, __strcoll)
+strong_alias(__strcoll, strcoll)
+#endif
+
+#undef L_strcmp

+ 14 - 0
libc/string/strcpy.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strcpy
+#define Wstrcpy __strcpy
+
+#include "wstring.c"
+
+strong_alias(__strcpy, strcpy)
+
+#undef L_strcpy

+ 14 - 0
libc/string/strcspn.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strcspn
+#define Wstrcspn __strcspn
+
+#include "wstring.c"
+
+strong_alias(__strcspn, strcspn)
+
+#undef L_strcspn

+ 19 - 0
libc/string/strdup.c

@@ -0,0 +1,19 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strdup
+#define Wstrdup __strdup
+
+#undef Wstrlen
+#undef Wstrcpy
+#define Wstrlen __strlen
+#define Wstrcpy __strcpy
+
+#include "wstring.c"
+
+strong_alias(__strdup, strdup)
+
+#undef L_strdup

+ 18 - 0
libc/string/strlcpy.c

@@ -0,0 +1,18 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strlcpy
+#define Wstrlcpy __strlcpy
+
+#include "wstring.c"
+
+strong_alias(__strlcpy, strlcpy)
+
+#ifdef __LOCALE_C_ONLY
+weak_alias(strlcpy, strxfrm)
+#endif
+
+#undef L_strlcpy

+ 14 - 0
libc/string/strlen.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strlen
+#define Wstrlen __strlen
+
+#include "wstring.c"
+
+strong_alias(__strlen, strlen)
+
+#undef L_strlen

+ 14 - 0
libc/string/strncat.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strncat
+#define Wstrncat __strncat
+
+#include "wstring.c"
+
+strong_alias(__strncat, strncat)
+
+#undef L_strncat

+ 14 - 0
libc/string/strncmp.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strncmp
+#define Wstrncmp __strncmp
+
+#include "wstring.c"
+
+strong_alias(__strncmp, strncmp)
+
+#undef L_strncmp

+ 14 - 0
libc/string/strncpy.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strncpy
+#define Wstrncpy __strncpy
+
+#include "wstring.c"
+
+strong_alias(__strncpy, strncpy)
+
+#undef L_strncpy

+ 14 - 0
libc/string/strnlen.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strnlen
+#define Wstrnlen __strnlen
+
+#include "wstring.c"
+
+strong_alias(__strnlen, strnlen)
+
+#undef L_strnlen

+ 14 - 0
libc/string/strpbrk.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strpbrk
+#define Wstrpbrk __strpbrk
+
+#include "wstring.c"
+
+strong_alias(__strpbrk, strpbrk)
+
+#undef L_strpbrk

+ 16 - 0
libc/string/strrchr.c

@@ -0,0 +1,16 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strrchr
+#define Wstrrchr __strrchr
+
+#include "wstring.c"
+
+strong_alias(__strrchr, strrchr)
+
+weak_alias(strrchr, rindex)
+
+#undef L_strrchr

+ 14 - 0
libc/string/strspn.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strspn
+#define Wstrspn __strspn
+
+#include "wstring.c"
+
+strong_alias(__strspn, strspn)
+
+#undef L_strspn

+ 14 - 0
libc/string/strstr.c

@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strstr
+#define Wstrstr __strstr
+
+#include "wstring.c"
+
+strong_alias(__strstr, strstr)
+
+#undef L_strstr

+ 19 - 0
libc/string/strtok_r.c

@@ -0,0 +1,19 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strtok_r
+#define Wstrtok_r __strtok_r
+
+#undef Wstrspn
+#define Wstrspn __strspn
+#undef Wstrpbrk
+#define Wstrpbrk __strpbrk
+
+#include "wstring.c"
+
+strong_alias(__strtok_r, strtok_r)
+
+#undef L_strtok_r

+ 15 - 0
libc/string/wcpcpy.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_stpcpy
+#define WANT_WIDE
+#define Wstpcpy __wcpcpy
+
+#include "wstring.c"
+
+strong_alias(__wcpcpy, wcpcpy)
+
+#undef L_stpcpy

+ 15 - 0
libc/string/wcpncpy.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_stpncpy
+#define WANT_WIDE
+#define Wstpncpy __wcpncpy
+
+#include "wstring.c"
+
+strong_alias(__wcpncpy, wcpncpy)
+
+#undef L_stpncpy

+ 15 - 0
libc/string/wcscat.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strcat
+#define WANT_WIDE
+#define Wstrcat __wcscat
+
+#include "wstring.c"
+
+strong_alias(__wcscat, wcscat)
+
+#undef L_strcat

+ 15 - 0
libc/string/wcschr.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strchr
+#define WANT_WIDE
+#define Wstrchr __wcschr
+
+#include "wstring.c"
+
+strong_alias(__wcschr, wcschr)
+
+#undef L_strchr

+ 15 - 0
libc/string/wcschrnul.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strchrnul
+#define WANT_WIDE
+#define Wstrchrnul __wcschrnul
+
+#include "wstring.c"
+
+strong_alias(__wcschrnul, wcschrnul)
+
+#undef L_strchrnul

+ 20 - 0
libc/string/wcscmp.c

@@ -0,0 +1,20 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strcmp
+#define WANT_WIDE
+#define Wstrcmp __wcscmp
+
+#include "wstring.c"
+
+strong_alias(__wcscmp, wcscmp)
+
+#ifdef __LOCALE_C_ONLY
+weak_alias(__wcscmp, __wcscoll)
+strong_alias(__wcscoll, wcscoll)
+#endif
+
+#undef L_strcmp

+ 15 - 0
libc/string/wcscpy.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strcpy
+#define WANT_WIDE
+#define Wstrcpy __wcscpy
+
+#include "wstring.c"
+
+strong_alias(__wcscpy, wcscpy)
+
+#undef L_strcpy

+ 15 - 0
libc/string/wcscspn.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strcspn
+#define WANT_WIDE
+#define Wstrcspn __wcscspn
+
+#include "wstring.c"
+
+strong_alias(__wcscspn, wcscspn)
+
+#undef L_strcspn

+ 20 - 0
libc/string/wcsdup.c

@@ -0,0 +1,20 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strdup
+#define WANT_WIDE
+#define Wstrdup __wcsdup
+
+#undef Wstrlen
+#undef Wstrcpy
+#define Wstrlen __wcslen
+#define Wstrcpy __wcscpy
+
+#include "wstring.c"
+
+strong_alias(__wcsdup, wcsdup)
+
+#undef L_strdup

+ 17 - 0
libc/string/wcslcpy.c

@@ -0,0 +1,17 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strlcpy
+#define WANT_WIDE
+#define Wstrlcpy __wcslcpy
+
+#include "wstring.c"
+
+#ifdef __LOCALE_C_ONLY
+weak_alias(__wcslcpy, wcsxfrm)
+#endif
+
+#undef L_strlcpy

+ 15 - 0
libc/string/wcslen.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strlen
+#define WANT_WIDE
+#define Wstrlen __wcslen
+
+#include "wstring.c"
+
+strong_alias(__wcslen, wcslen)
+
+#undef L_strlen

+ 15 - 0
libc/string/wcsncat.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strncat
+#define WANT_WIDE
+#define Wstrncat __wcsncat
+
+#include "wstring.c"
+
+strong_alias(__wcsncat, wcsncat)
+
+#undef L_strncat

+ 15 - 0
libc/string/wcsncmp.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strncmp
+#define WANT_WIDE
+#define Wstrncmp __wcsncmp
+
+#include "wstring.c"
+
+strong_alias(__wcsncmp, wcsncmp)
+
+#undef L_strncmp

+ 15 - 0
libc/string/wcsncpy.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strncpy
+#define WANT_WIDE
+#define Wstrncpy __wcsncpy
+
+#include "wstring.c"
+
+strong_alias(__wcsncpy, wcsncpy)
+
+#undef L_strncpy

+ 15 - 0
libc/string/wcsnlen.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strnlen
+#define WANT_WIDE
+#define Wstrnlen __wcsnlen
+
+#include "wstring.c"
+
+strong_alias(__wcsnlen, wcsnlen)
+
+#undef L_strnlen

+ 15 - 0
libc/string/wcspbrk.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strpbrk
+#define WANT_WIDE
+#define Wstrpbrk __wcspbrk
+
+#include "wstring.c"
+
+strong_alias(__wcspbrk, wcspbrk)
+
+#undef L_strpbrk

+ 15 - 0
libc/string/wcsrchr.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strrchr
+#define WANT_WIDE
+#define Wstrrchr __wcsrchr
+
+#include "wstring.c"
+
+strong_alias(__wcsrchr, wcsrchr)
+
+#undef L_strrchr

+ 15 - 0
libc/string/wcsspn.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strspn
+#define WANT_WIDE
+#define Wstrspn __wcsspn
+
+#include "wstring.c"
+
+strong_alias(__wcsspn, wcsspn)
+
+#undef L_strspn

+ 17 - 0
libc/string/wcsstr.c

@@ -0,0 +1,17 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strstr
+#define WANT_WIDE
+#define Wstrstr __wcsstr
+
+#include "wstring.c"
+
+strong_alias(__wcsstr, wcsstr)
+
+weak_alias(wcsstr, wcswcs)
+
+#undef L_strstr

+ 20 - 0
libc/string/wcstok.c

@@ -0,0 +1,20 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_strtok_r
+#define WANT_WIDE
+#define Wstrtok_r __wcstok
+
+#undef Wstrspn
+#define Wstrspn __wcsspn
+#undef Wstrpbrk
+#define Wstrpbrk __wcspbrk
+
+#include "wstring.c"
+
+strong_alias(__wcstok, wcstok)
+
+#undef L_strtok_r

+ 15 - 0
libc/string/wmemchr.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memchr
+#define WANT_WIDE
+#define Wmemchr __wmemchr
+
+#include "wstring.c"
+
+strong_alias(__wmemchr, wmemchr)
+
+#undef L_memchr

+ 15 - 0
libc/string/wmemcmp.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memcmp
+#define WANT_WIDE
+#define Wmemcmp __wmemcmp
+
+#include "wstring.c"
+
+strong_alias(__wmemcmp, wmemcmp)
+
+#undef L_memcmp

+ 15 - 0
libc/string/wmemcpy.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memcpy
+#define WANT_WIDE
+#define Wmemcpy __wmemcpy
+
+#include "wstring.c"
+
+strong_alias(__wmemcpy, wmemcpy)
+
+#undef L_memcpy

+ 15 - 0
libc/string/wmemmove.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memmove
+#define WANT_WIDE
+#define Wmemmove __wmemmove
+
+#include "wstring.c"
+
+strong_alias(__wmemmove, wmemmove)
+
+#undef L_memmove

+ 15 - 0
libc/string/wmempcpy.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_mempcpy
+#define WANT_WIDE
+#define Wmempcpy __wmempcpy
+
+#include "wstring.c"
+
+strong_alias(__wmempcpy, wmempcpy)
+
+#undef L_mempcpy

+ 15 - 0
libc/string/wmemset.c

@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
+#define L_memset
+#define WANT_WIDE
+#define Wmemset __wmemset
+
+#include "wstring.c"
+
+strong_alias(__wmemset, wmemset)
+
+#undef L_memset

File diff suppressed because it is too large
+ 288 - 77
libc/string/wstring.c


Some files were not shown because too many files changed in this diff