SFML community forums
Help => General => Topic started by: fallout on October 09, 2012, 08:32:21 pm
-
I'm new to Linux. I was wondering what the differences in .so files are (2.0 RC). There are .so, .so.2, and .so.2.0. I've got Eclipse pointing to the .so files, but I'm getting a warning that in /Debug/ProjectName the sfml-window.so.2 cannot be found.
What are the differences in .so files?
-
The actual library is .so.2.0. Then we have .so.2 which is a symbolic link to .so.2.0, and .so which is a link to .so.2. Which one you refer to depends on your needs: if you don't care at all about the version number, you link to .so, regardless what it points to. If you need to use version 2.x, you link to .so.2, regardless the minor version number. If you need a very specific version, let's say 2.0, because your program can only work with this version, then you link to .so.2.0.
I hope it's clear enough. If it's not, there should be better articles about the naming conventions, and how to manage versions of shared libraries on Linux.
-
That's very clear. Thank you.
Hm, I have Eclipse pointing to the folder where all the .so files are, and I've entered what libraries I needed. Do the .so files till have to be placed in a certain location? I've tried /usr/lib/, /lib/, and /usr/local/lib. None of them seem to work. I get the following error when I try to run the program (building is fine):
error while loading shared libraries: libsfml-window.so.2: cannot open shared object file: No such file or directory
-
Ah! I figured it out. Placed the shared libraries in /usr/local/lib.
I had done that before, but I never executed ldconfig. This must be done or it will not be detected. Got a window up and running. Cool.