I'm a problem when I compile a simple program with socket function like "socket", "connect", "gethostbyname"... in Windows.
I have included <windows.h> and all other header files required by the various functions, but this is the output of compiler:
undefined reference to `socket@12'
undefined reference to `htons@4'
undefined reference to `gethostbyname@4'
undefined reference to `connect@12'
undefined reference to `getpeername@12'
undefined reference to `getsockname@12'
undefined reference to `ntohs@4'
undefined reference to `inet_ntoa@4'
Then, which it could be the problem?
Tanks!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm a problem when I compile a simple program with socket function like "socket", "connect", "gethostbyname"... in Windows.
I have included <windows.h> and all other header files required by the various functions, but this is the output of compiler:
undefined reference to `socket@12'
undefined reference to `htons@4'
undefined reference to `gethostbyname@4'
undefined reference to `connect@12'
undefined reference to `getpeername@12'
undefined reference to `getsockname@12'
undefined reference to `ntohs@4'
undefined reference to `inet_ntoa@4'
Then, which it could be the problem?
Tanks!