From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28427 invoked by alias); 25 Jul 2014 10:14:47 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 28380 invoked by uid 89); 25 Jul 2014 10:14:43 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Fri, 25 Jul 2014 10:14:42 +0000 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s6PAEdhO007130 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 25 Jul 2014 06:14:39 -0400 Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.ams2.redhat.com [10.39.146.11]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s6PAEbfX031237; Fri, 25 Jul 2014 06:14:38 -0400 Message-ID: <53D22E0C.8050603@redhat.com> Date: Fri, 25 Jul 2014 10:19:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Doug Evans CC: Gary Benson , gdb-patches@sourceware.org, Tom Tromey Subject: Re: [PATCH 1/3 v4] Introduce common/errors.h References: <1406206287-6817-1-git-send-email-gbenson@redhat.com> <1406206287-6817-2-git-send-email-gbenson@redhat.com> <53D1053E.6030902@redhat.com> <21457.18385.59886.323894@ruffy.mtv.corp.google.com> In-Reply-To: <21457.18385.59886.323894@ruffy.mtv.corp.google.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-SW-Source: 2014-07/txt/msg00662.txt.bz2 On 07/24/2014 06:52 PM, Doug Evans wrote: > Pedro Alves writes: > > > + You should have received a copy of the GNU General Public License > > > + along with this program. If not, see . */ > > > + > > > +#include "config.h" > > > > Sorry for the push back, but it's wrong to only include "config.h". > > We need to include gnulib's config.h everywhere too. I think > > the best is to add a central common header that handles that > > detail first. > > OTOH, > just including "config.h" is a real common thing to do across all packages. > I can imagine this coming up again and again. > > IWBN if hacking on gdb didn't require special cases to standard > programming paradigms wherever possible. > Can we arrange for config.h to include gnulib's config.h? > Or, another thought would be to have configure generate gdb-config.h > (or some such) and then have src/gdb/config.h include both (and similarly > for gdbserver - haven't looked at the details though). I fail to see how changing any of that would substantially improve things. GDB has had defs.h for a long while, and people didn't seem to be confused by that -- it's quite common to have a project-specific global header to include. If we have something like that in common, then even if we have only a single config.h, we'd naturally include that from the common common/ header anyway instead of in addition to including the common/ file everywhere, also including config.h directly everywhere too. Thanks, Pedro Alves