Mirror of the gdb mailing list
 help / color / mirror / Atom feed
* Can't build m68k-linux gdb-5.2.1
@ 2002-08-19 15:54 Peter Barada
  2002-08-19 18:34 ` Andrew Cagney
  2002-08-19 18:53 ` Daniel Jacobowitz
  0 siblings, 2 replies; 9+ messages in thread
From: Peter Barada @ 2002-08-19 15:54 UTC (permalink / raw)
  To: gdb; +Cc: Peter.Barada


I'm trying to build a gdb for m68k-linux, configured as:

#!/bin/sh
# This file was generated automatically by configure.  Do not edit.
# This directory was configured as follows:
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/configure --host=i686-pc-linux-gnu --target=m68k-linux --prefix=/tmp/cross-tools --norecursion 
#  using "mt-frag"

And it won't link:

gcc -g -O2         -o gdb \
main.o libgdb.a cli-decode.o cli-script.o cli-cmds.o cli-setshow.o cli-utils.o mi-out.o mi-console.o mi-cmds.o mi-cmd-var.o mi-cmd-break.o mi-cmd-stack.o mi-cmd-disas.o mi-main.o mi-parse.o mi-getopt.o    ../bfd/libbfd.a ../readline/libreadline.a ../opcodes/libopcodes.a  ../libiberty/libiberty.a -lncurses     -lm  ../libiberty/libiberty.a \
-ldl -rdynamic
libgdb.a(infrun.o): In function `handle_inferior_event':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/infrun.c:2635: undefined reference to `m68k_linux_in_sigtramp'
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/infrun.c:2635: undefined reference to `m68k_linux_in_sigtramp'
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/infrun.c:2747: undefined reference to `m68k_linux_in_sigtramp'
libgdb.a(infrun.o): In function `check_sigtramp2':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/infrun.c:2955: undefined reference to `m68k_linux_in_sigtramp'
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/infrun.c:2955: undefined reference to `m68k_linux_in_sigtramp'
libgdb.a(stack.o): In function `frame_info':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/stack.c:848: undefined reference to `m68k_linux_frame_saved_pc'
libgdb.a(arch-utils.o): In function `init_frame_pc_default':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/arch-utils.c:370: undefined reference to `m68k_linux_frame_saved_pc'
libgdb.a(m68k-tdep.o): In function `isi_frame_num_args':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/m68k-tdep.c:107: undefined reference to `m68k_linux_frame_saved_pc'
libgdb.a(m68k-tdep.o): In function `delta68_frame_num_args':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/m68k-tdep.c:129: undefined reference to `m68k_linux_frame_saved_pc'
libgdb.a(m68k-tdep.o): In function `news_frame_num_args':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/m68k-tdep.c:151: undefined reference to `m68k_linux_frame_saved_pc'
libgdb.a(blockframe.o):/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/blockframe.c:48: more undefined references to `m68k_linux_frame_saved_pc' follow
libgdb.a(blockframe.o): In function `create_new_frame':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/blockframe.c:228: undefined reference to `m68k_linux_in_sigtramp'
libgdb.a(blockframe.o): In function `get_prev_frame':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/blockframe.c:465: undefined reference to `m68k_linux_in_sigtramp'
libgdb.a(blockframe.o): In function `generic_file_frame_chain_valid':
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/blockframe.c:1197: undefined reference to `m68k_linux_frame_saved_pc'
/home/pbarada/work/cvs-wavemark/cross-linux-tools/gdb-5.2.1/gdb/blockframe.c:1202: undefined reference to `m68k_linux_frame_saved_pc'
collect2: ld returned 1 exit status
make[1]: *** [gdb] Error 1

All the missing references are in gdb/m68klinux-nat.c, so I'd assume
this is supposed to be built, but isn't for --target=m68k-linux.  Does
anyone have any idea how I can get it to be built?

While I'm at it, how do I configure(and build) a gdbserver to run on
m68k-linux that's built on an x86-linux machine?

All help is appreciated.

-- 
Peter Barada                                   Peter.Barada@motorola.com
Wizard                                         781-852-2768 (direct)
WaveMark Solutions(wholly owned by Motorola)   781-270-0193 (fax)


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Can't build m68k-linux gdb-5.2.1
  2002-08-19 15:54 Can't build m68k-linux gdb-5.2.1 Peter Barada
@ 2002-08-19 18:34 ` Andrew Cagney
  2002-08-20  6:33   ` Peter Barada
  2002-08-19 18:53 ` Daniel Jacobowitz
  1 sibling, 1 reply; 9+ messages in thread
