From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2662 invoked by alias); 16 Dec 2011 14:30:05 -0000 Received: (qmail 2582 invoked by uid 22791); 16 Dec 2011 14:30:01 -0000 X-SWARE-Spam-Status: No, hits=-1.1 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,TW_DB,TW_SM X-Spam-Check-By: sourceware.org Received: from mail-iy0-f169.google.com (HELO mail-iy0-f169.google.com) (209.85.210.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 16 Dec 2011 14:29:48 +0000 Received: by iacb35 with SMTP id b35so3258147iac.0 for ; Fri, 16 Dec 2011 06:29:48 -0800 (PST) Received: by 10.50.15.134 with SMTP id x6mr8820301igc.51.1324045787919; Fri, 16 Dec 2011 06:29:47 -0800 (PST) Received: from [192.168.1.102] ([218.109.115.47]) by mx.google.com with ESMTPS id b20sm33279965ibj.7.2011.12.16.06.29.45 (version=SSLv3 cipher=OTHER); Fri, 16 Dec 2011 06:29:47 -0800 (PST) Message-ID: <4EEB56CE.6050908@gmail.com> Date: Fri, 16 Dec 2011 14:30:00 -0000 From: asmwarrior User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:8.0) Gecko/20111105 Thunderbird/8.0 MIME-Version: 1.0 To: gdb@sourceware.org Subject: Re: [windows mingw]gdb cvs head build error in windows-nat.c References: <4EEB53E4.3070207@gmail.com> In-Reply-To: <4EEB53E4.3070207@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2011-12/txt/msg00029.txt.bz2 On 2011-12-16 22:21, asmwarrior wrote: > I build under MSYS+mingw > Here is the build error: > > > gcc -O0 -g -D__USE_MINGW_ACCESS -I. -I../../gdb/gdb -I../../gdb/gdb/common -I. > ../../gdb/gdb/config -DLOCALEDIR="\"/mingw/share/locale\"" -DHAVE_CONFIG_H -I../. > ../gdb/gdb/../include/opcode -I../../gdb/gdb/../opcodes/.. -I../../gdb/gdb/../rea > dline/.. -I../bfd -I../../gdb/gdb/../bfd -I../../gdb/gdb/../include -I../libdecn > umber -I../../gdb/gdb/../libdecnumber -I../../gdb/gdb/gnulib -Ignulib -IE:/c > ode/python272/include -IE:/code/python272/include -Wall -Wdeclaration-after-stat > ement -Wpointer-arith -Wformat-nonliteral -Wno-pointer-sign -Wno-unused -Wunused > -value -Wunused-function -Wno-switch -Wno-char-subscripts -Wno-format -Werror -c > -o dcache.o -MT dcache.o -MMD -MP -MF .deps/dcache.Tpo ../../gdb/gdb/dcache.c > .../../gdb/gdb/windows-nat.c: In function 'init_windows_ops': > .../../gdb/gdb/windows-nat.c:2517:26: error: 'cygwin_get_dr' undeclared (first us > e in this function) > .../../gdb/gdb/windows-nat.c:2517:26: note: each undeclared identifier is reporte > d only once for each function it appears in > .../../gdb/gdb/windows-nat.c:2519:29: error: 'cygwin_get_dr7' undeclared (first u > se in this function) > cc1.exe: warnings being treated as errors > .../../gdb/gdb/windows-nat.c: At top level: > .../../gdb/gdb/windows-nat.c:2654:1: error: 'cygwin_get_dr' defined but not used > .../../gdb/gdb/windows-nat.c:2673:1: error: 'cygwin_get_dr7' defined but not used > > > So, I think it was caused by this: > > 2011-12-14 Pedro Alves > The change in windows-nat.c > > gdb/windows-nat.c | 21 ++++++++++++++++++++- > 1 files changed, 20 insertions(+), 1 deletions(-) > > diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c > index 20e3c67..97ed237 100644 > --- a/gdb/windows-nat.c > +++ b/gdb/windows-nat.c > @@ -2494,8 +2494,9 @@ init_windows_ops (void) > > i386_dr_low.set_control = cygwin_set_dr7; > i386_dr_low.set_addr = cygwin_set_dr; > - i386_dr_low.reset_addr = NULL; > + i386_dr_low.get_addr = cygwin_get_dr; > i386_dr_low.get_status = cygwin_get_dr6; > + i386_dr_low.get_control = cygwin_get_dr7; > > > any ideas? > > asmwarrior > ollydbg from codeblocks' forum > > This patch should fix the build error. gdb/windows-nat.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c index b4529bd..99157b8 100644 --- a/gdb/windows-nat.c +++ b/gdb/windows-nat.c @@ -172,8 +172,10 @@ static int windows_thread_alive (struct target_ops *, ptid_t); static void windows_kill_inferior (struct target_ops *); static void cygwin_set_dr (int i, CORE_ADDR addr); +static CORE_ADDR cygwin_get_dr (int i); static void cygwin_set_dr7 (unsigned long val); static unsigned long cygwin_get_dr6 (void); +static unsigned long cygwin_get_dr7 (void); static enum target_signal last_sig = TARGET_SIGNAL_0; /* Set if a signal was received from the debugged process. */ asmwarrior ollydbg from codeblocks' forum