diff -urN fwlogwatch-0.4.org/Makefile fwlogwatch-0.4/Makefile --- fwlogwatch-0.4.org/Makefile Thu Aug 30 14:00:03 2001 +++ fwlogwatch-0.4/Makefile Thu Aug 30 14:45:50 2001 @@ -1,8 +1,13 @@ # $Id$ +PREFIX=/usr +SBINDIR=$(PREFIX)/sbin +MANDIR=$(PREFIX)/man +SYSCONFDIR=/etc + # Linux CC = gcc -CFLAGS = -pipe -O2 -Wall #-pedantic #-g #-p +CFLAGS = $(OPT) -pipe -Wall -DSYSCONFDIR=\"$(SYSCONFDIR)\" LDFLAGS = #-g #-static -p LIBS = -lcrypt -lz #-lc_p @@ -66,14 +71,14 @@ $(CC) $(LDFLAGS) -o $@ $(OBJS) $(LIBS) install: all - $(INSTALL_PROGRAM) fwlogwatch /usr/local/sbin/fwlogwatch - $(INSTALL_SCRIPT) contrib/fwlw_notify /usr/local/sbin/fwlw_notify - $(INSTALL_SCRIPT) contrib/fwlw_respond /usr/local/sbin/fwlw_respond - $(INSTALL_DATA) fwlogwatch.8 /usr/local/man/man8/fwlogwatch.8 + $(INSTALL_PROGRAM) fwlogwatch $(DESTDIR)$(SBINDIR)/fwlogwatch + $(INSTALL_SCRIPT) contrib/fwlw_notify $(DESTDIR)$(SYSCONFDIR)/fwlw_notify + $(INSTALL_SCRIPT) contrib/fwlw_respond $(DESTDIR)$(SYSCONFDIR)/fwlw_respond + $(INSTALL_DATA) fwlogwatch.8 $(DESTDIR)$(MANDIR)/man8/fwlogwatch.8 install-config: - $(INSTALL_DATA) fwlogwatch.config /etc/fwlogwatch.config - $(INSTALL_DATA) fwlogwatch.template /etc/fwlogwatch.template + $(INSTALL_DATA) fwlogwatch.config $(DESTDIR)$(SYSCONFDIR)/fwlogwatch.config + $(INSTALL_DATA) fwlogwatch.template $(DESTDIR)$(SYSCONFDIR)/fwlogwatch.template uninstall: @rm -f /usr/local/sbin/fwlogwatch \ --- fwlogwatch-0.5.2/main.h.orig Sun Jan 27 19:17:42 2002 +++ fwlogwatch-0.5.2/main.h Tue Feb 19 08:04:49 2002 @@ -41,7 +41,7 @@ /* Files */ #define INFILE "/var/log/messages" -#define RCFILE "/etc/fwlogwatch.config" +#define RCFILE SYSCONFDIR "/fwlogwatch.config" /* Modes */ @@ -194,11 +194,11 @@ /* Interactive report mode */ #define CERT "[Insert address of abuse contact or CERT here]" -#define TEMPLATE "/etc/fwlogwatch.template" +#define TEMPLATE SYSCONFDIR "/fwlogwatch.template" #define FILENAME "fwlogwatchXXXXXX" #define INSERTREPORT "# insert report here" #define P_CAT "/bin/cat" -#define P_SENDMAIL "/usr/sbin/sendmail" +#define P_SENDMAIL "/usr/lib/sendmail" enum { OPT_NONE, @@ -210,8 +210,8 @@ #define ALERT 5 #define FORGET 86400 -#define FWLW_NOTIFY "/usr/local/sbin/fwlw_notify" -#define FWLW_RESPOND "/usr/local/sbin/fwlw_respond" +#define FWLW_NOTIFY SYSCONFDIR "/fwlw_notify" +#define FWLW_RESPOND SYSCONFDIR "/fwlw_respond" #define STATUS_TITLE _("fwlogwatch status") #define LISTENIF "127.0.0.1" #define LISTENPORT 888