diff --git a/srcpkgs/python-inotify/template b/srcpkgs/python-inotify/template index 56ed6ffc30..8a2379670f 100644 --- a/srcpkgs/python-inotify/template +++ b/srcpkgs/python-inotify/template @@ -1,18 +1,38 @@ # Template file for 'python-inotify' pkgname=python-inotify version=0.9.4 -revision=1 -build_style=python-module -hostmakedepends="python" -makedepends="python-devel" +revision=2 noarch=yes -pycompile_module="pyinotify.py" +wrksrc="pyinotify-${version}" +build_style=python-module +python_versions="2.7 3.4" +hostmakedepends="python-setuptools python3.4-setuptools" +makedepends="python-devel python3.4-devel" depends="python" -short_desc="Python module used for monitoring filesystems events on Linux platforms with inotify" +pycompile_module="pyinotify.py" +short_desc="Monitoring filesystems events with inotify on Linux (Python2)" +homepage="https://github.com/seb-m/pyinotify/" maintainer="Juan RP " -homepage="http://github.com/seb-m/pyinotify" license="MIT" +distfiles="https://pypi.python.org/packages/source/p/pyinotify/pyinotify-${version}.tar.gz" +checksum=a09767e4e0610e2e1e9f9dc89483b0ee4a53764e700f5866a570bec51d003fec -do_fetch() { - git clone -b ${version} git://github.com/seb-m/pyinotify ${pkgname}-${version} +pre_install() { + sed -i 's,#!/usr/bin/env python,&3.4,' build-3.4/lib/pyinotify.py +} + +post_install() { + vinstall COPYING 644 usr/share/licenses/${pkgname} +} + +python3.4-inotify_package() { + noarch=yes + depends="python3.4" + pycompile_version="3.4" + pycompile_module="pyinotify.py" + short_desc="${short_desc/Python2/Python3.4}" + pkg_install() { + vmove usr/lib/python3.4 + vinstall ${wrksrc}/COPYING 644 usr/share/licenses/${pkgname} + } } diff --git a/srcpkgs/python3.4-inotify b/srcpkgs/python3.4-inotify new file mode 120000 index 0000000000..cddf3ff670 --- /dev/null +++ b/srcpkgs/python3.4-inotify @@ -0,0 +1 @@ +python-inotify \ No newline at end of file