X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=bacula%2Fsrc%2Fbacula.h;h=fe95239896f91d2d057998c02ac771032cd0fba9;hb=0d68db46b120f0c8178fe4bffbb842d346f3b0a2;hp=80d6eba43c2862ffefffc51e35db1dd19ae38ea2;hpb=9d83c5d582869fb2f34f429e66921ff7446d0d3f;p=bacula%2Fbacula diff --git a/bacula/src/bacula.h b/bacula/src/bacula.h index 80d6eba43c..fe95239896 100644 --- a/bacula/src/bacula.h +++ b/bacula/src/bacula.h @@ -3,37 +3,58 @@ * * Version $Id$ */ - /* - Copyright (C) 2000, 2001, 2002 Kern Sibbald and John Walker + Bacula® - The Network Backup Solution + + Copyright (C) 2000-2006 Free Software Foundation Europe e.V. - This program is free software; you can redistribute it and/or - modify it under the terms of the GNU General Public License as - published by the Free Software Foundation; either version 2 of - the License, or (at your option) any later version. + The main author of Bacula is Kern Sibbald, with contributions from + many others, a complete list can be found in the file AUTHORS. + This program is Free Software; you can redistribute it and/or + modify it under the terms of version two of the GNU General Public + License as published by the Free Software Foundation and included + in the file LICENSE. - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of + This program is distributed in the hope that it will be useful, but + WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. - You should have received a copy of the GNU General Public - License along with this program; if not, write to the Free - Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, - MA 02111-1307, USA. + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + 02110-1301, USA. - */ + Bacula® is a registered trademark of John Walker. + The licensor of Bacula is the Free Software Foundation Europe + (FSFE), Fiduciary Program, Sumatrastrasse 25, 8006 Zürich, + Switzerland, email:ftf@fsfeurope.org. +*/ #ifndef _BACULA_H #define _BACULA_H 1 +#ifdef __cplusplus +/* Workaround for SGI IRIX 6.5 */ +#define _LANGUAGE_C_PLUS_PLUS 1 +#endif + +#if defined(HAVE_WIN32) +#if defined(HAVE_MINGW) +#include "mingwconfig.h" +#else +#include "winconfig.h" +#endif +#else #include "config.h" -#include "host.h" +#endif + #define _REENTRANT 1 #define _THREAD_SAFE 1 #define _POSIX_PTHREAD_SEMANTICS 1 + /* System includes */ #if HAVE_STDINT_H #include @@ -46,21 +67,40 @@ #include #endif #if HAVE_UNISTD_H +# ifdef HAVE_HPUX_OS +# undef _INCLUDE_POSIX1C_SOURCE +# endif #include #endif #if HAVE_ALLOCA_H #include #endif +#if defined(_MSC_VER) +#include +#include +#include +#endif #include #include +/* O_NOATIME is defined at fcntl.h when supported */ +#ifndef O_NOATIME +#define O_NOATIME 0 +#endif + +#if defined(_MSC_VER) +extern "C" { +#include "getopt.h" +} +#endif + #ifdef xxxxx #ifdef HAVE_GETOPT_LONG #include #else #include "lib/getopt.h" #endif -#endif +#endif #include #include @@ -84,7 +124,12 @@ #ifdef HAVE_SYS_SOCKET_H #include #endif +#if defined(HAVE_WIN32) & !defined(HAVE_MINGW) +#include +#endif +#if !defined(HAVE_WIN32) & !defined(HAVE_MINGW) #include +#endif #include #if HAVE_SYS_WAIT_H #include @@ -92,15 +137,53 @@ #include #include #include - + +#ifdef HAVE_OPENSSL +/* fight OpenSSL namespace pollution */ +#define STORE OSSL_STORE +#include +#include +#include +#include +#include +#include +#undef STORE +#endif + /* Local Bacula includes. Be sure to put all the system - * includes before these. + * includes before these. */ +#if defined(HAVE_WIN32) +#include +#include "win32/compat/compat.h" +#endif + #include "version.h" #include "bc_types.h" #include "baconfig.h" #include "lib/lib.h" +/* + * For wx-console compiles, we undo some Bacula defines. + * This prevents conflicts between wx-Widgets and Bacula. + * In wx-console files that malloc or free() Bacula structures + * config/resources and interface to the Bacula libraries, + * you must use bmalloc() and bfree(). + */ +#ifdef HAVE_WXCONSOLE +#undef New +#undef _ +#undef free +#undef malloc +#endif + +#if defined(HAVE_WIN32) +#include "win32/winapi.h" +#include "winhost.h" +#else +#include "host.h" +#endif + #ifndef HAVE_ZLIB_H #undef HAVE_LIBZ /* no good without headers */ #endif