Generate krb5-types.h instead of using a static one on Windows

This commit is contained in:
Asanka Herath
2009-11-25 12:37:40 -05:00
parent 94c9bd3557
commit 251879f39e
2 changed files with 20 additions and 3 deletions

View File

@@ -39,6 +39,9 @@ RCSID("$Id$");
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#ifdef WIN32
#include <ws2tcpip.h>
#endif
#define BITSIZE(TYPE) \
{ \
@@ -157,7 +160,11 @@ int main(int argc, char **argv)
fprintf(f, "#include <netinet/in6_machtypes.h>\n");
#endif
#ifdef HAVE_SOCKLEN_T
#ifndef WIN32
fprintf(f, "#include <sys/socket.h>\n");
#else
fprintf(f, "#include <ws2tcpip.h>\n");
#endif
#endif
fprintf(f, "\n");
@@ -236,7 +243,6 @@ int main(int argc, char **argv)
fprintf(f, "\n");
#if defined(_WIN32)
#include <ws2tcpip.h>
fprintf(f, "typedef SOCKET krb5_socket_t;\n");
#else
fprintf(f, "typedef int krb5_socket_t;\n");