Sophie

Sophie

distrib > Mandriva > 2009.0 > i586 > by-pkgid > b9f6f0a3629a315433cec278696d786b > files > 12

rsyslog-3.18.3-1mdv2009.0.src.rpm

%define _libdir /%{_lib}

Summary:	Enhanced system logging and kernel message trapping daemons
Name:		rsyslog
Version:	3.18.3
Release:	%mkrel 1
License:	GPLv3
Group:		System/Kernel and hardware
URL:		http://www.rsyslog.com/
Source0:	http://download.rsyslog.com/%{name}/%{name}-%{version}.tar.gz
Source1:	rsyslog.init
Source2:	rsyslog.sysconfig
Source3:	rsyslog.conf
Source4:	00_common.conf
Source5:	01_mysql.conf
Source6:	02_pgsql.conf
Source7:	03_gssapi.conf
Source8:	04_relp.conf
Source9:	05_dbi.conf
Source10:	06_snmp.conf
Source11:	sysklogd.conf
Patch0:		rsyslog-3.18.0-undef.patch
BuildRequires:	autoconf
BuildRequires:	automake
BuildRequires:	krb5-devel
BuildRequires:	libdbi-devel
BuildRequires:	libtool
BuildRequires:	mysql-devel >= 4.0
BuildRequires:	net-snmp-devel
BuildRequires:	pkgconfig
BuildRequires:	postgresql-devel
BuildRequires:	relp-devel
BuildRequires:	zlib-devel
Requires:	logrotate
Provides:       syslog-daemon
Requires(post):	rpm-helper
Requires(preun):rpm-helper
#Provides:	sysklogd = 1.4.3-1
#Obsoletes:	sysklogd < 1.4.3-1
Conflicts:	logrotate < 3.5.2
Buildroot:	%{_tmppath}/%{name}-%{version}-%{release}-buildroot

%description
Rsyslog is an enhanced multi-threaded syslogd supporting, among others, MySQL,
PostgreSQL, syslog/tcp, RFC 3195, permitted sender lists, filtering on any
message part, and fine grain output format control. It is quite compatible to
stock sysklogd and can be used as a drop-in replacement. Its advanced features
make it suitable for enterprise-class, encryption protected syslog relay chains
while  at the same time being very easy to setup for the novice user.

 o lmnet.so    - Implementation of network related stuff.
 o lmregexp.so - Implementation of regexp related stuff.
 o lmtcpclt.so - This is the implementation of TCP-based syslog clients.
 o lmtcpsrv.so - Common code for plain TCP based servers.
 o imtcp.so    - This is the implementation of the TCP input module.
 o imudp.so    - This is the implementation of the UDP input module.
 o imuxsock.so - This is the implementation of the Unix sockets input module.
 o imklog.so   - The kernel log input module for Linux.
 o immark.so   - This is the implementation of the build-in mark message input
                 module.
 o imfile.so - This is the input module for reading text file data.

%package	mysql
Summary:	MySQL support for rsyslog
Group:		System/Kernel and hardware
Requires:	%{name} = %{version}-%{release}

%description	mysql
The rsyslog-mysql package contains a dynamic shared object that will add
MySQL database support to rsyslog.

 o ommysql.so - This is the implementation of the build-in output module for
                MySQL.

%package	pgsql
Summary:	PostgreSQL support for rsyslog
Group:		System/Kernel and hardware
Requires:	%{name} = %{version}-%{release}

%description	pgsql
The rsyslog-pgsql package contains a dynamic shared object that will add
PostgreSQL database support to rsyslog.

 o ompgsql.so - This is the implementation of the build-in output module for
                PgSQL.

%package	gssapi
Summary:	GSS-API support for rsyslog
Group:		System/Kernel and hardware
Requires:	%{name} = %{version}-%{release}

%description	gssapi
The rsyslog-gssapi package contains dynamic shared objects that will add
GSS-API support to rsyslog.

 o lmgssutil.so - This is a miscellaneous helper class for gss-api features.
 o imgssapi.so  - This is the implementation of the GSSAPI input module.
 o omgssapi.so  - This is the implementation of the build-in forwarding output
                  module.

