I downloaded SFML 2.3.1 sources from
http://www.sfml-dev.org/files/SFML-2.3.1-sources.zip. I compiled and "make installed" them (using cmake) on freshly installed Ubuntu 15.04 64 bit (which means there had been no SFML libs in the system).
When I want to launch my SFML app I get following error:
error while loading shared libraries: libsfml-graphics.so.2.3: cannot open shared object file: No such file or directory
Using ldd ./myapp I get following output related to SFML (standard C++ libs are found)
libsfml-graphics.so.2.3 => not found
libsfml-window.so.2.3 => not found
libsfml-system.so.2.3 => not found
Which is a bit strange, because my /usr/local/lib looks like this:
http://i.imgur.com/ueD8Bfx.png. And I have some static libs in /usr/local/lib and linker founds them without problems. There are also no problems with headers in /usr/local/include.
I link following libraries: "sfml-network;sfml-audio;sfml-graphics;sfml-window;sfml-system".
Do you have any idea? I remember there was a terminal command related to ld that refreshed shared library cache but I don't remember it. Anyway I think it should be done automatically after reboot, so this probably isn't the problem.
This is very strange as I've been using SFML on Linux for years without any linking problems. Now I installed Ubuntu 15.04 and the problems appeared. Maybe Ubuntu stopped looking in /usr/local/lib for shared libs? Or something is messed up with SFML libs' links in 2.3.1?
EDIT:Well the magical command which I didn't remeber was "sudo ldconfig". It solved the problem. Altough I am almost sure that ldconfig happens automatically during reboot... I have no idea why reboots didn't trigger it.
Anyway you can delete this thread. Problem is solved and it turned out to be Linux problem, rather than SFML one.