%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} Name: libpreludedb Version: 0.9.11.1 Release: 1%{?dist} Summary: Provide the framework for easy access to the Prelude database Group: System Environment/Libraries License: GPL URL: http://prelude-ids.org/ Source0: http://prelude-ids.org/download/releases/%{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Patch0: %{name}-x86_64-sqlite3.patch BuildRequires: libprelude, libprelude-devel, mysql-devel, postgresql-devel, python-devel, sqlite-devel %description The PreludeDB Library provides an abstraction layer upon the type and the format of the database used to store IDMEF alerts. It allows developers to use the Prelude IDMEF database easily and efficiently wi thout worrying about SQL, and to access the database independently of the type/format of the database. %package devel Summary: Libraries and headers for PreludeDB Group: System Environment/Libraries Requires: libpreludedb = %{version}-%{release}, libprelude-devel, automake %description devel The PreludeDB Library provides an abstraction layer upon the type and the format of the database used to store IDMEF alerts. It allows developers to use the Prelude IDMEF database easily and efficiently wi thout worrying about SQL, and to access the database independently of the type/format of the database. %package mysql Summary: Plugin to use prelude with a mysql database Group: System Environment/Libraries Requires: libpreludedb = %{version}-%{release}, mysql, mysql-server %description mysql This plugin authorise prelude to store alerts into a mysql database. %package pgsql Summary: Plugin to use prelude with a pgsql database Group: System Environment/Libraries Requires: libpreludedb = %{version}-%{release}, postgresql-server %description pgsql This plugin authorise prelude to store alerts into a pgsql database. %package sqlite Summary: Plugin to use prelude with a sqlite database Group: System Environment/Libraries Requires: libpreludedb = %{version}-%{release}, sqlite %description sqlite This plugin authorise prelude to store alerts into a sqlite database. %package python Summary: Python bindings for libpreludedb Group: System Environment/Libraries Requires: libpreludedb = %{version}-%{release} %description python Python bindings for libpreludedb. %package perl Summary: Perl bindings for libpreludedb Group: System Environment/Libraries Requires: libpreludedb = %{version}-%{release} %description perl Perl bindings for libpreludedb. %prep %setup -q %patch0 -p1 %build %configure --with-html-dir=%{_defaultdocdir}/%{name}-%{version}/html \ --disable-static # removing rpath sed -i.rpath -e 's|LD_RUN_PATH=""||' bindings/Makefile make %install rm -rf %{buildroot} mkdir -p %{buildroot}%{_defaultdocdir}/%{name}-%{version} mkdir -p %{buildroot}%{perl_vendorarch} make install DESTDIR=%{buildroot} INSTALL="%{__install} -c -p" cp -p ChangeLog README NEWS COPYING LICENSE.README HACKING.README \ %{buildroot}%{_defaultdocdir}/%{name}-%{version} mv %{buildroot}%{perl_sitearch}/* %{buildroot}%{perl_vendorarch} rm -f %{buildroot}/%{perl_archlib}/perllocal.pod rm -f %{buildroot}/%{_libdir}/%{name}.la rm -f %{buildroot}/%{_libdir}/%{name}/plugins/formats/classic.la rm -f %{buildroot}/%{_libdir}/%{name}/plugins/sql/mysql.la rm -f %{buildroot}/%{_libdir}/%{name}/plugins/sql/pgsql.la rm -f %{buildroot}/%{_libdir}/%{name}/plugins/sql/sqlite3.la rm -f %{buildroot}/%{perl_vendorarch}/auto/PreludeDB/.packlist rm -f %{buildroot}/%{perl_vendorarch}/auto/PreludeDB/PreludeDB.bs %clean rm -rf %{buildroot} %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %defattr(-,root,root,-) %{_bindir}/preludedb-admin %dir %{_libdir}/%{name}/ %{_libdir}/%{name}*.so.* %dir %{_libdir}/%{name}/plugins/ %dir %{_libdir}/%{name}/plugins/formats/ %{_libdir}/%{name}/plugins/formats/* %dir %{_defaultdocdir}/%{name}-%{version}/ %doc %{_defaultdocdir}/%{name}-%{version}/[A-Z]* %dir %{_libdir}/%{name}/plugins/sql/ %dir %{_datadir}/%{name} %dir %{_datadir}/%{name}/classic/ %files devel %defattr(-,root,root) %{_bindir}/%{name}-config %{_libdir}/%{name}*.so %dir %{_includedir}/%{name}/ %{_includedir}/%{name}/* %{_datadir}/aclocal/libpreludedb.m4 %doc %{_defaultdocdir}/%{name}-%{version}/html/ %files python %{python_sitearch}/* %files perl %defattr(0755,root,root) %{perl_vendorarch}/auto/* %attr(0644,root,root) %{perl_vendorarch}/PreludeDB.pm %files mysql %defattr(0755,root,root) %{_libdir}/%{name}/plugins/sql/mysql.so %attr(0644,root,root) %{_datadir}/%{name}/classic/mysql*.sql %attr(0755,root,root) %{_datadir}/%{name}/classic/*.sh %files sqlite %defattr(-,root,root) %{_libdir}/%{name}/plugins/sql/sqlite3.so %{_datadir}/%{name}/classic/sqlite* %files pgsql %defattr(-,root,root) %{_libdir}/%{name}/plugins/sql/pgsql.so %{_datadir}/%{name}/classic/pgsql* %changelog * Fri Jan 05 2007 Thorsten Scherf 0.9.11.1-1 - moved to new upstream version 0.9.11.1 * Mon Jan 01 2007 Thorsten Scherf 0.9.11-4 - added x86_64-sqlite3.patch to resolve x86_86 build problems * Sun Dec 31 2006 Thorsten Scherf 0.9.11-3 - resolved macro problem in changelog - changed several dirowner - moved html docs into -devel * Sat Dec 30 2006 Thorsten Scherf 0.9.11-2 - corrected file list entries - added new BuildReqs to the devel-package - changed dirowner - fixed x86_86 arch build problem with %%python_sitearch * Fri Dec 29 2006 Thorsten Scherf 0.9.11-1 - resolved rpath issue - added python_sitearch and python_sitelib - fixed permissions problem - moved to new upstream version 0.9.11 * Mon Nov 20 2006 Thorsten Scherf 0.9.10-2 - Some minor fixes in requirements * Tue Oct 24 2006 Thorsten Scherf 0.9.10-1 - New fedora build based on release 0.9.10 - New fedora build based on release 0.9.10