]> git.pld-linux.org Git - packages/autolog.git/blob - autolog.spec
- fix improper usage of %%{_sysconfdir}
[packages/autolog.git] / autolog.spec
1 Summary:        Terminates connections for idle users
2 Summary(pl):    Przerywa po³±czenia bezczynnych u¿ytkowników
3 Name:           autolog
4 Version:        0.40
5 Release:        1
6 License:        GPL
7 Group:          Daemons
8 Source0:        ftp://sunsite.unc.edu/pub/Linux/system/Admin/idle/%{name}-%{version}.tar.gz
9 Source1:        %{name}.init
10 Prereq:         /sbin/chkconfig
11 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
12
13 %description
14 Autolog is a program to automatically log off users who are idle for a
15 specified amount of time. A configuration file allows you to specify
16 different idle times and logout rules for different users, groups, tty
17 lines, etc.
18
19 %description -l pl
20 Autolog to program automatycznie wylogowuj±cy u¿ytkowników, którzy nie
21 korzystaj± przez okre¶lony czas z terminala. Plik konfiguracyjny
22 pozwala na okre¶lenie czasów oraz regu³ postêpowania dla ró¿nych
23 u¿ytkowników, grup, linii tty itp.
24
25 %prep
26 %setup -q
27
28 %build
29 # Remove stale binaries
30 %{__make} clean
31
32 %{__make} CFLAGS="%{rpmcflags}"
33
34 %install
35 rm -rf $RPM_BUILD_ROOT
36 install -d $RPM_BUILD_ROOT{%{_sbindir},%{_mandir}/man{5,8},/etc/rc.d/init.d}
37
38 install autolog $RPM_BUILD_ROOT%{_sbindir}
39 install autolog.conf $RPM_BUILD_ROOT%{_sysconfdir}
40 install autolog.8.gz $RPM_BUILD_ROOT%{_mandir}/man8
41 install autolog.conf.5.gz $RPM_BUILD_ROOT%{_mandir}/man5
42 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
43
44 %clean
45 rm -rf $RPM_BUILD_ROOT
46
47 %post
48 /sbin/chkconfig --add autolog
49 if [ -f /var/lock/subsys/autolog ]; then
50         /etc/rc.d/init.d/autolog restart >&2
51 else
52         echo "Run \"/etc/rc.d/init.d/autolog start\" to activate autolog."
53 fi
54
55 %preun
56 if [ "$1" = "0" ]; then
57         if [ -f /var/lock/subsys/autolog ]; then
58                 /etc/rc.d/init.d/autolog stop >&2
59         fi
60         /sbin/chkconfig --del autolog
61 fi
62
63 %files
64 %defattr(644,root,root,755)
65 %doc README CHANGES
66 %attr(755,root,root) %{_sbindir}/%{name}
67 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/autolog.conf
68 %attr(754,root,root) /etc/rc.d/init.d/%{name}
69 %{_mandir}/man?/*
This page took 0.066421 seconds and 3 git commands to generate.