From: Andrew Cagney @ 2002-08-19 18:34 UTC (permalink / raw)
  To: Peter Barada; +Cc: gdb, Peter.Barada

> I'm trying to build a gdb for m68k-linux, configured as:

> All the missing references are in gdb/m68klinux-nat.c, so I'd assume
> this is supposed to be built, but isn't for --target=m68k-linux.  Does
> anyone have any idea how I can get it to be built?

Looks like for the moment you'll need to use m68k-elf.

The file m68klinux-nat.c should only contain stuff for a native build 
(eg ptrace interface).  The OS dependant, but not specific to native, is 
typically put in a file like m68k-linux-tdep.c.  cf m68knbsd-tdep.c. 
Patches against mainline welcome (do you have an FSF assignment?).

It should also be noted that GDB's mainline m68k was recently 
multi-arched so while the m68k-elf should be ok, I'm not sure what the 
state of m68k-linux-gnu is.

Would you be able to create abug report to track this:
http://sources.redhat.com/gdb/bugs/

> While I'm at it, how do I configure(and build) a gdbserver to run on
> m68k-linux that's built on an x86-linux machine?
> 
> All help is appreciated.

You'll need to config/compile it using a cross compiler 
(m68k-linux-gnu-gcc say).

enjoy,
Andrew



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Can't build m68k-linux gdb-5.2.1
  2002-08-19 15:54 Can't build m68k-linux gdb-5.2.1 Peter Barada
  2002-08-19 18:34 ` Andrew Cagney
@ 2002-08-19 18:53 ` Daniel Jacobowitz
  2002-08-20  6:40   ` Peter Barada
  1 sibling, 1 reply; 9+ messages in thread
From: Daniel Jacobowitz @ 2002-08-19 18:53 UTC (permalink / raw)
  To: Peter Barada; +Cc: gdb, Peter.Barada

On Mon, Aug 19, 2002 at 06:54:22PM -0400, Peter Barada wrote:
> While I'm at it, how do I configure(and build) a gdbserver to run on
> m68k-linux that's built on an x86-linux machine?

Just create a new object directory, and run $path/gdbserver/configure
--host=m68k-linux.  I think m68k support works, but it's not tested.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Can't build m68k-linux gdb-5.2.1
  2002-08-19 18:34 ` Andrew Cagney
@ 2002-08-20  6:33   ` Peter Barada
  2002-08-20  6:48     ` Andrew Cagney
  0 siblings, 1 reply; 9+ messages in thread
From: Peter Barada @ 2002-08-20  6:33 UTC (permalink / raw)
  To: ac131313; +Cc: Peter.Barada, gdb, Peter.Barada


>> I'm trying to build a gdb for m68k-linux, configured as:
>
>> All the missing references are in gdb/m68klinux-nat.c, so I'd assume
>> this is supposed to be built, but isn't for --target=m68k-linux.  Does
>> anyone have any idea how I can get it to be built?
>
>Looks like for the moment you'll need to use m68k-elf.
>
>The file m68klinux-nat.c should only contain stuff for a native build 
>(eg ptrace interface).  The OS dependant, but not specific to native, is 
>typically put in a file like m68k-linux-tdep.c.  cf m68knbsd-tdep.c. 
>Patches against mainline welcome (do you have an FSF assignment?).

1) I can use m68k-elf for now.
2) I'm still working the legal department to come up with an
   assignment to cover changes for gdb.

>Would you be able to create abug report to track this:
>http://sources.redhat.com/gdb/bugs/

Shold the bug be that m68k-linux should not build on a machine that is
*not* m68k-linux, or that it should build for m68k-linux only if
CC is a cross-compiler?

>> While I'm at it, how do I configure(and build) a gdbserver to run on
>> m68k-linux that's built on an x86-linux machine?
>> 
>> All help is appreciated.
>
>You'll need to config/compile it using a cross compiler 
>(m68k-linux-gnu-gcc say).

Do you have a configure command line to suggest?

-- 
Peter Barada                                   Peter.Barada@motorola.com
Wizard                                         781-852-2768 (direct)
WaveMark Solutions(wholly owned by Motorola)   781-270-0193 (fax)


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Can't build m68k-linux gdb-5.2.1
  2002-08-19 18:53 ` Daniel Jacobowitz
@ 2002-08-20  6:40   ` Peter Barada
  0 siblings, 0 replies; 9+ messages in thread
