2 * Storage daemon specific defines and includes
7 Copyright (C) 2000-2005 Kern Sibbald
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.
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.
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,
29 #define STORAGE_DAEMON 1
34 # ifdef HAVE_SYS_MTIO_H
35 # include <sys/mtio.h>
38 # include <sys/tape.h>
45 #include "stored_conf.h"
50 #include <zlib.h> /* compression headers */
52 #define uLongf uint32_t
57 #include "lib/fnmatch.h"
61 #define NAMELEN(dirent) (strlen((dirent)->d_name))
63 #ifndef HAVE_READDIR_R
64 int readdir_r(DIR *dirp, struct dirent *entry, struct dirent **result);
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 */
74 extern int _rewind_dev(char *file, int line, DEVICE *dev);
75 #define rewind_dev(d) _rewind_dev(__FILE__, __LINE__, (d))
78 #endif /* __STORED_H_ */