%package	relp
Summary:	RELP support for rsyslog
Group:		System/Kernel and hardware
Requires:	%{name} = %{version}-%{release}

%description	relp
The rsyslog-relp package contains a dynamic shared object that will add
RELP support to rsyslog.

 o imrelp.so - This is the implementation of the RELP input module.
 o omrelp.so - This is the implementation of the RELP output module.

%package	dbi
Summary:	Dbi support for rsyslog
Group:		System/Kernel and hardware
Requires:	%{name} = %{version}-%{release}

%description	dbi
The rsyslog-dbi package contains a dynamic shared object that will add
dbi driver support to rsyslog.

 o omlibdbi.so - This is the implementation of the dbi output module.

%package	snmp
Summary:	SNMP support for rsyslog
Group:		System/Kernel and hardware
Requires:	%{name} = %{version}-%{release}

%description	snmp
The rsyslog-snmp package contains a dynamic shared object that will add
SNMP support to rsyslog.

 o omsnmp.so - This module sends an snmp trap.

%package	docs
Summary:	HTML documentation for rsyslog
Group:		System/Kernel and hardware

%description	docs
This package contains the HTML documentation for rsyslog.

%prep

%setup -q
%patch0 -p1

mkdir -p Mandriva
cp %{SOURCE1} Mandriva/rsyslog.init
cp %{SOURCE2} Mandriva/rsyslog.sysconfig
cp %{SOURCE3} Mandriva/rsyslog.conf
cp %{SOURCE4} Mandriva/00_common.conf
cp %{SOURCE5} Mandriva/01_mysql.conf
cp %{SOURCE6} Mandriva/02_pgsql.conf
cp %{SOURCE7} Mandriva/03_gssapi.conf
cp %{SOURCE8} Mandriva/04_relp.conf
cp %{SOURCE9} Mandriva/05_dbi.conf
cp %{SOURCE10} Mandriva/06_snmp.conf
cp %{SOURCE11} Mandriva/syslog.conf

%build
%serverbuild

%configure2_5x \
    --disable-static \
    --sbindir=/sbin \
    --enable-largefile \
    --enable-regexp \
    --enable-zlib \
    --enable-gssapi-krb5 \
    --enable-pthreads \
    --enable-klog \
    --enable-inet \
    --enable-mysql \
    --enable-pgsql \
    --enable-libdbi \
    --enable-snmp \
    --enable-rsyslogd \
    --enable-mail \
    --enable-relp \
    --enable-imfile \
    --enable-imtemplate

%make

%install
rm -rf %{buildroot}

%makeinstall_std

install -d -m 755 %{buildroot}%{_initrddir}
install -d -m 755 %{buildroot}%{_sysconfdir}/sysconfig
install -d -m 755 %{buildroot}%{_sysconfdir}/logrotate.d
install -d -m 755 %{buildroot}%{_sysconfdir}/rsyslog.d

