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

Author Topic: Problem Installing.  (Read 1093 times)

0 Members and 1 Guest are viewing this topic.

nicooomg

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
Problem Installing.
« on: October 26, 2011, 04:30:25 pm »
Hello,
I've seen SFML on another project, and thought good to use the lib.
So, after downloading the current v1.6, I've put it in D:/CPP/SFML.

Here's my specs:
using Visual Studio 2010 Premium, installed in C:/...., on Windows 7 64bits.

So I started a project, with the sample code.


In project properties,
I've added in include "D:/CPP/SFML/include"
I've added in libs "D:/CPP/SFML/lib"
In C/C++ > preprocessor, i've added SFML_DYNAMIC to the preprocessor definition
In linker, I added sfml-system.lib.

And when I try to compile,

Code: [Select]

1>------ Début de la génération : Projet : MyGame, Configuration : Debug Win32 ------
1>La génération a démarré 26/10/2011 16:28:36.
1>InitializeBuildStatus:
1>  Mise à jour de l'horodatage "Debug\MyGame.unsuccessfulbuild".
1>ClCompile:
1>  Toutes les sorties sont à jour.
1>MyGame.obj : error LNK2019: symbole externe non résolu "__declspec(dllimport) void __cdecl sf::Sleep(unsigned int)" (__imp_?Sleep@sf@@YAXI@Z) référencé dans la fonction _main
1>MyGame.obj : error LNK2019: symbole externe non résolu "__declspec(dllimport) public: unsigned int __thiscall sf::Clock::GetElapsedTime(void)const " (__imp_?GetElapsedTime@Clock@sf@@QBEIXZ) référencé dans la fonction _main
1>C:\Users\nico\documents\visual studio 2010\Projects\MyGame\Debug\MyGame.exe : fatal error LNK1120: 2 externes non résolus
1>
1>ÉCHEC de la build.
1>
1>Temps écoulé 00:00:02.04
========== Génération : 0 a réussi, 1 a échoué, 0 mis à jour, 0 a été ignoré ==========


So linking errors, hmm. I have no idea how to fix this, anyone might help me out ?
And at the same time, I want to link all sfml libs, so mind telling me for all of them too ? x)

thanks, nico

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Re: Problem Installing.
« Reply #1 on: October 26, 2011, 05:34:39 pm »
Quote from: "nicooomg"
So linking errors, hmm. I have no idea how to fix this, anyone might help me out ?
In Debug mode, you have to link to sfml-system-d.lib. This is explained in the tutorials...

Quote from: "nicooomg"
current v1.6
Version 1.6 is the last released version, but it's far from being current ;)

You can also use the SFML 2 development branch via GitHub, which I strongly recommend because of its new features and bugfixes.
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

 

anything