Hi, once again I get these lovely linker errors. They really love me
This is my setup:
VC++ Directories:
Include files:
C:\Daniel\SFML-1.2\include
Library files:
C:\Daniel\SFML-1.2\lib\vc2008\static
Additional dependencies:
sfml-graphics-d.lib sfml-main-d.lib sfml-system-d.lib sfml-window-d.lib
This is the code I'm trying to compile (the one from the doc-page without the music and the sprite):
#include <SFML/Graphics.hpp>
int main()
{
// Create the main window
sf::RenderWindow App(sf::VideoMode(800, 600), "SFML window");
// Create a graphical string to display
sf::String Text("Hello SFML", "arial.ttf", 50);
// Start the game loop
bool Running = true;
while (Running)
{
// Process events
sf::Event Event;
while (App.GetEvent(Event))
{
// Close window : exit
if (Event.Type == sf::Event::Closed)
Running = false;
}
// Draw the string
App.Draw(Text);
// Update the window
App.Display();
}
return EXIT_SUCCESS;
}
This is the output:
1>------ Rebuild All started: Project: sfml12test, Configuration: Debug Win32 ------
1>Deleting intermediate and output files for project 'sfml12test', configuration 'Debug|Win32'
1>Compiling...
1>main.cpp
1>Compiling manifest to resources...
1>Microsoft (R) Windows (R) Resource Compiler Version 6.0.5724.0
1>Copyright (C) Microsoft Corporation. All rights reserved.
1>Linking...
1>LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library
1>sfml-graphics-d.lib(ImageLoader.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ) referenced in function "public: void __thiscall std::_Iterator_base::_Adopt(class std::_Container_base const *)" (?_Adopt@_Iterator_base@std@@QAEXPBV_Container_base@2@@Z)
1>sfml-window-d.lib(Window.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ)
1>sfml-window-d.lib(VideoMode.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ)
1>sfml-window-d.lib(VideoModeSupport.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ)
1>sfml-graphics-d.lib(RenderWindow.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ)
1>sfml-graphics-d.lib(String.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ)
1>sfml-graphics-d.lib(Image.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ)
1>sfml-graphics-d.lib(FontManager.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ)
1>sfml-window-d.lib(WindowImpl.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(ImageLoader.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(GraphicsDevice.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ)
1>sfml-window-d.lib(Window.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ)
1>sfml-window-d.lib(VideoMode.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(RenderWindow.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ) referenced in function __unwindfunclet$??0?$_Vector_val@EV?$allocator@E@std@@@std@@IAE@V?$allocator@E@1@@Z$0
1>sfml-graphics-d.lib(String.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(Image.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(FontManager.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ)
1>sfml-window-d.lib(WindowImpl.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ) referenced in function "public: void __thiscall std::_Iterator_base::_Adopt(class std::_Container_base const *)" (?_Adopt@_Iterator_base@std@@QAEXPBV_Container_base@2@@Z)
1>sfml-graphics-d.lib(ImageLoader.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(GraphicsDevice.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ)
1>sfml-window-d.lib(Window.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ)
1>sfml-window-d.lib(VideoMode.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(RenderWindow.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(String.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(Image.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(FontManager.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ)
1>sfml-graphics-d.lib(Image.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Swap_aux(class std::_Container_base &)" (__imp_?_Swap_aux@_Container_base@std@@QAEXAAV12@@Z) referenced in function "public: void __thiscall std::vector<class sf::Color,class std::allocator<class sf::Color> >::swap(class std::vector<class sf::Color,class std::allocator<class sf::Color> > &)" (?swap@?$vector@VColor@sf@@V?$allocator@VColor@sf@@@std@@@std@@QAEXAAV12@@Z)
1>sfml-graphics-d.lib(Image.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Swap_all(class std::_Container_base &)const " (__imp_?_Swap_all@_Container_base@std@@QBEXAAV12@@Z) referenced in function "public: void __thiscall std::vector<class sf::Color,class std::allocator<class sf::Color> >::swap(class std::vector<class sf::Color,class std::allocator<class sf::Color> > &)" (?swap@?$vector@VColor@sf@@V?$allocator@VColor@sf@@@std@@@std@@QAEXAAV12@@Z)
1>C:\Daniel\sfml12test\Debug\sfml12test.exe : fatal error LNK1120: 5 unresolved externals
1>Build log was saved at "file://c:\Daniel\sfml12test\sfml12test\Debug\BuildLog.htm"
1>sfml12test - 29 error(s), 1 warning(s)
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
Sorry for being a pain in the ass with all these linker errors, they are haunting me.