diff options
author | Peter S. Mazinger <ps.m@gmx.net> | 2006-01-03 14:46:56 +0000 |
---|---|---|
committer | Peter S. Mazinger <ps.m@gmx.net> | 2006-01-03 14:46:56 +0000 |
commit | fe68563b9a070fedf117c8738652587945427bb3 (patch) | |
tree | 300a37bb5f0cd28a984900d8e48925de2478fd1e | |
parent | 8356ff4a52a5df7e5e84ac13f7dad7c29e0bda9c (diff) |
Use strong_alias everywhere instead of .global/.set. Correct some cases where the non-hidden version was used.
95 files changed, 213 insertions, 326 deletions
diff --git a/libc/string/arm/_memcpy.S b/libc/string/arm/_memcpy.S index 236500e5f..e8d78af23 100644 --- a/libc/string/arm/_memcpy.S +++ b/libc/string/arm/_memcpy.S @@ -73,6 +73,7 @@ .text .global _memcpy +.hidden _memcpy .type _memcpy,%function .align 4 diff --git a/libc/string/arm/bcopy.S b/libc/string/arm/bcopy.S index a02807527..2914b8972 100644 --- a/libc/string/arm/bcopy.S +++ b/libc/string/arm/bcopy.S @@ -39,8 +39,8 @@ /* bcopy = memcpy/memmove with arguments reversed. */ -.global bcopy -.set bcopy,__bcopy +#include <features.h> + .text .global __bcopy .hidden __bcopy @@ -55,3 +55,5 @@ __bcopy: b _memcpy (PLT) .size __bcopy,.-__bcopy + +strong_alias(__bcopy,bcopy) diff --git a/libc/string/arm/bzero.S b/libc/string/arm/bzero.S index 93582f7c8..2cb67097e 100644 --- a/libc/string/arm/bzero.S +++ b/libc/string/arm/bzero.S @@ -37,16 +37,19 @@ * by Erik Andersen <andersen@codepoet.org> */ +#include <features.h> + .text .global __bzero +.hidden __bzero .type __bzero,%function .align 4 __bzero: mov r2, r1 mov r1, #0 - b memset (PLT) + b __memset .size __bzero,.-__bzero -.weak bzero ; bzero = __bzero +strong_alias(__bzero,bzero) diff --git a/libc/string/arm/memcmp.S b/libc/string/arm/memcmp.S index bdb5aca18..a97e02742 100644 --- a/libc/string/arm/memcmp.S +++ b/libc/string/arm/memcmp.S @@ -29,9 +29,8 @@ * by Erik Andersen <andersen@codepoet.org> */ +#include <features.h> -.global memcmp -.set memcmp,__memcmp .text .global __memcmp .hidden __memcmp @@ -56,4 +55,6 @@ __memcmp: mov pc, lr .size __memcmp,.-__memcmp -.weak bcmp ; bcmp = memcmp + +strong_alias(__memcmp,memcmp) +strong_alias(__memcmp,bcmp) diff --git a/libc/string/arm/memcpy.S b/libc/string/arm/memcpy.S index 372da4c49..8f81a15e5 100644 --- a/libc/string/arm/memcpy.S +++ b/libc/string/arm/memcpy.S @@ -37,8 +37,8 @@ * by Erik Andersen <andersen@codepoet.org> */ -.global memcpy -.set memcpy,__memcpy +#include <features.h> + .text .global __memcpy .hidden __memcpy @@ -47,7 +47,9 @@ __memcpy: stmfd sp!, {r0, lr} - bl _memcpy (PLT) + bl _memcpy ldmfd sp!, {r0, pc} .size __memcpy,.-__memcpy + +strong_alias(__memcpy,memcpy) diff --git a/libc/string/arm/memmove.S b/libc/string/arm/memmove.S index eafd345b4..a26cf731e 100644 --- a/libc/string/arm/memmove.S +++ b/libc/string/arm/memmove.S @@ -37,8 +37,8 @@ * by Erik Andersen <andersen@codepoet.org> */ -.global memmove -.set memmove,__memmove +#include <features.h> + .text .global __memmove .hidden __memmove @@ -47,7 +47,9 @@ __memmove: stmfd sp!, {r0, lr} - bl _memcpy (PLT) + bl _memcpy ldmfd sp!, {r0, pc} .size __memmove,.-__memmove + +strong_alias(__memmove,memmove) diff --git a/libc/string/arm/memset.S b/libc/string/arm/memset.S index 5fca03a13..dea05a6b0 100644 --- a/libc/string/arm/memset.S +++ b/libc/string/arm/memset.S @@ -17,10 +17,9 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ +#include <features.h> #include <sys/syscall.h> -.global memset -.set memset,__memset .text .global __memset .hidden __memset @@ -72,3 +71,5 @@ __memset: mov pc, lr .size __memset,.-__memset + +strong_alias(__memset,memset) diff --git a/libc/string/arm/strcmp.S b/libc/string/arm/strcmp.S index 33acc14cf..3f462dec0 100644 --- a/libc/string/arm/strcmp.S +++ b/libc/string/arm/strcmp.S @@ -31,8 +31,6 @@ #include <features.h> -.global strcmp -.set strcmp,__strcmp .text .global __strcmp .hidden __strcmp @@ -50,7 +48,9 @@ __strcmp: mov pc, lr .size __strcmp,.-__strcmp + +strong_alias(__strcmp,strcmp) #ifndef __UCLIBC_HAS_LOCALE__ -.global __strcoll ; .hidden __strcoll ; __strcoll = __strcmp -.global strcoll ; .set strcoll,__strcmp +hidden_strong_alias(__strcmp,__strcoll) +strong_alias(__strcmp,strcoll) #endif diff --git a/libc/string/arm/strlen.S b/libc/string/arm/strlen.S index 7d91fd033..f623cbe20 100644 --- a/libc/string/arm/strlen.S +++ b/libc/string/arm/strlen.S @@ -17,6 +17,7 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ +#include <features.h> #include <endian.h> #include <sys/syscall.h> @@ -25,8 +26,6 @@ * exit: r0 = len */ -.global strlen -.set strlen,__strlen .text .global __strlen .hidden __strlen @@ -80,3 +79,5 @@ Llastword: @ drop through to here once we find a mov pc,lr .size __strlen,.-__strlen + +strong_alias(__strlen,strlen) diff --git a/libc/string/arm/strncmp.S b/libc/string/arm/strncmp.S index 94e93f7df..a3278727e 100644 --- a/libc/string/arm/strncmp.S +++ b/libc/string/arm/strncmp.S @@ -29,8 +29,8 @@ * by Erik Andersen <andersen@codepoet.org> */ -.global strncmp -.set strncmp,__strncmp +#include <features.h> + .text .global __strncmp .hidden __strncmp @@ -57,3 +57,5 @@ __strncmp: mov pc, lr .size __strncmp,.-__strncmp + +strong_alias(__strncmp,strncmp) diff --git a/libc/string/frv/memcpy.S b/libc/string/frv/memcpy.S index 1ffc7c398..abd8a28db 100644 --- a/libc/string/frv/memcpy.S +++ b/libc/string/frv/memcpy.S @@ -18,6 +18,7 @@ * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +#include <features.h> .text .p2align 4 @@ -30,8 +31,6 @@ # to caller's fixup routine, aborting the remainder of the copy # ############################################################################### - .globl memcpy - .set memcpy,__memcpy .globl __memcpy .hidden __memcpy .type __memcpy,@function @@ -125,3 +124,5 @@ memcpy_32: bralr .size __memcpy, .-__memcpy + +strong_alias(__memcpy,memcpy) diff --git a/libc/string/frv/memset.S b/libc/string/frv/memset.S index 62e705a44..a548b3779 100644 --- a/libc/string/frv/memset.S +++ b/libc/string/frv/memset.S @@ -18,6 +18,7 @@ * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +#include <features.h> .text .p2align 4 @@ -31,8 +32,6 @@ # GR4, GR7, GR8, and GR11 must be managed # ############################################################################### - .globl memset - .set memset,__memset .globl __memset .hidden __memset .type __memset,@function @@ -156,3 +155,5 @@ __memset: cstb.p gr12,@(gr4,gr0) ,cc7,#1 bralr .size __memset, .-__memset + +strong_alias(__memset,memset) diff --git a/libc/string/generic/memchr.c b/libc/string/generic/memchr.c index bc0623f3f..68c820814 100644 --- a/libc/string/generic/memchr.c +++ b/libc/string/generic/memchr.c @@ -29,8 +29,6 @@ #define LONG_MAX_32_BITS 2147483647 -#undef memchr - /* Search no more than N bytes of S for C. */ void attribute_hidden *__memchr (const void * s, int c_in, size_t n) { @@ -174,4 +172,4 @@ void attribute_hidden *__memchr (const void * s, int c_in, size_t n) return 0; } -strong_alias(__memchr, memchr) +strong_alias(__memchr,memchr) diff --git a/libc/string/generic/memcmp.c b/libc/string/generic/memcmp.c index a3fcba036..13e11692a 100644 --- a/libc/string/generic/memcmp.c +++ b/libc/string/generic/memcmp.c @@ -20,8 +20,6 @@ #include <string.h> -#undef memcmp - #include "memcopy.h" #include <endian.h> @@ -332,6 +330,6 @@ attribute_hidden __memcmp (const __ptr_t s1, const __ptr_t s2, size_t len) return 0; } -strong_alias(__memcmp, memcmp) +strong_alias(__memcmp,memcmp) -weak_alias(memcmp, bcmp) +strong_alias(__memcmp,bcmp) |