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

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Harris

Pages: [1]
1
I found my error. Please remove this thread.

2
SFML_STATIC is not the problem I have used it correctly. Thank you for the idea.

3
IED: Visual Studio Express 2012 - 64bit
SMFL Version: 2.0 - Visual C++ 11 (2012) - 64 bits

Previously, I had a development version of SFML - 2.0 working with VS 2012 by using CMake, but the new version of SFML does not contain CMakeList.txt and should support VS 2012 by default.

I followed the instructions perfectly. I have everything statically linked correctly, I tried dynamically linking, but recieved the same errors. I have looked over the forums and have tried several things to try and fix this. Please help.

#include <SFML/Graphics.hpp>
#include <iostream>

int main()
{
        sf::RenderWindow window(sf::VideoMode(800, 600), "Game");

        while(window.isOpen())
        {
                sf::Event event;

                while(window.pollEvent(event))
                {
                        if(event.type == sf::Event::Closed)
                        {
                                window.close();
                        }
                }

                window.display();

                window.clear();
        }

        return 0;
}
 

Error   1       error LNK2019: unresolved external symbol "public: __thiscall sf::String::String(char const *,class std::locale const &)" (??0String@sf@@QAE@PBDABVlocale@std@@@Z) referenced in function _main C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   2       error LNK2019: unresolved external symbol "public: __thiscall sf::VideoMode::VideoMode(unsigned int,unsigned int,unsigned int)" (??0VideoMode@sf@@QAE@III@Z) referenced in function _main       C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   3       error LNK2019: unresolved external symbol "public: void __thiscall sf::Window::close(void)" (?close@Window@sf@@QAEXXZ) referenced in function _main     C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   4       error LNK2019: unresolved external symbol "public: bool __thiscall sf::Window::isOpen(void)const " (?isOpen@Window@sf@@QBE_NXZ) referenced in function _main    C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   5       error LNK2019: unresolved external symbol "public: bool __thiscall sf::Window::pollEvent(class sf::Event &)" (?pollEvent@Window@sf@@QAE_NAAVEvent@2@@Z) referenced in function _main    C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   6       error LNK2019: unresolved external symbol "public: void __thiscall sf::Window::display(void)" (?display@Window@sf@@QAEXXZ) referenced in function _main C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   7       error LNK2019: unresolved external symbol "public: __thiscall sf::Color::Color(unsigned char,unsigned char,unsigned char,unsigned char)" (??0Color@sf@@QAE@EEEE@Z) referenced in function _main C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   8       error LNK2019: unresolved external symbol "public: void __thiscall sf::RenderTarget::clear(class sf::Color const &)" (?clear@RenderTarget@sf@@QAEXABVColor@2@@Z) referenced in function _main   C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   9       error LNK2019: unresolved external symbol "public: __thiscall sf::RenderWindow::RenderWindow(class sf::VideoMode,class sf::String const &,unsigned int,struct sf::ContextSettings const &)" (??0RenderWindow@sf@@QAE@VVideoMode@1@ABVString@1@IABUContextSettings@1@@Z) referenced in function _main    C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   10      error LNK2019: unresolved external symbol "public: virtual __thiscall sf::RenderWindow::~RenderWindow(void)" (??1RenderWindow@sf@@UAE@XZ) referenced in function _main  C:\Users\Harris\documents\visual studio 2012\Projects\Game\Game\Main.obj        Game
Error   11      error LNK1120: 10 unresolved externals  C:\Users\Harris\documents\visual studio 2012\Projects\Game\Debug\Game.exe       Game
 

This is the exactly same code I have used in the development versions of SFML - 2.0 which worked perfectly.

If I am missing something or there is a really easy fix that I cannot see than I apologize, but I would really like to get this setup and working.

Pages: [1]
anything