python-pyinotify/python-pyinotify.spec

131 lines
4.3 KiB
RPMSpec
Raw Permalink Normal View History

%define python_majversion %(echo %python_version | cut -d. -f 1)
Name: python-pyinotify
Version: 0.9.6
Release: 4mamba
Summary: Linux filesystem events monitoring
Group: System/Libraries/Python
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://github.com/seb-m/pyinotify
Source: https://pypi.debian.net/pyinotify/pyinotify-%{version}.tar.gz
Source1: python-pyinotify-script
License: MIT
## AUTOBUILDREQ-BEGIN
BuildRequires: libpython311-devel
## AUTOBUILDREQ-END
BuildRequires: python3-devel >= 3.11.5-3mamba
Provides: python-inotify
Obsoletes: python-inotify <= 0.9.6-1mamba
BuildArch: noarch
%description
Pyinotify is a pure Python module used for monitoring filesystems events.
Pyinotify relies on inotify, a Linux Kernel functionality (starting with kernel version 2.6.13).
inotify is an event-driven notification mechanism, its notifications are exported to user space through three system calls.
Pyinotify binds these system calls and provides an implementation on top of them.
%package doc
Group: Documentation
Summary: Documentation package for %{name}
%description doc
Pyinotify is a pure Python module used for monitoring filesystems events.
Pyinotify relies on inotify, a Linux Kernel functionality (starting with kernel version 2.6.13).
inotify is an event-driven notification mechanism, its notifications are exported to user space through three system calls.
Pyinotify binds these system calls and provides an implementation on top of them.
This package contains the documentation files.
%if "%{?with_pyver}"
%define py_requires_append \
Obsoletes: python-pyinotify <= 0.9.6-1mamba
%pyver_package
%endif
%prep
%setup -q -n pyinotify-%{version}
%build
CFLAGS="%{optflags}" %{__python} setup.py build
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%{__python} setup.py install \
-O1 --skip-build \
--root="%{buildroot}" \
--install-headers=%{_includedir}/python \
--install-lib=%{python_sitearch} \
--record=%{name}.filelist
sed -i "\,\.egg-info/,d;s,.*/man/.*,&.gz," %{name}.filelist
## set encoding for documentation
#mv ChangeLog_old ChangeLog_old.iso88591
#iconv -f iso88591 -t utf8 -o ChangeLog_old \
# ChangeLog_old.iso88591
#rm -f ChangeLog_old.iso88591
# install launch script
install -D -m 0755 -p %{S:1} \
%{buildroot}%{_bindir}/pyinotify
# fix permissions
chmod 0755 %{buildroot}%{python_sitearch}/pyinotify.py
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%files %{?pyappend} -f %{name}.filelist
%defattr(-,root,root)
%{_bindir}/pyinotify
%dir %{python_sitearch}/pyinotify-%{version}-py*.egg-info
%{python_sitearch}/pyinotify-%{version}-py*.egg-info/*
%doc ACKS COPYING
%files doc
%defattr(-,root,root)
%doc python%{python_majversion}/examples
#%doc python%{python_majversion}/docstrings
%changelog
* Tue Sep 26 2023 Automatic Build System <autodist@mambasoft.it> 0.9.6-4mamba
- rebuilt by autoport with build requirements: python3-devel>=3.11.5-3mamba
* Mon May 31 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.6-3mamba
- obsolete python-pyinotify <= 0.9.6-1mamba
* Sat May 29 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.6-2mamba
- rebuilt with -py3 and distdeps
* Fri Jun 05 2015 Automatic Build System <autodist@mambasoft.it> 0.9.6-1mamba
- automatic version update by autodist
* Sun Jan 25 2015 Automatic Build System <autodist@mambasoft.it> 0.9.5-1mamba
- automatic version update by autodist
* Fri May 17 2013 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.4-2mamba
- python 2.7 mass rebuild
* Tue Nov 20 2012 Automatic Build System <autodist@mambasoft.it> 0.9.4-1mamba
- update to 0.9.4
* Wed Jun 13 2012 Automatic Build System <autodist@mambasoft.it> 0.9.3-1mamba
- automatic version update by autodist
* Thu May 12 2011 Automatic Build System <autodist@mambasoft.it> 0.9.2-1mamba
- automatic update by autodist
* Tue Nov 09 2010 Automatic Build System <autodist@mambasoft.it> 0.9.1-1mamba
- automatic update by autodist
* Sun Jun 20 2010 Automatic Build System <autodist@mambasoft.it> 0.9.0-1mamba
- update to 0.9.0
* Wed Jan 20 2010 Stefano Cotta Ramusino <stefano.cotta@openmamba.org> 0.8.9-1mamba
- update to 0.8.9
- package name changed to python-pyinotify
* Wed May 13 2009 gil <puntogil@libero.it> 0.8.6-1mamba
- package created by autospec