From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) by sourceware.org (Postfix) with ESMTP id 4540C393F832 for ; Wed, 23 Jun 2021 22:27:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 4540C393F832 Received: from vapier (localhost [127.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id A93AC335CD7; Wed, 23 Jun 2021 22:27:01 +0000 (UTC) Date: Wed, 23 Jun 2021 18:26:55 -0400 From: Mike Frysinger To: Pedro Alves Cc: Simon Marchi , gdb-patches@sourceware.org Subject: Re: [PATCH] gdb/gdbserver: switch to AC_CONFIG_MACRO_DIRS Message-ID: Mail-Followup-To: Pedro Alves , Simon Marchi , gdb-patches@sourceware.org References: <20210615054416.1232-1-vapier@gentoo.org> <33565c24-0468-1ded-63db-d7ef402d5329@polymtl.ca> <5ece9821-45a3-14f6-33a1-3506b6efe72f@polymtl.ca> <4f273dab-3803-9143-7b16-4cb873834dd0@palves.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <4f273dab-3803-9143-7b16-4cb873834dd0@palves.net> X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00, JMQ_SPF_NEUTRAL, KAM_DMARC_STATUS, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=no 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: Wed, 23 Jun 2021 22:27:07 -0000 On 23 Jun 2021 10:38, Pedro Alves wrote: > On 2021-06-18 5:38 a.m., Mike Frysinger via Gdb-patches wrote: > > > > how about at the top of acinclude.m4: > > dnl NB: When possible, try to avoid explicit includes of ../config/ files. > > dnl They're normally found by aclocal automatically and recorded in aclocal.m4. > > dnl However, some are kept here explicitly to silence harmless warnings from > > dnl aclocal when it finds AM_xxx macros via local search paths instead of > > dnl system search paths. > > -mike > > That seems good to me, but I think better would be to put all such include lines > together and put the comment right on top of that section. Like: > > dnl NB: When possible, we try to avoid explicit includes of ../config/ files. > dnl They're normally found by aclocal automatically and recorded in aclocal.m4. > dnl However, the following are kept here explicitly to silence harmless warnings > dnl from aclocal when it finds AM_xxx macros via local search paths instead of > dnl system search paths. > m4_include([../config/foo.m4]) > m4_include([../config/bar.m4]) > > > I've had my share of "comments at the top" that I've missed in the past... how about: --- a/gdb/acinclude.m4 +++ b/gdb/acinclude.m4 @@ -9,6 +9,18 @@ dnl They're normally found by aclocal automatically and recorded in aclocal.m4. dnl However, some are kept here explicitly to silence harmless warnings from dnl aclocal when it finds AM_xxx macros via local search paths instead of dnl system search paths. +dnl +dnl For AM_LC_MESSAGES +m4_include([../config/lcmessage.m4]) +dnl For AM_LANGINFO_CODESET. +m4_include([../config/codeset.m4]) +dnl We need to explicitly include these before iconv.m4 to avoid warnings. +m4_include([../config/lib-ld.m4]) +m4_include([../config/lib-prefix.m4]) +m4_include([../config/lib-link.m4]) +m4_include([../config/iconv.m4]) +dnl For zlib itself. +m4_include([../config/zlib.m4]) m4_include(acx_configure_dir.m4) @@ -27,20 +39,6 @@ m4_include(../gdbsupport/selftest.m4) dnl gdb/configure.in uses BFD_NEED_DECLARATION, so get its definition. m4_include(../bfd/bfd.m4) -dnl For AM_LC_MESSAGES -m4_include([../config/lcmessage.m4]) - -dnl For AM_LANGINFO_CODESET. -m4_include([../config/codeset.m4]) - -dnl We need to explicitly include these before iconv.m4 to avoid warnings. -m4_include([../config/lib-ld.m4]) -m4_include([../config/lib-prefix.m4]) -m4_include([../config/lib-link.m4]) -m4_include([../config/iconv.m4]) - -m4_include([../config/zlib.m4]) - m4_include([../gdbsupport/common.m4]) dnl For libiberty_INIT. --- a/gdbserver/acinclude.m4 +++ b/gdbserver/acinclude.m4 @@ -3,6 +3,10 @@ dnl They're normally found by aclocal automatically and recorded in aclocal.m4. dnl However, some are kept here explicitly to silence harmless warnings from dnl aclocal when it finds AM_xxx macros via local search paths instead of dnl system search paths. +dnl +dnl codeset.m4 is needed for common.m4, but not for +dnl anything else in gdbserver. +m4_include(../config/codeset.m4) dnl gdb/gdbserver/configure.in uses BFD_HAVE_SYS_PROCFS_TYPE. m4_include(../bfd/bfd.m4) @@ -10,9 +14,6 @@ m4_include(../bfd/bfd.m4) dnl This gets AM_GDB_WARNINGS. m4_include(../gdbsupport/warning.m4) -dnl codeset.m4 is needed for common.m4, but not for -dnl anything else in gdbserver. -m4_include(../config/codeset.m4) m4_include(../gdbsupport/common.m4) dnl For libiberty_INIT.