-# $Id: Makefile.in,v 1.6 2001/04/06 10:09:40 stelian Exp $
+# $Id: Makefile.in,v 1.7 2001/04/12 16:03:29 stelian Exp $
top_srcdir= @top_srcdir@
srcdir= @srcdir@
DEPLIBS= ../compat/lib/libcompat.a
PROG= dump
+RPROG= rdump
LINKS= ${SBINDIR}/dump ${SBINDIR}/rdump
SRCS= itime.c main.c optr.c tape.c traverse.c unctime.c
OBJS= itime.o main.o optr.o tape.o traverse.o unctime.o \
../common/dumprmt.o
MAN8= dump.8
-MLINKS= $(MANDIR)/dump.8 $(MANDIR)/rdump.8
+RMAN8= rdump.8
-all:: $(PROG) dump.8
+all:: $(PROG) $(MAN8)
$(PROG): $(OBJS) $(DEPLIBS)
$(LD) $(CFLAGS) $(LDFLAGS) -o $(PROG) $(OBJS) $(LIBS)
-dump.8: dump.8.in
+$(MAN8): dump.8.in
sed -e "s|__DUMPDATES__|$(DUMPDATESPATH)|g" \
-e "s|__DATE__|$(DATE)|g" \
-e "s|__VERSION__|$(VERSION)|g" $< > $@
$(INSTALL) -d $(SBINDIR) $(MANDIR)
$(INSTALLBIN) $(PROG) $(SBINDIR)
$(INSTALLMAN) $(srcdir)/$(MAN8) $(MANDIR)
- @set $(LINKS) $(MLINKS); \
- while test $$# -ge 2; do \
- l=$$1; \
- shift; \
- t=$$1; \
- shift; \
- echo $$t -\> $$l; \
- $(RM) -f $$t; \
- $(LN_S) $$l $$t; \
- done; true
+ cd $(SBINDIR) && $(RM) -f $(RPROG) && $(LN_S) $(PROG) $(RPROG)
+ cd $(MANDIR) && $(RM) -f $(RMAN8) && $(LN_S) $(MAN8) $(RMAN8)
clean::
- $(RM) -f $(PROG) \#* *.s *.o *.a *~ core dump.8
+ $(RM) -f $(PROG) $(MAN8) \#* *.s *.o *.a *~ core
distclean:: clean
$(RM) -f Makefile Makefile.old .depend
#ifndef lint
static const char rcsid[] =
- "$Id: main.c,v 1.44 2001/04/11 15:24:03 stelian Exp $";
+ "$Id: main.c,v 1.45 2001/04/12 16:03:29 stelian Exp $";
#endif /* not lint */
#include <config.h>
int i, anydirskipped, bflag = 0, Tflag = 0, honorlevel = 1;
dump_ino_t maxino;
struct stat statbuf;
- dev_t filedev;
+ dev_t filedev = 0;
#ifdef __linux__
errcode_t retval;
char directory[MAXPATHLEN];
#ifndef lint
static const char rcsid[] =
- "$Id: tape.c,v 1.42 2001/04/12 13:14:15 stelian Exp $";
+ "$Id: tape.c,v 1.43 2001/04/12 16:03:29 stelian Exp $";
#endif /* not lint */
#include <config.h>
if (compressed) {
comp_buf->length = bufsize;
worklen = TP_BSIZE + writesize;
+ compresult = Z_DATA_ERROR;
if (do_compress)
compresult = compress2(comp_buf->buf, &worklen,
(char *)slp->tblock[0], writesize, compressed);
-# $Id: Makefile.in,v 1.7 2001/04/06 10:09:40 stelian Exp $
+# $Id: Makefile.in,v 1.8 2001/04/12 16:03:30 stelian Exp $
top_srcdir= @top_srcdir@
srcdir= @srcdir@
DEPLIBS= ../compat/lib/libcompat.a
PROG= restore
+RPROG= rrestore
LINKS= ${SBINDIR}/restore ${SBINDIR}/rrestore
SRCS= dirs.c interactive.c main.c restore.c symtab.c tape.c \
utilities.c
OBJS= dirs.o interactive.o main.o restore.o symtab.o tape.o \
utilities.o ../common/dumprmt.o
MAN8= restore.8
-MLINKS= $(MANDIR)/restore.8 $(MANDIR)/rrestore.8
+RMAN8= rrestore.8
-all:: $(PROG) restore.8
+all:: $(PROG) $(MAN8)
$(PROG): $(OBJS) $(DEPLIBS)
$(CC) $(CFLAGS) $(LDFLAGS) -o $(PROG) $(OBJS) $(LIBS)
-restore.8: restore.8.in
+$(MAN8): restore.8.in
sed -e "s|__DATE__|$(DATE)|g" \
-e "s|__VERSION__|$(VERSION)|g" $< > $@
$(INSTALL) -d $(SBINDIR) $(MANDIR)
$(INSTALLBIN) $(PROG) $(SBINDIR)
$(INSTALLMAN) $(srcdir)/$(MAN8) $(MANDIR)
- @set $(LINKS) $(MLINKS); \
- while test $$# -ge 2; do \
- l=$$1; \
- shift; \
- t=$$1; \
- shift; \
- echo $$t -\> $$l; \
- $(RM) -f $$t; \
- $(LN_S) $$l $$t; \
- done; true
+ cd $(SBINDIR) && $(RM) -f $(RPROG) && $(LN_S) $(PROG) $(RPROG)
+ cd $(MANDIR) && $(RM) -f $(RMAN8) && $(LN_S) $(MAN8) $(RMAN8)
clean::
- $(RM) -f $(PROG) \#* *.s *.o *.a *~ core restore.8
+ $(RM) -f $(PROG) $(MAN8) \#* *.s *.o *.a *~ core
distclean:: clean
$(RM) -f Makefile Makefile.old .depend
#ifndef lint
static const char rcsid[] =
- "$Id: tape.c,v 1.33 2001/04/11 13:42:52 stelian Exp $";
+ "$Id: tape.c,v 1.34 2001/04/12 16:03:30 stelian Exp $";
#endif /* not lint */
#include <config.h>
static char *decompress_tapebuf __P((struct tapebuf *, int));
static void msg_read_error __P((char *));
#endif
-static int read_a_block __P((int, void *, size_t, long *));
+static int read_a_block __P((int, char *, size_t, long *));
#define PREFIXSIZE sizeof(struct tapebuf)
#define COMPARE_ONTHEFLY 1
/*
* Read a block of data handling all of the messy details.
*/
-static int read_a_block(int fd, void *buf, size_t len, long *lengthread)
+static int read_a_block(int fd, char *buf, size_t len, long *lengthread)
{
long i = 1, size;