From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from omta034.useast.a.cloudfilter.net (omta034.useast.a.cloudfilter.net [44.202.169.33]) by sourceware.org (Postfix) with ESMTPS id 1C5423858D39 for ; Tue, 3 Oct 2023 18:59:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1C5423858D39 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tromey.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tromey.com Received: from eig-obgw-5005a.ext.cloudfilter.net ([10.0.29.234]) by cmsmtp with ESMTP id nkTgqSJfvIBlVnkbUq4LqZ; Tue, 03 Oct 2023 18:58:44 +0000 Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with ESMTPS id nkbtqBoNsusn6nkbuq7vz7; Tue, 03 Oct 2023 18:59:10 +0000 X-Authority-Analysis: v=2.4 cv=a9cjSGeF c=1 sm=1 tr=0 ts=651c647e a=ApxJNpeYhEAb1aAlGBBbmA==:117 a=ApxJNpeYhEAb1aAlGBBbmA==:17 a=OWjo9vPv0XrRhIrVQ50Ab3nP57M=:19 a=dLZJa+xiwSxG16/P+YVxDGlgEgI=:19 a=bhdUkHdE2iEA:10 a=Qbun_eYptAEA:10 a=CCpqsmhAAAAA:8 a=vZwB2tH4DnY7EsAsnIUA:9 a=ul9cdbp4aOFLsgKbc677:22 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:References :Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=A+f0HDSTK1zf/QUbMgM9c1tLnRirvV9xK9atmK/EAH8=; b=OSqRZe1i/Kyjw+ekWrbWfqD7O8 Cu/12+cs/dUalmJ4TaY9S7uPMBsbHfHiY+ynrbpeVCGHciQBFIGbHKfVPLB6UuyiNjYlgFcI0pd6d S61ZmAhqE51/esEMn1mX4BqEq; Received: from 71-211-130-31.hlrn.qwest.net ([71.211.130.31]:44728 helo=murgatroyd) by box5379.bluehost.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1qnkbt-002UKc-1S; Tue, 03 Oct 2023 12:59:09 -0600 From: Tom Tromey To: Thiago Jung Bauermann via Gdb-patches Cc: Thiago Jung Bauermann Subject: Re: [PATCH] gdb/configure.ac: Add option --with-additional-debug-dirs References: <20230606233118.146167-1-thiago.bauermann@linaro.org> X-Attribution: Tom Date: Tue, 03 Oct 2023 12:59:08 -0600 In-Reply-To: <20230606233118.146167-1-thiago.bauermann@linaro.org> (Thiago Jung Bauermann via Gdb-patches's message of "Wed, 7 Jun 2023 01:31:18 +0200") Message-ID: <87a5szzg5f.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box5379.bluehost.com X-AntiAbuse: Original Domain - sourceware.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 71.211.130.31 X-Source-L: No X-Exim-ID: 1qnkbt-002UKc-1S X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 71-211-130-31.hlrn.qwest.net (murgatroyd) [71.211.130.31]:44728 X-Source-Auth: tom+tromey.com X-Email-Count: 1 X-Org: HG=bhshared;ORG=bluehost; X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-CMAE-Envelope: MS4xfCzPL/k3PJ1zbE6Uzw5MuTNZDfyChiAl7iWE4hIRfKZrlQcm+6PeMXJiwWPFmXFXzjIRqVIv80UH7knbkE6q+g6quZLXjuXwAa0FOeXiPxCZJIRKQkfI psf5FSoS+UvjnJrZRIWNeXk3tZS1IuWzvc3YWQDIbQ4/cXN4WvlEMCljfAnwQtePjX50g/T/5VB0cQo1s0w7cNgw58ssdzNDC/s= X-Spam-Status: No, score=-3025.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,GIT_PATCH_0,JMQ_SPF_NEUTRAL,RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2,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 List-Id: >>>>> "Thiago" == Thiago Jung Bauermann via Gdb-patches writes: Thiago> If you want to install GDB in a custom prefix, have it look for debug info Thiago> in that prefix but also in the distro's default location (typically, Thiago> /usr/lib/debug) and run the GDB testsuite before doing "make install", you Thiago> have a bit of a problem: ... Thiago> I thought it was simpler to add a new option to specify a list of Thiago> additional directories that will be appended to the debug-file-directory Thiago> setting. I don't think this was ever reviewed? Sorry about that. Thiago> diff --git a/gdb/configure.ac b/gdb/configure.ac Thiago> index fb43cd10d6c8..715001384177 100644 Thiago> --- a/gdb/configure.ac Thiago> +++ b/gdb/configure.ac Thiago> @@ -119,6 +119,12 @@ GDB_AC_WITH_DIR(DEBUGDIR, separate-debug-dir, Thiago> [look for global separate debug info in this path @<:@LIBDIR/debug@:>@], Thiago> [${libdir}/debug]) Thiago> +AC_ARG_WITH(additional-debug-dirs, Thiago> +AS_HELP_STRING([--with-additional-debug-dirs=PATHs], Thiago> + [list of additional directories to search for separate debug info]), Thiago> +[AC_DEFINE_UNQUOTED(ADDITIONAL_DEBUG_DIRS, "${withval}", Thiago> + Additional directories to look for separate debug info.)]) It's a nit but I think it's normal to indent the body of AC_ARG_WITH. Thiago> +#ifdef ADDITIONAL_DEBUG_DIRS Thiago> + debug_file_directory = debug_file_directory + DIRNAME_SEPARATOR Thiago> + + ADDITIONAL_DEBUG_DIRS; Thiago> +#endif gdb style is to put parens around the RHS of the assignment in this case, and indent the 2nd line to line up. I think a new configure switch could use at least a NEWS entry. I didn't see --with-separate-debug-dir in the docs, so there's maybe not a natural place for this there. Tom