Accepting request 419482 from devel:languages:python
1 OBS-URL: https://build.opensuse.org/request/show/419482 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-dulwich?expand=0&rev=18
This commit is contained in:
parent
c16ad319b6
commit
a4cbcfa6d3
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Aug 15 14:51:56 UTC 2016 - toddrme2178@gmail.com
|
||||||
|
|
||||||
|
- Fix update-alternatives implementation.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Jan 14 10:19:50 UTC 2016 - toddrme2178@gmail.com
|
Thu Jan 14 10:19:50 UTC 2016 - toddrme2178@gmail.com
|
||||||
|
|
||||||
|
@ -29,7 +29,7 @@ BuildRequires: fdupes
|
|||||||
BuildRequires: python-Sphinx
|
BuildRequires: python-Sphinx
|
||||||
BuildRequires: python-devel
|
BuildRequires: python-devel
|
||||||
Requires(post): update-alternatives
|
Requires(post): update-alternatives
|
||||||
Requires(postun): update-alternatives
|
Requires(preun): update-alternatives
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
|
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
|
||||||
%{!?python_sitearch: %global python_sitearch %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
%{!?python_sitearch: %global python_sitearch %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
||||||
%endif
|
%endif
|
||||||
@ -53,21 +53,19 @@ mkdir -p %{buildroot}%{_sysconfdir}/alternatives
|
|||||||
for p in dulwich dul-receive-pack dul-upload-pack ; do
|
for p in dulwich dul-receive-pack dul-upload-pack ; do
|
||||||
mv %{buildroot}%{_bindir}/$p %{buildroot}%{_bindir}/$p-%{py_ver}
|
mv %{buildroot}%{_bindir}/$p %{buildroot}%{_bindir}/$p-%{py_ver}
|
||||||
ln -s -f %{_sysconfdir}/alternatives/$p %{buildroot}%{_bindir}/$p
|
ln -s -f %{_sysconfdir}/alternatives/$p %{buildroot}%{_bindir}/$p
|
||||||
# create a dummy target for /etc/alternatives/$p
|
|
||||||
touch %{buildroot}%{_sysconfdir}/alternatives/$p
|
|
||||||
done
|
done
|
||||||
|
|
||||||
%fdupes %{buildroot}
|
%fdupes %{buildroot}
|
||||||
|
|
||||||
%post
|
%post
|
||||||
"%_sbindir/update-alternatives" \
|
%_sbindir/update-alternatives \
|
||||||
--install %{_bindir}/dulwich dulwich %{_bindir}/dulwich-%{py_ver} 30 \
|
--install %{_bindir}/dulwich dulwich %{_bindir}/dulwich-%{py_ver} 30 \
|
||||||
--slave %{_bindir}/dul-receive-pack dul-receive-pack %{_bindir}/dul-receive-pack-%{py_ver} \
|
--slave %{_bindir}/dul-receive-pack dul-receive-pack %{_bindir}/dul-receive-pack-%{py_ver} \
|
||||||
--slave %{_bindir}/dul-upload-pack dul-upload-pack %{_bindir}/dul-upload-pack-%{py_ver}
|
--slave %{_bindir}/dul-upload-pack dul-upload-pack %{_bindir}/dul-upload-pack-%{py_ver}
|
||||||
|
|
||||||
%postun
|
%preun
|
||||||
if [ $1 -eq 0 ] ; then
|
if [ $1 -eq 0 ] ; then
|
||||||
"%_sbindir/update-alternatives" --remove dulwich %{_bindir}/dulwich-%{py_ver}
|
%_sbindir/update-alternatives --remove dulwich %{_bindir}/dulwich-%{py_ver}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
%files
|
%files
|
||||||
|
Loading…
Reference in New Issue
Block a user