From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=3.0 tests=AWL,BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, NICE_REPLY_A,RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL, SPF_HELO_NONE,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 3C52C1F4B4 for ; Sun, 4 Oct 2020 23:40:54 +0000 (UTC) Received: from localhost ([::1]:40540 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kPDcb-0005fC-1j for normalperson@yhbt.net; Sun, 04 Oct 2020 19:40:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36634) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kPDcX-0005ew-8F for bug-gnulib@gnu.org; Sun, 04 Oct 2020 19:40:49 -0400 Received: from mo4-p00-ob.smtp.rzone.de ([81.169.146.219]:22004) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kPDcT-0002qZ-7i for bug-gnulib@gnu.org; Sun, 04 Oct 2020 19:40:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1601854840; s=strato-dkim-0002; d=clisp.org; h=References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=pvgF+D5JsJksoy4yklbx+hHhpOyTeESTDw5x6BJg3ps=; b=qpbCWKtTjjA6V412fdKrgUpKJGqdXLrPFHLuynGDPdd+CwWqp2EjsiODL7thyH0ceT nPZ1vpKfD/nyBt39h/XiKsqTZTTA4p2c6vWoCPummHtk1hJeAd3j1Xyt/x5KhTDOqOCe 0/i4QWnuwCovZLUUmuJZkFD98ddifaOkNWnGGVurXWpXJ4ZROGqfNq8uQRXreHXmh/6w GNLxdHwU+sYsH8ji1MDhjH06FjSVLaTgDGp2yI2XN2lyZLH4ooZTMExj38sQtVmuHlpB 7kWcHrd0MgzbezT7rKiwIsl24ouwHPmzFJH/J95VAbgxgz3AONI/8812adSV/K3uHP/f PwjA== X-RZG-AUTH: ":Ln4Re0+Ic/6oZXR1YgKryK8brlshOcZlIWs+iCP5vnk6shH+AHjwLuWOGaf0yJVW" X-RZG-CLASS-ID: mo00 Received: from bruno.haible.de by smtp.strato.de (RZmta 47.2.1 DYNA|AUTH) with ESMTPSA id R01daaw94Nee6gP (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (curve X9_62_prime256v1 with 256 ECDH bits, eq. 3072 bits RSA)) (Client did not present a certificate); Mon, 5 Oct 2020 01:40:40 +0200 (CEST) From: Bruno Haible To: Paul Eggert Subject: Re: AS_IF Date: Mon, 05 Oct 2020 01:40:39 +0200 Message-ID: <5379911.DDbiVqAGs0@omega> User-Agent: KMail/5.1.3 (Linux/4.4.0-189-generic; KDE/5.18.0; x86_64; ; ) In-Reply-To: References: <2073481.UNetMlQRTc@omega> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Received-SPF: none client-ip=81.169.146.219; envelope-from=bruno@clisp.org; helo=mo4-p00-ob.smtp.rzone.de X-detected-operating-system: by eggs.gnu.org: First seen = 2020/10/04 19:40:41 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: bug-gnulib@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Gnulib discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: bug-gnulib@gnu.org Errors-To: bug-gnulib-bounces+normalperson=yhbt.net@gnu.org Sender: "bug-gnulib" Hi Paul, > The third patch merely streamlines 'configure' when running on platforms like > Solaris that need not use libsigsegv. > > - if test "$gl_cv_lib_sigsegv" = yes \ > - && test "$gl_cv_sys_xsi_stack_overflow_heuristic" != yes; then > - AC_SUBST([LIBCSTACK], [$LIBSIGSEGV]) > - AC_SUBST([LTLIBCSTACK], [$LTLIBSIGSEGV]) > - fi > + AS_IF([test "$gl_cv_sys_xsi_stack_overflow_heuristic" != yes], > + [gl_LIBSIGSEGV > + AS_IF([test "$gl_cv_lib_sigsegv" = yes], > + [AC_SUBST([LIBCSTACK], [$LIBSIGSEGV]) > + AC_SUBST([LTLIBCSTACK], [$LTLIBSIGSEGV])])]) Any particular reason why AS_IF is used here? I typically don't use AS_IF because - I find a line of shell code more readable than a mix between m4 syntax and shell syntax, - it's yet another step in the learning curve, for someone who wants to understand how Autoconf macros work. The Autoconf documentation says AS_IF "ensures any required macros ... are expanded before the first test." AFAICS, this is relevant for code written directly into configure.ac. But inside an AC_DEFUN it is irrelevant, because required macros are hoisted before the body of the AC_DEFUN anyway. Bruno