summaryrefslogtreecommitdiff
path: root/sysutils/py-psutil
diff options
context:
space:
mode:
authorrichard <richard@pkgsrc.org>2013-12-07 21:25:23 +0000
committerrichard <richard@pkgsrc.org>2013-12-07 21:25:23 +0000
commit669f6dc91c5cf3e1f1f16e04d9fd1801e507247a (patch)
tree3c60640fa08f42d3fe955135045eaaebb40e5500 /sysutils/py-psutil
parentbf1b5c8c2d0a94386164a3a4c87d7bda9f4813a0 (diff)
downloadpkgsrc-669f6dc91c5cf3e1f1f16e04d9fd1801e507247a.tar.gz
Update to 1.2.1, changelog follows:
1.2.1 - 2013-11-25 ------------------ BUG FIXES * #348: [Windows XP] fixed "ImportError: DLL load failed" occurring on module import. * #425: [Solaris] crash on import due to failure at determining BOOT_TIME. * #443: [Linux] can't set CPU affinity on systems with more than 64 cores. 1.2.0 - 2013-11-20 ------------------ ENHANCEMENTS * #439: assume os.getpid() if no argument is passed to psutil.Process constructor. * #440: new psutil.wait_procs() utility function which waits for multiple processes to terminate. BUG FIXES * #348: [Windows XP/Vista] fixed "ImportError: DLL load failed" occurring on module import. 1.1.3 - 2013-11-07 ------------------ BUG FIXES * #442: [Linux] psutil won't compile on certain version of Linux because of missing prlimit(2) syscall.
Diffstat (limited to 'sysutils/py-psutil')
-rw-r--r--sysutils/py-psutil/Makefile11
-rw-r--r--sysutils/py-psutil/PLIST4
-rw-r--r--sysutils/py-psutil/distinfo13
-rw-r--r--sysutils/py-psutil/patches/patch-psutil___psutil__sunos.c33
-rw-r--r--sysutils/py-psutil/patches/patch-setup.py28
-rw-r--r--sysutils/py-psutil/patches/patch-test_test__psutil.py10
6 files changed, 70 insertions, 29 deletions
diff --git a/sysutils/py-psutil/Makefile b/sysutils/py-psutil/Makefile
index b45a251cb2b..a720bbde8ec 100644
--- a/sysutils/py-psutil/Makefile
+++ b/sysutils/py-psutil/Makefile
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.2 2013/11/02 09:38:34 wiz Exp $
+# $NetBSD: Makefile,v 1.3 2013/12/07 21:25:23 richard Exp $
-DISTNAME= psutil-1.1.2
+DISTNAME= psutil-1.2.1
PKGNAME= ${PYPKGPREFIX}-${DISTNAME}
CATEGORIES= sysutils
MASTER_SITES= https://pypi.python.org/packages/source/p/psutil/
@@ -12,6 +12,13 @@ LICENSE= modified-bsd
REPLACE_PYTHON= psutil/*py
+.include "../../mk/bsd.prefs.mk"
+
+# facilitate PLIST processing
+.if ${OPSYS} == "SunOS"
+LOWER_OPSYS= ${OPSYS:tl}
+.endif
+
.include "../../lang/python/application.mk"
.include "../../lang/python/egg.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/sysutils/py-psutil/PLIST b/sysutils/py-psutil/PLIST
index 8f609f6ad45..66945d6277d 100644
--- a/sysutils/py-psutil/PLIST
+++ b/sysutils/py-psutil/PLIST
@@ -1,5 +1,5 @@
-@comment $NetBSD: PLIST,v 1.1 2013/10/12 13:32:36 wiz Exp $
-${PYSITELIB}/_psutil_netbsd.so
+@comment $NetBSD: PLIST,v 1.2 2013/12/07 21:25:23 richard Exp $
+${PYSITELIB}/_psutil_${LOWER_OPSYS}.so
${PYSITELIB}/_psutil_posix.so
${PYSITELIB}/${EGG_INFODIR}/PKG-INFO
${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt
diff --git a/sysutils/py-psutil/distinfo b/sysutils/py-psutil/distinfo
index 5439013965d..219a42d32c6 100644
--- a/sysutils/py-psutil/distinfo
+++ b/sysutils/py-psutil/distinfo
@@ -1,13 +1,14 @@
-$NetBSD: distinfo,v 1.2 2013/11/02 09:38:34 wiz Exp $
+$NetBSD: distinfo,v 1.3 2013/12/07 21:25:23 richard Exp $
-SHA1 (psutil-1.1.2.tar.gz) = fb529c3452a2ed6f6243c8683146f5f915ca69d5
-RMD160 (psutil-1.1.2.tar.gz) = f59b044334d5dab75d3096ebe05d58a6ed1a5e6d
-Size (psutil-1.1.2.tar.gz) = 165709 bytes
+SHA1 (psutil-1.2.1.tar.gz) = c8c1842bf1c63b9068ac25a37f7aae11fcecd57f
+RMD160 (psutil-1.2.1.tar.gz) = 5b014f73dce4035527886637ebd1b653e5a7faba
+Size (psutil-1.2.1.tar.gz) = 167397 bytes
SHA1 (patch-psutil_____init____.py) = aa75a84992250e28db01d5fe13a68ed0cdcea883
SHA1 (patch-psutil___psnetbsd.py) = 20089b57640a5eb30aeb1f5460624a570f1d3236
SHA1 (patch-psutil___psutil__netbsd.c) = c251e097ce5c919537176f16406ad6892db955fc
SHA1 (patch-psutil___psutil__netbsd.h) = 33e3c857f764d8391db747068ade7ea333698ec0
+SHA1 (patch-psutil___psutil__sunos.c) = 78bdb8103a10022785202873c7e60886a885340f
SHA1 (patch-psutil_arch_netbsd_process__info.c) = c384d12cc47514d6396d779d59c586ef2b42a89a
SHA1 (patch-psutil_arch_netbsd_process__info.h) = b23075df15749e4e5274ccb9e21d67ac55fdd199
-SHA1 (patch-setup.py) = 651079583b3c6cb0f0253dcd2b8f963160f52fa8
-SHA1 (patch-test_test__psutil.py) = c0053788aefaf9c651c733a9911e0ca76e6d3537
+SHA1 (patch-setup.py) = 3e87561b6dfd7e851e232342dab3b2e8ade28cfd
+SHA1 (patch-test_test__psutil.py) = fa3ba09430f8ad307cf6674dee3e7cbfa9144e3b
diff --git a/sysutils/py-psutil/patches/patch-psutil___psutil__sunos.c b/sysutils/py-psutil/patches/patch-psutil___psutil__sunos.c
new file mode 100644
index 00000000000..67b25366bcf
--- /dev/null
+++ b/sysutils/py-psutil/patches/patch-psutil___psutil__sunos.c
@@ -0,0 +1,33 @@
+$NetBSD: patch-psutil___psutil__sunos.c,v 1.1 2013/12/07 21:25:24 richard Exp $
+
+--- psutil/_psutil_sunos.c.orig 2013-11-20 19:29:05.000000000 +0000
++++ psutil/_psutil_sunos.c
+@@ -772,8 +772,9 @@ error:
+ return NULL;
+ }
+
+-
++#ifndef EXPER_IP_AND_ALL_IRES
+ #define EXPER_IP_AND_ALL_IRES (1024+4)
++#endif
+
+ // a signaler for connections without an actual status
+ static int PSUTIL_CONN_NONE = 128;
+@@ -790,7 +791,7 @@ static PyObject*
+ get_process_connections(PyObject* self, PyObject* args)
+ {
+ long pid;
+- int sd = NULL;
++ int sd = 0;
+ mib2_tcpConnEntry_t *tp = NULL;
+ mib2_udpEntry_t *ude;
+ #if defined(AF_INET6)
+@@ -1059,7 +1060,7 @@ error:
+ Py_XDECREF(py_raddr);
+ Py_DECREF(py_retlist);
+ // TODO : free databuf
+- if (sd != NULL)
++ if (sd > 0)
+ close(sd);
+ return NULL;
+ }
diff --git a/sysutils/py-psutil/patches/patch-setup.py b/sysutils/py-psutil/patches/patch-setup.py
index d12670b7495..822379faa2f 100644
--- a/sysutils/py-psutil/patches/patch-setup.py
+++ b/sysutils/py-psutil/patches/patch-setup.py
@@ -1,25 +1,25 @@
-$NetBSD: patch-setup.py,v 1.2 2013/11/02 09:38:34 wiz Exp $
+$NetBSD: patch-setup.py,v 1.3 2013/12/07 21:25:24 richard Exp $
Port to NetBSD.
---- setup.py.orig 2013-10-22 18:12:21.000000000 +0000
+--- setup.py.orig 2013-11-20 19:29:05.000000000 +0000
+++ setup.py
-@@ -145,6 +145,18 @@ elif sys.platform.startswith("freebsd"):
+@@ -122,6 +122,18 @@ elif sys.platform.startswith("freebsd"):
libraries=["devstat"]),
posix_extension,
]
+# NetBSD
+elif sys.platform.startswith("netbsd"):
-+ extensions = [Extension(
-+ '_psutil_netbsd',
-+ sources = [
-+ 'psutil/_psutil_netbsd.c',
-+ 'psutil/_psutil_common.c',
-+ 'psutil/arch/netbsd/process_info.c'
-+ ],
-+ libraries=[]),
-+ posix_extension,
-+ ]
++ extensions = [Extension(
++ '_psutil_netbsd',
++ sources = [
++ 'psutil/_psutil_netbsd.c',
++ 'psutil/_psutil_common.c',
++ 'psutil/arch/netbsd/process_info.c'
++ ],
++ libraries=[]),
++ posix_extension,
++ ]
# Linux
elif sys.platform.startswith("linux"):
- kernel_ver = get_kernel_version()
+ extensions = [Extension(
diff --git a/sysutils/py-psutil/patches/patch-test_test__psutil.py b/sysutils/py-psutil/patches/patch-test_test__psutil.py
index a5f6ad10e4b..bf2f8d97641 100644
--- a/sysutils/py-psutil/patches/patch-test_test__psutil.py
+++ b/sysutils/py-psutil/patches/patch-test_test__psutil.py
@@ -1,15 +1,15 @@
-$NetBSD: patch-test_test__psutil.py,v 1.1 2013/10/12 13:32:36 wiz Exp $
+$NetBSD: patch-test_test__psutil.py,v 1.2 2013/12/07 21:25:24 richard Exp $
Port to NetBSD.
---- test/test_psutil.py.orig 2013-07-10 14:02:21.000000000 +0000
+--- test/test_psutil.py.orig 2013-11-22 21:26:42.000000000 +0000
+++ test/test_psutil.py
-@@ -62,7 +62,7 @@ POSIX = os.name == 'posix'
+@@ -77,7 +77,7 @@ POSIX = os.name == 'posix'
LINUX = sys.platform.startswith("linux")
WINDOWS = sys.platform.startswith("win32")
OSX = sys.platform.startswith("darwin")
-BSD = sys.platform.startswith("freebsd")
+BSD = sys.platform.startswith("freebsd") or sys.platform.startswith("netbsd")
SUNOS = sys.platform.startswith("sunos")
-
-
+ VALID_PROC_STATUSES = [getattr(psutil, x) for x in dir(psutil)
+ if x.startswith('STATUS_')]