install -p -m 755 Mandriva/rsyslog.init %{buildroot}%{_initrddir}/rsyslog
install -p -m 644 Mandriva/rsyslog.conf %{buildroot}%{_sysconfdir}/rsyslog.conf
install -p -m 644 Mandriva/syslog.conf %{buildroot}%{_sysconfdir}/syslog.conf
install -p -m 644 redhat/rsyslog.log %{buildroot}%{_sysconfdir}/logrotate.d/rsyslog
install -p -m 644 Mandriva/rsyslog.sysconfig %{buildroot}/%{_sysconfdir}/sysconfig/rsyslog
install -p -m 644 Mandriva/*_*.conf %{buildroot}%{_sysconfdir}/rsyslog.d/

#get rid of *.la
rm %{buildroot}/%{_libdir}/rsyslog/*.la

# cleanup
rm -f %{buildroot}%{_libdir}/rsyslog/imtemplate.so

# fix html docs
rm -rf html_docs; mkdir -p html_docs
cp doc/*.html doc/*.jpg html_docs/
chmod 644 html_docs/*

%post
%_post_service rsyslog

for n in /var/log/{messages,secure,maillog,spooler}; do
    [ -f $n ] && continue
    umask 066 && touch $n
done

if [ "$1" = 0 ]; then
    # use sysklogd configuration file
    if [ -f /etc/sysconfig/syslog ]; then
        mv -f /etc/sysconfig/rsyslog /etc/sysconfig/rsyslog.rpmnew
        cp /etc/sysconfig/syslog /etc/sysconfig/rsyslog
    fi
fi

%triggerpostun -- rsyslog < 2.0.1-2mdv2008.1
if [ ! -f /etc/syslog.conf ]; then
    # restore syslog.conf
    mv -f /etc/rsyslog.conf /etc/syslog.conf
    mv -f /etc/rsyslog.conf.rpmnew /etc/rsyslog.conf
fi

%triggerun -- rsyslog < 3.0.0
/bin/kill `cat /var/run/rklogd.pid 2> /dev/null` > /dev/null 2>&1 ||:

%preun
%_preun_service rsyslog

%postun
if [ "$1" -ge "1" ]; then
    %{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :
fi	

%post mysql
%{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :

%preun mysql
if [ "$1" = 0 ]; then
    %{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :
fi

%post pgsql
%{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :

%preun pgsql
if [ "$1" = 0 ]; then
    %{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :
fi

%post gssapi
%{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :

%preun gssapi
if [ "$1" = 0 ]; then
    %{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :
fi

%post relp
%{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :

%preun relp
if [ "$1" = 0 ]; then
    %{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :
fi

%post dbi
%{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :

%preun dbi
if [ "$1" = 0 ]; then
    %{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :
fi

%post snmp
%{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :

%preun snmp
if [ "$1" = 0 ]; then
    %{_initrddir}/rsyslog condrestart > /dev/null 2>/dev/null || :
fi

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root)
%doc AUTHORS NEWS README  doc/rsyslog-example.conf
%{_initrddir}/rsyslog
%config(noreplace) %{_sysconfdir}/rsyslog.conf
%config(noreplace) %{_sysconfdir}/syslog.conf
%config(noreplace) %{_sysconfdir}/sysconfig/rsyslog
%config(noreplace) %{_sysconfdir}/logrotate.d/rsyslog
%dir %{_sysconfdir}/rsyslog.d
%config(noreplace) %{_sysconfdir}/rsyslog.d/*_common.conf
/sbin/rsyslogd
%dir %{_libdir}/rsyslog
%{_libdir}/rsyslog/imfile.so
%{_libdir}/rsyslog/imklog.so
%{_libdir}/rsyslog/immark.so
%{_libdir}/rsyslog/imtcp.so
%{_libdir}/rsyslog/imudp.so
%{_libdir}/rsyslog/imuxsock.so
%{_libdir}/rsyslog/lmnet.so
%{_libdir}/rsyslog/lmregexp.so
%{_libdir}/rsyslog/lmtcpclt.so
%{_libdir}/rsyslog/lmtcpsrv.so
%{_libdir}/rsyslog/omtesting.so
%{_libdir}/rsyslog/ommail.so
%{_mandir}/*/*

