On Oct 28, Bruce Momjian mentioned:
> > gcc -o psql -L../../interfaces/libpq command.o common.o help.o input.o
> > stringutils.o mainloop.o copy.o startup.o prompt.o variables.o large_obj.o
> > print.o describe.o -lpq -L/usr/sup/gnu/lib -lgen -lcrypt -lnsl -lsocket
> > -ldl -lm -lreadline -ltermcap -lcurses
> > ld: fatal: symbol `xmalloc' is multiply defined:
> > (file common.o and file /usr/sup/gnu/lib/libreadline.a(xmalloc.o));
> > ld: fatal: File processing errors. No output written to psql
> > make: *** [psql] Error 1
> >
> > This happens on a (particular) Solaris box but not on a (particular) Linux
> > box. Beats the heck out of me. ;(
>
> I can't find xmalloc in the source, and can't figure out how it could be
> _defined_ in common.o. Strange.
Oh, I defined it in that file, it's used in psql. Unfortunately, it seems
to be used internally in readline as well. In now figured out that this
causes problems only with static linking, but not dynamic. I'm no expert
on linking, does anyone have an idea or do I have to make up a different
name?
--
Peter Eisentraut Sernanders vaeg 10:115
peter_e@gmx.net 75262 Uppsala
http://yi.org/peter-e/ Sweden