File multitail.spec of Package multitail
# vim: set ts=4 sw=4 et:
# Copyright (c) 2004-2010 oc2pus, pbleser
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
Name: multitail
Summary: Tail Multiple Files
Version: 5.2.9
Release: 0
Group: System/X11/Terminals
License: GPL-2.0+
URL: http://www.vanheusden.com/multitail/
Source: http://www.vanheusden.com/multitail/multitail-%{version}.tgz
Patch1: multitail-bufferoverflowstrncat.patch
Patch2: multitail-remove_date.patch
# PATCH-FIX-UPSTREAM multitail-getadddrinfo.patch - pascal.bleser@opensuse.org -- replaces IPv4 socket code with getaddrinfo which is more flexible, safe and supports IPv6, for sending to a syslog server and receiving syslog events in multitail
Patch3: multitail-getaddrinfo.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: ncurses-devel make gcc
%description
MultiTail lets you view one or multiple files like the original
tail program.
The difference is that it creates multiple windows on your console
(with ncurses). Merging of 2 or even more logfiles is possible.
It can also use colors while displaying the logfiles (through
regular expressions), for faster recognition of what is important
and what not. It can also filter lines (again with regular
expressions). It has interactive menus for editing given regular
expressions and deleting and adding windows. One can also have
windows with the output of shell scripts and other software. When
viewing the output of external software, MultiTail can mimic the
functionality of tools like 'watch' and such.
%prep
%setup -q
%patch1 -p1
%patch2
%patch3
%__sed -i 's/\r//g' manual.html
%__chmod 644 manual.html
%__sed -i 's|/etc/%{name}|%{_datadir}/%{name}|g' "%{name}.conf"
%build
export CFLAGS="%{optflags} -I%{_includedir}/ncurses"
%__make %{?_smp_mflags} DEBUG=""
%install
%__install -dm 755 %{buildroot}%{_sysconfdir}
%__install -m 644 %{name}.conf \
%{buildroot}%{_sysconfdir}
%__install -dm 755 %{buildroot}%{_bindir}
%__install -m 755 %{name} \
%{buildroot}%{_bindir}
%__install -dm 755 %{buildroot}%{_datadir}/%{name}
%__install -m 755 convert-* \
%{buildroot}%{_datadir}/%{name}
%__install -m 755 colors-* \
%{buildroot}%{_datadir}/%{name}
%__install -dm 755 %{buildroot}%{_mandir}/man1
%__install -m 644 %{name}.1 \
%{buildroot}%{_mandir}/man1
%clean
%{?buildroot:%__rm -rf "%{buildroot}"}
%files
%defattr(-, root, root)
%doc *.txt Changes manual*.html
%config(noreplace) %{_sysconfdir}/%{name}.conf
%dir %{_datadir}/multitail
%{_datadir}/multitail/*
%{_bindir}/multitail
%{_mandir}/man1/multitail.1%{ext_man}
%changelog