From: Peter Barada @ 2002-08-20  6:40 UTC (permalink / raw)
  To: drow; +Cc: Peter.Barada, gdb


>> While I'm at it, how do I configure(and build) a gdbserver to run on
>> m68k-linux that's built on an x86-linux machine?
>
>Just create a new object directory, and run $path/gdbserver/configure
>--host=m68k-linux.  I think m68k support works, but it's not tested.

Ah.  I found that:

$ export PATH=<path-to-m68k-linux-gcc>:$PATH
$ mkdir obj-gdbserver
$ cd obj-gdbserver
$ CC=m68k-linux-gcc ~/gdb-5.2.1/gdb/gdbserver/configure --host=m68k-linux 
$ make

builds a gdbserver that is at least:

$ file gdbserver
gdbserver: ELF 32-bit MSB executable, Motorola 68000, version 1, dynamically linked (uses shared libs), not stripped

-- 
Peter Barada                                   Peter.Barada@motorola.com
Wizard                                         781-852-2768 (direct)
WaveMark Solutions(wholly owned by Motorola)   781-270-0193 (fax)


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Can't build m68k-linux gdb-5.2.1
  2002-08-20  6:33   ` Peter Barada
@ 2002-08-20  6:48     ` Andrew Cagney
  2002-08-20  7:03       ` Daniel Jacobowitz
  2002-08-20  7:51       ` Peter Barada
  0 siblings, 2 replies; 9+ messages in thread
From: Andrew Cagney @ 2002-08-20  6:48 UTC (permalink / raw)
  To: Peter Barada; +Cc: Peter.Barada, gdb

>>> I'm trying to build a gdb for m68k-linux, configured as:
> 
>>
> 
>>> All the missing references are in gdb/m68klinux-nat.c, so I'd assume
>>> this is supposed to be built, but isn't for --target=m68k-linux.  Does
>>> anyone have any idea how I can get it to be built?
> 
>>
>>Looks like for the moment you'll need to use m68k-elf.
>>
>>The file m68klinux-nat.c should only contain stuff for a native build 
>>(eg ptrace interface).  The OS dependant, but not specific to native, is 
>>typically put in a file like m68k-linux-tdep.c.  cf m68knbsd-tdep.c. 
>>Patches against mainline welcome (do you have an FSF assignment?).
> 
> 
> 1) I can use m68k-elf for now.
> 2) I'm still working the legal department to come up with an
>    assignment to cover changes for gdb.
> 
> 
>>Would you be able to create abug report to track this:
>>http://sources.redhat.com/gdb/bugs/
> 
> 
> Shold the bug be that m68k-linux should not build on a machine that is
> *not* m68k-linux, or that it should build for m68k-linux only if
> CC is a cross-compiler?

A m68k-linux-gnu targeted GDB should build on any UNIX like host.

>>> While I'm at it, how do I configure(and build) a gdbserver to run on
>>> m68k-linux that's built on an x86-linux machine?
>>> 
>>> All help is appreciated.
> 
>>
>>You'll need to config/compile it using a cross compiler 
>>(m68k-linux-gnu-gcc say).
> 
> 
> Do you have a configure command line to suggest?

I think DanielJ covered this (However, we desperatly need doco 
explaining the procedure :-/).

Andrew



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Can't build m68k-linux gdb-5.2.1
  2002-08-20  6:48     ` Andrew Cagney
@ 2002-08-20  7:03       ` Daniel Jacobowitz
  2002-08-20  7:56         ` Andrew Cagney
  2002-08-20  7:51       ` Peter Barada
  1 sibling, 1 reply; 9+ messages in thread
From: Daniel Jacobowitz @ 2002-08-20  7:03 UTC (permalink / raw)
  To: Andrew Cagney; +Cc: Peter Barada, Peter.Barada, gdb