%files mysql
%defattr(-,root,root)
%doc plugins/ommysql/createDB.sql plugins/ommysql/contrib/delete_mysql
%config(noreplace) %{_sysconfdir}/rsyslog.d/*_mysql.conf
%{_libdir}/rsyslog/ommysql.so

%files pgsql
%defattr(-,root,root)
%doc plugins/ompgsql/createDB.sql
%config(noreplace) %{_sysconfdir}/rsyslog.d/*_pgsql.conf
%{_libdir}/rsyslog/ompgsql.so

%files gssapi
%defattr(-,root,root)
%config(noreplace) %{_sysconfdir}/rsyslog.d/*_gssapi.conf
%{_libdir}/rsyslog/omgssapi.so
%{_libdir}/rsyslog/imgssapi.so
%{_libdir}/rsyslog/lmgssutil.so

%files relp
%defattr(-,root,root)
%config(noreplace) %{_sysconfdir}/rsyslog.d/*_relp.conf
%{_libdir}/rsyslog/imrelp.so
%{_libdir}/rsyslog/omrelp.so

%files dbi
%defattr(-,root,root)
%config(noreplace) %{_sysconfdir}/rsyslog.d/*_dbi.conf
%{_libdir}/rsyslog/omlibdbi.so

%files snmp
%defattr(-,root,root)
%config(noreplace) %{_sysconfdir}/rsyslog.d/*_snmp.conf
%{_libdir}/rsyslog/omsnmp.so

%files docs
%defattr(-,root,root)
%doc html_docs/*


%changelog
* Mon Aug 18 2008 Frederik Himpe <fhimpe@mandriva.org> 3.18.3-1mdv2009.0
+ Revision: 273386
- update to new version 3.18.3

* Wed Aug 13 2008 Frederik Himpe <fhimpe@mandriva.org> 3.18.2-1mdv2009.0
+ Revision: 271579
- update to new version 3.18.2

* Tue Jul 22 2008 Funda Wang <fundawang@mandriva.org> 3.18.1-1mdv2009.0
+ Revision: 239940
- New version 3.18.1

* Sat Jul 19 2008 Oden Eriksson <oeriksson@mandriva.com> 3.18.0-1mdv2009.0
+ Revision: 238712
- added the mail plugin feature
- added the sysklogd.conf file from the sysklogd package

* Sat Jul 12 2008 Tomasz Pawel Gajc <tpg@mandriva.org> 3.18.0-0.1mdv2009.0
+ Revision: 234124
- Patch0: rediff
- update to new version 3.18.0
- new license policy
- do not package COPYING and INSTALL files

* Sat May 03 2008 Oden Eriksson <oeriksson@mandriva.com> 3.16.1-0.1mdv2009.0
+ Revision: 200689
- 3.16.1
- sync with rsyslog-3.14.1-2.fc9.src.rpm
- fix order in S3
- added S4-S10 to take advantage of the new modular design
- fix descriptions
- added the relp, dbi and snmp sub packages
- fix %%post and %%preun script for the modules
- put the modules in /%%{_lib}/rsyslog/ to avoid future problems
  if /usr for some reason should not be mounted at boot...

* Mon Jan 28 2008 Olivier Blin <oblin@mandriva.com> 2.0.1-2mdv2008.1
+ Revision: 159377
- create /etc/rsyslog.d and include /etc/rsyslog.d/*.conf from rsyslog.conf
- restore syslog.conf on upgrade of previous rsyslog package
- include syslog.conf in rsyslog.conf instead of moving the file, to ease cohabitation of sysklogd and rsyslog packages
- do not remove original /etc/sysconfig/syslog
- migrate sysklogd configuration files in initial installation only

* Thu Jan 24 2008 Oden Eriksson <oeriksson@mandriva.com> 2.0.1-1mdv2008.1
+ Revision: 157600
- 2.0.1 (3.x.x is the unstable branch)

  + Olivier Blin <oblin@mandriva.com>
    - 3.10.2

* Wed Jan 02 2008 Oden Eriksson <oeriksson@mandriva.com> 2.0.0-1mdv2008.1
+ Revision: 140614
- 2.0.0

* Sat Dec 29 2007 Oden Eriksson <oeriksson@mandriva.com> 1.21.2-1mdv2008.1
+ Revision: 139317
- 1.21.2

* Mon Dec 24 2007 Oden Eriksson <oeriksson@mandriva.com> 1.21.1-1mdv2008.1
+ Revision: 137430
- 1.21.1

* Wed Dec 19 2007 Oden Eriksson <oeriksson@mandriva.com> 1.21.0-1mdv2008.1
+ Revision: 134359
- 1.21.0
- enable all features

  + Thierry Vignaud <tvignaud@mandriva.com>
    - kill re-definition of %%buildroot on Pixel's request

* Thu Dec 13 2007 Oden Eriksson <oeriksson@mandriva.com> 1.20.1-1mdv2008.1
+ Revision: 119281
- 1.20.1

* Fri Dec 07 2007 Oden Eriksson <oeriksson@mandriva.com> 1.20.0-1mdv2008.1
+ Revision: 116322
- 1.20.0

* Mon Dec 03 2007 Oden Eriksson <oeriksson@mandriva.com> 1.19.12-1mdv2008.1
+ Revision: 114551
- 1.19.12

* Thu Nov 22 2007 Oden Eriksson <oeriksson@mandriva.com> 1.19.10-1mdv2008.1
+ Revision: 111227
- import rsyslog


* Thu Nov 22 2007 Oden Eriksson <oeriksson@mandriva.com> 1.19.10-1mdv2008.1
- initial Mandriva package (fedora import)

* Wed Oct 03 2007 Peter Vrabec <pvrabec@redhat.com> 1.19.6-3
- remove NUL character from recieved messages

* Tue Sep 25 2007 Tomas Heinrich <theinric@redhat.com> 1.19.6-2
- fix message suppression (303341)

* Tue Sep 25 2007 Tomas Heinrich <theinric@redhat.com> 1.19.6-1
- upstream bugfix release

* Tue Aug 28 2007 Peter Vrabec <pvrabec@redhat.com> 1.19.2-1
- upstream bugfix release
- support for negative app selector, patch from 
  theinric@redhat.com

* Fri Aug 17 2007 Peter Vrabec <pvrabec@redhat.com> 1.19.0-1
- new upstream release with MySQL support(as plugin)

* Wed Aug 08 2007 Peter Vrabec <pvrabec@redhat.com> 1.18.1-1
- upstream bugfix release

* Mon Aug 06 2007 Peter Vrabec <pvrabec@redhat.com> 1.18.0-1
- new upstream release

* Thu Aug 02 2007 Peter Vrabec <pvrabec@redhat.com> 1.17.6-1
- upstream bugfix release

* Mon Jul 30 2007 Peter Vrabec <pvrabec@redhat.com> 1.17.5-1
- upstream bugfix release
- fix typo in provides 

* Wed Jul 25 2007 Jeremy Katz <katzj@redhat.com> - 1.17.2-4
- rebuild for toolchain bug

* Tue Jul 24 2007 Peter Vrabec <pvrabec@redhat.com> 1.17.2-3
- take care of sysklogd configuration files in %%post

* Tue Jul 24 2007 Peter Vrabec <pvrabec@redhat.com> 1.17.2-2
- use EVR in provides/obsoletes sysklogd

* Mon Jul 23 2007 Peter Vrabec <pvrabec@redhat.com> 1.17.2-1
- upstream bug fix release

* Fri Jul 20 2007 Peter Vrabec <pvrabec@redhat.com> 1.17.1-1
- upstream bug fix release
- include html docs (#248712)
- make "-r" option compatible with sysklogd config (248982)

* Tue Jul 17 2007 Peter Vrabec <pvrabec@redhat.com> 1.17.0-1
- feature rich upstream release

* Thu Jul 12 2007 Peter Vrabec <pvrabec@redhat.com> 1.15.1-2
- use obsoletes and hadle old config files

* Wed Jul 11 2007 Peter Vrabec <pvrabec@redhat.com> 1.15.1-1
- new upstream bugfix release

* Tue Jul 10 2007 Peter Vrabec <pvrabec@redhat.com> 1.15.0-1
- new upstream release introduce capability to generate output 
  file names based on templates

* Tue Jul 03 2007 Peter Vrabec <pvrabec@redhat.com> 1.14.2-1
- new upstream bugfix release

* Mon Jul 02 2007 Peter Vrabec <pvrabec@redhat.com> 1.14.1-1
- new upstream release with IPv6 support

* Tue Jun 26 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.5-3
- add BuildRequires for  zlib compression feature

* Mon Jun 25 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.5-2
- some spec file adjustments.
- fix syslog init script error codes (#245330)

* Fri Jun 22 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.5-1
- new upstream release

* Fri Jun 22 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.4-2
- some spec file adjustments.

* Mon Jun 18 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.4-1
- upgrade to new upstream release

* Wed Jun 13 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.2-2
- DB support off

* Tue Jun 12 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.2-1
- new upstream release based on redhat patch

* Fri Jun 08 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.1-2
- rsyslog package provides its own kernel log. daemon (rklogd)

* Mon Jun 04 2007 Peter Vrabec <pvrabec@redhat.com> 1.13.1-1
- Initial rpm build