From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16315 invoked by alias); 6 Mar 2012 11:52:53 -0000 Received: (qmail 16303 invoked by uid 22791); 6 Mar 2012 11:52:52 -0000 X-SWARE-Spam-Status: No, hits=-6.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 06 Mar 2012 11:52:40 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q26BqGqA006375 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 6 Mar 2012 06:52:16 -0500 Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id q26BqFNV004974; Tue, 6 Mar 2012 06:52:15 -0500 Message-ID: <4F55FA6F.2090203@redhat.com> Date: Tue, 06 Mar 2012 11:52:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.1) Gecko/20120216 Thunderbird/10.0.1 MIME-Version: 1.0 To: Andreas Arnez CC: Joel Brobecker , gdb-patches@sourceware.org Subject: Re: [PATCH] s390-nat.c: Fix missing prototypes References: <8762ejrlqv.fsf@vnet.ibm.com> <20120305190642.GJ2853@adacore.com> <87ipiigiup.fsf@linux.vnet.ibm.com> <4F55E636.8040501@redhat.com> <8762eigdxh.fsf@linux.vnet.ibm.com> In-Reply-To: <8762eigdxh.fsf@linux.vnet.ibm.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit 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 X-SW-Source: 2012-03/txt/msg00187.txt.bz2 On 03/06/2012 11:35 AM, Andreas Arnez wrote: >> I think we should consider putting >> >> #ifdef HAVE_SYS_PROCFS_H >> #include >> #endif >> >> in gregset.h itself. > > Right, that sounds OK. Then Joel's commit for s390-nat.c could be left > as is. Builds fine on x64-64 Fedora, even when I move the gregset.h include in amd64-linux-nat.c to the top, right below defs.h, like: --- c/gdb/amd64-linux-nat.c +++ w/gdb/amd64-linux-nat.c @@ -19,6 +19,7 @@ along with this program. If not, see . */ #include "defs.h" +#include "gregset.h" #include "inferior.h" #include "gdbcore.h" #include "regcache.h" @@ -46,9 +47,6 @@ #include #include "gdb_proc_service.h" -/* Prototypes for supply_gregset etc. */ -#include "gregset.h" - #include "amd64-tdep.h" #include "i386-linux-tdep.h" #include "amd64-nat.h" (which fails to build without the patch below) Comments, anyone? 2012-03-06 Pedro Alves * gregset.h [HAVE_SYS_PROCFS_H]: Include . --- gdb/gregset.h | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/gdb/gregset.h b/gdb/gregset.h index 4f34788..d73b5b8 100644 --- a/gdb/gregset.h +++ b/gdb/gregset.h @@ -19,6 +19,10 @@ #ifndef GREGSET_H #define GREGSET_H +#ifdef HAVE_SYS_PROCFS_H +#include +#endif + #ifndef GDB_GREGSET_T #define GDB_GREGSET_T gregset_t #endif