On Tue, Aug 20, 2002 at 09:48:13AM -0400, Andrew Cagney wrote:
> >>>I'm trying to build a gdb for m68k-linux, configured as:
> >
> >>
> >
> >>>All the missing references are in gdb/m68klinux-nat.c, so I'd assume
> >>>this is supposed to be built, but isn't for --target=m68k-linux.  Does
> >>>anyone have any idea how I can get it to be built?
> >
> >>
> >>Looks like for the moment you'll need to use m68k-elf.
> >>
> >>The file m68klinux-nat.c should only contain stuff for a native build 
> >>(eg ptrace interface).  The OS dependant, but not specific to native, is 
> >>typically put in a file like m68k-linux-tdep.c.  cf m68knbsd-tdep.c. 
> >>Patches against mainline welcome (do you have an FSF assignment?).
> >
> >
> >1) I can use m68k-elf for now.
> >2) I'm still working the legal department to come up with an
> >   assignment to cover changes for gdb.
> >
> >
> >>Would you be able to create abug report to track this:
> >>http://sources.redhat.com/gdb/bugs/
> >
> >
> >Shold the bug be that m68k-linux should not build on a machine that is
> >*not* m68k-linux, or that it should build for m68k-linux only if
> >CC is a cross-compiler?
> 
> A m68k-linux-gnu targeted GDB should build on any UNIX like host.
> 
> >>>While I'm at it, how do I configure(and build) a gdbserver to run on
> >>>m68k-linux that's built on an x86-linux machine?
> >>>
> >>>All help is appreciated.
> >
> >>
> >>You'll need to config/compile it using a cross compiler 
> >>(m68k-linux-gnu-gcc say).
> >
> >
> >Do you have a configure command line to suggest?
> 
> I think DanielJ covered this (However, we desperatly need doco 
> explaining the procedure :-/).

It's already there.  In gdbserver/README.  I have a promise to Eli
sitting in my inbox to add it to gdb/INSTALL, except that I just
noticed there _isn't_ a gdb/INSTALL.  So I don't know how much more
prominent I can make it.

No one reads the READMEs...

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Can't build m68k-linux gdb-5.2.1
  2002-08-20  6:48     ` Andrew Cagney
  2002-08-20  7:03       ` Daniel Jacobowitz
@ 2002-08-20  7:51       ` Peter Barada
  1 sibling, 0 replies; 9+ messages in thread
From: Peter Barada @ 2002-08-20  7:51 UTC (permalink / raw)
  To: ac131313; +Cc: Peter.Barada, Peter.Barada, gdb


>> Shold the bug be that m68k-linux should not build on a machine that is
>> *not* m68k-linux, or that it should build for m68k-linux only if
>> CC is a cross-compiler?
>
>A m68k-linux-gnu targeted GDB should build on any UNIX like host.

After thinking about it a bit more, you are correct.  gdb must be able
to be built on a host targeted for m68k-linux since I'd expect to run
m68k-linux-gdb on my x86 box, using a gdbserver running on the target.

>>Would you be able to create abug report to track this:
>>http://sources.redhat.com/gdb/bugs/

I've reported that gdb-5.2.1 can't build --traget=m68k-linux on my
i686-linux-gnu box dup to missing m68k_linux_in_sigtramp symbol.

-- 
Peter Barada                                   Peter.Barada@motorola.com
Wizard                                         781-852-2768 (direct)
WaveMark Solutions(wholly owned by Motorola)   781-270-0193 (fax)


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Can't build m68k-linux gdb-5.2.1
  2002-08-20  7:03       ` Daniel Jacobowitz
@ 2002-08-20  7:56         ` Andrew Cagney
  0 siblings, 0 replies; 9+ messages in thread
From: Andrew Cagney @ 2002-08-20  7:56 UTC (permalink / raw)
  To: Daniel Jacobowitz; +Cc: Peter Barada, Peter.Barada, gdb

> 
> It's already there.  In gdbserver/README.  I have a promise to Eli
> sitting in my inbox to add it to gdb/INSTALL, except that I just
> noticed there _isn't_ a gdb/INSTALL.  So I don't know how much more
> prominent I can make it.

Er, this is documentation :-)

Debugging remote programs:
http://sources.redhat.com/gdb/current/onlinedocs/gdb_18.html#SEC133

Installing GDB:
http://sources.redhat.com/gdb/current/onlinedocs/gdb_30.html#SEC620

> No one reads the READMEs...

GDB does have gdb/README so I'd assume that is where Eli ment.

Andrew



^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2002-08-20 14:56 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-08-19 15:54 Can't build m68k-linux gdb-5.2.1 Peter Barada
2002-08-19 18:34 ` Andrew Cagney
2002-08-20  6:33   ` Peter Barada
2002-08-20  6:48     ` Andrew Cagney
2002-08-20  7:03       ` Daniel Jacobowitz
2002-08-20  7:56         ` Andrew Cagney
2002-08-20  7:51       ` Peter Barada
2002-08-19 18:53 ` Daniel Jacobowitz
2002-08-20  6:40   ` Peter Barada

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox