From: Mark Kettenis <kettenis@elgar.kettenis.dyndns.org>
To: Michal Ludvig <mludvig@suse.cz>
Cc: Andreas Jaeger <aj@SuSE.de>, Andrew Cagney <ac131313@cygnus.com>,
gdb-patches@sources.redhat.com
Subject: Re: [patch] Add x86-64 target to MAINTAINERS, broken
Date: Mon, 04 Mar 2002 04:35:00 -0000 [thread overview]
Message-ID: <86ofi45x3w.fsf@elgar.kettenis.dyndns.org> (raw)
In-Reply-To: Michal Ludvig's message of "Mon, 04 Mar 2002 12:13:26 +0100"
Michal Ludvig <mludvig@suse.cz> writes:
> Andreas Jaeger wrote:
> > Andrew Cagney <ac131313@cygnus.com> writes:
> >>In file included from /home/scratch/GDB/src/gdb/x86-64-tdep.c:30:
> >>/home/scratch/GDB/src/gdb/x86-64-tdep.h:27: sys/reg.h: No such file or
> >>directory
> >>gmake[1]: *** [x86-64-tdep.o] Error 1
> >>gmake[1]: Leaving directory
> >>`/home/scratch/GDB/X-x86_64-unknown-linux-gnu/gdb'
> >>gmake: *** [all-gdb] Error 2
> >>
> >>when trying to build an x86_64-linux-gnu target.
> >>
> >
> > I fear you applied a broken patch by Michal. Has this been fixed?
> > Michal, can you test whether the CVS version works now?
>
> File sys/reg.h comes from x86-64 glibc sources and yes, using my
> crosscompiler it compiles without problems for --host=x86-64 and
> --target=x86-64...
x86-64-tdep.h should definitely *not* include <sys/reg.h>, or any
target header for that matter. It should be possible to build a GDB
that can debug x86-64 stuff on any host. Currently that's not
possible since there are problems with dwarfcfi.c, which doesn't
compile on a 32-bit host right now, which is a pity since it means I
cannot really help you with fixing the x86-64 bits.
Anyway, you should really try to test your build with --target=x86-64
on a totally different platform, e.g. *BSD on a sparc.
Anyway, I think the attached patch solves the <sys/reg.h> problem. It
shouldn't break your x86-64 target, but I'm not entirely sure. Can
you test it for me?
Mark
Index: ChangeLog
from Mark Kettenis <kettenis@gnu.org>
* x86-64-tdep.h: Do not include <sys/reg.h>.
(x86_64_regmap): Remove.
Index: x86-64-tdep.h
===================================================================
RCS file: /cvs/src/src/gdb/x86-64-tdep.h,v
retrieving revision 1.1
diff -u -p -r1.1 x86-64-tdep.h
--- x86-64-tdep.h 2001/09/21 12:19:15 1.1
+++ x86-64-tdep.h 2002/03/04 11:34:55
@@ -1,5 +1,5 @@
/* Target-dependent code for GDB, the GNU debugger.
- Copyright 2001
+ Copyright 2001, 2002
Free Software Foundation, Inc.
Contributed by Jiri Smid, SuSE Labs.
@@ -24,18 +24,6 @@
#define X86_64_TDEP_H
#include "i386-tdep.h"
-#include <sys/reg.h>
-
-/* Mapping between the general-purpose registers in `struct user'
- format and GDB's register array layout. */
-
-static int x86_64_regmap[] = {
- RAX, RDX, RCX, RBX,
- RSI, RDI, RBP, RSP,
- R8, R9, R10, R11,
- R12, R13, R14, R15,
- RIP, EFLAGS
-};
/* Number of all registers */
#define X86_64_NUM_REGS (51)
next prev parent reply other threads:[~2002-03-04 12:35 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-02-26 18:44 Andrew Cagney
2002-03-01 22:37 ` Andreas Jaeger
2002-03-04 3:13 ` Michal Ludvig
2002-03-04 4:35 ` Mark Kettenis [this message]
2002-03-04 4:41 ` Michal Ludvig
2002-03-04 8:40 ` Kevin Buettner
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=86ofi45x3w.fsf@elgar.kettenis.dyndns.org \
--to=kettenis@elgar.kettenis.dyndns.org \
--cc=ac131313@cygnus.com \
--cc=aj@SuSE.de \
--cc=gdb-patches@sources.redhat.com \
--cc=mludvig@suse.cz \
/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