Hello! I have been having trouble setting up SFML with Code Blocks. I initially followed the tutorial on their web page, but that didn't work, so I found this thread:
http://en.sfml-dev.org/forums/index.php?topic=17956.msg128987#msg128987So I set everything exactly as the solution in that thread said (minus the glew).
It helped with the previous errors, but now I'm getting a " undefined reference to '__chkstk_ms'" one.
||=== Build: Debug in SFMLTutorial (compiler: GNU GCC Compiler) ===|
:ImageLoader.cpp||undefined reference to `__chkstk_ms'|
ImageLoader.cpp||undefined reference to `__chkstk_ms'|
ImageLoader.cpp||undefined reference to `__chkstk_ms'|
ImageLoader.cpp||undefined reference to `__chkstk_ms'|
ImageLoader.cpp||undefined reference to `__chkstk_ms'|
ImageLoader.cpp||more undefined references to `__chkstk_ms' follow|
:WindowImplWin32.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::c_str() const'|
WindowImplWin32.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
WindowImplWin32.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
WindowImplWin32.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::c_str() const'|
WindowImplWin32.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
WindowImplWin32.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
:WglContext.cpp||undefined reference to `std::basic_ostringstream<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::basic_ostringstream(std::_Ios_Openmode)'|
WglContext.cpp||undefined reference to `std::basic_ostream<wchar_t, std::char_traits<wchar_t> >& std::operator<< <wchar_t, std::char_traits<wchar_t> >(std::basic_ostream<wchar_t, std::char_traits<wchar_t> >&, wchar_t const*)'|
WglContext.cpp||undefined reference to `std::basic_ostringstream<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::str() const'|
WglContext.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
WglContext.cpp||undefined reference to `std::basic_ostringstream<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_ostringstream()'|
WglContext.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
WglContext.cpp||undefined reference to `std::basic_ostringstream<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_ostringstream()'|
:JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::basic_string()'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator=(wchar_t const*)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator+=(wchar_t)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator+=(wchar_t const*)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator+=(wchar_t)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator+=(wchar_t const*)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::c_str() const'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::c_str() const'|
JoystickImpl.cpp||undefined reference to `std::basic_ostringstream<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::basic_ostringstream(std::_Ios_Openmode)'|
JoystickImpl.cpp||undefined reference to `std::basic_ostream<wchar_t, std::char_traits<wchar_t> >::operator<<(unsigned int)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator=(wchar_t const*)'|
JoystickImpl.cpp||undefined reference to `std::basic_ostringstream<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::str() const'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator+=(std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> > const&)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator+=(wchar_t const*)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::c_str() const'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator=(wchar_t const*)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::operator+=(wchar_t)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::append(wchar_t const*, unsigned int)'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::c_str() const'|
JoystickImpl.cpp||undefined reference to `std::basic_ostringstream<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_ostringstream()'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
JoystickImpl.cpp||undefined reference to `std::basic_ostringstream<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_ostringstream()'|
JoystickImpl.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
:String.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::length() const'|
String.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::end() const'|
String.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::begin() const'|
String.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::basic_string()'|
String.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::reserve(unsigned int)'|
String.cpp||undefined reference to `std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::~basic_string()'|
||More errors follow but not being shown.|
||Edit the max errors limit in compiler options...|
||=== Build failed: 50 error(s), 0 warning(s) (0 minute(s), 1 second(s)) ===|
I have tried to find a solution to this, but the only thing I was able to find was this:
http://en.sfml-dev.org/forums/index.php?topic=11306.0Where the guy downloaded a different version of GCC and Codeblocks.
I have tried downloading a different version of MinGW, like the user in the previous thread, but it solved nothing. I am using SFML 2.3.1 with GCC 4.8.1, Code Blocks 13.12 on a 64bit Windows 7.
Any help is appreciated, thank you.