From patchwork Mon Jan 24 10:47:19 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Martin_Li=C5=A1ka?= X-Patchwork-Id: 50385 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 E0663385782C for ; Mon, 24 Jan 2022 10:47:38 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by sourceware.org (Postfix) with ESMTPS id 6E0B23858001 for ; Mon, 24 Jan 2022 10:47:21 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 6E0B23858001 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.cz Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 582032197D for ; Mon, 24 Jan 2022 10:47:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1643021240; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GD1UrLLyUDYI6mQTmbx2cqJZCsDCvj9o+1pcXeHfL/M=; b=uLiS0dtwkq2mD3Ie//STGHAxffO6sRxnDQPPMGyk8FH5oqwma8IcN2hpOFUG26eMJ3hDi3 rtE116sI4U6IjGGdKw7bL7YoryuG4TgOWGe5THyRKp9Lo80hPFK8+P2QwP+zzbHBxrD3n3 5armttCTRy7I0ftJTKv1CKbfYN2228Y= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1643021240; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GD1UrLLyUDYI6mQTmbx2cqJZCsDCvj9o+1pcXeHfL/M=; b=ijNTjlyGgS4KX0jD/AzWcA7dM/4jga3GoHf6kASAsB6mCjDHhcEx5OuEvjdXoSqeQkty5c wyiDnkCSF9rSmYBg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 4468213B1C for ; Mon, 24 Jan 2022 10:47:20 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id 6HvGDriD7mECdQAAMHmgww (envelope-from ) for ; Mon, 24 Jan 2022 10:47:20 +0000 Message-ID: Date: Mon, 24 Jan 2022 11:47:19 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.5.0 From: =?utf-8?q?Martin_Li=C5=A1ka?= Subject: [PATCH] acinclude.m4: Remove duplicite AC_DEFUN. To: gcc-patches@gcc.gnu.org Content-Language: en-US X-Spam-Status: No, score=-11.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Sender: "Gcc-patches" The function LIBAT_CHECK_LINKER_FEATURES is defined twice in the file. Ready to be installed? Thanks, Martin libatomic/ChangeLog: * acinclude.m4: Remove duplicate LIBAT_CHECK_LINKER_FEATURES. * configure: Regenerate. --- libatomic/acinclude.m4 | 102 ----------------------------------------- libatomic/configure | 6 +-- 2 files changed, 3 insertions(+), 105 deletions(-) diff --git a/libatomic/acinclude.m4 b/libatomic/acinclude.m4 index 20814bf6cdc..3703a435003 100644 --- a/libatomic/acinclude.m4 +++ b/libatomic/acinclude.m4 @@ -389,108 +389,6 @@ AC_DEFUN([LIBAT_CHECK_LINKER_FEATURES], [ ]) -dnl -dnl If GNU ld is in use, check to see if tricky linker opts can be used. If -dnl the native linker is in use, all variables will be defined to something -dnl safe (like an empty string). -dnl -dnl Defines: -dnl SECTION_LDFLAGS='-Wl,--gc-sections' if possible -dnl OPT_LDFLAGS='-Wl,-O1' if possible -dnl LD (as a side effect of testing) -dnl Sets: -dnl with_gnu_ld -dnl libat_ld_is_gold (possibly) -dnl libat_gnu_ld_version (possibly) -dnl -dnl The last will be a single integer, e.g., version 1.23.45.0.67.89 will -dnl set libat_gnu_ld_version to 12345. Zeros cause problems. -dnl -AC_DEFUN([LIBAT_CHECK_LINKER_FEATURES], [ - # If we're not using GNU ld, then there's no point in even trying these - # tests. Check for that first. We should have already tested for gld - # by now (in libtool), but require it now just to be safe... - test -z "$SECTION_LDFLAGS" && SECTION_LDFLAGS='' - test -z "$OPT_LDFLAGS" && OPT_LDFLAGS='' - AC_REQUIRE([AC_PROG_LD]) - AC_REQUIRE([AC_PROG_AWK]) - - # The name set by libtool depends on the version of libtool. Shame on us - # for depending on an impl detail, but c'est la vie. Older versions used - # ac_cv_prog_gnu_ld, but now it's lt_cv_prog_gnu_ld, and is copied back on - # top of with_gnu_ld (which is also set by --with-gnu-ld, so that actually - # makes sense). We'll test with_gnu_ld everywhere else, so if that isn't - # set (hence we're using an older libtool), then set it. - if test x${with_gnu_ld+set} != xset; then - if test x${ac_cv_prog_gnu_ld+set} != xset; then - # We got through "ac_require(ac_prog_ld)" and still not set? Huh? - with_gnu_ld=no - else - with_gnu_ld=$ac_cv_prog_gnu_ld - fi - fi - - # Start by getting the version number. I think the libtool test already - # does some of this, but throws away the result. - libat_ld_is_gold=no - if $LD --version 2>/dev/null | grep 'GNU gold'> /dev/null 2>&1; then - libat_ld_is_gold=yes - fi - changequote(,) - ldver=`$LD --version 2>/dev/null | - sed -e 's/[. ][0-9]\{8\}$//;s/.* \([^ ]\{1,\}\)$/\1/; q'` - changequote([,]) - libat_gnu_ld_version=`echo $ldver | \ - $AWK -F. '{ if (NF<3) [$]3=0; print ([$]1*100+[$]2)*100+[$]3 }'` - - # Set --gc-sections. - if test "$with_gnu_ld" = "notbroken"; then - # GNU ld it is! Joy and bunny rabbits! - - # All these tests are for C++; save the language and the compiler flags. - # Need to do this so that g++ won't try to link in libstdc++ - ac_test_CFLAGS="${CFLAGS+set}" - ac_save_CFLAGS="$CFLAGS" - CFLAGS='-x c++ -Wl,--gc-sections' - - # Check for -Wl,--gc-sections - # XXX This test is broken at the moment, as symbols required for linking - # are now in libsupc++ (not built yet). In addition, this test has - # cored on solaris in the past. In addition, --gc-sections doesn't - # really work at the moment (keeps on discarding used sections, first - # .eh_frame and now some of the glibc sections for iconv). - # Bzzzzt. Thanks for playing, maybe next time. - AC_MSG_CHECKING([for ld that supports -Wl,--gc-sections]) - AC_TRY_RUN([ - int main(void) - { - try { throw 1; } - catch (...) { }; - return 0; - } - ], [ac_sectionLDflags=yes],[ac_sectionLDflags=no], [ac_sectionLDflags=yes]) - if test "$ac_test_CFLAGS" = set; then - CFLAGS="$ac_save_CFLAGS" - else - # this is the suspicious part - CFLAGS='' - fi - if test "$ac_sectionLDflags" = "yes"; then - SECTION_LDFLAGS="-Wl,--gc-sections $SECTION_LDFLAGS" - fi - AC_MSG_RESULT($ac_sectionLDflags) - fi - - # Set linker optimization flags. - if test x"$with_gnu_ld" = x"yes"; then - OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS" - fi - - AC_SUBST(SECTION_LDFLAGS) - AC_SUBST(OPT_LDFLAGS) -]) - - dnl dnl Add version tags to symbols in shared library (or not), additionally dnl marking other symbols as private/local (or not). diff --git a/libatomic/configure b/libatomic/configure index 5867e69ac14..fb920c9a687 100755 --- a/libatomic/configure +++ b/libatomic/configure @@ -11380,7 +11380,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11393 "configure" +#line 11383 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -11486,7 +11486,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11499 "configure" +#line 11489 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -15588,7 +15588,7 @@ case "$host" in case "$enable_cet" in auto) # Check if target supports multi-byte NOPs - # and if assembler supports CET insn. + # and if compiler and assembler support CET insn. cet_save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -fcf-protection" cat confdefs.h - <<_ACEOF >conftest.$ac_ext