Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: SFML 1.6 + Visual Studio Pro 2010 - Compiles, doesn't run  (Read 2762 times)

0 Members and 1 Guest are viewing this topic.

apaitch

  • Newbie
  • *
  • Posts: 1
    • View Profile
SFML 1.6 + Visual Studio Pro 2010 - Compiles, doesn't run
« on: March 03, 2012, 02:54:27 am »
Hello,

So yes. I followed the tutorial from the main website. I set the include directories as required, and VS detects all the files and compiles properly. However, when I try to actually run it gives me an error (the .dll files are in the same folder) saying that the application can't start and suggesting I re-install it. Any ideas what I could do to fix it?

This is the debug configuration. Static linking gives a similar error.

Thanks!
-Roman

Tex Killer

  • Full Member
  • ***
  • Posts: 242
    • View Profile
SFML 1.6 + Visual Studio Pro 2010 - Compiles, doesn't run
« Reply #1 on: March 03, 2012, 03:26:00 am »
You must recompile SFML to use it on Visual Studio 2010. There is a tutorial about this on the SFML 2 tutorials section on the site.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
SFML 1.6 + Visual Studio Pro 2010 - Compiles, doesn't run
« Reply #2 on: March 03, 2012, 10:08:14 am »
Quote
There is a tutorial about this on the SFML 2 tutorials section on the site.

Don't look at this tutorial, it is for... SFML 2 ;)

There are billions of posts about this on the forum. Even video tutorials and precompiled libraries.
Laurent Gomila - SFML developer

CyberRascal

  • Newbie
  • *
  • Posts: 3
    • View Profile
SFML 1.6 + Visual Studio Pro 2010 - Compiles, doesn't run
« Reply #3 on: March 03, 2012, 11:50:11 am »
Let me get this straight:

OP downloaded libraries for VS 2008 and tried to use in a VS 2010 project. Is the reason this doesn't work because of mixing C runtimes, or binary incompatibility between the compilers, or both?

Or something else entirely?

coolhome

  • Jr. Member
  • **
  • Posts: 59
    • View Profile
SFML 1.6 + Visual Studio Pro 2010 - Compiles, doesn't run
« Reply #4 on: March 03, 2012, 05:37:55 pm »
You can't mix runtimes I believe.

Solution 1:
Recompile SFML for Visual Studio 2010. However when you recompile there is a naming problem of the files that are generated.

I have already compiled them correctly. Here is a link to the zip.
http://coderzilla.com/libraries/SFML-1/binaries/1.6-MSVC10/SFML-1.6.zip

Solution 2:
Tell the Visual Studio 2010 project to use Visual Studio 2008 compiler.

Right click project -> Project Property --> Configuration Properties -> General -> Platform Toolset to v90.
CoderZilla - Everything Programming

 

anything