[OT] socket communications

General questions regarding the usage of CodeLite
HJarausch
CodeLite Veteran
Posts: 98
Joined: Thu Feb 18, 2010 10:54 pm
Genuine User: Yes
IDE Question: C++
Contact:

[OT] socket communications

Post by HJarausch »

Hi,
I had a hard time googling for how to use sockets under MinGW.
I have code which works under Linux but gives missing header files under MinGW.
Furthermore I have code which works under Windows-native/Visual C++.
This, using WinSock2.h, compiles under CodeLite but gives a run time error
when started (some missing WinMain@16).

Since CodeLite is able to access its homepage and in addition there is a Subversion
plugin, it must be possible to use sockets when using CodeLite under MinGW.

Many thanks for a hint or pointer,
Helmut.
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: [OT] socket communications

Post by eranif »

HJarausch wrote:This, using WinSock2.h
This should be enough
HJarausch wrote:but gives a run time error
when started (some missing WinMain@16).
Can u post the complete build log?

Do you have main function?
Eran
Make sure you have read the HOW TO POST thread
HJarausch
CodeLite Veteran
Posts: 98
Joined: Thu Feb 18, 2010 10:54 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: [OT] socket communications

Post by HJarausch »

Thanks, I discovered I have to link to libws2_32. Now it works.

Helmut.
Post Reply