]> git.sur5r.net Git - bacula/bacula/blob - bacula/src/stored/stored.h
- Comment out Multiple Connections in the document.
[bacula/bacula] / bacula / src / stored / stored.h
1 /*
2  * Storage daemon specific defines and includes
3  *
4  *  Version $Id$
5  */
6 /*
7    Copyright (C) 2000-2005 Kern Sibbald
8
9    This program is free software; you can redistribute it and/or
10    modify it under the terms of the GNU General Public License as
11    published by the Free Software Foundation; either version 2 of
12    the License, or (at your option) any later version.
13
14    This program is distributed in the hope that it will be useful,
15    but WITHOUT ANY WARRANTY; without even the implied warranty of
16    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17    General Public License for more details.
18
19    You should have received a copy of the GNU General Public
20    License along with this program; if not, write to the Free
21    Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
22    MA 02111-1307, USA.
23
24  */
25
26 #ifndef __STORED_H_
27 #define __STORED_H_
28
29 #define STORAGE_DAEMON 1
30
31 #ifdef HAVE_MTIO_H
32 #include <mtio.h>
33 #else
34 # ifdef HAVE_SYS_MTIO_H
35 # include <sys/mtio.h>
36 # else
37 #   ifdef HAVE_SYS_TAPE
38 #   include <sys/tape.h>
39 #   endif
40 # endif
41 #endif
42 #include "block.h"
43 #include "record.h"
44 #include "dev.h"
45 #include "stored_conf.h"
46 #include "bsr.h"
47 #include "jcr.h"
48 #include "protos.h"
49 #ifdef HAVE_LIBZ
50 #include <zlib.h>                     /* compression headers */
51 #else
52 #define uLongf uint32_t
53 #endif
54 #ifdef HAVE_FNMATCH
55 #include <fnmatch.h>
56 #else
57 #include "lib/fnmatch.h"
58 #endif
59 #ifdef HAVE_DIRENT_H
60 #include <dirent.h>
61 #define NAMELEN(dirent) (strlen((dirent)->d_name))
62 #endif
63 #ifndef HAVE_READDIR_R
64 int readdir_r(DIR *dirp, struct dirent *entry, struct dirent **result);
65 #endif
66
67 /* Daemon globals from stored.c */
68 extern STORES *me;                    /* "Global" daemon resource */
69 extern bool forge_on;                 /* proceed inspite of I/O errors */
70 extern pthread_mutex_t device_release_mutex;
71 extern pthread_cond_t wait_device_release; /* wait for any device to be released */                           
72
73 #ifdef debug_tracing
74 extern int _rewind_dev(char *file, int line, DEVICE *dev);
75 #define rewind_dev(d) _rewind_dev(__FILE__, __LINE__, (d))
76 #endif
77
78 #endif /* __STORED_H_ */