SFML community forums
Help => General => Topic started by: Makuto on February 10, 2011, 03:04:21 pm
-
I keep getting an error saying "C:/Dev-Cpp/bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/bits/stl_construct.h: variable 'vtable for sf::Sprite' can't be auto-imported. Please read the documentation for ld's --enable-auto-import for details.
collect2: ld returned 1 exit status." I've linked to SFML_DYNAMIC, but I still can't get it to work. I'm using Code::Blocks.
-
I've linked to SFML_DYNAMIC
You probably do it wrong (it has nothing to do with "linking", it's a preprocessor symbol that you have to define). Make sure that you do exactly as in the tutorial.
-
I followed the tutorial again, and still got nothing. Are there any other things I can do to get this to work?
-
Tell us exactly how you did.
-
First, I added the search directories for the compiler and linker, then I typed in the linker settings "-lsfml-graphics-lsfml-window-lsfml-system," then I went to the #defines and added "SFML_DYNAMIC."
Is there a way that I can define it in the actual code?
-
Was this part:
"-lsfml-graphics-lsfml-window-lsfml-system,"
copy-pasted?
If so, you're lacking spaces between the libraries and have a comma too much at the end.
like this:
"-lsfml-graphics -lsfml-window -lsfml-system"
-
There is no comma, and I hit enter after each one.
-
Figured it out. You need to put the SFML_DYNAMIC in all of the tabs, not just #defines. It works great now! :)
Oh, and sorry for all the trouble!