From patchwork Tue Dec 6 16:02:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adhemerval Zanella Netto X-Patchwork-Id: 61591 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 19EE5383FD7F for ; Tue, 6 Dec 2022 16:03:28 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 19EE5383FD7F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1670342608; bh=2ROdcVpzFnQV7gJLLTWIFhGhtu8AZraQ5oI+hxY+IT8=; h=To:Subject:Date:In-Reply-To:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=BHZImfi45Wq3OIAbawnOU22HxiiS/cM2zlakBURBLCOOmFc2I4KbhX7LX7SAjuN7y CLKYASiZHqosYRYTlcatDZxEjMNVTW9TIfj6tJxq2j3UpyuAHueqx/hMHeVlnPo869 uQZMOntA50C1wBo6KSTnEYv/G/45dTls1ufLl7gw= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-ot1-x329.google.com (mail-ot1-x329.google.com [IPv6:2607:f8b0:4864:20::329]) by sourceware.org (Postfix) with ESMTPS id 85EDD3842319 for ; Tue, 6 Dec 2022 16:03:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 85EDD3842319 Received: by mail-ot1-x329.google.com with SMTP id v19-20020a9d5a13000000b0066e82a3872dso7510965oth.5 for ; Tue, 06 Dec 2022 08:03:06 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2ROdcVpzFnQV7gJLLTWIFhGhtu8AZraQ5oI+hxY+IT8=; b=Mw+YX+dFNXMITF89xaPDYPk6iqHoSqtNFmEL9Gj0V4nal60HZNaotx1lqI+IOEBNAu QiOhK9PACxrKQyRW6m55Ik9ZzxrF2xiMc9ZoXgqRZd/Dl81R+oNDkCJnjlVU4xt2QR+1 62nHxUchwmO+mgQ+RNd5tWwofyhjLr9aF1GRKa6WCQAIFPPLCGkdpHGcfM3Xk/98HsLp DLb3heYsvn1MIgTkzJUFoJ9POv9dPB7uOoWP80NAISGiOS2/puS8i0/yowXTSctEKqSv dFbI1d51LEpTWs1xFCs8d2SubblXU1nDUyiSS1fPMfwfJVYwl7EpJXAQ6rM8pUC2/fQb uFOg== X-Gm-Message-State: ANoB5pndzL6NlQ0HLCQH43D7mIG3Ga/PeDKQbhiiq1hF5y/KAwr81h67 qSpcz9yoj5hTVPQJXKCeRLD3ZI2fNd7oDjKq1tk= X-Google-Smtp-Source: AA0mqf4gpFsMFGjER2pdBW7Fg8NpM0Xppe7pzGL5zw4xQhRpJkhB06KRl+YGb6P+LLHeQQMX1RgB6w== X-Received: by 2002:a05:6830:186:b0:66e:7d07:2ead with SMTP id q6-20020a056830018600b0066e7d072eadmr10983852ota.154.1670342585574; Tue, 06 Dec 2022 08:03:05 -0800 (PST) Received: from mandiga.. ([2804:1b3:a7c2:6793:6a7:7646:7f3f:684e]) by smtp.gmail.com with ESMTPSA id k6-20020a544686000000b00349a06c581fsm8495008oic.3.2022.12.06.08.03.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Dec 2022 08:03:05 -0800 (PST) To: libc-alpha@sourceware.org, Vineet Gupta , =?utf-8?q?Ludovic_Court=C3=A8s?= , Carlos O'Donell Subject: [PATCH v2 1/3] configure: Allow user override LD, AR, OBJCOPY, and GPROF Date: Tue, 6 Dec 2022 13:02:41 -0300 Message-Id: <20221206160243.455627-2-adhemerval.zanella@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221206160243.455627-1-adhemerval.zanella@linaro.org> References: <20221206160243.455627-1-adhemerval.zanella@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-12.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Adhemerval Zanella via Libc-alpha From: Adhemerval Zanella Netto Reply-To: Adhemerval Zanella Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" The only way to override LD, AR, OBJCOPY, and GPROF is through --with-binutils (setting the environments variables on configure is overridden by LIBC_PROG_BINUTILS). The build-many-glibcs.py (bmg) glibcs option generates a working config, but not fully concise (some tools will be set from environment variable, while other will be set from $CC --print-prog-name). So remove the environment variable set to always use the "$CC --print-prog-name". Reviewed-by: Carlos O'Donell --- aclocal.m4 | 16 ++++++++++++---- configure | 16 ++++++++++++---- scripts/build-many-glibcs.py | 3 --- 3 files changed, 24 insertions(+), 11 deletions(-) diff --git a/aclocal.m4 b/aclocal.m4 index 7ab8ac023b..cbe3c4698a 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -118,12 +118,20 @@ case "$CC" in *fuse-ld=lld*) LDNAME=ld.lld;; *) LDNAME=ld;; esac -LD=`$CC -print-prog-name=$LDNAME` -AR=`$CC -print-prog-name=ar` +if test -z "$LD"; then + LD=`$CC -print-prog-name=$LDNAME` +fi +if test -z "$AR"; then + AR=`$CC -print-prog-name=ar` +fi AC_SUBST(AR) -OBJCOPY=`$CC -print-prog-name=objcopy` +if test -z "$OBJCOPY"; then + OBJCOPY=`$CC -print-prog-name=objcopy` +fi AC_SUBST(OBJCOPY) -GPROF=`$CC -print-prog-name=gprof` +if test -z "$GPROF"; then + GPROF=`$CC -print-prog-name=gprof` +fi AC_SUBST(GPROF) ]) diff --git a/configure b/configure index 62c2581cb0..8f91bb6e11 100755 --- a/configure +++ b/configure @@ -4145,12 +4145,20 @@ case "$CC" in *fuse-ld=lld*) LDNAME=ld.lld;; *) LDNAME=ld;; esac -LD=`$CC -print-prog-name=$LDNAME` -AR=`$CC -print-prog-name=ar` +if test -z "$LD"; then + LD=`$CC -print-prog-name=$LDNAME` +fi +if test -z "$AR"; then + AR=`$CC -print-prog-name=ar` +fi -OBJCOPY=`$CC -print-prog-name=objcopy` +if test -z "$OBJCOPY"; then + OBJCOPY=`$CC -print-prog-name=objcopy` +fi -GPROF=`$CC -print-prog-name=gprof` +if test -z "$GPROF"; then + GPROF=`$CC -print-prog-name=gprof` +fi diff --git a/scripts/build-many-glibcs.py b/scripts/build-many-glibcs.py index 9292a0d3ff..887ef7b6d5 100755 --- a/scripts/build-many-glibcs.py +++ b/scripts/build-many-glibcs.py @@ -1521,10 +1521,7 @@ class GlibcPolicyDefault(object): '--host=%s' % glibc.triplet, 'CC=%s' % glibc.tool_name('gcc'), 'CXX=%s' % glibc.tool_name('g++'), - 'AR=%s' % glibc.tool_name('ar'), - 'LD=%s' % glibc.tool_name('ld'), 'NM=%s' % glibc.tool_name('nm'), - 'OBJCOPY=%s' % glibc.tool_name('objcopy'), 'OBJDUMP=%s' % glibc.tool_name('objdump'), 'RANLIB=%s' % glibc.tool_name('ranlib'), 'READELF=%s' % glibc.tool_name('readelf'), From patchwork Tue Dec 6 16:02:42 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adhemerval Zanella Netto X-Patchwork-Id: 61592 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 175E9383FD52 for ; Tue, 6 Dec 2022 16:04:10 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 175E9383FD52 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1670342650; bh=c/4MBgzcrSl4F74PpjvLezgvcvV/qYHWw58wMa1YIPk=; h=To:Subject:Date:In-Reply-To:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=gLdUT4oVUOEkeTM9Kk3OVsAHtsnk18GkGdCuyUo7PqaYHVYy/jeQzn5BlQHtH73qf vluEEyk6ChLgfuI2XA9PUTjo87OIu2wJnaKPIcJTaLxHHBVC0qSbUA3SD7gtxStrE2 Y+mM4dw6ajC8NgXGe3tZHbC31Hq3S49LRXtlLlf0= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-ot1-x32b.google.com (mail-ot1-x32b.google.com [IPv6:2607:f8b0:4864:20::32b]) by sourceware.org (Postfix) with ESMTPS id A79E8384230A for ; Tue, 6 Dec 2022 16:03:08 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org A79E8384230A Received: by mail-ot1-x32b.google.com with SMTP id z14-20020a9d65ce000000b0067059c25facso1415658oth.6 for ; Tue, 06 Dec 2022 08:03:08 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=c/4MBgzcrSl4F74PpjvLezgvcvV/qYHWw58wMa1YIPk=; b=gBfiULA0uNlXsMhpDYo72D75ZlQErEpxSCauHIVm8XMwhwKs9KqSSnLTrZB5iIl7Fl kCBAWmsxFpVt9jNkFfQFihJ0txvQvQ4kwVGTSKwC6bb+vxaNCvkBpeMPtt1MjEGccp6b clxEQ5/3upI/6KB/f8sao8+KPW1gbgRIF095yqfQdW/dWDHGSpRTUE43AhHlqF1qKpOV glY0zGK8PITQUbu/LBEFu9chScBgTmTa2fd0RWtVYufBfacqFMz40XkECg5VWfhFWgk0 mljuZbTprZi4DQDSbrXvkVf7cxzToV5LDK/HrA51mc0DugMDvg+eLmzJ5SX0vAi1yGA4 ULqw== X-Gm-Message-State: ANoB5pl7pg1okQ71bWtGPil0vur04I/w8aHYG8/faCubdpXswhWvTzw0 5IDZJwBKPI7T/iJude+gXNK/0kew3ZrznKLTo2k= X-Google-Smtp-Source: AA0mqf5oWEugEGzWKYXwltD3kQ4XKwZ4efmJ98vFTe7g26n3tZdT6Pc3oNchfjBHgtNu2ut7XyXzNA== X-Received: by 2002:a05:6830:398c:b0:66d:1553:c5ce with SMTP id bs12-20020a056830398c00b0066d1553c5cemr34096122otb.324.1670342587585; Tue, 06 Dec 2022 08:03:07 -0800 (PST) Received: from mandiga.. ([2804:1b3:a7c2:6793:6a7:7646:7f3f:684e]) by smtp.gmail.com with ESMTPSA id k6-20020a544686000000b00349a06c581fsm8495008oic.3.2022.12.06.08.03.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Dec 2022 08:03:07 -0800 (PST) To: libc-alpha@sourceware.org, Vineet Gupta , =?utf-8?q?Ludovic_Court=C3=A8s?= , Carlos O'Donell Subject: [PATCH v2 2/3] configure: Move nm, objdump, and readelf to LIBC_PROG_BINUTILS Date: Tue, 6 Dec 2022 13:02:42 -0300 Message-Id: <20221206160243.455627-3-adhemerval.zanella@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221206160243.455627-1-adhemerval.zanella@linaro.org> References: <20221206160243.455627-1-adhemerval.zanella@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-12.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Adhemerval Zanella via Libc-alpha From: Adhemerval Zanella Netto Reply-To: Adhemerval Zanella Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" It allows to be overriden on configure tie the tools with the cross compiler used. --- aclocal.m4 | 12 ++ configure | 295 ++--------------------------------- configure.ac | 4 - scripts/build-many-glibcs.py | 3 - 4 files changed, 27 insertions(+), 287 deletions(-) diff --git a/aclocal.m4 b/aclocal.m4 index cbe3c4698a..213835e1d5 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -133,6 +133,18 @@ if test -z "$GPROF"; then GPROF=`$CC -print-prog-name=gprof` fi AC_SUBST(GPROF) +if test -z "$READELF"; then + READELF=`$CC -print-prog-name=readelf` +fi +AC_SUBST(READELF) +if test -z "$OBJDUMP"; then + OBJDUMP=`$CC -print-prog-name=objdump` +fi +AC_SUBST(OBJDUMP) +if test -z "$NM"; then + NM=`$CC -print-prog-name=nm` +fi +AC_SUBST(NM) ]) dnl Run a static link test with -nostdlib -nostartfiles. diff --git a/configure b/configure index 8f91bb6e11..efb891456a 100755 --- a/configure +++ b/configure @@ -646,7 +646,6 @@ libc_cv_with_fp PYTHON PYTHON_PROG AUTOCONF -NM BISON AWK SED @@ -654,6 +653,9 @@ MAKEINFO MSGFMT MAKE LD +NM +OBJDUMP +READELF GPROF OBJCOPY AR @@ -683,8 +685,6 @@ sysheaders ac_ct_CXX CXXFLAGS CXX -OBJDUMP -READELF CPP cross_compiling BUILD_CC @@ -2870,190 +2870,6 @@ if test -z "$CPP"; then CPP="$CC -E" fi -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}readelf", so it can be a program name with args. -set dummy ${ac_tool_prefix}readelf; 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_READELF+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$READELF"; then - ac_cv_prog_READELF="$READELF" # 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_READELF="${ac_tool_prefix}readelf" - $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 -READELF=$ac_cv_prog_READELF -if test -n "$READELF"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 -$as_echo "$READELF" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_READELF"; then - ac_ct_READELF=$READELF - # Extract the first word of "readelf", so it can be a program name with args. -set dummy readelf; 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_READELF+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_READELF"; then - ac_cv_prog_ac_ct_READELF="$ac_ct_READELF" # 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_READELF="readelf" - $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_READELF=$ac_cv_prog_ac_ct_READELF -if test -n "$ac_ct_READELF"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_READELF" >&5 -$as_echo "$ac_ct_READELF" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_READELF" = x; then - READELF="false" - 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 - READELF=$ac_ct_READELF - fi -else - READELF="$ac_cv_prog_READELF" -fi - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; 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_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # 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_OBJDUMP="${ac_tool_prefix}objdump" - $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 -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 -$as_echo "$OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; 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_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # 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_OBJDUMP="objdump" - $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_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 -$as_echo "$ac_ct_OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="false" - 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 - OBJDUMP=$ac_ct_OBJDUMP - fi -else - OBJDUMP="$ac_cv_prog_OBJDUMP" -fi - # We need the C++ compiler only for testing. ac_ext=cpp @@ -4160,6 +3976,18 @@ if test -z "$GPROF"; then GPROF=`$CC -print-prog-name=gprof` fi +if test -z "$READELF"; then + READELF=`$CC -print-prog-name=readelf` +fi + +if test -z "$OBJDUMP"; then + OBJDUMP=`$CC -print-prog-name=objdump` +fi + +if test -z "$NM"; then + NM=`$CC -print-prog-name=nm` +fi + # Accept binutils 2.25 or newer. @@ -4781,99 +4609,6 @@ if test $libc_cv_compiler_ok != yes; then : critic_missing="$critic_missing compiler" fi -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args. -set dummy ${ac_tool_prefix}nm; 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_NM+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NM"; then - ac_cv_prog_NM="$NM" # 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_NM="${ac_tool_prefix}nm" - $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 -NM=$ac_cv_prog_NM -if test -n "$NM"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 -$as_echo "$NM" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_NM"; then - ac_ct_NM=$NM - # Extract the first word of "nm", so it can be a program name with args. -set dummy nm; 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_NM+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_NM"; then - ac_cv_prog_ac_ct_NM="$ac_ct_NM" # 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_NM="nm" - $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_NM=$ac_cv_prog_ac_ct_NM -if test -n "$ac_ct_NM"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 -$as_echo "$ac_ct_NM" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_NM" = x; then - NM="false" - 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 - NM=$ac_ct_NM - fi -else - NM="$ac_cv_prog_NM" -fi - - if test "x$maintainer" = "xyes"; then for ac_prog in autoconf do diff --git a/configure.ac b/configure.ac index 022b8f68bc..011844a3d4 100644 --- a/configure.ac +++ b/configure.ac @@ -51,8 +51,6 @@ if test $host != $build; then fi AC_SUBST(cross_compiling) AC_PROG_CPP -AC_CHECK_TOOL(READELF, readelf, false) -AC_CHECK_TOOL(OBJDUMP, objdump, false) # We need the C++ compiler only for testing. AC_PROG_CXX @@ -632,8 +630,6 @@ AC_PREPROC_IFELSE([AC_LANG_PROGRAM([[]], [[ AS_IF([test $libc_cv_compiler_ok != yes], [critic_missing="$critic_missing compiler"]) -AC_CHECK_TOOL(NM, nm, false) - if test "x$maintainer" = "xyes"; then AC_CHECK_PROGS(AUTOCONF, autoconf, no) case "x$AUTOCONF" in diff --git a/scripts/build-many-glibcs.py b/scripts/build-many-glibcs.py index 887ef7b6d5..a49f50b792 100755 --- a/scripts/build-many-glibcs.py +++ b/scripts/build-many-glibcs.py @@ -1521,10 +1521,7 @@ class GlibcPolicyDefault(object): '--host=%s' % glibc.triplet, 'CC=%s' % glibc.tool_name('gcc'), 'CXX=%s' % glibc.tool_name('g++'), - 'NM=%s' % glibc.tool_name('nm'), - 'OBJDUMP=%s' % glibc.tool_name('objdump'), 'RANLIB=%s' % glibc.tool_name('ranlib'), - 'READELF=%s' % glibc.tool_name('readelf'), 'STRIP=%s' % glibc.tool_name('strip'), ] if glibc.os == 'gnu': From patchwork Tue Dec 6 16:02:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adhemerval Zanella Netto X-Patchwork-Id: 61593 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 104163871F9F for ; Tue, 6 Dec 2022 16:04:54 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 104163871F9F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1670342694; bh=/UwI2hGO+DSI8Syg5GLHZ1efOvhs7klisFa4xT4rMrw=; h=To:Subject:Date:In-Reply-To:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=UkBGvCp1MozSs+CkH4xcgP4hjFc6/Sqma+JtVjoDmj5QwZKa4wb1ThewW9zupNFtg uBo/PvkZPE6VEfuLffZYm1YRg3bdMTLyAi4myfgae2kWhZvG+lNdo545qXYvns6wGh G6bKj6vdJJN/G9Uk/XZLsDtLs+dfBTfwA0QaZ9vI= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-oa1-x35.google.com (mail-oa1-x35.google.com [IPv6:2001:4860:4864:20::35]) by sourceware.org (Postfix) with ESMTPS id 8F20E383FD69 for ; Tue, 6 Dec 2022 16:03:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 8F20E383FD69 Received: by mail-oa1-x35.google.com with SMTP id 586e51a60fabf-144bd860fdbso4784226fac.0 for ; Tue, 06 Dec 2022 08:03:10 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/UwI2hGO+DSI8Syg5GLHZ1efOvhs7klisFa4xT4rMrw=; b=Pp3aq3a53XLd9QUzX3PChlPqwCRZPGrniv5aQ/jeQnLwAxeoBBnpTq4lRcwd/reJRk FiqsphtGDW1LgYtzTxssa99IY/zdLfQGdfgW8WdPx6QfqUeUZz/oc3j5EmNHVZpAvDun dfMFpUAracRubXiECyGOFeqzjtj35/QHAKta+4lpoKyV5vXixAi+DOa/i9sTPIv1U+xK jbXzLEPiSxpZwpeK4Eggc1ooNSp4mrk+NJaqyOuCGUvZK/QCLhWdTRWzJnOsQK5FToea Yb+5jjkOIBO9LDtuhyP+uSGCuIjRDOYa9BY+iKOMFqPVifJm+XxQQwIkzfEK/ZplLn+q AxQA== X-Gm-Message-State: ANoB5pn9evI5tj9lO9pFa9EW4KV6cceQJHq0c4rQVchL7ebNCfgdRfSD CbB81MTvlv9dynBGS8FLG6iWsV+CwWEZAMz4KKo= X-Google-Smtp-Source: AA0mqf4DBKqo++WIEOMrnfxNhLmB9Z2OaIxi4nK/iingE6Q20JNWSTe5jW7JtQdQvIIp64Lc7GNmQQ== X-Received: by 2002:a05:6870:518:b0:13b:709c:f479 with SMTP id j24-20020a056870051800b0013b709cf479mr36445865oao.2.1670342589418; Tue, 06 Dec 2022 08:03:09 -0800 (PST) Received: from mandiga.. ([2804:1b3:a7c2:6793:6a7:7646:7f3f:684e]) by smtp.gmail.com with ESMTPSA id k6-20020a544686000000b00349a06c581fsm8495008oic.3.2022.12.06.08.03.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Dec 2022 08:03:09 -0800 (PST) To: libc-alpha@sourceware.org, Vineet Gupta , =?utf-8?q?Ludovic_Court=C3=A8s?= , Carlos O'Donell Subject: [PATCH v2 3/3] scripts/build-many-glibcs.py: Remove unused RANLIB and STRIP option Date: Tue, 6 Dec 2022 13:02:43 -0300 Message-Id: <20221206160243.455627-4-adhemerval.zanella@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221206160243.455627-1-adhemerval.zanella@linaro.org> References: <20221206160243.455627-1-adhemerval.zanella@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-12.5 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Adhemerval Zanella via Libc-alpha From: Adhemerval Zanella Netto Reply-To: Adhemerval Zanella Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" --- scripts/build-many-glibcs.py | 2 -- 1 file changed, 2 deletions(-) Reviewed-by: Carlos O'Donell diff --git a/scripts/build-many-glibcs.py b/scripts/build-many-glibcs.py index a49f50b792..32f336366c 100755 --- a/scripts/build-many-glibcs.py +++ b/scripts/build-many-glibcs.py @@ -1521,8 +1521,6 @@ class GlibcPolicyDefault(object): '--host=%s' % glibc.triplet, 'CC=%s' % glibc.tool_name('gcc'), 'CXX=%s' % glibc.tool_name('g++'), - 'RANLIB=%s' % glibc.tool_name('ranlib'), - 'STRIP=%s' % glibc.tool_name('strip'), ] if glibc.os == 'gnu': self.configure_args.append('MIG=%s' % glibc.tool_name('mig'))