Re: [greenstone-users] multiply defined symbols

From Virginia Knight
DateTue, 21 Dec 2004 10:05:27 -0000
Subject Re: [greenstone-users] multiply defined symbols
In-Reply-To (2112215-1102419466-192-168-0-2)
We found that the problem was ultimately with the linker. My path was set
up so that the linker which was used was Sun's in /usr/ucb rather than the
Solaris version in /usr/ccs/bin/ld. When the path to the linker was changed
the error disappeared.

Virginia Knight

>
> --On Tuesday, December 07, 2004 17:27 +1300 "John R. McPherson"
> <jrm21@cs.waikato.ac.nz> wrote:
>
>> On Mon, 2004-12-06 at 23:19, Virginia Knight wrote:
>>> I'm getting messages such as the following in
>>> /mnt/disk1/cmvhk/gsdl/src/recpt:
>>>
>>> ld: fatal: symbol `unicode_strnlen' is multiply defined:
>>> (file ../../packages/mg/lib/libmg.a(unitool.o) and file
>>> ../mgpp/lib/libmg.a(unitool.o));
>>>
>>> As before, I'm using gcc 3.4.2 on Solaris 2.5.
>>
>> In /mnt/disk1/cmvhk/gsdl/src/mgpp/Makefile and Makefile.in,
>> try modifying line 59 so where it has:
>>#####
>> .SUFFIXES: .cpp .o
>> .cpp.o:
>> $(CXXCOMPILE) -D__cplusplus $<
>>#####
>> try replacing $(COMPILE) with $(CXXCOMPILE).
>>
>> (The problem is that there is a function with the same name
>> in the mg code written in C, and the mgpp code written in C++).
>>
>> John McPherson
>>
----------------------
Virginia Knight, Institute for Learning and Research Technology
Tel: +44 (0)117 928 7154 Fax: +44 (0)117 928 7112
University of Bristol, 8-10 Berkeley Square, Bristol BS8 1HH
Virginia.Knight@bristol.ac.uk
Official homepage: http://www.ilrt.bris.ac.uk/aboutus/staff?search=cmvhk
Personal homepage: http://www.ilrt.bris.ac.uk/~ggvhk/virginia.html
ILRT homepage: http://www.ilrt.bristol.ac.uk