2006-10-27 11:06:13 +02:00
|
|
|
#
|
2011-12-12 10:05:43 +01:00
|
|
|
# spec file for package python-pyinotify
|
2006-10-27 11:06:13 +02:00
|
|
|
#
|
2013-01-15 15:14:28 +01:00
|
|
|
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2006-10-27 11:06:13 +02:00
|
|
|
#
|
2010-10-28 20:37:10 +02:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2006-10-27 11:06:13 +02:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2010-11-02 16:20:20 +01:00
|
|
|
|
2006-10-27 11:06:13 +02:00
|
|
|
Name: python-pyinotify
|
2013-01-15 15:14:28 +01:00
|
|
|
Version: 0.9.4
|
2013-01-18 15:20:51 +01:00
|
|
|
Release: 0
|
2006-10-27 11:06:13 +02:00
|
|
|
Summary: Python module for watching filesystems changes
|
2013-01-18 15:20:51 +01:00
|
|
|
License: MIT
|
2010-10-28 20:37:10 +02:00
|
|
|
Group: Development/Libraries/Python
|
2013-01-18 15:20:51 +01:00
|
|
|
Url: http://github.com/seb-m/pyinotify
|
2013-01-15 15:14:28 +01:00
|
|
|
# downloaded from https://github.com/seb-m/pyinotify/tags
|
2013-01-18 15:20:51 +01:00
|
|
|
Source: pyinotify-%{version}.tar.gz
|
2010-11-02 14:28:47 +01:00
|
|
|
Source1: pyinotify
|
2010-10-28 20:37:10 +02:00
|
|
|
BuildRequires: python-devel
|
2006-10-27 11:06:13 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2013-01-18 15:20:51 +01:00
|
|
|
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
|
|
|
|
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
2010-10-28 20:44:52 +02:00
|
|
|
%else
|
2013-01-18 15:20:51 +01:00
|
|
|
BuildArch: noarch
|
2010-10-28 20:44:52 +02:00
|
|
|
%endif
|
2006-10-27 11:06:13 +02:00
|
|
|
|
|
|
|
%description
|
2010-10-12 00:29:53 +02:00
|
|
|
pyinotify is a Python module for watching filesystems changes. By its design
|
|
|
|
pyinotify can be used for any kind of fs monitoring.
|
|
|
|
|
|
|
|
pyinotify relies on a recent Linux Kernel feature (merged in kernel 2.6.13)
|
|
|
|
called inotify. inotify is an event-driven notifier, its notifications are
|
|
|
|
exported from kernel space to user space. The raw interface of inotify is
|
|
|
|
compounded of three system calls. pyinotify binds these system calls and
|
|
|
|
provides an implementation on top of them offering a generic and abstract way
|
|
|
|
to use inotify with Python. Pyinotify doesn't requires much detailed knowledge
|
|
|
|
of inotify. Moreover, it only needs few statements for initializing, watching,
|
|
|
|
handling (eventually trough a new separate thread), and processing events
|
|
|
|
notifications through subclassing. The only things to know is the path of items
|
|
|
|
to watch, the kind of events to monitor and the actions to execute on these
|
|
|
|
notifications.
|
|
|
|
|
2006-10-27 11:06:13 +02:00
|
|
|
%prep
|
2013-01-15 15:14:28 +01:00
|
|
|
%setup -q -n pyinotify-%{version}
|
2006-10-27 11:06:13 +02:00
|
|
|
|
|
|
|
%build
|
2013-01-15 15:14:28 +01:00
|
|
|
python setup.py build
|
2006-10-27 11:06:13 +02:00
|
|
|
|
|
|
|
%install
|
2013-01-18 15:20:51 +01:00
|
|
|
python ./setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
2010-11-02 14:28:47 +01:00
|
|
|
install -D -m 0755 %{SOURCE1} %{buildroot}%{_bindir}/pyinotify
|
2006-10-27 11:06:13 +02:00
|
|
|
|
2013-01-18 15:20:51 +01:00
|
|
|
%files
|
2006-10-27 11:06:13 +02:00
|
|
|
%defattr(-,root,root)
|
2013-01-18 15:20:51 +01:00
|
|
|
%doc ACKS COPYING README.md python2/examples
|
2010-11-02 14:28:47 +01:00
|
|
|
%{_bindir}/pyinotify
|
2013-01-18 15:20:51 +01:00
|
|
|
%{python_sitelib}/*
|
2010-10-12 00:29:53 +02:00
|
|
|
|
2010-10-28 20:37:10 +02:00
|
|
|
%changelog
|