problems patching gdb for rtems
Matthew J Fletcher
mfletcher at serck-controls.co.uk
Thu Oct 19 09:13:29 UTC 2000
>> I have tried to patch both gdb4.18 and gdb5.02 with the rtems diffs
>> (snapshots/gdb-xx-diff), but both fail on configure.in and makefile.in,
>> the code files seem to have been patched just fine.
>>
>> I have used fresh virgin install (from the rtems site), of gdb both
>> times, is this a known problem, or as anyone else had this problem.. ?
>
> Could you provide some information on your host? Are there .rej
> "reject"
> files? What message is printed when you apply the patch?
The patch says xx HUNK failed at line xxx (there are loads)
/* ------------------------------ */
/* this is from configure.in.rej */
/* ------------------------------ */
***************
*** 52,63 ****
sim_hw_src=`echo $hardware | sed -e 's/,/.c hw_/g' -e 's/^/hw_/' -e
s'/$/.c/'`
sim_hw_obj=`echo $sim_hw_src | sed -e 's/\.c/.o/g'`
if test x"$silent" != x"yes" && test x"$hardware" != x""; then
- echo "Setting hardware to $sim_hw_src, $sim_hw_obj"
-
fi],[hardware="cpu,memory,nvram,iobus,htab,disk,trace,register,vm,init,core,pal,com,eeprom,opic,glue,phb,ide"
sim_hw_src=`echo $hardware | sed -e 's/,/.c hw_/g' -e 's/^/hw_/' -e
s'/$/.c/'`
sim_hw_obj=`echo $sim_hw_src | sed -e 's/\.c/.o/g'`
if test x"$silent" != x"yes"; then
- echo "Setting hardware to $sim_hw_src, $sim_hw_obj"
fi])dnl
--- 147,158 ----
sim_hw_src=`echo $hardware | sed -e 's/,/.c hw_/g' -e 's/^/hw_/' -e
s'/$/.c/'`
sim_hw_obj=`echo $sim_hw_src | sed -e 's/\.c/.o/g'`
if test x"$silent" != x"yes" && test x"$hardware" != x""; then
+ echo "Setting hardware to $sim_hw_src, $sim_hw_obj, $sim_sysv_ipc_hw"
+
fi],[hardware="cpu,memory,nvram,iobus,htab,disk,trace,register,vm,init,core,pal,com,eeprom,opic,glue,phb,ide${sim_sysv_ipc_hw}"
sim_hw_src=`echo $hardware | sed -e 's/,/.c hw_/g' -e 's/^/hw_/' -e
s'/$/.c/'`
sim_hw_obj=`echo $sim_hw_src | sed -e 's/\.c/.o/g'`
if test x"$silent" != x"yes"; then
+ echo "Setting hardware to $sim_hw_src, $sim_hw_obj, $sim_sysv_ipc_hw"
fi])dnl
***************
*** 531,536 ****
AC_EXEEXT
AC_SUBST(CC_FOR_BUILD)
AC_SUBST(CFLAGS)
AC_SUBST(HDEFINES)
AR=${AR-ar}
--- 626,632 ----
AC_EXEEXT
AC_SUBST(CC_FOR_BUILD)
+ AC_SUBST(sim_hwflags)
AC_SUBST(CFLAGS)
AC_SUBST(HDEFINES)
AR=${AR-ar}
/* -------------------------- */
/* and now remdeb_f.rej */
/* -------------------------- */
+
+ % /*
+ % * NOTE: this corresponds to the 35 registers defined in KnThreadCtx
+ % * defined for sparc.
+ % */
+ struct xdr_regs
+ {
+ unsigned int tabreg[35];
+ };
+
+ #ifdef RPC_HDR
+
+ %/* now define register macros to apply to xdr_reg struct */
+ %
+ %#define PSR 0
+ %#define PC1 1
+ %#define nPC 2
+ %#define Y 3
+
+ %#define G1 4
+ %#define G2 5
+ %#define G3 6
+ %#define G4 7
+ %#define G5 8
+ %#define G6 9
+ %#define G7 10
+
+ %#define O0 11
+ %#define O1 12
+ %#define O2 13
+ %#define O3 14
+ %#define O4 15
+ %#define O5 16
+ %#define O6 17
+ %#define O7 18
+
+ %#define L0 19
+ %#define L1 20
+ %#define L2 21
+ %#define L3 22
+ %#define L4 23
+ %#define L5 24
+ %#define L6 25
+ %#define L7 26
+
+ %#define I0 27
+ %#define I1 28
+ %#define I2 29
+ %#define I3 30
+ %#define I4 31
+ %#define I5 32
+ %#define I6 33
+ %#define I7 34
+ %
+ %#define REG_PC tabreg[PC1] /* PC (pc) register offset */
+ %#define REG_NPC tabreg[nPC] /* PC (npc) register offset */
+ %#define REG_SP tabreg[O6] /* SP (o6) register offset */
+ %#define REG_FP tabreg[I6] /* FP (i6) register offset */
+
+ %#define ST_DEBUGGER_TRAP 0x12
+ %#define FIRST_DEBUG_TRAP ST_DEBUGGER_TRAP
+ %#define LAST_DEBUG_TRAP ST_DEBUGGER_TRAP
+ %#define SET_BREAK(l) (0x91d02000|ST_DEBUGGER_TRAP)
+ %#define ORG_BREAK(c, p) (p)
+ %#define IS_BREAK(l) ( (((l) & 0xff) >= FIRST_DEBUG_TRAP) && (((l)
& 0xff) <= LAST_DEBUG_TRAP))
+ %#define IS_STEP(regs) (0)
+ %#define BREAK_ADJ 0 /* must subtract one from address
after bp */
+ %#define BREAK_SIZE 4 /* Breakpoint occupies four byte */
+ #endif
+
/* -------------------------- */
/* makefile.in.rej */
/* -------------------------- */
***************
*** 91,96 ****
TERMIO_CFLAGS = @sim_termio@
WARNING_CFLAGS = @sim_warnings@
DEVZERO_CFLAGS = @sim_devzero@
CONFIG_CFLAGS = $(BSWAP_CFLAGS) \
$(ENDIAN_CFLAGS) \
$(REGPARM_CFLAGS) \
--- 91,97 ----
TERMIO_CFLAGS = @sim_termio@
WARNING_CFLAGS = @sim_warnings@
DEVZERO_CFLAGS = @sim_devzero@
+ HARDWARE_CFLAGS = @sim_hwflags@
CONFIG_CFLAGS = $(BSWAP_CFLAGS) \
$(ENDIAN_CFLAGS) \
$(REGPARM_CFLAGS) \
***************
*** 111,117 ****
$(MODEL_CFLAGS) \
$(STDIO_CFLAGS) \
$(TERMIO_CFLAGS) \
- $(DEVZERO_CFLAGS)
STD_CFLAGS
= $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(WARNING_CFLAGS)
$(SIM_CFLAGS) $(HDEFINES) $(TDEFINES) $(INCLUDES)
NOWARN_CFLAGS
= $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(SIM_CFLAGS) $(HDEFINES)
$(TDEFINES) $(INCLUDES)
--- 112,119 ----
$(MODEL_CFLAGS) \
$(STDIO_CFLAGS) \
$(TERMIO_CFLAGS) \
+ $(DEVZERO_CFLAGS) \
+ $(HARDWARE_CFLAGS)
STD_CFLAGS
= $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(WARNING_CFLAGS)
$(SIM_CFLAGS) $(HDEFINES) $(TDEFINES) $(INCLUDES)
NOWARN_CFLAGS
= $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(SIM_CFLAGS) $(HDEFINES)
$(TDEFINES) $(INCLUDES)
***************
*** 599,604 ****
hw_pal.o: hw_pal.c $(DEVICE_TABLE_H)
hw_phb.o: hw_phb.c $(DEVICE_TABLE_H) hw_phb.h
hw_register.o: hw_register.c $(DEVICE_TABLE_H)
hw_trace.o: hw_trace.c $(DEVICE_TABLE_H)
hw_vm.o: hw_vm.c $(DEVICE_TABLE_H)
# ignore this line, it stops make from getting confused
--- 601,608 ----
hw_pal.o: hw_pal.c $(DEVICE_TABLE_H)
hw_phb.o: hw_phb.c $(DEVICE_TABLE_H) hw_phb.h
hw_register.o: hw_register.c $(DEVICE_TABLE_H)
+ hw_sem.o: hw_sem.c $(DEVICE_TABLE_H)
+ hw_shm.o: hw_shm.c $(DEVICE_TABLE_H)
hw_trace.o: hw_trace.c $(DEVICE_TABLE_H)
hw_vm.o: hw_vm.c $(DEVICE_TABLE_H)
# ignore this line, it stops make from getting confused
**********************************************************************
Serck Controls Ltd, Rowley Drive, Coventry, CV3 4FH, UK
Tel: 44 (0) 24 7630 5050 Fax: 44 (0) 24 7630 2437
Web: www.serck-controls.co.uk Admin: post at serck-controls.co.uk
**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the above. Any views or opinions presented are solely those of the
author and do not necessarily represent those of Serck Controls Ltd.
Please note that Serck Controls Ltd is able to, and reserves the right
to, monitor e-mail communications passing through its network.
This email has been checked for viruses. Serck Controls Ltd shall not
be responsible for damage caused by any undetected virus.
**********************************************************************
More information about the users
mailing list