#include "vtape.h"
+
+#ifdef USE_VTAPE
+
static int dbglevel = 100;
#define FILE_OFFSET 30
vtape *ftape_list[FTAPE_MAX_DRIVE];
return result;
}
-/****************************************************************/
-
-#ifdef HAVE_FREEBSD_OS
-int vtape::tape_op(struct mtop *mt_com)
-{
- return -1;
-}
-
-int vtape::tape_get(struct mtget *mt_get)
-{
- return -1;
-}
-
-#else /* Posix */
-
int vtape::tape_op(struct mtop *mt_com)
{
int result=0;
return 0;
}
-#endif /* ! HAVE_FREEBSD_OS */
-
int vtape::tape_pos(struct mtpos *mt_pos)
{
if (current_block >= 0) {
atEOF, atEOT, atEOD, atBOT);
}
+#else /* USE_VTAPE */
+
+int vtape_ioctl(int fd, unsigned long int request, ...)
+{
+ return -1;
+}
+
+int vtape_open(const char *pathname, int flags, ...)
+{
+ return -1;
+}
+
+int vtape_close(int fd)
+{
+ return -1;
+}
+
+void vtape_debug(int level)
+{
+}
+
+ssize_t vtape_read(int fd, void *buffer, size_t count)
+{
+ return -1;
+}
+
+ssize_t vtape_write(int fd, const void *buffer, size_t count)
+{
+ return -1;
+}
+
+#endif /* ! USE_VTAPE */
#include <stddef.h>
#include "bacula.h"
-#define FTAPE_MAX_DRIVE 50
-
/*
* Theses functions will replace open/read/write
*/
ssize_t vtape_read(int fd, void *buffer, size_t count);
ssize_t vtape_write(int fd, const void *buffer, size_t count);
+#ifdef USE_VTAPE
+
+#define FTAPE_MAX_DRIVE 50
+
typedef enum {
VT_READ_EOF, /* Need to read the entire EOF struct */
VT_SKIP_EOF /* Have already read the EOF byte */
int tape_pos(struct mtpos *mt_com);
};
+
+#endif /*!USE_VTAPE */
+
#endif /* !VTAPE_H */
General:
19Jun08
+ebl Update vtape driver to compile only under linux.
ebl Fix a bug when restoring with a wrong mediatype.
18Jun08
kes Eliminate ints from conf files and structures to avoid