summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
authorwiggin15 <wiggin15@yahoo.com>2017-09-26 14:52:42 +0300
committerGiampaolo Rodola <g.rodola@gmail.com>2017-09-26 19:52:42 +0800
commit1ebe625e5aa21b33e9de5652c305d1d0a2147059 (patch)
tree79448f6cc3df6d892c2fe22ead726b2a94a52111 /setup.py
parent730e0fbba6a2ef4a01a5a67759e15dad5613d3a9 (diff)
downloadpsutil-1ebe625e5aa21b33e9de5652c305d1d0a2147059.tar.gz
AIX support (#1123)
* AIX support * AIX support * AIX support * AIX support - use get_procfs_path() instead of /proc * AIX support - group sections like in other modules * AIX support * AIX support * AIX support * AIX support - remove unnecessary dict copy
Diffstat (limited to 'setup.py')
-rwxr-xr-xsetup.py15
1 files changed, 14 insertions, 1 deletions
diff --git a/setup.py b/setup.py
index 5f268349..1bc94083 100755
--- a/setup.py
+++ b/setup.py
@@ -37,6 +37,7 @@ from _common import OSX # NOQA
from _common import POSIX # NOQA
from _common import SUNOS # NOQA
from _common import WINDOWS # NOQA
+from _common import AIX # NOQA
macros = []
@@ -239,7 +240,17 @@ elif SUNOS:
],
define_macros=macros,
libraries=['kstat', 'nsl', 'socket'])
-
+# AIX
+elif AIX:
+ macros.append(("PSUTIL_AIX", 1))
+ ext = Extension(
+ 'psutil._psutil_aix',
+ sources=sources + [
+ 'psutil/_psutil_aix.c',
+ 'psutil/arch/aix/net_connections.c',
+ 'psutil/arch/aix/ifaddrs.c'],
+ libraries=['perfstat'],
+ define_macros=macros)
else:
sys.exit('platform %s is not supported' % sys.platform)
@@ -254,6 +265,8 @@ if POSIX:
if platform.release() == '5.10':
posix_extension.sources.append('psutil/arch/solaris/v10/ifaddrs.c')
posix_extension.define_macros.append(('PSUTIL_SUNOS10', 1))
+ elif AIX:
+ posix_extension.sources.append('psutil/arch/aix/ifaddrs.c')
extensions = [ext, posix_extension]
else: