Update to sanlock 3.8.0

- Update source to python 3.8.0
- Convert spec to python 3
- Unify whitespace in the spec
This commit is contained in:
Nir Soffer 2019-06-12 23:50:15 +03:00
parent e7f6761b2e
commit 1b0b340d0f
3 changed files with 24 additions and 22 deletions

1
.gitignore vendored
View File

@ -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

View File

@ -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 <nsoffer@redhat.com> - 3.8.0-1
- Update to sanlock-3.8.0
- Convert spec to python 3
* Tue May 21 2019 Nir Soffer <nsoffer@redhat.com> - 3.7.3-1
- Update to sanlock-3.7.3
- Add missing BuildRequires and Requires

View File

@ -1 +1 @@
SHA512 (sanlock-3.7.3.tar.gz) = 0564471310b431acb6ede7f68dc16424c087ae350d62991ea31f8e3ab61f1984c8ffe875d05bde2e058c596a388057539a851e925d3ba0352525e55da92ae933
SHA512 (sanlock-3.8.0.tar.gz) = 06b854d66e24c98a25416ca86491fb5623eb2fa3741253982c6096e9301bb6418d28b94cb8ac9bf55359452b8d80109bbdf9f6d09c925df089212b5822dbbf03