From c8d42aac4b98efb499cbfbad9907a55387a076be Mon Sep 17 00:00:00 2001 From: Peter Vrabec Date: Wed, 24 Mar 2010 15:30:11 +0000 Subject: [PATCH] upgrade --- .cvsignore | 2 +- openscap-0.5.8-config.patch | 21 +++++++++++++++++++++ openscap.spec | 35 +++++++++++++++++++++++++++++++++-- sources | 2 +- 4 files changed, 56 insertions(+), 4 deletions(-) create mode 100644 openscap-0.5.8-config.patch diff --git a/.cvsignore b/.cvsignore index 2130a9d..374f3c6 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1 +1 @@ -openscap-0.5.7.tar.gz +openscap-0.5.8.tar.gz diff --git a/openscap-0.5.8-config.patch b/openscap-0.5.8-config.patch new file mode 100644 index 0000000..6d5d66c --- /dev/null +++ b/openscap-0.5.8-config.patch @@ -0,0 +1,21 @@ +diff -up openscap-0.5.8/dist/fedora/oscap-scan.cron.config openscap-0.5.8/dist/fedora/oscap-scan.cron +--- openscap-0.5.8/dist/fedora/oscap-scan.cron.config 2010-03-24 15:57:03.646108236 +0100 ++++ openscap-0.5.8/dist/fedora/oscap-scan.cron 2010-03-24 15:57:26.986117969 +0100 +@@ -5,7 +5,7 @@ + # sent to root mail. Please configure oscap-scan options before you use it! + ########## + +-#OPTIONS="/usr/share/openscap/scap-fedora12-oval.xml" ++OPTIONS="/usr/share/openscap/scap-fedora13-oval.xml" + PROG="/usr/bin/oscap-scan" + if [ x"$OPTIONS" == "x" ] + then +diff -up openscap-0.5.8/dist/fedora/oscap-scan.sys.config openscap-0.5.8/dist/fedora/oscap-scan.sys +--- openscap-0.5.8/dist/fedora/oscap-scan.sys.config 2010-03-24 15:57:44.733108831 +0100 ++++ openscap-0.5.8/dist/fedora/oscap-scan.sys 2010-03-24 15:57:56.122129104 +0100 +@@ -1,4 +1,4 @@ + + #oscap-scan command line options: +-#OPTIONS="-q --result-file /var/log/oscap-scan.xml.log /usr/share/openscap/scap-fedora12-oval.xml" ++OPTIONS="-q --result-file /var/log/oscap-scan.xml.log /usr/share/openscap/scap-fedora13-oval.xml" + diff --git a/openscap.spec b/openscap.spec index 0350e27..5e67be4 100644 --- a/openscap.spec +++ b/openscap.spec @@ -2,13 +2,14 @@ %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} Name: openscap -Version: 0.5.7 +Version: 0.5.8 Release: 1%{?dist} Summary: Set of open source libraries enabling integration of the SCAP line of standards Group: System Environment/Libraries License: LGPLv2+ URL: http://www.open-scap.org/ Source0: http://fedorahosted.org/releases/o/p/openscap/%{name}-%{version}.tar.gz +Patch1: openscap-0.5.8-config.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: swig pcre-devel libxml2-devel BuildRequires: rpm-devel @@ -55,13 +56,16 @@ libraries can be used by perl. Summary: Openscap utilities Group: Applications/System Requires: %{name} = %{version}-%{release} -BuildRequires: libcurl-devel +Requires(post): chkconfig +Requires(preun): chkconfig initscripts +BuildRequires: libcurl-devel %description utils The %{name}-utils package contains various utilities based on %{name} library. %prep %setup -q +%patch1 -p1 %build %configure --disable-debug @@ -69,7 +73,14 @@ make %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT + make install DESTDIR=$RPM_BUILD_ROOT + +install -d -m 755 $RPM_BUILD_ROOT%{_initrddir} +install -d -m 755 $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig +install -p -m 755 dist/fedora/oscap-scan.init $RPM_BUILD_ROOT%{_initrddir}/oscap-scan +install -p -m 644 dist/fedora/oscap-scan.sys $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/oscap-scan + find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';' %clean @@ -79,6 +90,17 @@ rm -rf $RPM_BUILD_ROOT %postun -p /sbin/ldconfig + +%post utils +/sbin/chkconfig --add oscap-scan + +%preun utils +if [ $1 -eq 0 ]; then + /sbin/service oscap-scan stop > /dev/null 2>&1 + /sbin/chkconfig --del oscap-scan +fi + + %files %defattr(-,root,root,-) %doc AUTHORS COPYING ChangeLog NEWS README @@ -102,9 +124,18 @@ rm -rf $RPM_BUILD_ROOT %files utils %defattr(-,root,root,-) +%config(noreplace) %{_sysconfdir}/sysconfig/oscap-scan +%{_initrddir}/oscap-scan +%{_datadir}/openscap/* +%{_mandir}/man8/* %{_bindir}/* + %changelog +* Wed Mar 24 2010 Peter Vrabec 0.5.8-1 +- upgrade +- configure initscipt and cronjob script + * Fri Feb 26 2010 Peter Vrabec 0.5.7-1 - upgrade - new utils package diff --git a/sources b/sources index 5342793..4dfcd5f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -0c72fb5549f71ea095e0fe537f8030e8 openscap-0.5.7.tar.gz +cb62e24375b5a3dd01e5675d5782b9b6 openscap-0.5.8.tar.gz