Although finding <wx/cmdline.h>
, NetBeans complains error in <wx/wxprec.h>
and <wx/socket.h>
Build:
g++ `wx-config --cxxflags` -o dist/Debug/GNU-Linux-x86/client build/Debug/GNU-Linux-x86/main.o -lpthread `wx-config --cxxflags`
Project Properties in NetBeans
I need to include these files to create a socket, I'm trying to do the following:
wxPrintf("Creating socket...\n");
wxSocketClient socketClient;
socketClient = new wxSocketBase(wxSOCKET_NONE);
wxPrintf("Addressing...\n");
wxIPV4address addr;
addr.Hostname("127.0.0.1");
addr.Service(3000);
if (!socketClient.IsOk()) {
wxPrintf("Could not listen at the specified port !\n");
return 1;
}
wxPrintf("Trying to make connection...\n");
if (socketClient.Connect(addr, false)) {
wxPrintf("Success\n");
} else {
wxPrintf("Error!\n");
return 1;
}
My project is just console. I do not need GUI.