* Version $Id$
*/
/*
- Copyright (C) 2000-2005 Kern Sibbald
+ Copyright (C) 2000-2006 Kern Sibbald
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
#define _LANGUAGE_C_PLUS_PLUS 1
#endif
-#ifdef WIN32
+#if defined(HAVE_WIN32)
+#if defined(HAVE_MINGW)
+#include "mingwconfig.h"
+#else
#include "winconfig.h"
+#endif
#include "winhost.h"
#else
#include "config.h"
#if HAVE_ALLOCA_H
#include <alloca.h>
#endif
+
#include <errno.h>
#include <fcntl.h>
+/* O_NOATIME is defined at fcntl.h when supported */
+#ifndef O_NOATIME
+#define O_NOATIME 0
+#endif
+
#ifdef xxxxx
#ifdef HAVE_GETOPT_LONG
#include <getopt.h>
#ifdef HAVE_SYS_SOCKET_H
#include <sys/socket.h>
#endif
-#ifdef HAVE_WIN32
+#if defined(HAVE_WIN32) & !defined(HAVE_MINGW)
#include <winsock2.h>
-#else
+#endif
+#if !defined(HAVE_WIN32) & !defined(HAVE_MINGW)
#include <sys/stat.h>
-#endif
+#endif
#include <sys/time.h>
#if HAVE_SYS_WAIT_H
#include <sys/wait.h>
#include <openssl/x509v3.h>
#include <openssl/rand.h>
#include <openssl/err.h>
+#include <openssl/asn1.h>
+#include <openssl/asn1t.h>
#undef STORE
#endif
/* Local Bacula includes. Be sure to put all the system
* includes before these.
*/
+#if defined(HAVE_WIN32)
+#include <windows.h>
+#include "win32/compat/compat.h"
+#endif
+
#include "version.h"
#include "bc_types.h"
#include "baconfig.h"
#include "lib/lib.h"
+#ifdef HAVE_WXCONSOLE
+#undef New
+#undef _
+#endif
+
+#if defined(HAVE_WIN32)
+#include "win32/winapi.h"
+#endif
+
#ifndef HAVE_ZLIB_H
#undef HAVE_LIBZ /* no good without headers */
#endif