gdb 6.0: build on Solaris 5.8 fails for infrun.c

Andrew Cagney cagney@gnu.org
Thu Oct 23 16:16:00 GMT 2003


> I'm trying to build gdb 6.0 uner Solaris 5.8, but compilation of infrun.c
> fails.
> 
> gcc -c -g -O2  -I/usr/include/v9  -I. -I/vol/freeware/source/gdb-6.0/gdb -I/vol/freeware/source/gdb-6.0/gdb/config -DLOCALEDIR="\"/vol/freeware/SunOS-5.8/gdb/6.0/share/locale\"" -DHAVE_CONFIG_H -I/vol/freeware/source/gdb-6.0/gdb/../include/opcode -I/vol/freeware/source/gdb-6.0/gdb/../readline/.. -I../bfd -I/vol/freeware/source/gdb-6.0/gdb/../bfd  -I/vol/freeware/source/gdb-6.0/gdb/../include -I../intl -I/vol/freeware/source/gdb-6.0/gdb/../intl  -DMI_OUT=1 -Wimplicit -Wreturn-type -Wcomment -Wtrigraphs -Wformat -Wparentheses -Wpointer-arith -Wuninitialized  /vol/freeware/source/gdb-6.0/gdb/infrun.c 
> /usr/ccs/bin/as: "/var/tmp/ccM45XPr.s", line 3929: error: constant value must
> be between -4096 and 4095
> 
> The .s file around line 3929 contains:
> .LLM446:
> 	call	registers_changed, 0
> 	add	%o7, (.LL108-.-4), %o7
> .stabn 68,0,1658,.LLM447-handle_inferior_event
> 
> (line 3929 is the line with the "add" instruction)
> 
> uname -a for my workstation gives:
> SunOS sfsws4 5.8 Generic_108528-23 sun4u sparc SUNW,Sun-Fire-280R
> 
> 
> Does anybody have an idea what the problem is?

Looks very like a GCC bug.  I see you're using Sun's assembler 
(usr/ccs/bin/as) which rules out GAS ;-). As a workaround, try

	CFLAGS='-g -O' ...path.to.configure/configure

or building the file with:

	make CFLAGS='-g -O' infrun.o

or updating your GCC.

Andrew




More information about the Gdb mailing list