diff options
author | Mike Frysinger <vapier@gentoo.org> | 2022-02-05 01:43:41 -0500 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2022-02-08 20:19:18 -0500 |
commit | 34af195290f0168ea63e039028a80503865ee3f9 (patch) | |
tree | 1edcc6ee109fa92a23a1aa25e141dd6bf1528460 /newlib/libm | |
parent | b9346cee1a1ac2b496d98f723e802a6e7959b1e0 (diff) | |
download | newlib-34af195290f0168ea63e039028a80503865ee3f9.zip newlib-34af195290f0168ea63e039028a80503865ee3f9.tar.gz newlib-34af195290f0168ea63e039028a80503865ee3f9.tar.bz2 |
newlib: switch to standard AM_PROG_AS
Now that we require a recent automake version, rely on it to provide AS
and CCAS and CCASFLAGS for us.
Diffstat (limited to 'newlib/libm')
-rw-r--r-- | newlib/libm/aclocal.m4 | 20 | ||||
-rwxr-xr-x | newlib/libm/configure | 118 |
2 files changed, 32 insertions, 106 deletions
diff --git a/newlib/libm/aclocal.m4 b/newlib/libm/aclocal.m4 index e92803b..ce5020f 100644 --- a/newlib/libm/aclocal.m4 +++ b/newlib/libm/aclocal.m4 @@ -56,6 +56,26 @@ m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) +# Figure out how to run the assembler. -*- Autoconf -*- + +# Copyright (C) 2001-2017 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_AS +# ---------- +AC_DEFUN([AM_PROG_AS], +[# By default we simply use the C compiler to build assembly code. +AC_REQUIRE([AC_PROG_CC]) +test "${CCAS+set}" = set || CCAS=$CC +test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS +AC_ARG_VAR([CCAS], [assembler compiler command (defaults to CC)]) +AC_ARG_VAR([CCASFLAGS], [assembler compiler flags (defaults to CFLAGS)]) +_AM_IF_OPTION([no-dependencies],, [_AM_DEPENDENCIES([CCAS])])dnl +]) + # AM_AUX_DIR_EXPAND -*- Autoconf -*- # Copyright (C) 2001-2017 Free Software Foundation, Inc. diff --git a/newlib/libm/configure b/newlib/libm/configure index 1aaa4ee..99ee6c9 100755 --- a/newlib/libm/configure +++ b/newlib/libm/configure @@ -660,6 +660,7 @@ GREP LIBTOOL OBJDUMP DLLTOOL +AS SED sys_dir shared_machine_dir @@ -682,12 +683,11 @@ ELIX_LEVEL_0_FALSE ELIX_LEVEL_0_TRUE NO_INCLUDE_LIST NEWLIB_CFLAGS -CCASFLAGS -CCAS READELF RANLIB AR -AS +CCASFLAGS +CCAS CPP OBJEXT EXEEXT @@ -3815,6 +3815,13 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu +# By default we simply use the C compiler to build assembly code. + +test "${CCAS+set}" = set || CCAS=$CC +test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS + + + # Check whether --enable-target-optspace was given. if test "${enable_target_optspace+set}" = set; then : @@ -4109,101 +4116,6 @@ AM_BACKSLASH='\' - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args. -set dummy ${ac_tool_prefix}as; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AS+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AS"; then - ac_cv_prog_AS="$AS" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AS="${ac_tool_prefix}as" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AS=$ac_cv_prog_AS -if test -n "$AS"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 -$as_echo "$AS" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_AS"; then - ac_ct_AS=$AS - # Extract the first word of "as", so it can be a program name with args. -set dummy as; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_AS+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AS"; then - ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_AS="as" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_AS=$ac_cv_prog_ac_ct_AS -if test -n "$ac_ct_AS"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5 -$as_echo "$ac_ct_AS" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_AS" = x; then - AS="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AS=$ac_ct_AS - fi -else - AS="$ac_cv_prog_AS" -fi - if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. set dummy ${ac_tool_prefix}ar; ac_word=$2 @@ -4508,12 +4420,6 @@ fi MAINT=$MAINTAINER_MODE_TRUE -# By default we simply use the C compiler to build assembly code. -test "${CCAS+set}" = set || CCAS=$CC -test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS - - - # We need AC_EXEEXT to keep automake happy in cygnus mode. However, # at least currently, we never actually build a program, so we never @@ -11292,7 +11198,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11295 "configure" +#line 11201 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -11398,7 +11304,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11401 "configure" +#line 11307 "configure" #include "confdefs.h" #if HAVE_DLFCN_H |