SFML community forums

Help => Graphics => Topic started by: palo on April 14, 2018, 04:43:57 pm

Title: undefined reference.. only to font.loadfromfile?
Post by: palo on April 14, 2018, 04:43:57 pm
Hello,
I'm making a program in sfml, and until now i used graphics only(everything worked fine), but when i tried to do something with text i have a problem:
everything works, apart from font.loadFromFile(). when i comment this section, compiler doesn't show any problems, like undefined reference to text.setFont(font)
what can be the problem? O.o
i have correctly linked libraries, it worked on previous program.
thanks
Title: Re: undefined reference.. only to font.loadfromfile?
Post by: eXpl0it3r on April 14, 2018, 09:37:26 pm
Your compiler doesn't match the compiler used to build SFML.

The easy solution is to simply build SFML with CMake and your compiler.