From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1791) id 4C81D385152E; Fri, 28 Oct 2022 17:42:41 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4C81D385152E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1666978961; bh=l8R+h4HJc7giQD10PQxfs9mmPbWm5DiXspypIz5zgqE=; h=From:To:Subject:Date:From; b=sR0s2mbiaqunJlUMQmEz1YpwmFPFYtG0hpTK70mK3pzkgPTDNvbLw6x9stQd6nLg5 mTmdEHrCBYTZ1zJlfgcXGQk9RsFBVKvxpVlSKnfQgA0qufoZHD0QLpjYSwEr5Kn05d PPrcIA6M7BgOqJhIQNMEHKUam1KM8WHGzE+SCBgI= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Adhemerval Zanella To: glibc-cvs@sourceware.org Subject: [glibc/azanella/clang] Remove AS usage X-Act-Checkin: glibc X-Git-Author: Adhemerval Zanella X-Git-Refname: refs/heads/azanella/clang X-Git-Oldrev: a1c32083b21b83bbed047b441d93883c4a6128cb X-Git-Newrev: 5ad8a19a29a52fa941e0e0dace6f4b46947f6b00 Message-Id: <20221028174241.4C81D385152E@sourceware.org> Date: Fri, 28 Oct 2022 17:42:41 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=5ad8a19a29a52fa941e0e0dace6f4b46947f6b00 commit 5ad8a19a29a52fa941e0e0dace6f4b46947f6b00 Author: Adhemerval Zanella Date: Thu Jun 9 10:42:24 2022 -0300 Remove AS usage There is no direct usage assembler usage, all uses are through compiler. Diff: --- aclocal.m4 | 6 ---- configure | 85 ------------------------------------------------ configure.ac | 5 --- sysdeps/x86/configure | 18 +++++----- sysdeps/x86/configure.ac | 12 +++---- 5 files changed, 15 insertions(+), 111 deletions(-) diff --git a/aclocal.m4 b/aclocal.m4 index 3b4df4a371..94c931b4f2 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -118,7 +118,6 @@ case "$CC" in *fuse-ld=lld*) LDNAME=ld.lld;; *) LDNAME=ld;; esac -AS=`$CC -print-prog-name=as` LD=`$CC -print-prog-name=$LDNAME` AR=`$CC -print-prog-name=ar` AC_SUBST(AR) @@ -130,11 +129,6 @@ GPROF=`$CC -print-prog-name=gprof` AC_SUBST(GPROF) # Determine whether we are using GNU binutils. -AC_CACHE_CHECK(whether $AS is GNU as, libc_cv_prog_as_gnu, -[LIBC_PROG_FOO_GNU($AS, libc_cv_prog_as_gnu=yes, libc_cv_prog_as_gnu=no)]) -rm -f a.out -gnu_as=$libc_cv_prog_as_gnu - AC_CACHE_CHECK(whether $LD is GNU ld, libc_cv_prog_ld_gnu, [LIBC_PROG_FOO_GNU($LD, libc_cv_prog_ld_gnu=yes, libc_cv_prog_ld_gnu=no)]) gnu_ld=$libc_cv_prog_ld_gnu diff --git a/configure b/configure index f777e4fafd..3476e62ee7 100755 --- a/configure +++ b/configure @@ -646,7 +646,6 @@ MAKEINFO MSGFMT MAKE LD -AS GPROF OBJCOPY OBJDUMP @@ -4576,7 +4575,6 @@ case "$CC" in *fuse-ld=lld*) LDNAME=ld.lld;; *) LDNAME=ld;; esac -AS=`$CC -print-prog-name=as` LD=`$CC -print-prog-name=$LDNAME` AR=`$CC -print-prog-name=ar` @@ -4588,25 +4586,6 @@ GPROF=`$CC -print-prog-name=gprof` # Determine whether we are using GNU binutils. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $AS is GNU as" >&5 -$as_echo_n "checking whether $AS is GNU as... " >&6; } -if ${libc_cv_prog_as_gnu+:} false; then : - $as_echo_n "(cached) " >&6 -else - # Most GNU programs take a -v and spit out some text including -# the word 'GNU'. Some try to read stdin, so give them /dev/null. -if $AS -o conftest -v &1 | grep GNU > /dev/null 2>&1; then - libc_cv_prog_as_gnu=yes -else - libc_cv_prog_as_gnu=no -fi -rm -fr contest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_prog_as_gnu" >&5 -$as_echo "$libc_cv_prog_as_gnu" >&6; } -rm -f a.out -gnu_as=$libc_cv_prog_as_gnu - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $LD is GNU ld" >&5 $as_echo_n "checking whether $LD is GNU ld... " >&6; } if ${libc_cv_prog_ld_gnu+:} false; then : @@ -4627,70 +4606,6 @@ gnu_ld=$libc_cv_prog_ld_gnu # Accept binutils 2.25 or newer. -for ac_prog in $AS -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; 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_prog" - $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 - - - test -n "$AS" && break -done - -if test -z "$AS"; then - ac_verc_fail=yes -else - # Found it, now check the version. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking version of $AS" >&5 -$as_echo_n "checking version of $AS... " >&6; } - ac_prog_version=`$AS --version 2>&1 | sed -n 's/^.*GNU assembler.* \([0-9]*\.[0-9.]*\).*$/\1/p'` - case $ac_prog_version in - '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; - 2.1[0-9][0-9]*|2.2[5-9]*|2.[3-9][0-9]*|[3-9].*|[1-9][0-9]*) - ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; - *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; - - esac - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_prog_version" >&5 -$as_echo "$ac_prog_version" >&6; } -fi -if test $ac_verc_fail = yes; then - AS=: critic_missing="$critic_missing as" -fi - - libc_cv_with_lld=no case $($LD --version) in "GNU gold"*) diff --git a/configure.ac b/configure.ac index 03e14b13a0..410ff604c2 100644 --- a/configure.ac +++ b/configure.ac @@ -1003,11 +1003,6 @@ AC_PROG_LN_S LIBC_PROG_BINUTILS # Accept binutils 2.25 or newer. -AC_CHECK_PROG_VER(AS, $AS, --version, - [GNU assembler.* \([0-9]*\.[0-9.]*\)], - [2.1[0-9][0-9]*|2.2[5-9]*|2.[3-9][0-9]*|[3-9].*|[1-9][0-9]*], - AS=: critic_missing="$critic_missing as") - libc_cv_with_lld=no case $($LD --version) in "GNU gold"*) diff --git a/sysdeps/x86/configure b/sysdeps/x86/configure index a9c8c2ef67..af6ac34b5b 100644 --- a/sysdeps/x86/configure +++ b/sysdeps/x86/configure @@ -33,12 +33,12 @@ $as_echo "$libc_cv_x86_cet_available" >&6; } fi if test $enable_cet != no; then # Check if assembler supports CET. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $AS supports CET" >&5 -$as_echo_n "checking whether $AS supports CET... " >&6; } -if ${libc_cv_x86_cet_as+:} false; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports CET" >&5 +$as_echo_n "checking whether $CC supports CET... " >&6; } +if ${libc_cv_x86_cet_cc+:} false; then : $as_echo_n "(cached) " >&6 else - cat > conftest.s < conftest.S <&5 test $ac_status = 0; }; }; then - libc_cv_x86_cet_as=yes + libc_cv_x86_cet_cc=yes else - libc_cv_x86_cet_as=no + libc_cv_x86_cet_cc=no fi rm -rf conftest* fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_x86_cet_as" >&5 -$as_echo "$libc_cv_x86_cet_as" >&6; } - if test $libc_cv_x86_cet_as = no; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_x86_cet_cc" >&5 +$as_echo "$libc_cv_x86_cet_cc" >&6; } + if test $libc_cv_x86_cet_cc = no; then as_fn_error $? "$AS doesn't support CET" "$LINENO" 5 fi fi diff --git a/sysdeps/x86/configure.ac b/sysdeps/x86/configure.ac index edd43a2551..4e2a6d68ff 100644 --- a/sysdeps/x86/configure.ac +++ b/sysdeps/x86/configure.ac @@ -22,18 +22,18 @@ EOF fi if test $enable_cet != no; then # Check if assembler supports CET. - AC_CACHE_CHECK(whether $AS supports CET, - libc_cv_x86_cet_as, [dnl -cat > conftest.s < conftest.S <&AS_MESSAGE_LOG_FD); then - libc_cv_x86_cet_as=yes + libc_cv_x86_cet_cc=yes else - libc_cv_x86_cet_as=no + libc_cv_x86_cet_cc=no fi rm -rf conftest*]) - if test $libc_cv_x86_cet_as = no; then + if test $libc_cv_x86_cet_cc = no; then AC_MSG_ERROR([$AS doesn't support CET]) fi fi