From: Alberto Luaces <aluaces@udc.es>
To: gdb-patches@sources.redhat.com
Subject: Undefined uintptr_t with mingw
Date: Tue, 21 Dec 2010 16:35:00 -0000 [thread overview]
Message-ID: <87k4j3krv3.fsf@eps142.cdf.udc.es> (raw)
Hello,
while building gdb with the mingw cross-compiler from Debian
(4.4.4-0.1+b1) I run across this error:
i586-mingw32msvc-gcc -c -Wall -g -O2 -D__USE_MINGW_ACCESS -I. -I../../../gdb-7.2/gdb/gdbserver -I../../../gdb-7.2/gdb/gdbserver/../common -I../../../gdb-7.2/gdb/gdbserver/../regformats -I../../../gdb-7.2/gdb/gdbserver/../../include ../../../gdb-7.2/gdb/gdbserver/win32-low.c
../../../gdb-7.2/gdb/gdbserver/win32-low.c: In function âchild_add_threadâ:
../../../gdb-7.2/gdb/gdbserver/win32-low.c:192: error: âuintptr_tâ undeclared (first use in this function)
../../../gdb-7.2/gdb/gdbserver/win32-low.c:192: error: (Each undeclared identifier is reported only once
../../../gdb-7.2/gdb/gdbserver/win32-low.c:192: error: for each function it appears in.)
../../../gdb-7.2/gdb/gdbserver/win32-low.c:192: error: expected â;â before âtlbâ
../../../gdb-7.2/gdb/gdbserver/win32-low.c: In function âchild_xfer_memoryâ:
../../../gdb-7.2/gdb/gdbserver/win32-low.c:283: error: âuintptr_tâ undeclared (first use in this function)
../../../gdb-7.2/gdb/gdbserver/win32-low.c:283: error: expected â;â before âaddrâ
../../../gdb-7.2/gdb/gdbserver/win32-low.c:287: error: âaddrâ undeclared (first use in this function)
../../../gdb-7.2/gdb/gdbserver/win32-low.c: In function âhandle_load_dllâ:
../../../gdb-7.2/gdb/gdbserver/win32-low.c:1208: error: âuintptr_tâ undeclared (first use in this function)
../../../gdb-7.2/gdb/gdbserver/win32-low.c:1208: error: expected â;â before âeventâ
../../../gdb-7.2/gdb/gdbserver/win32-low.c: In function âhandle_unload_dllâ:
../../../gdb-7.2/gdb/gdbserver/win32-low.c:1216: error: âuintptr_tâ undeclared (first use in this function)
../../../gdb-7.2/gdb/gdbserver/win32-low.c:1216: error: expected â,â or â;â before âcurrent_eventâ
../../../gdb-7.2/gdb/gdbserver/win32-low.c: In function âhandle_exceptionâ:
../../../gdb-7.2/gdb/gdbserver/win32-low.c:1317: error: âuintptr_tâ undeclared (first use in this function)
../../../gdb-7.2/gdb/gdbserver/win32-low.c:1317: error: expected â)â before âcurrent_eventâ
../../../gdb-7.2/gdb/gdbserver/win32-low.c:1317: error: too few arguments to function âphex_nzâ
make[4]: *** [win32-low.o] Error 1
Since uintptr_t is defined in <stdint.h>, I succesfully built gdb with
this change:
diff -ur gdb-7.2orig/gdb/gdbserver/win32-low.c gdb-7.2/gdb/gdbserver/win32-low.c
--- gdb-7.2orig/gdb/gdbserver/win32-low.c 2010-12-21 16:27:10.000000000 +0100
+++ gdb-7.2/gdb/gdbserver/win32-low.c 2010-12-21 17:21:56.000000000 +0100
@@ -33,6 +33,7 @@
#include <sys/param.h>
#include <malloc.h>
#include <process.h>
+#include <stdint.h>
#ifndef USE_WIN32API
#include <sys/cygwin.h>
Does it sound right to apply to GDB?
Thanks,
--
Alberto
next reply other threads:[~2010-12-21 16:35 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-21 16:35 Alberto Luaces [this message]
2010-12-22 4:00 ` Joel Brobecker
2010-12-22 12:29 ` Pedro Alves
2010-12-22 13:11 ` Pedro Alves
2010-12-22 14:32 ` Joel Brobecker
2010-12-22 13:12 ` Joel Brobecker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87k4j3krv3.fsf@eps142.cdf.udc.es \
--to=aluaces@udc.es \
--cc=gdb-patches@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox