Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
* sysdeps/generic/expm1.c: #undef expm1 before weak_alias.
	* libc-symbols.h [! HAVE_ASM_SET_DIRECTIVE] (strong_alias,
 	strong_alias_asm): Use `foo = bar' syntax instead.
	* configure.in: Fix AC_ARG_WITH uses; check for --with-fp.  Move
 	$host_os checks to set gnu_ld/as and elf before sysdirs
 	generation.  Fix $with_fp test.
	[$elf=yes]: Prepend MACHINE/elf directory.
  • Loading branch information
Roland McGrath committed Apr 14, 1995
1 parent 6e33fad commit 335aa32
Show file tree
Hide file tree
Showing 4 changed files with 56 additions and 15 deletions.
9 changes: 9 additions & 0 deletions ChangeLog
@@ -1,5 +1,14 @@
Thu Apr 13 09:45:01 1995 Roland McGrath <roland@churchy.gnu.ai.mit.edu>

* sysdeps/generic/expm1.c: #undef expm1 before weak_alias.

* libc-symbols.h [! HAVE_ASM_SET_DIRECTIVE] (strong_alias,
strong_alias_asm): Use `foo = bar' syntax instead.
* configure.in: Fix AC_ARG_WITH uses; check for --with-fp. Move
$host_os checks to set gnu_ld/as and elf before sysdirs
generation. Fix $with_fp test.
[$elf=yes]: Prepend MACHINE/elf directory.

* elf/libelf.h (elf_hash): Use XOR instead of ANDN when the bits
being cleared are already known to be set. Thanks Ulrich.

Expand Down
50 changes: 35 additions & 15 deletions configure.in
Expand Up @@ -20,22 +20,25 @@ esac
])

dnl Arguments to specify presence of other packages/features.
AC_ARG_WITH(fp, dnl
--with-fp if using floating-point hardware,
with_fp=$withval, with_fp=yes)
AC_ARG_WITH(gnu-binutils, dnl
--with-gnu-binutils if using GNU binutils (as and ld),
gnu_binutils=yes, gnu_binutils=no)
gnu_binutils=$withval, gnu_binutils=no)
AC_ARG_WITH(gnu-ld, dnl
--with-gnu-ld if using GNU ld (in the binutils package),
gnu_ld=yes, gnu_ld=no)
gnu_ld=$withval, gnu_ld=no)
AC_ARG_WITH(gnu-as, dnl
--with-gnu-as if using GNU as (in the binutils package),
gnu_as=yes, gnu_as=no)
gnu_as=$withval, gnu_as=no)
test $gnu_binutils = yes && gnu_as=yes gnu_ld=yes
AC_ARG_WITH(elf, dnl
--with-elf if using the ELF object format,
elf=yes, elf=no)
elf=$withval, elf=no)
AC_ARG_WITH(weak-symbols, dnl
--with-weak-symbols if weak symbols are available in as and ld,
weak=yes, weak=no)
weak=$withval, weak=no)

dnl Arguments to enable or disable building the shared, profiled, and
dnl -fomit-frame-pointer libraries.
Expand Down Expand Up @@ -166,11 +169,24 @@ fi

# We have now validated the configuration.

# Some configurations imply other options.
case "$host_os" in
gnu* | linux* | bsd4.4* | netbsd* | freebsd*)
# These systems always use GNU tools.
gnu_ld=yes gnu_as=yes
esac
case "$host_os" in
gnu*elf* | linux* | sysv4* | solaris2*)
# These systems always use the ELF format.
elf=yes
esac


# Remove the leading slashes.
sysnames="`echo $sysnames | sed -e 's@^/@@' -e 's@ /@ @g'`"

# Prepend the machine's FPU directory unless --without-fp.
if test "$with_fp" = no; then
if test "$with_fp" = yes; then
fpu_dirs=
for m in $mach; do
if test -d $sysdep_dir$m/fpu; then
Expand All @@ -180,6 +196,19 @@ if test "$with_fp" = no; then
sysnames="`echo $fpu_dirs | sed -e 's,^/,,' -e 's, /,,g'` $sysnames"
fi

# If using ELF, prepend the machine-specific ELF ABI directory.
if test "$elf" = yes; then
elf_dirs=
for m in $mach; do
if test -d $sysdep_dir$m/elf; then
elf_dirs="elf_dirs $m/elf"
fi
done
sysnames="`echo elf_dirs | sed -e 's,^/,,' -e 's, /,,g'` $sysnames"
fi



# Expand the list of system names into a full list of directories
# from each element's parent name and Implies file (if present).
set $sysnames
Expand Down Expand Up @@ -241,15 +270,6 @@ libc_cv_sysdirs="$sysnames"])
AC_SUBST(sysnames) sysnames="$libc_cv_sysdirs"
AC_MSG_RESULT(${sysnames})

case "$host_os" in
gnu* | linux* | bsd4.4* | netbsd* | freebsd*)
gnu_ld=yes gnu_as=yes
esac
case "$host_os" in
gnu*elf* | linux* | sysv4* | solaris2*)
elf=yes
esac

AC_PROG_INSTALL
if test "$INSTALL" = "${srcdir}/install-sh"; then
# The makefiles need to use a different form to find it in $srcdir.
Expand Down
11 changes: 11 additions & 0 deletions libc-symbols.h
Expand Up @@ -80,6 +80,7 @@ Cambridge, MA 02139, USA. */
#endif

/* Define ALIAS as a strong alias for ORIGINAL. */
#ifdef HAVE_ASM_SET_DIRECTIVE
#define strong_alias_asm(original, alias) \
.set C_SYMBOL_NAME (alias),C_SYMBOL_NAME (original)
#ifdef ASSEMBLER
Expand All @@ -88,6 +89,16 @@ Cambridge, MA 02139, USA. */
#define strong_alias(original, alias) \
asm (".set " __SYMBOL_PREFIX #alias "," __SYMBOL_PREFIX #original);
#endif
#else
#define strong_alias_asm(original, alias) \
C_SYMBOL_NAME (alias) = C_SYMBOL_NAME (original)
#ifdef ASSEMBLER
#define strong_alias(original, alias) strong_alias_asm (original, alias)
#else
#define strong_alias(original, alias) \
asm (__SYMBOL_PREFIX #alias " = " __SYMBOL_PREFIX #original);
#endif
#endif

/* Define ALIAS as a weak alias for ORIGINAL.
If weak aliases are not available, this defines a strong alias. */
Expand Down
1 change: 1 addition & 0 deletions sysdeps/generic/expm1.c
Expand Up @@ -166,4 +166,5 @@ double x;
return( finite(x) ? scalb(one,5000) : x);
}

#undef expm1
weak_alias (__expm1, expm1)

0 comments on commit 335aa32

Please sign in to comment.