Hi,
I've been trying to compile and run my application non Solaris using CC (details below) but haven't got luck with running the application because of a linker error :
--------------------------------------------------------------------------------------------


ld.so.1: java: fatal: relocation error: file ./libtest.so: symbol __1cDstdMbasic_string4Ccn0ALchar_traits4Cc__n0AJallocator4Cc___J__nullref_: referenced symbol not found
--------------------------------------------------------------------------------------------


Here's what I'm trying to do :
I'm compiling one library to include another shared library which uses the "string" class (STL). The compilation of both the libraries proceeds perfectly fine. However, when i preload this library with LD_PRELOAD and run a JAVA application (which will have calls to some function in the preloaded library), the get the above linker error.


Here's what all I have tries to get this working : ( I understand that this error is due to a missing library that CC has not linked to and I've no idea what the library is!!!)
1.> # LD_LIBRARY_PATH=/usr/lib:$LD_LIBRARY_PATH
# export LD_LIBRARY_PATH - NO LUCK :-(
2.> linked to /opt/SUNWspro/lib/libCrun.so (found this from another forum on the net), but NO LUCK :-(
3.> export LD_DEBUG=bindings
export LD_DEBUG_OUTPUT=/home/log.txt (so that all symbols referred are logged!!!)
i did a grep on the log for the symbol but NO LUCK!!! :-(
4.> Added /opt/SUNWspro/lib to LD_LIBRARY_PATH - yet NO LUCK!!!


Please can you help me with this? What is the library that is to be linked too, or is there something else?

Details About my system, compiler and compilation options :
1.> uname -a output : SunOS sh1sol9 5.9 Generic_117171-12 sun4u sparc SUNW,Sun-Fire-280R Solaris
2.> CC version : Sun WorkShop 6 update 2 C++ 5.3
3.> Compilation flags I've used to build the library :
FIRST LIBRARY : CC -G -xcode=pic32 -I../common/ -ldl ../common/logger.cpp helper_functions.cpp BCPEntries.cpp BCP_class.cpp -o libBCP.so


SECOND LIBRARY : CC -G -xcode=pic32 -I../common/ test_BCP_construct.cpp -lBCP -L. -o libtest.so

Please help me out of this,
Any and every help (or even a hint to it) will be appreciated!!!
Thanks in advance,

-
Madhur Tanwani.
--
______________________________________________________________________
Pune GNU/Linux Users Group Mailing List:      ([email protected])
List Information:  http://plug.org.in/mailing-list/listinfo/plug-mail
Send 'help' to [EMAIL PROTECTED] for mailing instructions.

Reply via email to