diff --git a/devel/Makefile b/devel/Makefile index 85f5d0834ee43..d5d56f3dd325a 100644 --- a/devel/Makefile +++ b/devel/Makefile @@ -4832,6 +4832,7 @@ SUBDIR += py-iniconfig SUBDIR += py-inifile SUBDIR += py-iniparse + SUBDIR += py-inotify-simple SUBDIR += py-installer SUBDIR += py-intbitset SUBDIR += py-intelhex diff --git a/devel/py-inotify-simple/Makefile b/devel/py-inotify-simple/Makefile new file mode 100644 index 0000000000000..8b558c4fd1774 --- /dev/null +++ b/devel/py-inotify-simple/Makefile @@ -0,0 +1,22 @@ +PORTNAME= inotify-simple +PORTVERSION= 1.3.5 +CATEGORIES= devel python +MASTER_SITES= PYPI +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} +DISTNAME= ${PORTNAME:S/-/_/}-${PORTVERSION} + +MAINTAINER= grembo@FreeBSD.org +COMMENT= Simple wrapper around inotify +WWW= https://github.com/chrisjbillington/inotify_simple + +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + +LIB_DEPENDS= libinotify.so:devel/libinotify + +USES= python +USE_PYTHON= autoplist distutils + +NO_ARCH= yes + +.include diff --git a/devel/py-inotify-simple/distinfo b/devel/py-inotify-simple/distinfo new file mode 100644 index 0000000000000..e783015aa2117 --- /dev/null +++ b/devel/py-inotify-simple/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1707611159 +SHA256 (inotify_simple-1.3.5.tar.gz) = 8440ffe49c4ae81a8df57c1ae1eb4b6bfa7acb830099bfb3e305b383005cc128 +SIZE (inotify_simple-1.3.5.tar.gz) = 9747 diff --git a/devel/py-inotify-simple/files/patch-inotify__simple.py b/devel/py-inotify-simple/files/patch-inotify__simple.py new file mode 100644 index 0000000000000..6f4492d46d697 --- /dev/null +++ b/devel/py-inotify-simple/files/patch-inotify__simple.py @@ -0,0 +1,11 @@ +--- inotify_simple.py.orig 2024-02-11 00:28:11 UTC ++++ inotify_simple.py +@@ -82,7 +82,7 @@ class INotify(FileIO): + manually with ``os.read(fd)``) to raise ``BlockingIOError`` if no data + is available.""" + try: +- libc_so = find_library('c') ++ libc_so = find_library('inotify') + except RuntimeError: # Python on Synology NASs raises a RuntimeError + libc_so = None + global _libc; _libc = _libc or CDLL(libc_so or 'libc.so.6', use_errno=True) diff --git a/devel/py-inotify-simple/pkg-descr b/devel/py-inotify-simple/pkg-descr new file mode 100644 index 0000000000000..0967120301949 --- /dev/null +++ b/devel/py-inotify-simple/pkg-descr @@ -0,0 +1,2 @@ +inotify_simple is a simple Python wrapper around inotify. +No fancy bells and whistles, just a literal wrapper with ctypes.