File tailbeep.spec of Package tailbeep

# norootforbuild

Name:				 tailbeep
Version:			 0.46
Release:			 0
Summary:			 Log File Monitoring and Alerting Tool
Source:			 http://soomka.com/tailbeep-%{version}.tar.gz
URL:				 http://soomka.com/
Group:			 System/Monitoring
License:			 GNU General Public License version 2 or later (GPL v2 or later)
BuildRoot:		 %{_tmppath}/build-%{name}-%{version}
BuildRequires:	 gcc make glibc-devel

%description
Tailbeep opens a file (-f), seeks to the end, and watches for a string (-s). If
the string is found, a beep is sent to the specified tty (-t) device. You can
also daemonize (-d) it. It was written to watch... /var/log/messages for the
DENY string (to catch anyone trying to break into a firewall), but you can use
it to watch any open file that gets appended to. You can also create a log if
you like, so you can record the events, in long or short mode. Tailbeep
requires write access to one of the tty devices on the console.

%prep
%setup -q
%__chmod 0644 *

%build
%__make %{?jobs:-j%{jobs}} \
	CC="%__cc" \
	CFLAGS="%{optflags} -Wall"

%install
%__install -D -m0755 tailbeep "%{buildroot}%{_bindir}/tailbeep"

%__install -d examples
%__mv *.example.sh ./examples/
%__chmod 0644 ./examples/*
%__sed -i 's|/usr/local/bin/||g' examples/*.sh

%clean
%__rm -rf "%{buildroot}"

%files
%defattr(-,root,root)
%doc CHANGES COPYING README
%doc examples
%{_bindir}/tailbeep

%changelog
# vim: set sw=3 ts=3 noet:
# Local Variables:
# mode: rpm-spec
# tab-width: 3
# End: