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

Author Topic: sf::Music error  (Read 4410 times)

0 Members and 1 Guest are viewing this topic.

sparkon

  • Newbie
  • *
  • Posts: 21
    • View Profile
sf::Music error
« on: August 25, 2012, 04:26:42 pm »
Hello guys! i have been using sfml for a bit and now i've decided to put some music in my game ( not sf::Sound ) the problem is that whenever i initialize sf::Music music; compiler ( Code::Blocks 10.05 ) gives me en error :
undefined reference to 'sf::Thread::~Thread()' i guessed that SFML use thread to handle music so i imported all the modules... but still this error.
I've been googling around but haven't found no problems like mine. Thank you for your time... waiting for answer :)

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: sf::Music error
« Reply #1 on: August 25, 2012, 05:33:10 pm »
You must link to sfml-system.
Laurent Gomila - SFML developer

sparkon

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: sf::Music error
« Reply #2 on: August 26, 2012, 10:10:36 am »
I linked the sfml-system-s-d and included it aswell

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Re: sf::Music error
« Reply #3 on: August 26, 2012, 10:40:22 am »
And the error persists?

What configuration (Debug/Release, Static/Dynamic Link) do you use?
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: sf::Music error
« Reply #4 on: August 26, 2012, 12:30:43 pm »
You must link libraries in the right order, as explained in the tutorial.
Laurent Gomila - SFML developer

sparkon

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: sf::Music error
« Reply #5 on: August 26, 2012, 07:58:52 pm »
i'm using Debug / static and they are linked it the right order :
- graphics
-window
-system
- network
- audio
i tried - audio and - network ... but still not working

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: sf::Music error
« Reply #6 on: August 26, 2012, 08:10:52 pm »
Can you show me where you read that this is the right order? :P

Read the tutorial carefully, it's clearly explained.
Laurent Gomila - SFML developer

 

anything