4

So here's the short story.

I wanted to compile the latest Transmission client from source but in order to do that I needed the libevent-2 library which is not available from Ubuntu 10.04's repository.

Therefore, I grabbed libevent-2's source code, compiled it and installed it (sudo make install).

I am now able to compile transmission and install it. However, when I try to launch it /usr/local/bin/transmission-gtk, I get the following error:

/usr/local/bin/transmission-gtk: error while loading shared libraries: libevent-2.0.so.5: cannot open shared object file: No such file or directory

However, libevent-2.0.so.5 is in the /usr/local/lib directory instead of /usr/local/lib. Is that possibly the problem? Where should I go from here?

3
  • Setting LD_LIBRARY_PATH="/usr/local/lib" seemed to fix my problem. Mar 19, 2011 at 11:24
  • Always it is better to set such environment variables like below. Either export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib or LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH to ensure that you are losing old ld library path settings.
    – Jamess
    Mar 19, 2011 at 14:02
  • Even if you solve your own problem make it an answer so it's obvious to the next person with this problem, thanks! (Incorporate what Jamess said too to make it better) Mar 19, 2011 at 16:43

2 Answers 2

6

Set LD_LIBRARY_PATH to "/usr/local/lib"

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:"/usr/local/lib" in Bashexport LD_LIBRARY_PATH=$LD_LIBRARY_PATH:"/usr/local/lib"

2

Was unable to set my path right apparently, a symbolic link like this worked:

sudo ln -s /usr/local/lib/libevent-2.0.so.5 /usr/lib/libevent-2.0.so.5

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .