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

Author Topic: Linking problem  (Read 1447 times)

0 Members and 2 Guests are viewing this topic.

inaudax

  • Newbie
  • *
  • Posts: 7
    • View Profile
Linking problem
« on: November 18, 2013, 01:24:39 am »
I am having a linking problem with a project I am working on.  I have been over the linking many times and I know for sure that everything is linked properly but whenever I call "draw" on my RenderWindow object I get a link error with RenderStates.  If I use any of the colors i.e. sf::Color::Red I also get a link error but not if I define the color by rgb.  Those are the only errors that I get when I try to compile.  Anyone had this issue or have any suggestions?

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: Linking problem
« Reply #1 on: November 18, 2013, 01:33:28 am »
Regardless of how sure you are, you should provide the full build command see here on how to.

My guess is that you're linking dynamically but still have SFML_STATIC defined.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

wintertime

  • Sr. Member
  • ****
  • Posts: 255
    • View Profile
Re: Linking problem
« Reply #2 on: November 18, 2013, 01:36:52 am »
This is only a guess, though if you also use other SFML-classes that could be a sign of using a slightly incompatible version of compiler to the compiler that SFML was compiled with.
You may like to download another package, if available, but recently there is gcc 4.8 and SFML website got packages for 4.7, so you would have to try recompiling SFML from source or change compiler if thats your problem.

inaudax

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: Linking problem
« Reply #3 on: November 18, 2013, 02:37:42 am »
Regardless of how sure you are, you should provide the full build command see here on how to.

My guess is that you're linking dynamically but still have SFML_STATIC defined.

That is exactly what it was.  I thought I had gotten rid of the definition but I double checked after reading your post and now it is working perfectly.  Thanks!