[yum] yum 3.2.29

Seth Vidal skvidal at fedoraproject.org
Thu Jan 13 17:34:27 UTC 2011


commit 3d4bb3b45602e53b32bcb8992eb2bbda121092a6
Author: Seth Vidal <skvidal at fedoraproject.org>
Date:   Thu Jan 13 12:34:17 2011 -0500

    yum 3.2.29

 .gitignore |    1 +
 sources    |    2 +-
 yum.spec   |   82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
 3 files changed, 80 insertions(+), 5 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 063d903..db9e578 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,3 @@
 yum-3.2.27.tar.gz
 yum-3.2.28.tar.gz
+/yum-3.2.29.tar.gz
diff --git a/sources b/sources
index fa09d52..eaeddf2 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-91eff58aa4c25cd4f46b21201bbf9bea  yum-3.2.28.tar.gz
+8b6b106190980c606b77ebf6a81b5f70  yum-3.2.29.tar.gz
diff --git a/yum.spec b/yum.spec
index d28f169..6edf581 100644
--- a/yum.spec
+++ b/yum.spec
@@ -6,8 +6,8 @@
 
 Summary: RPM installer/updater
 Name: yum
-Version: 3.2.28
-Release: 17%{?dist}
+Version: 3.2.29
+Release: 1%{?dist}
 License: GPLv2+
 Group: System Environment/Base
 Source0: http://yum.baseurl.org/download/3.2/%{name}-%{version}.tar.gz
@@ -18,7 +18,7 @@ Patch1: yum-mirror-priority.patch
 Patch3: yum-multilib-policy-best.patch
 Patch4: no-more-exactarchlist.patch
 Patch5: geode-arch.patch
-Patch6: yum-HEAD.patch
+#Patch6: yum-HEAD.patch
 
 Patch20: yum-manpage-files.patch
 
@@ -99,6 +99,23 @@ Requires(post): /sbin/service
 yum-updatesd provides a daemon which checks for available updates and 
 can notify you when they are available via email, syslog or dbus. 
 
+
+%package cron
+Summary: Files needed to run yum updates as a cron job
+Group: System Environment/Base
+Requires: yum >= 3.0 vixie-cron crontabs yum-plugin-downloadonly findutils
+Requires(post): /sbin/chkconfig
+Requires(post): /sbin/service
+Requires(preun): /sbin/chkconfig
+Requires(preun): /sbin/service
+Requires(postun): /sbin/service
+
+%description cron
+These are the files needed to run yum updates as a cron job.
+Install this package if you want auto yum updates nightly via cron.
+
+
+
 %prep
 %setup -q
 %patch0 -p0
@@ -106,7 +123,7 @@ can notify you when they are available via email, syslog or dbus.
 %patch3 -p0
 %patch4 -p0
 %patch5 -p1
-%patch6 -p1
+#%%patch6 -p1
 %patch20 -p1
 
 %build
@@ -150,6 +167,50 @@ chmod +x $RPM_BUILD_ROOT/%{python_sitelib}/rpmUtils/*.py
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+
+%post cron
+# Make sure chkconfig knows about the service
+/sbin/chkconfig --add yum-cron
+# if an upgrade:
+if [ "$1" -ge "1" ]; then
+# if there's a /etc/rc.d/init.d/yum file left, assume that there was an
+# older instance of yum-cron which used this naming convention.  Clean 
+# it up, do a conditional restart
+ if [ -f /etc/init.d/yum ]; then 
+# was it on?
+  /sbin/chkconfig yum
+  RETVAL=$?
+  if [ $RETVAL = 0 ]; then
+# if it was, stop it, then turn on new yum-cron
+   /sbin/service yum stop 1> /dev/null 2>&1
+   /sbin/service yum-cron start 1> /dev/null 2>&1
+   /sbin/chkconfig yum-cron on
+  fi
+# remove it from the service list
+  /sbin/chkconfig --del yum
+ fi
+fi 
+exit 0
+
+%preun cron
+# if this will be a complete removeal of yum-cron rather than an upgrade,
+# remove the service from chkconfig control
+if [ $1 = 0 ]; then
+ /sbin/chkconfig --del yum-cron
+ /sbin/service yum-cron stop 1> /dev/null 2>&1
+fi
+exit 0
+
+%postun cron
+# If there's a yum-cron package left after uninstalling one, do a
+# conditional restart of the service
+if [ "$1" -ge "1" ]; then
+ /sbin/service yum-cron condrestart 1> /dev/null 2>&1
+fi
+exit 0
+
+
+
 %files -f %{name}.lang
 %defattr(-, root, root, -)
 %doc README AUTHORS COPYING TODO INSTALL ChangeLog
@@ -179,7 +240,20 @@ rm -rf $RPM_BUILD_ROOT
 %dir %{yum_pluginslib}
 %dir %{yum_pluginsshare}
 
+%files cron
+%defattr(-,root,root)
+%doc COPYING
+%{_sysconfdir}/cron.daily/0yum.cron
+%config(noreplace) %{_sysconfdir}/yum/yum-daily.yum
+%config(noreplace) %{_sysconfdir}/yum/yum-weekly.yum
+%{_sysconfdir}/rc.d/init.d/yum-cron
+%config(noreplace) %{_sysconfdir}/sysconfig/yum-cron
+
 %changelog
+* Thu Jan 13 2011 Seth Vidal <skvidal at fedoraproject.org> - 3.2.29-1
+- 3.2.29
+- add yum-cron subpkg
+
 * Thu Jan  6 2011 James Antill <james at fedoraproject.org> - 3.2.28-17
 - Allow kernel installs with multilib protection ... oops!
 - Don't conflict with fixed versions of Zif.


More information about the scm-commits mailing list