From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from barracuda.ebox.ca (barracuda.ebox.ca [96.127.255.19]) by sourceware.org (Postfix) with ESMTPS id 5540A385E020 for ; Mon, 26 Oct 2020 02:17:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 5540A385E020 X-ASG-Debug-ID: 1603678637-0c856e1c44326ae0001-fS2M51 Received: from smtp.ebox.ca (smtp.ebox.ca [96.127.255.82]) by barracuda.ebox.ca with ESMTP id 3lSS7NEz9zaOXPg2 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 25 Oct 2020 22:17:17 -0400 (EDT) X-Barracuda-Envelope-From: simon.marchi@polymtl.ca X-Barracuda-RBL-Trusted-Forwarder: 96.127.255.82 Received: from simark.localdomain (173-246-6-90.qc.cable.ebox.net [173.246.6.90]) by smtp.ebox.ca (Postfix) with ESMTP id 79BF8441D64; Sun, 25 Oct 2020 22:17:17 -0400 (EDT) From: Simon Marchi X-Barracuda-RBL-IP: 173.246.6.90 X-Barracuda-Effective-Source-IP: 173-246-6-90.qc.cable.ebox.net[173.246.6.90] X-Barracuda-Apparent-Source-IP: 173.246.6.90 To: gdb-patches@sourceware.org Subject: [PATCH 12/13] gdb: replace AC_TRY_LINK in sanitize.m4 Date: Sun, 25 Oct 2020 22:17:08 -0400 X-ASG-Orig-Subj: [PATCH 12/13] gdb: replace AC_TRY_LINK in sanitize.m4 Message-Id: <20201026021709.3216266-3-simon.marchi@polymtl.ca> X-Mailer: git-send-email 2.29.0 In-Reply-To: <20201026021709.3216266-1-simon.marchi@polymtl.ca> References: <20201026021447.3174684-1-simon.marchi@polymtl.ca> <20201026021709.3216266-1-simon.marchi@polymtl.ca> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Barracuda-Connect: smtp.ebox.ca[96.127.255.82] X-Barracuda-Start-Time: 1603678637 X-Barracuda-Encrypted: DHE-RSA-AES256-SHA X-Barracuda-URL: https://96.127.255.19:443/cgi-mod/mark.cgi X-Virus-Scanned: by bsmtpd at ebox.ca X-Barracuda-Scan-Msg-Size: 1411 X-Barracuda-BRTS-Status: 1 X-Barracuda-Spam-Score: 0.50 X-Barracuda-Spam-Status: No, SCORE=0.50 using global scores of TAG_LEVEL=1000.0 QUARANTINE_LEVEL=1000.0 KILL_LEVEL=8.0 tests=BSF_RULE7568M X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.3.85498 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- 0.50 BSF_RULE7568M Custom Rule 7568M X-Spam-Status: No, score=-13.4 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_QUARANTINE, KAM_DMARC_STATUS, KAM_NUMSUBJECT, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_SOFTFAIL, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Oct 2020 02:17:19 -0000 ... with AC_LINK_IFELSE + AC_LANG_PROGRAM. All changes in the generated configure file are insignificant whitespace changes. gdb/ChangeLog: * configure: Re-generate. * sanitize.m4: Replace AC_TRY_LINK with AC_LINK_IFELSE + AC_LANG_PROGRAM. Change-Id: I6fc4c39e10b28d2ade964e0d59a7f8ec0d3a272a --- gdb/configure | 1 + gdb/sanitize.m4 | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/gdb/configure b/gdb/configure index a08c8c57ae39..aa89158d06d3 100755 --- a/gdb/configure +++ b/gdb/configure @@ -16655,6 +16655,7 @@ if ac_fn_cxx_try_link "$LINENO"; then : enable_ubsan=yes else enable_ubsan=no + fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext diff --git a/gdb/sanitize.m4 b/gdb/sanitize.m4 index 78d00703ca70..87a4f3c9f212 100644 --- a/gdb/sanitize.m4 +++ b/gdb/sanitize.m4 @@ -34,7 +34,11 @@ if test "x$enable_ubsan" = xyes; then dnl A link check is required because it is possible to install gcc dnl without libubsan, leading to link failures when compiling with dnl -fsanitize=undefined. - AC_TRY_LINK([],[],enable_ubsan=yes,enable_ubsan=no) + AC_LINK_IFELSE( + [AC_LANG_PROGRAM([], [])], + [enable_ubsan=yes], + [enable_ubsan=no] + ) CXXFLAGS="$saved_CXXFLAGS" AC_MSG_RESULT($enable_ubsan) if test "x$enable_ubsan" = xyes; then -- 2.29.0