Hi, I new to network programming, and am starting off by making a console chat program. When I try and compile, it comes up with this error, and I don't understand whats going wrong. It happens when I try to initalize winsock, there is a small extract of my code if that helps...
Code:
WSADATA WsaDat;
if (WSAStartup(MAKEWORD(1, 1), &WsaDat) != 0)
{
printf("WSA Initialization failed.");
}
And here is the error...
Code:
"Test.exe" -L"C:/Program Files/Dev-Cpp/lib"
test.o(.text+0x7a8):test.cpp: undefined reference to `WSAStartup@8'
make.exe: *** [Test.exe] Error 1