]> git.pld-linux.org Git - packages/syslog-ng.git/blame_incremental - syslog-ng.spec
- converted to UTF-8
[packages/syslog-ng.git] / syslog-ng.spec
... / ...
CommitLineData
1#
2# Conditional build:
3%bcond_with dynamic # link dynamically with glib and eventlog
4#
5%define mainver 2.0
6%define minver 2
7
8Summary: Syslog-ng - new generation of the system logger
9Summary(pl.UTF-8): Syslog-ng - zamiennik syskloga
10Summary(pt_BR.UTF-8): Daemon de log nova geração
11Name: syslog-ng
12Version: %{mainver}.%{minver}
13Release: 1
14License: GPL v2
15Group: Daemons
16Source0: http://www.balabit.com/downloads/syslog-ng/%{mainver}/src/%{name}-%{version}.tar.gz
17# Source0-md5: 7ef12e1e43a99c5b6b8d1984dde72151
18Source1: %{name}.init
19Source2: %{name}.conf
20Source3: %{name}.logrotate
21Patch0: %{name}-link.patch
22URL: http://www.balabit.com/products/syslog_ng/
23BuildRequires: autoconf >= 2.53
24BuildRequires: automake
25BuildRequires: bison
26BuildRequires: flex
27BuildRequires: libwrap-devel
28BuildRequires: pkgconfig
29BuildRequires: rpmbuild(macros) >= 1.268
30%if %{with dynamic}
31BuildRequires: eventlog-devel >= 0.2
32BuildRequires: glib2-devel >= 1:2.0.0
33%else
34BuildRequires: eventlog-static >= 0.2
35BuildRequires: glib2-static >= 1:2.0.0
36BuildRequires: glibc-static
37%endif
38Requires(post): fileutils
39Requires(post,preun): /sbin/chkconfig
40Requires: logrotate
41Requires: psmisc >= 20.1
42Requires: rc-scripts >= 0.2.0
43Provides: syslogdaemon
44Obsoletes: klogd
45Obsoletes: msyslog
46Obsoletes: syslog
47BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48
49%description
50syslog-ng is a syslogd replacement for unix and unix-like systems. It
51has been tested on Solaris, BSDi and Linux, and were found to run
52reliably. syslog-ng gives you a much enhanced configuration scheme,
53which lets you filter messages based on not only priority/facility
54pairs, but also on message content. You can use regexps to direct log
55stream to different destinations. A destination can be anything from a
56simple file to a network connection. syslog-ng supports TCP
57logforwarding, together with hashing to prevent unauthorized
58modification on the line.
59
60%description -l pl.UTF-8
61Syslog-ng jest zamiennikiem dla standardowo używanych programów typu
62sysklog. Działa w systemie SunOS, BSD, Linux. Daje znacznie większe
63możliwości logowania i kontrolowania zbieranych informacji.
64
65%description -l pt_BR.UTF-8
66Syslog-ng é um substituto para o syslog tradicional, mas com diversas
67melhorias, como, por exemplo, a habilidade de filtrar mensagens de log
68por seu conteúdo (usando expressões regulares) e não apenas pelo par
69facility/prioridade como o syslog original.
70
71%prep
72%setup -q
73%patch0 -p1
74
75%{__tar} xzf doc/reference/syslog-ng.html.tar.gz
76
77%build
78%{__aclocal}
79%{__autoconf}
80%{__automake}
81%configure \
82 --sysconfdir=%{_sysconfdir}/syslog-ng \
83%if %{with dynamic}
84 --enable-dynamic-linking
85%endif
86
87%{__make}
88
89%install
90rm -rf $RPM_BUILD_ROOT
91install -d $RPM_BUILD_ROOT{/etc/{sysconfig,logrotate.d,rc.d/init.d},%{_sysconfdir}/syslog-ng} \
92 $RPM_BUILD_ROOT/var/log
93
94%{__make} install \
95 DESTDIR=$RPM_BUILD_ROOT
96
97install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/syslog-ng
98install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/syslog-ng/syslog-ng.conf
99install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/syslog-ng
100
101for n in daemon debug iptables kernel lpr maillog messages secure spooler syslog user xferlog
102do
103 > $RPM_BUILD_ROOT/var/log/$n
104done
105touch $RPM_BUILD_ROOT/etc/sysconfig/%{name}
106
107%clean
108rm -rf $RPM_BUILD_ROOT
109
110%post
111for n in /var/log/{daemon,debug,iptables,kernel,lpr,maillog,messages,secure,spooler,syslog,user,xferlog}
112do
113 [ -f $n ] && continue
114 touch $n
115 chmod 640 $n
116done
117
118/sbin/chkconfig --add syslog-ng
119%service syslog-ng restart "syslog-ng daemon"
120
121%preun
122if [ "$1" = "0" ]; then
123 %service syslog-ng stop
124 /sbin/chkconfig --del syslog-ng
125fi
126
127%files
128%defattr(644,root,root,755)
129%doc doc/examples/syslog-ng.conf.sample doc/reference/syslog-ng.txt* contrib/syslog-ng.conf.{doc,RedHat}
130%doc syslog-ng.html/*
131%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name}
132%attr(750,root,root) %dir %{_sysconfdir}/syslog-ng
133%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/syslog-ng/syslog-ng.conf
134%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/syslog-ng
135%attr(754,root,root) /etc/rc.d/init.d/syslog-ng
136%attr(755,root,root) %{_sbindir}/syslog-ng
137%{_mandir}/man[58]/*
138
139%attr(640,root,root) %ghost /var/log/*
This page took 0.06684 seconds and 4 git commands to generate.