File daemontools.spec of Package daemontools

#
# Spec file for package daemontools (Version 0.76)
#
# Copyright (c) 2008-2009 Exata T.I., Maringa, PR, Brasil,
#               2008-2009, Weberhofer GmbH, Austria.
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#
# Please submit bugfixes or comments via http://bugs.opensuse.org
#

# norootforbuild

Name:           daemontools
Version:        0.76
Release:        1
License:        Public Domain
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Obsoletes:      %{name}-toaster %{name}-toaster-doc
Provides:       %{name}-toaster
Group:          System/Base
Summary:        DJB daemontools - tools for managing UNIX services
URL:            http://cr.yp.to/daemontools.html
Source:         %{name}-%{version}.tar.bz2
Source1:        %{name}-%{version}-man.tar.bz2
Patch:          %{name}-errno.patch
Patch1:         %{name}-no-return.patch
Patch2:         fix_includes_prototypes.patch


%description
Supervise monitors a service. It starts the service and restarts the
service if it dies.  The companion  svc program  stops,  pauses,  or
restarts the service on sysadmin request.  The svstat program prints
a one-line status report.

Multilog saves error  messages to  one or more  logs.  It optionally
timestamps each line and,  for each log,  includes or excludes lines
matching specified patterns.  It automatically rotates logs to limit
the amount of disk space used.   If the disk fills up, it pauses and
tries again, without losing any data.

Author:
--------
    D. J. Bernstein


%prep
%setup -q -a 1
%patch
%patch1
%patch2


%build
cd src
echo 'cc %{optflags}' > conf-cc
echo 'cc -s %{optflags}' > conf-ld
echo %{buildroot}/%{_prefix} > home
%{__make}


%install
%{__install} -d %{buildroot}%{_bindir}
pushd src
    for BFILE in envdir envuidgid fghack multilog pgrphack readproctitle setlock setuidgid softlimit supervise svc svok svscan svscanboot svstat tai64n tai64nlocal
    do
        %{__install} -m 755 $BFILE %{buildroot}%{_bindir}
    done
popd

%{__install} -d %{buildroot}%{_mandir}/man8
%{__install} -m 644 %{name}-%{version}-man/*8 %{buildroot}%{_mandir}/man8


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


%files
%defattr(0755,root,root)
%{_bindir}/envdir
%{_bindir}/envuidgid
%{_bindir}/fghack
%{_bindir}/multilog
%{_bindir}/pgrphack
%{_bindir}/readproctitle
%{_bindir}/setlock
%{_bindir}/setuidgid
%{_bindir}/softlimit
%{_bindir}/supervise
%{_bindir}/svc
%{_bindir}/svok
%{_bindir}/svscan
%{_bindir}/svscanboot
%{_bindir}/svstat
%{_bindir}/tai64n
%{_bindir}/tai64nlocal

%defattr(0644,root,root,0755)
%doc src/CHANGES %doc package/README %doc src/TODO
%{_mandir}/man8/envdir.8.*
%{_mandir}/man8/envuidgid.8.*
%{_mandir}/man8/fghack.8.*
%{_mandir}/man8/multilog.8.*
%{_mandir}/man8/pgrphack.8.*
%{_mandir}/man8/readproctitle.8.*
%{_mandir}/man8/setlock.8.*
%{_mandir}/man8/setuidgid.8.*
%{_mandir}/man8/softlimit.8.*
%{_mandir}/man8/supervise.8.*
%{_mandir}/man8/svc.8.*
%{_mandir}/man8/svok.8.*
%{_mandir}/man8/svscan.8.*
%{_mandir}/man8/svscanboot.8.*
%{_mandir}/man8/svstat.8.*
%{_mandir}/man8/tai64n.8.*
%{_mandir}/man8/tai64nlocal.8.*

%changelog
openSUSE Build Service is sponsored by