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

Author Topic: Finished install tutorial, get error on sample program!  (Read 4079 times)

0 Members and 1 Guest are viewing this topic.

DanCarew

  • Newbie
  • *
  • Posts: 5
    • View Profile
Finished install tutorial, get error on sample program!
« on: June 08, 2009, 07:44:43 am »
I'm using Visual Studio 2008, I finished the installation tutorial completely but still receive the following error when I try to actually run the program:
This application has failed to start because sfml-system.dll was not found.

What am I missing here?  Like I said, I did every single step for installation on the tutorial.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Finished install tutorial, get error on sample program!
« Reply #1 on: June 08, 2009, 08:40:12 am »
The message is clear: you didn't copy the SFML DLLs to your executable's directory (or to a directory which is in the PATH).
Laurent Gomila - SFML developer

DanCarew

  • Newbie
  • *
  • Posts: 5
    • View Profile
Finished install tutorial, get error on sample program!
« Reply #2 on: June 08, 2009, 10:25:43 am »
Thank you, that seems to fix the problem.

There is, however, a new problem.  I am getting ten errors that look similar to this here:
Code: [Select]
Pong.obj : error LNK2019: unresolved external symbol "public: void __thiscall sf::Window::Display(void)" (?Display@Window@sf@@QAEXXZ) referenced in function _main

I apologize for these mundane questions.  This is my first time using any non-standard libraries, and I am learning it all by myself.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Finished install tutorial, get error on sample program!
« Reply #3 on: June 08, 2009, 10:57:33 am »
You didn't link to sfml-window.lib.
Laurent Gomila - SFML developer

DanCarew

  • Newbie
  • *
  • Posts: 5
    • View Profile
Finished install tutorial, get error on sample program!
« Reply #4 on: June 09, 2009, 07:06:33 am »
Thank you!

Figured out my last problem as well, wasn't defining SFML_DYNAMIC.

DanCarew

  • Newbie
  • *
  • Posts: 5
    • View Profile
Finished install tutorial, get error on sample program!
« Reply #5 on: June 09, 2009, 08:04:23 am »
Now... the game compiles fine, but when it launches, it crashed.  Debug narrows the issue down to
Code: [Select]
if (!BallSoundBuffer.LoadFromFile("datas/pong/ball.wav"))

The error is
Code: [Select]
Unhandled exception at 0x68d7fdf1 in SFMLTEST.exe: 0xC0000005: Access violation reading location 0xcccccccc.

For some reason, the game's title bar appears as ÌÌÌÌSFML Pong and not just SFML Pong as it should be.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Finished install tutorial, get error on sample program!
« Reply #6 on: June 09, 2009, 08:43:17 am »
You must use debug libraries ("-d" suffix) when compiling in debug mode.

You know, every single question you asked is marked as "important" in the "getting started" tutorial, and you also can find plenty of answers for them with a search on the forum.
Laurent Gomila - SFML developer

DanCarew

  • Newbie
  • *
  • Posts: 5
    • View Profile
Finished install tutorial, get error on sample program!
« Reply #7 on: June 09, 2009, 08:44:21 am »
Thank you for your assistance!  I must have been looking at the wrong tutorial section all along...

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
Finished install tutorial, get error on sample program!
« Reply #8 on: June 10, 2009, 08:42:55 am »
I guess you've been in the "c++ for beginners" tutorial section? ;)

SCNR. It's just that this happens so many times and it's kinda unfair because Laurent spent a huge amount of time writing those tutorials especially for developers like you. ;)

 

anything