From 210dd78238dc99d1ba27318bf81393237620b72b Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Mon, 19 Oct 2015 12:06:00 +0000 Subject: Remove .weak, .weakext configure tests. There are configure tests for assembler .weak support, and, as a fallback, for .weakext support. .weakext appears to be an ECOFF thing (although a few ELF targets support it as well). .weak has been supported by the GNU assembler for ELF targets since version 2.2, so given the requirement for ELF the configure tests are obsolete; this patch removes them. Tested for x86_64 (testsuite, and that installed shared libraries are unchanged by the patch). * configure.ac (libc_cv_asm_weak_directive): Remove configure test. (libc_cv_asm_weakext_directive): Likewise. * configure: Regenerated. * config.h.in (HAVE_ASM_WEAK_DIRECTIVE): Remove #undef. (HAVE_ASM_WEAKEXT_DIRECTIVE): Likewise. * include/libc-symbols.h [!HAVE_ASM_WEAK_DIRECTIVE && !HAVE_ASM_WEAKEXT_DIRECTIVE]: Remove #error. [HAVE_ASM_WEAKEXT_DIRECTIVE]: Remove conditional code. [!HAVE_ASM_WEAKEXT_DIRECTIVE]: Make code unconditional. --- include/libc-symbols.h | 22 +++------------------- 1 file changed, 3 insertions(+), 19 deletions(-) (limited to 'include') diff --git a/include/libc-symbols.h b/include/libc-symbols.h index e2c63fc392..a9ac0e3ed7 100644 --- a/include/libc-symbols.h +++ b/include/libc-symbols.h @@ -35,11 +35,9 @@ file in the C library by -imacros. We include config.h which is generated by configure. - It should define for us the following symbols: + It should define for us the following symbol: * HAVE_ASM_SET_DIRECTIVE if we have `.set B, A' instead of `A = B'. - * HAVE_ASM_WEAK_DIRECTIVE if we have weak symbols using `.weak'. - * HAVE_ASM_WEAKEXT_DIRECTIVE if we have weak symbols using `.weakext'. */ @@ -80,10 +78,6 @@ /* The symbols in all the user (non-_) macros are C symbols. */ -#if !defined HAVE_ASM_WEAK_DIRECTIVE && !defined HAVE_ASM_WEAKEXT_DIRECTIVE -# error "weak symbol support needed" -#endif - #ifndef __SYMBOL_PREFIX # define __SYMBOL_PREFIX #endif @@ -142,23 +136,13 @@ # define strong_data_alias(original, alias) strong_alias(original, alias) # endif -# ifdef HAVE_ASM_WEAKEXT_DIRECTIVE -# define weak_alias(original, alias) \ - .weakext C_SYMBOL_NAME (alias), C_SYMBOL_NAME (original) -# define weak_extern(symbol) \ - .weakext C_SYMBOL_NAME (symbol) - -# else /* ! HAVE_ASM_WEAKEXT_DIRECTIVE */ - -# define weak_alias(original, alias) \ +# define weak_alias(original, alias) \ .weak C_SYMBOL_NAME (alias) ASM_LINE_SEP \ C_SYMBOL_NAME (alias) = C_SYMBOL_NAME (original) -# define weak_extern(symbol) \ +# define weak_extern(symbol) \ .weak C_SYMBOL_NAME (symbol) -# endif /* ! HAVE_ASM_WEAKEXT_DIRECTIVE */ - #endif /* __ASSEMBLER__ */ /* On some platforms we can make internal function calls (i.e., calls of -- cgit 1.4.1