Hello community,

here is the log from the commit of package python3-docutils for 
openSUSE:Factory checked in at 2016-08-22 13:59:51
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python3-docutils (Old)
 and      /work/SRC/openSUSE:Factory/.python3-docutils.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python3-docutils"

Changes:
--------
--- /work/SRC/openSUSE:Factory/python3-docutils/python3-docutils.changes        
2016-05-17 17:10:12.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python3-docutils.new/python3-docutils.changes   
2016-08-22 13:59:52.000000000 +0200
@@ -1,0 +2,5 @@
+Mon Aug 15 14:51:56 UTC 2016 - [email protected]
+
+- Fix update-alternatives implementation.
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python3-docutils.spec ++++++
--- /var/tmp/diff_new_pack.sh22P9/_old  2016-08-22 13:59:53.000000000 +0200
+++ /var/tmp/diff_new_pack.sh22P9/_new  2016-08-22 13:59:53.000000000 +0200
@@ -31,6 +31,8 @@
 BuildRequires:  python3-nose
 BuildRequires:  python3-xml
 Requires:       python3-xml
+Requires(post): update-alternatives
+Requires(preun): update-alternatives
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 BuildArch:      noarch
 
@@ -56,26 +58,20 @@
 
 %install
 python3 setup.py install --prefix=%{_prefix} --root=%{buildroot}
+
+# Prepare for update-alternatives usage
+mkdir -p %{buildroot}%{_sysconfdir}/alternatives
 binaries="rst2html rst2latex rst2man rst2odt rst2odt_prepstyles rst2pseudoxml 
rst2s5 rst2xetex rst2xml rstpep2html"
-for i in $binaries; do
-    ln -s %{_bindir}/${i}-%{py3_ver} %{buildroot}%{_bindir}/${i}
+for p in $binaries; do
+    ln -s -f %{_sysconfdir}/alternatives/$p %{buildroot}%{_bindir}/$p
 done
 
 # Fails test for now, all of them
 #%check
 #nosetests
 
-%pre
-# Since binaries became ghosted to be used with update-alternatives,
-# we have to get rid of the old binary resulting from the
-# non-update-alternativies-ified package:
-binaries="rst2html rst2latex rst2man rst2odt rst2odt_prepstyles rst2pseudoxml 
rst2s5 rst2xetex rst2xml rstpep2html"
-for i in $binaries; do
-    [ -h %{_bindir}/${i} ] || rm -f %{_bindir}/${i}
-done
-
 %post
-update-alternatives \
+%_sbindir/update-alternatives \
     --install %{_bindir}/rst2html rst2html %{_bindir}/rst2html-%{py3_ver} 30 \
     --slave %{_bindir}/rst2latex rst2latex %{_bindir}/rst2latex-%{py3_ver} \
     --slave %{_bindir}/rst2man rst2man %{_bindir}/rst2man-%{py3_ver} \
@@ -89,24 +85,45 @@
 
 %preun
 if [ $1 -eq 0 ] ; then
-    update-alternatives --remove rst2html %{_bindir}/rst2html-%{py3_ver}
+    %_sbindir/update-alternatives --remove rst2html 
%{_bindir}/rst2html-%{py3_ver}
 fi
 
 %files
 %defattr(-,root,root,-)
-%doc COPYING.txt FAQ.txt HISTORY.txt README.txt THANKS.txt BUGS.txt docs/* 
licenses
-%ghost %{_bindir}/rst2html
-%ghost %{_bindir}/rst2latex
-%ghost %{_bindir}/rst2man
-%ghost %{_bindir}/rst2odt
-%ghost %{_bindir}/rst2odt_prepstyles
-%ghost %{_bindir}/rst2pseudoxml
-%ghost %{_bindir}/rst2s5
-%ghost %{_bindir}/rst2xetex
-%ghost %{_bindir}/rst2xml
-%ghost %{_bindir}/rstpep2html
-%{_bindir}/rst*-%{py3_ver}
+%doc COPYING.txt FAQ.txt HISTORY.txt README.txt THANKS.txt BUGS.txt 
+%doc docs/* 
+%doc licenses
+%{_bindir}/rst2html
+%{_bindir}/rst2latex
+%{_bindir}/rst2man
+%{_bindir}/rst2odt
+%{_bindir}/rst2odt_prepstyles
+%{_bindir}/rst2pseudoxml
+%{_bindir}/rst2s5
+%{_bindir}/rst2xetex
+%{_bindir}/rst2xml
+%{_bindir}/rstpep2html
+%{_bindir}/rst2html-%{py3_ver}
+%{_bindir}/rst2latex-%{py3_ver}
+%{_bindir}/rst2man-%{py3_ver}
+%{_bindir}/rst2odt-%{py3_ver}
+%{_bindir}/rst2odt_prepstyles-%{py3_ver}
+%{_bindir}/rst2pseudoxml-%{py3_ver}
+%{_bindir}/rst2s5-%{py3_ver}
+%{_bindir}/rst2xetex-%{py3_ver}
+%{_bindir}/rst2xml-%{py3_ver}
+%{_bindir}/rstpep2html-%{py3_ver}
+%ghost %{_sysconfdir}/alternatives/rst2html
+%ghost %{_sysconfdir}/alternatives/rst2latex
+%ghost %{_sysconfdir}/alternatives/rst2man
+%ghost %{_sysconfdir}/alternatives/rst2odt
+%ghost %{_sysconfdir}/alternatives/rst2odt_prepstyles
+%ghost %{_sysconfdir}/alternatives/rst2pseudoxml
+%ghost %{_sysconfdir}/alternatives/rst2s5
+%ghost %{_sysconfdir}/alternatives/rst2xetex
+%ghost %{_sysconfdir}/alternatives/rst2xml
+%ghost %{_sysconfdir}/alternatives/rstpep2html
 %{python3_sitelib}/docutils/
-%{python3_sitelib}/docutils-%{version}-py%{py3_ver}.egg-info
+%{python3_sitelib}/docutils-%{version}-py*.egg-info
 
 %changelog


Reply via email to