I made de static compilation of the sfml2 with cmake and mingw. It's working well for graphics, open windows, handle events... but when I try to use network I'm get this errors:
My test code:
#include <SFML/Graphics.hpp>
#include <SFML/Window.hpp>
#include <SFML/System.hpp>
#include <SFML/Network.hpp>
sf::TcpSocket sock;
int main() {
sf::RenderWindow wnd;
return 0;
}
Code blocks errors:
F:\sfml2\lib/libsfml-network-s.a(Packet.cpp.obj):Packet.cpp:(.text+0x779): undefined reference to `sf::String::clear()'
F:\sfml2\lib/libsfml-network-s.a(Packet.cpp.obj):Packet.cpp:(.text+0x804): undefined reference to `sf::String::String(unsigned int)'
F:\sfml2\lib/libsfml-network-s.a(Packet.cpp.obj):Packet.cpp:(.text+0x81d): undefined reference to `sf::String::operator+=(sf::String const&)'
F:\sfml2\lib/libsfml-network-s.a(Packet.cpp.obj):Packet.cpp:(.text+0x87d): undefined reference to `sf::String::clear()'
F:\sfml2\lib/libsfml-network-s.a(Packet.cpp.obj):Packet.cpp:(.text+0xf4b): undefined reference to `sf::String::getSize() const'
F:\sfml2\lib/libsfml-network-s.a(Packet.cpp.obj):Packet.cpp:(.text+0xf9f): undefined reference to `sf::String::begin() const'
F:\sfml2\lib/libsfml-network-s.a(Packet.cpp.obj):Packet.cpp:(.text+0xfba): undefined reference to `sf::String::end() const'
Maybe someone can help me. Thanks!