]> git.pld-linux.org Git - packages/syslog-ng.git/blob - syslog-ng.spec
- 1.4.11
[packages/syslog-ng.git] / syslog-ng.spec
1 Summary:        Syslog-ng - new generation fo the system logger
2 Summary(pl):    Syslog-ng - zamiennik sysklog'a
3 Name:           syslog-ng
4 Version:        1.4.11
5 Release:        1
6 License:        GPL
7 Group:          Daemons
8 Group(de):      Server
9 Group(pl):      Serwery
10 Source0:        http://www.balabit.hu/downloads/syslog-ng/1.4/%{name}-%{version}.tar.gz
11 Source1:        %{name}.init
12 Source2:        %{name}.conf
13 Source3:        %{name}.logrotate
14 Patch0:         %{name}-autoconf.patch
15 URL:            http://www.balabit.hu/products/syslog-ng/
16 BuildRequires:  autoconf
17 BuildRequires:  automake
18 BuildRequires:  libol-static >= 0.2.20
19 BuildRequires:  flex
20 Prereq:         rc-scripts >= 0.2.0
21 Requires:       logrotate
22 Requires:       fileutils
23 Provides:       syslogdaemon
24 Obsoletes:      syslog
25 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27 %define         _sysconfdir     /etc
28
29 %description
30 syslog-ng is a syslogd replacement for unix and unix-like systems. It
31 has been tested on Solaris, BSDi and Linux, and were found to run
32 reliably. syslog-ng gives you a much enhanced configuration scheme,
33 which lets you filter messages based on not only priority/facility
34 pairs, but also on message content. You can use regexps to direct log
35 stream to different destinations. A destination can be anything from a
36 simple file to a network connection. syslog-ng supports TCP
37 logforwarding, together with hashing to prevent unauthorized
38 modification on the line.
39
40 %description -l pl
41 Syslog-ng jest zamiennikiem dla standartowo u¿ywanych programów typu
42 sysklog Dzia³a w systemie SunON, BSD, Linux. Daje znacznie wiêksze
43 mo¿liwosci logowanie i kontrolowanie zbieranych informacji.
44
45 %prep
46 %setup -q
47 %patch -p1
48
49 %build
50 aclocal
51 autoconf
52 automake -a -c
53 %configure
54 %{__make}
55
56 %install
57 rm -rf $RPM_BUILD_ROOT
58 install -d $RPM_BUILD_ROOT{/etc/rc.d/init.d,%{_sysconfdir}/{syslog-ng,logrotate.d}} \
59         $RPM_BUILD_ROOT/var/log/{archiv,}/{news,mail}
60
61 %{__make} DESTDIR=$RPM_BUILD_ROOT install
62
63 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/syslog-ng
64 install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/syslog-ng/syslog-ng.conf
65 install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/syslog-ng
66
67 gzip -9nf doc/syslog-ng.conf.{demo,sample} doc/sgml/syslog-ng.txt \
68
69 touch $RPM_BUILD_ROOT/var/log/syslog
70
71 %post
72 for n in /var/log/{kernel,messages,secure,maillog,spooler,debug,cron,syslog,daemon,lpr,user,ppp,mail/{info,warn,err}}
73 do
74         [ -f $n ] && continue
75         touch $n
76         chmod 640 $n
77 done
78
79 /sbin/chkconfig --add syslog-ng
80 if [ -f /var/lock/subsys/syslog-ng ]; then
81         /etc/rc.d/init.d/syslog-ng restart &>/dev/null
82 else
83         echo "Run \"/etc/rc.d/init.d/syslog-ng start\" to start syslog-ng daemon."
84 fi
85 if [ -f /var/lock/subsys/klogd ]; then
86         /etc/rc.d/init.d/klogd restart 1>&2
87 fi
88
89 %preun
90 if [ "$1" = "0" ]; then
91         if [ -f /var/lock/subsys/syslog-ng ]; then
92                 /etc/rc.d/init.d/syslog-ng stop >&2
93         fi
94         /sbin/chkconfig --del syslog-ng
95 fi
96
97 %clean
98 rm -rf $RPM_BUILD_ROOT
99
100 %files
101 %defattr(644,root,root,755)
102 %doc doc/*.gz doc/sgml/syslog-ng.txt*
103 %attr(750,root,root) %dir %{_sysconfdir}/syslog-ng
104 %attr(640,root,root) %config %verify(not size mtime md5) %{_sysconfdir}/syslog-ng/syslog-ng.conf
105 %attr(640,root,root) %config %verify(not size mtime md5) %{_sysconfdir}/logrotate.d/syslog-ng
106 %attr(754,root,root) /etc/rc.d/init.d/syslog-ng
107 %attr(755,root,root) %{_sbindir}/syslog-ng
108 %{_mandir}/man[58]/*
109
110 %attr(640,root,root) %ghost /var/log/syslog
111 %attr(750,root,root) %ghost /var/log/news
112 %attr(750,root,root) %dir /var/log/mail
113 %attr(750,root,root) %dir /var/log/archiv/mail
This page took 0.087831 seconds and 4 git commands to generate.