|
From: | Claude Devarenne |
Subject: | problem building gdbserver for gdb-5.0 |
Date: | Tue, 10 Apr 2001 15:04:36 -0700 (PDT) |
Hi,
I am having problems building gdbserver for gdb-5.0. I am on a Solaris 2.7 sparc machine: SunOS server03 5.7 Generic_106541-12 sun4u sparc SUNW,Ultra-80.
Here is the output of my build attempt (I did run the fixincludes script from gcc):
/home/cdevaren/gdb5/gdb-5.0/gdb/gdbserver>./configure
loading cache ./config.cache
checking host system type... sparc-sun-solaris2.7
checking target system type... sparc-sun-solaris2.7
checking build system type... sparc-sun-solaris2.7
checking for a BSD compatible install... ./../../install-sh -c
creating ./config.status
creating Makefile
linking ./../config/sparc/xm-sun4sol2.h to xm.h
linking ./../config/sparc/tm-sun4sol2.h to tm.h
linking ./../config/sparc/nm-sun4sol2.h to nm.h
/home/cdevaren/gdb5/gdb-5.0/gdb/gdbserver>make
rm -f gdbserver
gcc -o gdbserver utils.o server.o remote-utils.o \
-lsocket -lnsl
Undefined first referenced
symbol in file
initialize_low server.o
myresume server.o
registers server.o
store_inferior_registers server.o
mythread_alive server.o
fetch_inferior_registers server.o
write_inferior_memory server.o
create_inferior server.o
mywait server.o
read_inferior_memory server.o
kill_inferior server.o
ld: fatal: Symbol referencing errors. No output written to gdbserver
collect2: ld returned 1 exit status
make: *** [gdbserver] Error 1
I looked at the make file and I am puzzled by it:
...
SFILES = $(srcdir)/low-hppabsd.c $(srcdir)/low-linux.c $(srcdir)/low-lynx.c \
$(srcdir)/low-nbsd.c $(srcdir)/low-sim.c $(srcdir)/low-sparc.c \
$(srcdir)/low-sun3.c $(srcdir)/utils.c $(srcdir)/server.c \
$(srcdir)/remote-utils.c
DEPFILES = $(GDBSERVER_DEPFILES)
SOURCES = $(SFILES) $(ALLDEPFILES)
TAGFILES = $(SOURCES) ${HFILES} ${ALLPARAM} ${POSSLIBS}
OBS = utils.o $(GDBSERVER_DEPFILES) server.o remote-utils.o
...
GDBSERVER_DEPFILES is used but never defined and none of the SFILES ever get compiled which is where all the symbols the linker complains about can be found.
I tried to compile low-sparc.c but the include files in /usr/ucbinclude seem to cause errors:
/home/cdevaren/gdb5/gdb-5.0/gdb/gdbserver>gcc -c -g -I. -I.. -I. -I./.. -I./../config -I./../../include -I../../bfd -I/usr/ucbinclude -DGDBSERVER low-sparc.c
In file included from low-sparc.c:30:
/usr/ucbinclude/sys/param.h:131: warning: `NULL' redefined
/tools/sw/gnu/gcc/2.95.2/sun5/lib/gcc-lib/sparc-sun-solaris2.7/2.95.2/include/stddef.h:328: warning: this is the location of the previous definition
In file included from ../../include/obstack.h:145,
from ../symtab.h:27,
from ../value.h:240,
from ../breakpoint.h:25,
from ../inferior.h:26,
from low-sparc.c:24:
/usr/include/string.h:43: warning: conflicting types for built-in function `memcpy'
/usr/include/string.h:51: warning: conflicting types for built-in function `memcmp'
/usr/include/string.h:69: warning: conflicting types for built-in function `memset'
In file included from low-sparc.c:32:
/usr/include/sys/user.h:262: `MAXSIG' undeclared here (not in a function)
low-sparc.c: In function `mywait':
low-sparc.c:120: warning: passing arg 1 of `wait' from incompatible pointer type
low-sparc.c:124: invalid operands to binary &
low-sparc.c:126: invalid operands to binary >>
low-sparc.c:128: invalid operands to binary >>
low-sparc.c:130: invalid operands to binary &
low-sparc.c:130: invalid operands to binary >>
low-sparc.c:132: invalid operands to binary &
low-sparc.c:134: invalid operands to binary &
low-sparc.c:140: invalid operands to binary >>
low-sparc.c: In function `fetch_inferior_registers':
low-sparc.c:167: storage size of `inferior_fp_registers' isn't known
low-sparc.c: In function `store_inferior_registers':
low-sparc.c:214: storage size of `inferior_fp_registers' isn't known
Any help would be greatly appreciated. Thank you in advance.
Claude
[Prev in Thread] | Current Thread | [Next in Thread] |