[CC'd to grass-dev for reference.]
Bencze Sándor wrote:
>> I try to compile GRASS to "Solaris 10 6/06" and I can't! I have tryed
>> with gcc <> Solaris cc, make , gmake, dmake and I got allways errors.
>> The last one is this:
>>
>> Errors in:
>> /home/elv/Documents/Downloads/Grass/grass-6.1.0/lib/vask
>>
>
> This is probably a curses issue. Check the output from "make" for the
> actual error message.
>
Yes, this is a curses problem with the following error message:gcc -shared -o
/home/elv/Documents/Downloads/Grass/grass-6.1.0/dist.sparc-sun-solaris2.10/lib/libgrass_vask.6.1.0.so
-L/home/elv/Documents/Downloads/Grass/grass-6.1.0/dist.sparc-sun-solaris2.10/lib
-L/usr/lib -L/usr/local/lib -L/usr/sfw/lib -L/usr/lib/64
-Wl,-R,/home/elv/Documents/Downloads/Grass/grass-6.1.0/dist.sparc-sun-solaris2.10/lib
OBJ.sparc-sun-solaris2.10/V_acc.o OBJ.sparc-sun-solaris2.10/V_call.o
OBJ.sparc-sun-solaris2.10/V_clear.o OBJ.sparc-sun-solaris2.10/V_const.o
OBJ.sparc-sun-solaris2.10/V_error.o OBJ.sparc-sun-solaris2.10/V_exit.o
OBJ.sparc-sun-solaris2.10/V_init.o OBJ.sparc-sun-solaris2.10/V_line.o
OBJ.sparc-sun-solaris2.10/V_ques.o OBJ.sparc-sun-solaris2.10/V_support.o
OBJ.sparc-sun-solaris2.10/V_trim_dec.o -lncurses && if [ -z "" ] ; then
ln -f -s libgrass_vask.6.1.0.so
/home/elv/Documents/Downloads/Grass/grass-6.1.0/dist.sparc-sun-solaris2.10/lib/libgrass_vask.so;
fi
Text relocation remains referenced
against symbol offset in file
<unknown> 0x670
/usr/local/lib/libncurses.a(lib_addch.o)
ld: fatal: relocations remain against allocatable but non-writable sections
collect2: ld returned 1 exit status
gmake: ***
[/home/elv/Documents/Downloads/Grass/grass-6.1.0/dist.sparc-sun-solaris2.10/lib/libgrass_vask.6.1.0.so]
Error 1But I have a brand new curses compilend in the default location!
Several options:
1. Recompile the curses library either as a shared library or with
-fPIC, so that shared libraries can be linked against it.
2. Remove the line:
EXTRA_LIBS=$(CURSES)
from lib/vask/Makefile, and change the line:
VASKLIB = -l$(VASK_LIBNAME)
to:
VASKLIB = -l$(VASK_LIBNAME) $(CURSES)
in include/Make/Grass.make and/or include/Make/Grass.make.in.
3. If Solaris provides a shared [n]curses library in /usr/lib, create
a symlink named libncurses.so in e.g. /usr/local/lib.
The configure script prefers -lncurses to -lcurses, so if you have a
shared libcurses and a static libncurses, it will chose the latter,
even though the former is preferable. OTOH, if you have both shared
and static versions with the same name in the same directory, the
shared version will normally be preferred.
--
Glynn Clements <glynn@gclements.plus.com>