3
« on: February 05, 2013, 10:22:31 pm »
Hi,
I'm pretty new to SFML and I have a slight libraries issue I was hoping someone could help with.
As a little background info, I'm using SFML as part of a university project, which I'm developing at home and must present at university. Since I don't have administrative rights on the university machines, I need to make this program as self-contained as possible.
I can currently get SFML running with, what I thought was, static libraries but when I ran it on another laptop to test, it complained about sfml-xxx-2.dll being missing. I resolved this by adding the required dlls to the sysWOW directory. However, I'm afraid that I might not be able to do that when the time comes to present the project.
I'm using VS2012, with the following setup (I'll give Release info only):
1 - C/C++ -> General -> Additional Include Directories: C:\SFML\Include
2 - Linker -> General -> Additional Library Directories: C:\SFML\lib
3 - Linker -> Input -> Additional Dependencies: sfml-xxxx.lib (where 'xxxx' = graphics/audio etc)
When I originally created the project, I had the libraries installed in the directories for points 1 and 2. I've now moved them to the project directory and it builds fine. However, when I try to run it, I get the message about the missing dll (graphics, in this case, but I'm assuming if I add graphics it'll just pop up with an error for one of the others).
I tried adding a preprocessor definition of SFML_STATIC but that gives a bunch of unresolved external errors at compile time. I've tried going through the tutorials, but the seem to differ. I'm not sure which is correct, to be honest. One hints that extra settings needed to be added for the use of the dynamic libraries, the other suggests the same for static.
The only other info I can think of worth mentioning is that I compiled SFML using CMake and VS2012.
Apologies for the long post - it wasn't intended when I set out writing it - and thanks in advance for any advice.