Hi, I've been using SFML for quite a long time and didn't have any linker-related errors. Today I downloaded SFML 2.0 for vs2012 x64, set up project(include and lib folders, input libs for linker, x64 platform setting etc.) and tried to compile
this tutorial code example, but I get following error:
Error 1 error LNK2019: unresolved external symbol "__declspec(dllimport) public: __cdecl sf::RenderWindow::RenderWindow(class sf::VideoMode,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,unsigned int,struct sf::ContextSettings const &)" (__imp_??0RenderWindow@sf@@QEAA@VVideoMode@1@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IAEBUContextSettings@1@@Z) referenced in function main E:\dev\Projects\arcadium\arcadium\EntryPoint.obj
But if I change constructor for
sf::RenderWindow window to default like this:
#include <SFML/Graphics.hpp>
int main()
{
sf::RenderWindow window;
window.setActive(true);
window.setVisible(true);
sf::CircleShape shape(100.f);
shape.setFillColor(sf::Color::Green);
while (window.isOpen())
{
sf::Event event;
while (window.pollEvent(event))
{
if (event.type == sf::Event::Closed)
window.close();
}
window.clear();
window.draw(shape);
window.display();
}
return 0;
}
This code compiles without errors but evidently doesn't create any window. Am I missing something here?
Any help will be appreciated.