Commit ed3b33d9 authored by Axel Beckert's avatar Axel Beckert

Imported Upstream version 0.3

parent 064d459d
Installation Instructions
-------------------------
Since has only been tested under linux/i386. Other systems which
use the same types in the fields returned by stat(2) should
be able to use since without porting. Otherwise you might
have to hack things.
To build the executable type:
Installation instructions: Su to root and type:
make
To copy the executable and manual page, become root and type:
make install
Will compile the since binary and add the following files to
your system:
The default locations are:
/usr/local/bin/since
/usr/local/man/man1/since.1
/usr/local/bin/since
/usr/local/man/man1/since.1
###########################################################################
# Files ###################################################################
NAME = since
VERSION = 0.3
SRC = $(NAME).c
OBJ = $(NAME).o
TARGET = $(NAME)
MAN = $(NAME).1
ARCHIVE = $(NAME)-$(VERSION).tar.gz
LSM = $(NAME)-$(VERSION).lsm
INTARGET = /usr/local/bin/$(TARGET)
INMAN = /usr/local/man/man1/$(MAN)
###########################################################################
# Compiler and Flags ######################################################
CC = gcc
CFLAGS = -Wall -fomit-frame-pointer
CFLAGS = -Wall -O2 -fomit-frame-pointer -DVERSION=\"$(VERSION)\"
STRIP = strip
#CFLAGS += -DTRACE
......@@ -12,29 +27,12 @@ STRIP = strip
###########################################################################
# Auxillary Programs ######################################################
LN = ln
LNFLAGS = -s
RM = rm
RMFLAGS = -f
RM = rm -f
INSTALL = install -c
LINK = ln -s
TOUCH = touch
CP = cp
CHMOD = chmod
TAR = tar
CI = ci
CO = co
###########################################################################
# Files ###################################################################
SRC = since.c
OBJ = since.o
TARGET = since
MAN = since.1
INTARGET = /usr/local/bin/since
INMAN = /usr/local/man/man1/since.1
MKLSM = ./mklsm
###########################################################################
# Generic build all #######################################################
......@@ -45,10 +43,8 @@ all : $(TARGET)
# Install #################################################################
install : $(TARGET)
$(CP) $(TARGET) $(INTARGET)
$(CHMOD) 755 $(INTARGET)
$(CP) $(MAN) $(INMAN)
$(CHMOD) 755 $(INMAN)
$(INSTALL) -m 0755 $(TARGET) $(INTARGET)
$(INSTALL) -m 0644 $(MAN) $(INMAN)
###########################################################################
# Build since executable ##################################################
......@@ -64,18 +60,20 @@ $(TARGET) : $(OBJ)
$(CC) $(CFLAGS) -c $*.c
###########################################################################
# Transport - zip the entire thing ########################################
# Generate a package ready for distribution ###############################
transport :
$(TOUCH) -t 01010000 *
$(TOUCH) -t 01010001 since.c
$(TAR) czvf since-0.1.tar.gz since-0.1/$(SRC) since-0.1/$(MAN) since-0.1/$(TARGET) since-0.1/Makefile since-0.1/README since-0.1/INSTALL since-0.1/COPYING since-0.1/since-0.1.lsm
package :
$(TOUCH) $(SRC)
$(RM) $(NAME)-$(VERSION)
$(LINK) . $(NAME)-$(VERSION)
$(TAR) czvf $(ARCHIVE) $(NAME)-$(VERSION)/{$(SRC),$(MAN),$(TARGET),Makefile,README,INSTALL,COPYING}
$(MKLSM) $(NAME) $(VERSION)
###########################################################################
# Remove intermediate files ###############################################
clean :
$(RM) $(RMFLAGS) *.o core
$(RM) *.o core $(NAME)-$(VERSION)
reallyclean : clean
$(RM) $(RMFLAGS) $(TARGET)
$(RM) $(TARGET) $(ARCHIVE)
since
-----
since 0.1
Read INSTALL for installation instructions.
since is like tail(1) with state - it allows the user to
since is a tail(1) with state - it allows the user to
view only the lines appended to a log file since the last
time since was used.
read INSTALL for installation instructions.
To understand how it works run the commands:
make
echo "First line" >> testlogfile
./since testlogfile
echo "Second line" >> testlogfile
./since testlogfile
rm testlogfile
You might want to set up the following alias:
alias dosince='since /var/log/messages /var/log/xferlog'
since is released under the terms of the GNU public
license. Click accept now... errr... sorry... just
look at COPYING.
since was hacked in half a day. So unlikely to be
bugfree. But it works for me.
File added
Begin3
Title: since
Version: 0.1
Entered-date: 11JUL98
Description: Tail(1) with state. It allows the user to
view only the data appended to log files
since the last time.
Keywords: tail log viewer
Platforms: linux
Copying-policy: GPL
End
......@@ -24,7 +24,7 @@ is useful for watching over log files.
.SH EXAMPLE USAGE
.B since -v /var/log/xferlog | less
(type the command, then ftp something from localhost,
then type the command again)
then type the command again).
.SH OPTIONS
.IP -h
Print a terse help message.
......@@ -66,9 +66,12 @@ will use the file
.RE
.SH BUGS
.B since
will break when used across NFS on architectures which have different
st_* field sizes.
.B since
uses the inode of a file as its key, if that inode is recycled
.B since
might get confused.
might get confused.
.B since
is not particularly efficient when storing the
.BI stat()
......@@ -81,7 +84,7 @@ shell scripts.
.B since
may only be used, distributed and modified in accordance with
the terms of the
.B GPL (GNU Public License)
.B GPL (GNU General Public License)
as published by the
.B FSF (Free Software Foundation).
.SH "SEE ALSO"
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment