diff options
author | Roland McGrath <roland@gnu.org> | 1996-03-19 21:10:11 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 1996-03-19 21:10:11 +0000 |
commit | c224a18a9045610c4ec1e4d959f6a5dd6b117dd9 (patch) | |
tree | 3ec6bbc9ad25817511f08d4a10035d351d88f6bf /configure.in | |
parent | b20e47cb14ec8edccab7c722743a731e67280702 (diff) | |
download | glibc-c224a18a9045610c4ec1e4d959f6a5dd6b117dd9.tar.gz glibc-c224a18a9045610c4ec1e4d959f6a5dd6b117dd9.tar.xz glibc-c224a18a9045610c4ec1e4d959f6a5dd6b117dd9.zip |
* config.make.in (weak-symbols): Variable removed.
* configure.in (--with-weak-symbols): Option removed. (NO_UNDERSCORES, HAVE_ASM_WEAK_DIRECTIVE, HAVE_ASM_WEAKEXT_DIRECTIVE): New tests. * config.h.in (HAVE_WEAK_SYMBOLS): #undef removed. (NO_UNDERSCORES, HAVE_ASM_WEAK_DIRECTIVE, HAVE_ASM_WEAKEXT_DIRECTIVE): New #undefs. * libc-symbols.h: Use them instead of HAVE_WEAK_SYMBOLS. * inet/inet_lnaof.c: Use u_int32_t instead of u_long. * inet/inet_mkadr.c: Likewise. * inet/inet_net.c: Likewise. * inet/inet_netof.c: Likewise. * inet/rcmd.c: Likewise. * inet/arpa/inet.h: Likewise. * inet/netinet/in.h: Likewise. * inet/netinet/tcp.h: Likewise. * inet/protocols/rwhod.h: Likewise. * inet/protocols/talkd.h: Likewise. * resolv/inet_addr.c: Likewise. * sunrpc/rpc/xdr.h (IXDR_GET_LONG, IXDR_PUT_LONG): change casts to u_int32_t (instead of u_long).
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 73 |
1 files changed, 65 insertions, 8 deletions
diff --git a/configure.in b/configure.in index 4c9d881100..d124e49964 100644 --- a/configure.in +++ b/configure.in @@ -1,6 +1,6 @@ Dnl Process this file with autoconf to produce a configure script. AC_REVISION([$CVSid$]) -AC_PREREQ(2.4.2)dnl dnl Minimum Autoconf version required. +AC_PREREQ(2.9)dnl dnl Minimum Autoconf version required. AC_INIT(features.h) AC_CONFIG_HEADER(config.h) @@ -49,9 +49,6 @@ test $gnu_binutils = yes && gnu_as=yes gnu_ld=yes AC_ARG_WITH(elf, dnl --with-elf if using the ELF object format, elf=$withval, elf=no) -AC_ARG_WITH(weak-symbols, dnl - --with-weak-symbols if weak symbols are available in as and ld, - weak=$withval, weak=no) AC_ARG_ENABLE(libio, dnl [ --enable-libio build in GNU libio instead of GNU stdio], @@ -406,6 +403,69 @@ if test $elf != yes; then fi fi +if test $elf = yes; then + libc_cv_asm_underscores=no +else + AC_CACHE_CHECK(for _ prefix on C symbol names, libc_cv_asm_underscores, + [AC_TRY_COMPILE([asm ("_glibc_foobar:");], [glibc_foobar ();], + libc_cv_asm_underscores=yes, + libc_cv_asm_underscores=no)]) +fi +if test $libc_cv_asm_underscores = no; then + AC_DEFINE(NO_UNDERSCORES) +fi + +if test $elf = yes; then + libc_cv_weak_symbols=yes + libc_cv_asm_weak_directive=yes + libc_cv_asm_weakext_directive=no +else + AC_CACHE_CHECK(for assembler .weak directive, libc_cv_asm_weak_directive, + [dnl +cat > conftest.s <<EOF +.text +${libc_cv_asm_global_directive} foo +foo: .long 0 +.weak foo +.weak bar; bar = foo +EOF + if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then + libc_cv_asm_weak_directive=yes + else + libc_cv_asm_weak_directive=no + fi + rm -f conftest*]) + +if $libc_cv_asm_weak_directive = no; then + AC_CACHE_CHECK(for assembler .weakext directive, + libc_cv_asm_weakext_directive, + [dnl +cat > conftest.s <<EOF +.text +${libc_cv_asm_global_directive} foo +foo: .long 0 +.weakext foo +.weak bar, foo +EOF + if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then + libc_cv_asm_weakext_directive=yes + else + libc_cv_asm_weakext_directive=no + fi + rm -f conftest*]) + + fi # no .weak +fi # not ELF + +if test $libc_cv_asm_weak_directive; then + AC_DEFINE(HAVE_ASM_WEAK_DIRECTIVE) +elif test $libc_cv_asm_weakext_directive; then + AC_DEFINE(HAVE_ASM_WEAKEXT_DIRECTIVE) +fi + +### End of automated tests. +### Now run sysdeps configure fragments. + # sysdeps configure fragments may set these with files to be linked below. libc_link_dests= libc_link_sources= @@ -498,7 +558,7 @@ default) stdio=stdio ;; esac AC_MSG_RESULT($stdio) -AC_SUBST(gnu_ld) AC_SUBST(gnu_as) AC_SUBST(elf) AC_SUBST(weak) +AC_SUBST(gnu_ld) AC_SUBST(gnu_as) AC_SUBST(elf) if test $gnu_ld = yes; then AC_DEFINE(HAVE_GNU_LD) fi @@ -508,9 +568,6 @@ fi if test $elf = yes; then AC_DEFINE(HAVE_ELF) fi -if test $weak = yes; then - AC_DEFINE(HAVE_WEAK_SYMBOLS) -fi AC_SUBST(shared) if test $shared = default; then |