I'm relatively new to Visual C++ and Code::Blocks, just so everyone is aware.
I originally started in Visual C++ Express 2010 and abandonded that as I could never get it to work. I have googled and googled and tried and tried and I am so far convinced that VC++ 2008 files cannot be made compatible with 2010.
I have recompiled the vs2008 statics and dlls as 2010 and placed them in the folder I wish to use.
I have an empty CLR Project as my base. I create a main.cpp and toss in the Clock tutorial.
Source:
#include <SFML/System.hpp>
#include <iostream>
int main()
{
sf::Clock Clock;
while (Clock.GetElapsedTime() < 5.f)
{
std::cout << Clock.GetElapsedTime() << std::endl;
sf::Sleep(0.5f);
}
return 0;
}
I go into my Project Property Pages and set the following:
1) VC++ Directories -> Include Directories : I add my SFML1.6\include directory
2) VC++ Directories -> Library Directories : I add my SFML1.6\lib\vs2010 directory
3) Linker -> Input -> Additional Dependencies I add sfml-system-s-d.lib, sfml-window-s-d.lib, and sfml-graphics-s-d.lib
4) C/C++ -> Preprocessor : I add SFML_DYNAMIC
When I do that, I get the following. What am I doing wrong?
1>sfml-system-s-d.lib(Unicode.obj) : warning LNK4075: ignoring '/EDITANDCONTINUE' due to '/INCREMENTAL:NO' specification
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::locale::locale(void)" (__imp_??0locale@std@@QAE@XZ) referenced in function __catch$?GetCurrentLocale@?A0xf7357fa0@@YA?AVlocale@std@@XZ$0
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::locale::locale(char const *,int)" (__imp_??0locale@std@@QAE@PBDH@Z) referenced in function "class std::locale __cdecl `anonymous namespace'::GetCurrentLocale(void)" (?GetCurrentLocale@?A0xf7357fa0@@YA?AVlocale@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: class std::_String_const_iterator<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::begin(void)const " (__imp_?begin@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBE?AV?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ) referenced in function "public: __thiscall sf::Unicode::Text::Text(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (??0Text@Unicode@sf@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: class std::_String_const_iterator<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::end(void)const " (__imp_?end@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBE?AV?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ) referenced in function "public: __thiscall sf::Unicode::Text::Text(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (??0Text@Unicode@sf@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: unsigned int __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::length(void)const " (__imp_?length@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEIXZ) referenced in function "public: __thiscall sf::Unicode::Text::Text(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (??0Text@Unicode@sf@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: class std::_String_const_iterator<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::begin(void)const " (__imp_?begin@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBE?AV?$_String_const_iterator@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ) referenced in function "public: __thiscall sf::Unicode::Text::Text(class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > const &)" (??0Text@Unicode@sf@@QAE@ABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: class std::_String_const_iterator<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::end(void)const " (__imp_?end@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBE?AV?$_String_const_iterator@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ) referenced in function "public: __thiscall sf::Unicode::Text::Text(class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > const &)" (??0Text@Unicode@sf@@QAE@ABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: unsigned int __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::length(void)const " (__imp_?length@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBEIXZ) referenced in function "public: __thiscall sf::Unicode::Text::Text(class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > const &)" (??0Text@Unicode@sf@@QAE@ABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::~basic_string<char,struct std::char_traits<char>,class std::allocator<char> >(void)" (__imp_??1?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@XZ) referenced in function "public: __thiscall sf::Unicode::Text::operator class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >(void)const " (??BText@Unicode@sf@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (__imp_??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV01@@Z) referenced in function "public: __thiscall sf::Unicode::Text::operator class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >(void)const " (??BText@Unicode@sf@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::reserve(unsigned int)" (__imp_?reserve@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXI@Z) referenced in function "public: __thiscall sf::Unicode::Text::operator class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >(void)const " (??BText@Unicode@sf@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >(struct std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::_Has_debug_it)" (__imp_??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@U_Has_debug_it@01@@Z) referenced in function "public: __thiscall sf::Unicode::Text::operator class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >(void)const " (??BText@Unicode@sf@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::~basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >(void)" (__imp_??1?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@XZ) referenced in function "public: __thiscall sf::Unicode::Text::operator class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >(void)const " (??BText@Unicode@sf@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >(class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > const&)" (__imp_??0?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@ABV01@@Z) referenced in function "public: __thiscall sf::Unicode::Text::operator class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >(void)const " (??BText@Unicode@sf@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::reserve(unsigned int)" (__imp_?reserve@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXI@Z) referenced in function "public: __thiscall sf::Unicode::Text::operator class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >(void)const " (??BText@Unicode@sf@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >(struct std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::_Has_debug_it)" (__imp_??0?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@U_Has_debug_it@01@@Z) referenced in function "public: __thiscall sf::Unicode::Text::operator class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >(void)const " (??BText@Unicode@sf@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::locale::~locale(void)" (__imp_??1locale@std@@QAE@XZ) referenced in function "void __cdecl `private: static class std::locale const & __cdecl sf::Unicode::GetDefaultLocale(void)'::`2'::`dynamic atexit destructor for 'DefaultLocale''(void)" (??__FDefaultLocale@?1??GetDefaultLocale@Unicode@sf@@CAABVlocale@std@@XZ@YAXXZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_String_base::~_String_base(void)" (__imp_??1_String_base@std@@QAE@XZ) referenced in function "public: __thiscall std::_String_val<unsigned int,class std::allocator<unsigned int> >::~_String_val<unsigned int,class std::allocator<unsigned int> >(void)" (??1?$_String_val@IV?$allocator@I@std@@@std@@QAE@XZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: static void __cdecl std::_String_base::_Xlen(void)" (__imp_?_Xlen@_String_base@std@@SAXXZ) referenced in function "protected: bool __thiscall std::basic_string<unsigned int,struct std::char_traits<unsigned int>,class std::allocator<unsigned int> >::_Grow(unsigned int,bool)" (?_Grow@?$basic_string@IU?$char_traits@I@std@@V?$allocator@I@2@@std@@IAE_NI_N@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_String_base::_String_base(void)" (__imp_??0_String_base@std@@QAE@XZ) referenced in function "protected: __thiscall std::_String_val<unsigned int,class std::allocator<unsigned int> >::_String_val<unsigned int,class std::allocator<unsigned int> >(class std::allocator<unsignedint>)" (??0?$_String_val@IV?$allocator@I@std@@@std@@IAE@V?$allocator@I@1@@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: static void __cdecl std::_String_base::_Xran(void)" (__imp_?_Xran@_String_base@std@@SAXXZ) referenced in function "public: class std::basic_string<unsigned char,struct std::char_traits<unsigned char>,class std::allocator<unsigned char> > & __thiscall std::basic_string<unsigned char,struct std::char_traits<unsigned char>,class std::allocator<unsigned char> >::assign(class std::basic_string<unsigned char,struct std::char_traits<unsigned char>,class std::allocator<unsigned char> > const &,unsigned int,unsigned int)" (?assign@?$basic_string@EU?$char_traits@E@std@@V?$allocator@E@2@@std@@QAEAAV12@ABV12@II@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: class std::locale::facet const * __thiscall std::locale::_Getfacet(unsigned int)const " (__imp_?_Getfacet@locale@std@@QBEPBVfacet@12@I@Z) referenced in function "class std::ctype<wchar_t> const & __cdecl std::use_facet<class std::ctype<wchar_t> >(class std::locale const &)" (??$use_facet@V?$ctype@_W@std@@@std@@YAABV?$ctype@_W@0@ABVlocale@0@@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "private: static void __cdecl std::locale::facet::facet_Register(class std::locale::facet *)" (?facet_Register@facet@locale@std@@CAXPAV123@@Z) referenced in function "public: void __thiscall std::locale::facet::_Register(void)" (?_Register@facet@locale@std@@QAEXXZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) protected: char * __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::_Myptr(void)" (__imp_?_Myptr@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IAEPADXZ) referenced in function "public: char const & __thiscall std::_String_const_iterator<char,struct std::char_traits<char>,class std::allocator<char> >::operator*(void)const " (??D?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEABDXZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) protected: wchar_t * __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::_Myptr(void)" (__imp_?_Myptr@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IAEPA_WXZ) referenced in function "public: wchar_t const & __thiscall std::_String_const_iterator<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::operator*(void)const " (??D?$_String_const_iterator@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBEAB_WXZ)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::push_back(char)" (__imp_?push_back@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXD@Z) referenced in function "public: class std::back_insert_iterator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > & __thiscall std::back_insert_iterator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > >::operator=(char const &)" (??4?$back_insert_iterator@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@std@@QAEAAV01@ABD@Z)
1>sfml-system-s-d.lib(Unicode.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> >::push_back(wchar_t)" (__imp_?push_back@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEX_W@Z) referenced in function "public: class std::back_insert_iterator<class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > > & __thiscall std::back_insert_iterator<class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > >::operator=(wchar_t const &)" (??4?$back_insert_iterator@V?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@@std@@QAEAAV01@AB_W@Z)
[/code]