mirror of
git://sourceware.org/git/glibc.git
synced 2024-11-21 01:12:26 +08:00
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.
This commit is contained in:
parent
bd2260a206
commit
210dd78238
12
ChangeLog
12
ChangeLog
@ -1,5 +1,17 @@
|
||||
2015-10-19 Joseph Myers <joseph@codesourcery.com>
|
||||
|
||||
* 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.
|
||||
|
||||
* sysdeps/arm/backtrace.c (__backtrace): Convert to
|
||||
prototype-style function definition.
|
||||
* sysdeps/i386/backtrace.c (__backtrace): Likewise.
|
||||
|
@ -18,12 +18,6 @@
|
||||
/* Defined if building with SELinux support & libcap libs are detected. */
|
||||
#undef HAVE_LIBCAP
|
||||
|
||||
/* Define if weak symbols are available via the `.weak' directive. */
|
||||
#undef HAVE_ASM_WEAK_DIRECTIVE
|
||||
|
||||
/* Define if weak symbols are available via the `.weakext' directive. */
|
||||
#undef HAVE_ASM_WEAKEXT_DIRECTIVE
|
||||
|
||||
/* Define to the assembler line separator character for multiple
|
||||
assembler instructions per line. Default is `;' */
|
||||
#undef ASM_LINE_SEP
|
||||
|
67
configure
vendored
67
configure
vendored
@ -6117,73 +6117,6 @@ if test $libc_cv_have_section_quotes = yes; then
|
||||
|
||||
fi
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for assembler .weak directive" >&5
|
||||
$as_echo_n "checking for assembler .weak directive... " >&6; }
|
||||
if ${libc_cv_asm_weak_directive+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
cat > conftest.s <<EOF
|
||||
${libc_cv_dot_text}
|
||||
.globl foo
|
||||
foo:
|
||||
.weak foo
|
||||
.weak bar; bar = foo
|
||||
EOF
|
||||
if { ac_try='${CC-cc} $ASFLAGS -c conftest.s 1>&5'
|
||||
{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
test $ac_status = 0; }; }; then
|
||||
libc_cv_asm_weak_directive=yes
|
||||
else
|
||||
libc_cv_asm_weak_directive=no
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_asm_weak_directive" >&5
|
||||
$as_echo "$libc_cv_asm_weak_directive" >&6; }
|
||||
|
||||
if test $libc_cv_asm_weak_directive = no; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for assembler .weakext directive" >&5
|
||||
$as_echo_n "checking for assembler .weakext directive... " >&6; }
|
||||
if ${libc_cv_asm_weakext_directive+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
cat > conftest.s <<EOF
|
||||
${libc_cv_dot_text}
|
||||
.globl foo
|
||||
foo:
|
||||
.weakext bar foo
|
||||
.weakext baz
|
||||
.globl baz
|
||||
baz:
|
||||
EOF
|
||||
if { ac_try='${CC-cc} $ASFLAGS -c conftest.s 1>&5'
|
||||
{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
test $ac_status = 0; }; }; then
|
||||
libc_cv_asm_weakext_directive=yes
|
||||
else
|
||||
libc_cv_asm_weakext_directive=no
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_asm_weakext_directive" >&5
|
||||
$as_echo "$libc_cv_asm_weakext_directive" >&6; }
|
||||
|
||||
fi # no .weak
|
||||
|
||||
if test $libc_cv_asm_weak_directive = yes; then
|
||||
$as_echo "#define HAVE_ASM_WEAK_DIRECTIVE 1" >>confdefs.h
|
||||
|
||||
elif test $libc_cv_asm_weakext_directive = yes; then
|
||||
$as_echo "#define HAVE_ASM_WEAKEXT_DIRECTIVE 1" >>confdefs.h
|
||||
|
||||
fi
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld --no-whole-archive" >&5
|
||||
$as_echo_n "checking for ld --no-whole-archive... " >&6; }
|
||||
if ${libc_cv_ld_no_whole_archive+:} false; then :
|
||||
|
44
configure.ac
44
configure.ac
@ -1550,50 +1550,6 @@ if test $libc_cv_have_section_quotes = yes; then
|
||||
AC_DEFINE(HAVE_SECTION_QUOTES)
|
||||
fi
|
||||
|
||||
AC_CACHE_CHECK(for assembler .weak directive, libc_cv_asm_weak_directive,
|
||||
[dnl
|
||||
cat > conftest.s <<EOF
|
||||
${libc_cv_dot_text}
|
||||
.globl foo
|
||||
foo:
|
||||
.weak foo
|
||||
.weak bar; bar = foo
|
||||
EOF
|
||||
if AC_TRY_COMMAND(${CC-cc} $ASFLAGS -c conftest.s 1>&AS_MESSAGE_LOG_FD); then
|
||||
libc_cv_asm_weak_directive=yes
|
||||
else
|
||||
libc_cv_asm_weak_directive=no
|
||||
fi
|
||||
rm -f conftest*])
|
||||
|
||||
if test $libc_cv_asm_weak_directive = no; then
|
||||
AC_CACHE_CHECK(for assembler .weakext directive,
|
||||
libc_cv_asm_weakext_directive,
|
||||
[dnl
|
||||
cat > conftest.s <<EOF
|
||||
${libc_cv_dot_text}
|
||||
.globl foo
|
||||
foo:
|
||||
.weakext bar foo
|
||||
.weakext baz
|
||||
.globl baz
|
||||
baz:
|
||||
EOF
|
||||
if AC_TRY_COMMAND(${CC-cc} $ASFLAGS -c conftest.s 1>&AS_MESSAGE_LOG_FD); then
|
||||
libc_cv_asm_weakext_directive=yes
|
||||
else
|
||||
libc_cv_asm_weakext_directive=no
|
||||
fi
|
||||
rm -f conftest*])
|
||||
|
||||
fi # no .weak
|
||||
|
||||
if test $libc_cv_asm_weak_directive = yes; then
|
||||
AC_DEFINE(HAVE_ASM_WEAK_DIRECTIVE)
|
||||
elif test $libc_cv_asm_weakext_directive = yes; then
|
||||
AC_DEFINE(HAVE_ASM_WEAKEXT_DIRECTIVE)
|
||||
fi
|
||||
|
||||
AC_CACHE_CHECK(for ld --no-whole-archive, libc_cv_ld_no_whole_archive, [dnl
|
||||
cat > conftest.c <<\EOF
|
||||
_start () {}
|
||||
|
@ -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
|
||||
|
Loading…
Reference in New Issue
Block a user