[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Can't find a library that's right there



Josselin Mouette <joss@debian.org> writes:

> Le vendredi 20 août 2004 à 18:11 -0700, Ross Boylan a écrit :
>> I have a library on my system, yet I'm having trouble accessing it:
>> $ ls -l /usr/lib/R/bin/libR.so
>> -rw-r--r--  1 root root 1638320 Jun 22 05:01 /usr/lib/R/bin/libR.so
>> 
>> Here is my link step, and subsequent failures, even after setting
>> LD_LIBRARY_PATH:
>> 
>> g++ -o test1 mspathCEntry_test.o Manager_test.o TestManager.o
>> PathGenerator_test.o TestRecorder.o SimpleRecorder_test.o
>> TimeStepsGenerator_test.o StateTimeClassifier_test.o Environment_test.o
>> SuccessorGenerator_test.o Model_test.o ConstrainedCoefficients_test.o
>> Path_test.o Data_test.o TimeSteps_test.o TimePoint_test.o basic_test.o
>> ../mspath.so -L/usr/lib/debug -lboost_unit_test_framework \
>>          -L/usr/lib/R/bin -lR
>> ./test1 --report_level=detailed
>> ./test1: error while loading shared libraries: libR.so: cannot open
>> shared object file: No such file or directory
>> make: *** [runtest] Error 127
>
> For compilation, LD_LIBRARY_PATH is useless. You should set
> LIBRARY_PATH, or use a -L flag.

He isn't compiling but running the binary.

What is your LD_LIBRARY_PATH set to and when? Is it maybe cleared by
fakeroot or something? What does "ldd test1" say?

For libraries in non standard dirs you might have to set rpath.

MfG
        Goswin



Reply to: