From 1b0b340d0fd6e9f42f66002dcb47d0f294765443 Mon Sep 17 00:00:00 2001 From: Nir Soffer Date: Wed, 12 Jun 2019 23:50:15 +0300 Subject: [PATCH] Update to sanlock 3.8.0 - Update source to python 3.8.0 - Convert spec to python 3 - Unify whitespace in the spec --- .gitignore | 1 + sanlock.spec | 43 ++++++++++++++++++++++--------------------- sources | 2 +- 3 files changed, 24 insertions(+), 22 deletions(-) diff --git a/.gitignore b/.gitignore index 453c1bc..3e86521 100644 --- a/.gitignore +++ b/.gitignore @@ -26,3 +26,4 @@ /sanlock-3.7.0.tar.gz /sanlock-3.7.1.tar.gz /sanlock-3.7.3.tar.gz +/sanlock-3.8.0.tar.gz diff --git a/sanlock.spec b/sanlock.spec index 22711ee..1b69e3c 100644 --- a/sanlock.spec +++ b/sanlock.spec @@ -1,5 +1,5 @@ Name: sanlock -Version: 3.7.3 +Version: 3.8.0 Release: 1%{?dist} Summary: A shared storage lock manager @@ -10,8 +10,8 @@ BuildRequires: libaio-devel BuildRequires: libblkid-devel BuildRequires: libuuid-devel BuildRequires: make -BuildRequires: python2 -BuildRequires: python2-devel +BuildRequires: python3 +BuildRequires: python3-devel BuildRequires: systemd-units Requires: %{name}-lib = %{version}-%{release} Requires(pre): /usr/sbin/groupadd @@ -34,7 +34,7 @@ The sanlock daemon manages leases for applications on hosts using shared storage # upstream does not support _smp_mflags CFLAGS=$RPM_OPT_FLAGS make -C wdmd CFLAGS=$RPM_OPT_FLAGS make -C src -CFLAGS=$RPM_OPT_FLAGS make -C python +CFLAGS=$RPM_OPT_FLAGS make -C python PY_VERSION=3 CFLAGS=$RPM_OPT_FLAGS make -C reset %install @@ -47,7 +47,8 @@ make -C wdmd \ DESTDIR=$RPM_BUILD_ROOT make -C python \ install LIBDIR=%{_libdir} \ - DESTDIR=$RPM_BUILD_ROOT + DESTDIR=$RPM_BUILD_ROOT \ + PY_VERSION=3 make -C reset \ install LIBDIR=%{_libdir} \ DESTDIR=$RPM_BUILD_ROOT @@ -59,13 +60,13 @@ install -D -m 0644 init.d/wdmd.service.native $RPM_BUILD_ROOT/%{_unitdir}/wdmd.s install -D -m 0644 init.d/sanlk-resetd.service $RPM_BUILD_ROOT/%{_unitdir}/sanlk-resetd.service install -D -m 0644 src/logrotate.sanlock \ - $RPM_BUILD_ROOT/etc/logrotate.d/sanlock + $RPM_BUILD_ROOT/etc/logrotate.d/sanlock install -D -m 0644 src/sanlock.conf \ - $RPM_BUILD_ROOT/etc/sanlock/sanlock.conf + $RPM_BUILD_ROOT/etc/sanlock/sanlock.conf install -D -m 0644 init.d/wdmd.sysconfig \ - $RPM_BUILD_ROOT/etc/sysconfig/wdmd + $RPM_BUILD_ROOT/etc/sysconfig/wdmd install -Dd -m 0755 $RPM_BUILD_ROOT/etc/wdmd.d install -Dd -m 0775 $RPM_BUILD_ROOT/%{_localstatedir}/run/sanlock @@ -73,10 +74,10 @@ install -Dd -m 0775 $RPM_BUILD_ROOT/%{_localstatedir}/run/sanlk-resetd %pre getent group sanlock > /dev/null || /usr/sbin/groupadd \ - -g 179 sanlock + -g 179 sanlock getent passwd sanlock > /dev/null || /usr/sbin/useradd \ - -u 179 -c "sanlock" -s /sbin/nologin -r \ - -g 179 -d /var/run/sanlock sanlock + -u 179 -c "sanlock" -s /sbin/nologin -r \ + -g 179 -d /var/run/sanlock sanlock /usr/sbin/usermod -a -G disk sanlock %post @@ -122,23 +123,19 @@ access to the shared disks. %{_libdir}/libsanlock_client.so.* %{_libdir}/libwdmd.so.* -%package -n python2-sanlock -%{?python_provide:%python_provide python2-sanlock} -# Remove before F30 -Provides: %{name}-python = %{version}-%{release} -Provides: %{name}-python%{?_isa} = %{version}-%{release} -Obsoletes: %{name}-python < %{version}-%{release} +%package -n python3-sanlock +%{?python_provide:%python_provide python3-sanlock} Summary: Python bindings for the sanlock library Requires: %{name}-lib = %{version}-%{release} -%description -n python2-sanlock +%description -n python3-sanlock The %{name}-python package contains a module that permits applications written in the Python programming language to use the interface supplied by the sanlock library. -%files -n python2-sanlock -%{python2_sitearch}/sanlock_python-*.egg-info -%{python2_sitearch}/sanlock.so +%files -n python3-sanlock +%{python3_sitearch}/sanlock_python-*.egg-info +%{python3_sitearch}/sanlock*.so %package devel Summary: Development files for %{name} @@ -181,6 +178,10 @@ common sanlock lockspace. %changelog +* Wed Jun 12 2019 Nir Soffer - 3.8.0-1 +- Update to sanlock-3.8.0 +- Convert spec to python 3 + * Tue May 21 2019 Nir Soffer - 3.7.3-1 - Update to sanlock-3.7.3 - Add missing BuildRequires and Requires diff --git a/sources b/sources index 50b0646..5cc3b27 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (sanlock-3.7.3.tar.gz) = 0564471310b431acb6ede7f68dc16424c087ae350d62991ea31f8e3ab61f1984c8ffe875d05bde2e058c596a388057539a851e925d3ba0352525e55da92ae933 +SHA512 (sanlock-3.8.0.tar.gz) = 06b854d66e24c98a25416ca86491fb5623eb2fa3741253982c6096e9301bb6418d28b94cb8ac9bf55359452b8d80109bbdf9f6d09c925df089212b5822dbbf03