one more try...cygwin and gcc v3.2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





Im still having no luck writing a simple socket app.


I'm using gcc v3.2 and all I have in main.cpp is this;



#include <stdio.h> /* These are the usual header files */ #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> #include <netdb.h> #include <unistd.h> #include <string.h> #include <arpa/inet.h> #include <stdlib.h>

#define PORT 3550   /* Port that will be opened */
#define BACKLOG 2   /* Number of allowed connections */



int main(int arc, char** argv)
{
}




Compiler: Default compiler
Building Makefile: "C:\Dev-Cpp\projects\Makefile.win"
Executing make...
make.exe -f "C:\Dev-Cpp\projects\Makefile.win" all
g++.exe -c server.cpp -o server.o -I"C:/Dev-Cpp/include/c++" -I"C:/Dev-Cpp/include/c++/mingw32" -I"C:/Dev-Cpp/include/c++/backward" -I"C:/Dev-Cpp/include" -I c:\cygwin\usr\include


In file included from c:/cygwin/usr/include/asm/socket.h:14,
from c:/cygwin/usr/include/cygwin/socket.h:23,
from c:/cygwin/usr/include/sys/socket.h:15,
from server.cpp:3:
c:/cygwin/usr/include/cygwin/if.h:79: 'caddr_t' is used as a type, but is not
defined as a type.


In file included from c:/cygwin/usr/include/cygwin/in.h:21,
                from c:/cygwin/usr/include/netinet/in.h:14,
                from server.cpp:4:

c:/cygwin/usr/include/cygwin/types.h:37: conflicting types for `typedef
  __dev16_t dev_t'
C:/Dev-Cpp/include/sys/types.h:70: previous declaration as `typedef _dev_t
  dev_t'

make.exe: *** [server.o] Error 1

Execution terminated


but its bombing out with a tonne of compile errors. This is with the latest cygwin release and gcc v 3.2. If this is a gcc issue and I need to upgrade, can somebody tell me where I could get my hands on a copy of a prebuilt release for windows xp as building it here myself is failing each time.



cheers much


G

_________________________________________________________________
Check out the coupons and bargains on MSN Offers! http://shopping.msn.com/softcontent/softcontent.aspx?scmId=1418



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux