2 * bacula.h -- main header file to include in all Bacula source
7 Bacula® - The Network Backup Solution
9 Copyright (C) 2000-2006 Free Software Foundation Europe e.V.
11 The main author of Bacula is Kern Sibbald, with contributions from
12 many others, a complete list can be found in the file AUTHORS.
13 This program is Free Software; you can redistribute it and/or
14 modify it under the terms of version two of the GNU General Public
15 License as published by the Free Software Foundation and included
18 This program is distributed in the hope that it will be useful, but
19 WITHOUT ANY WARRANTY; without even the implied warranty of
20 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21 General Public License for more details.
23 You should have received a copy of the GNU General Public License
24 along with this program; if not, write to the Free Software
25 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
28 Bacula® is a registered trademark of John Walker.
29 The licensor of Bacula is the Free Software Foundation Europe
30 (FSFE), Fiduciary Program, Sumatrastrasse 25, 8006 Zürich,
31 Switzerland, email:ftf@fsfeurope.org.
38 /* Workaround for SGI IRIX 6.5 */
39 #define _LANGUAGE_C_PLUS_PLUS 1
42 #if defined(HAVE_WIN32)
43 #if defined(HAVE_MINGW)
44 #include "mingwconfig.h"
46 #include "winconfig.h"
54 #define _THREAD_SAFE 1
55 #define _POSIX_PTHREAD_SEMANTICS 1
71 # undef _INCLUDE_POSIX1C_SOURCE
86 /* O_NOATIME is defined at fcntl.h when supported */
98 #ifdef HAVE_GETOPT_LONG
101 #include "lib/getopt.h"
119 #include <sys/types.h>
120 #ifdef HAVE_SYS_BITYPES_H
121 #include <sys/bitypes.h>
123 #include <sys/ioctl.h>
124 #ifdef HAVE_SYS_SOCKET_H
125 #include <sys/socket.h>
127 #if defined(HAVE_WIN32) & !defined(HAVE_MINGW)
128 #include <winsock2.h>
130 #if !defined(HAVE_WIN32) & !defined(HAVE_MINGW)
131 #include <sys/stat.h>
133 #include <sys/time.h>
135 #include <sys/wait.h>
137 #include <netinet/in.h>
138 #include <arpa/inet.h>
142 /* fight OpenSSL namespace pollution */
143 #define STORE OSSL_STORE
144 #include <openssl/ssl.h>
145 #include <openssl/x509v3.h>
146 #include <openssl/rand.h>
147 #include <openssl/err.h>
148 #include <openssl/asn1.h>
149 #include <openssl/asn1t.h>
153 /* Local Bacula includes. Be sure to put all the system
154 * includes before these.
156 #if defined(HAVE_WIN32)
158 #include "win32/compat/compat.h"
162 #include "bc_types.h"
163 #include "baconfig.h"
167 * For wx-console compiles, we undo some Bacula defines.
168 * This prevents conflicts between wx-Widgets and Bacula.
169 * In wx-console files that malloc or free() Bacula structures
170 * config/resources and interface to the Bacula libraries,
171 * you must use bmalloc() and bfree().
173 #ifdef HAVE_WXCONSOLE
180 #if defined(HAVE_WIN32)
181 #include "win32/winapi.h"
188 #undef HAVE_LIBZ /* no good without headers */