2003-10-28 04:12:11 +03:00
|
|
|
# $NetBSD: README,v 1.4 2003/10/28 01:12:11 uwe Exp $
|
2003-10-26 20:18:04 +03:00
|
|
|
|
|
|
|
This note describes how to add support for gdb53 to a platform.
|
|
|
|
|
|
|
|
To make gdb work on your platform of choice you need to populate the files in
|
|
|
|
/usr/src/gnu/usr.bin/gdb53/arch/<platform>
|
|
|
|
|
|
|
|
1. Build gdb using the standard configure mechanism in the distribution
|
|
|
|
directory /usr/src/gnu/dist/gdb.
|
|
|
|
|
2003-10-28 04:12:11 +03:00
|
|
|
Alternatively, configure and build in a scratch directory, so that
|
|
|
|
you can avoid doing the last distclean step of this instructions.
|
|
|
|
|
2003-10-26 20:18:04 +03:00
|
|
|
2. Copy generated files (the ?m.h are not present on some platforms)
|
|
|
|
cp gdb/{tm.h,nm.h,xm.h,config.h} ...arch/<platform>
|
|
|
|
cp gdb/init.c ...arch/<platform>/gdb-init.c
|
|
|
|
cp arch/i386/version.c arch/<platform>
|
|
|
|
cp arch/i386/defs.mk arch/<platform>
|
|
|
|
|
|
|
|
3. Add coredump and netbsd thread support to init.c (we should fix the autoconf
|
2003-10-27 03:57:04 +03:00
|
|
|
stuff to do this automatically). At the declaration section on init.c add:
|
2003-10-26 20:49:24 +03:00
|
|
|
|
|
|
|
extern initialize_file_ftype _initialize_nbsd_thread;
|
|
|
|
#ifdef USE_TUI
|
|
|
|
extern initialize_file_ftype _initialize_tui;
|
|
|
|
extern initialize_file_ftype _initialize_tuiLayout;
|
|
|
|
extern initialize_file_ftype _initialize_tuiRegs;
|
|
|
|
extern initialize_file_ftype _initialize_tuiStack;
|
|
|
|
extern initialize_file_ftype _initialize_tuiWin;
|
|
|
|
extern initialize_file_ftype _initialize_tui_out;
|
|
|
|
#endif
|
|
|
|
extern initialize_file_ftype _initialize_corelow;
|
|
|
|
|
|
|
|
and at the bottom add:
|
2003-10-26 20:18:04 +03:00
|
|
|
|
|
|
|
_initialize_nbsd_thread ();
|
|
|
|
#ifdef USE_TUI
|
|
|
|
_initialize_tui ();
|
|
|
|
_initialize_tuiLayout ();
|
|
|
|
_initialize_tuiRegs ();
|
|
|
|
_initialize_tuiStack ();
|
|
|
|
_initialize_tuiWin ();
|
|
|
|
_initialize_tui_out ();
|
|
|
|
#endif
|
|
|
|
_initialize_corelow ();
|
|
|
|
|
2003-10-28 04:12:11 +03:00
|
|
|
4. Fix defs.mk to have the right files. The readline, libiberty,
|
2003-10-26 20:18:04 +03:00
|
|
|
ones should be ok; for the others, go to the build directory
|
|
|
|
|
|
|
|
ls -1 *.o | sed -e 's/$/ \\/'
|
|
|
|
|
|
|
|
and then incorporate the resulting sections into defs.mk. This should be
|
|
|
|
done for bfd, gdb, opcodes.
|
|
|
|
|
2003-10-28 04:12:11 +03:00
|
|
|
5. Fix defs.mk to have the right bfd flags in G_BFD_CPPFLAGS. Copy
|
|
|
|
them from `tdefaults' variable in generated bfd/Makefile.
|
|
|
|
|
|
|
|
6. Make distclean in the distribution directory and cvs update [distclean
|
2003-10-26 20:18:04 +03:00
|
|
|
removes some generated files we committed because they don't change across
|
|
|
|
platforms]
|