SFML Beginner Issues
I followed this tutorial http://www.sfml-dev.org/tutorials/1.5/start-vc.php and did everything I was told to (add .lib and include and such) yet it still returns an error. I checked everything numerous times and had a friend review it and I do not see an obvious cause. I am thinking it may be due to I have a 64 bit OS but I'm not entirely sure.
In the visual C++ did you add "SFML_DYNAMIC" to the C++ preprocessors?
If you think the problem is your 64-bit OS, you should download the source and compile it yourself, and then use that.
next time, post the error to, then we know what the problem is.
assainator
If you think the problem is your 64-bit OS, you should download the source and compile it yourself, and then use that.
next time, post the error to, then we know what the problem is.
assainator
Yes, I did. Here is the error I am getting:
1>c:\users\casey\documents\visual studio 2008\projects\clock\clock\clock.cpp(1) : warning C4627: '#include <SFML/System.hpp>': skipped when looking for precompiled header use
1> Add directive to 'stdafx.h' or rebuild precompiled header
1>c:\users\casey\documents\visual studio 2008\projects\clock\clock\clock.cpp(2) : warning C4627: '#include <iostream>': skipped when looking for precompiled header use
1> Add directive to 'stdafx.h' or rebuild precompiled header
1>c:\users\casey\documents\visual studio 2008\projects\clock\clock\clock.cpp(15) : fatal error C1010: unexpected end of file while looking for precompiled header. Did you forget to add '#include "stdafx.h"' to your source?
1>Build log was saved at "file://c:\Users\Casey\Documents\Visual Studio 2008\Projects\clock\clock\Debug\BuildLog.htm"
1>clock - 1 error(s), 2 warning(s)
1>c:\users\casey\documents\visual studio 2008\projects\clock\clock\clock.cpp(1) : warning C4627: '#include <SFML/System.hpp>': skipped when looking for precompiled header use
1> Add directive to 'stdafx.h' or rebuild precompiled header
1>c:\users\casey\documents\visual studio 2008\projects\clock\clock\clock.cpp(2) : warning C4627: '#include <iostream>': skipped when looking for precompiled header use
1> Add directive to 'stdafx.h' or rebuild precompiled header
1>c:\users\casey\documents\visual studio 2008\projects\clock\clock\clock.cpp(15) : fatal error C1010: unexpected end of file while looking for precompiled header. Did you forget to add '#include "stdafx.h"' to your source?
1>Build log was saved at "file://c:\Users\Casey\Documents\Visual Studio 2008\Projects\clock\clock\Debug\BuildLog.htm"
1>clock - 1 error(s), 2 warning(s)
It looks like you're not intending to use precompiled headers (no real need to for a simple tutorial), but have them enabled inadvertently.
Turn off precompiled headers in your project's options: C/C++ -> Precompiled Headers -> Create/Use Precompiled Header: Not Using Precompiled Headers
Turn off precompiled headers in your project's options: C/C++ -> Precompiled Headers -> Create/Use Precompiled Header: Not Using Precompiled Headers
You'll generally know when you want to use precompiled headers, namely if you have big, included-everywhere headers. So if you do, sure, turn them back on later - but after you've read some documentation on how to use them!
Otherwise, they are fine left turned off. They do not affect how your code runs, instead they are used to help decrease compilation times.
Otherwise, they are fine left turned off. They do not affect how your code runs, instead they are used to help decrease compilation times.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement