summaryrefslogtreecommitdiff
path: root/numpy/distutils/system_info.py
diff options
context:
space:
mode:
authorNick Papior <nickpapior@gmail.com>2016-01-17 19:23:59 +0100
committerNick Papior <nickpapior@gmail.com>2016-01-17 19:23:59 +0100
commit2da37a0e49c169f79f98e0e9d5b0370e9344029f (patch)
tree37d4f259a276b2c63e587d25164d66061d4c1660 /numpy/distutils/system_info.py
parentafd11746fc4e0f0c06c6331798bf66520183de4d (diff)
downloadnumpy-2da37a0e49c169f79f98e0e9d5b0370e9344029f.tar.gz
ENH: Allow site.cfg information with libraries key
This PR fixes the case when users create a site.cfg to fix library locations, but does not change the library names. Now numpy.distutils correctly checks all options related to libraries by defaulting to the library from the class via _lib_names Signed-off-by: Nick Papior <nickpapior@gmail.com>
Diffstat (limited to 'numpy/distutils/system_info.py')
-rw-r--r--numpy/distutils/system_info.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/numpy/distutils/system_info.py b/numpy/distutils/system_info.py
index d7b9bfbed..a541bfae2 100644
--- a/numpy/distutils/system_info.py
+++ b/numpy/distutils/system_info.py
@@ -663,7 +663,10 @@ class system_info(object):
return [b for b in [a.strip() for a in libs.split(',')] if b]
def get_libraries(self, key='libraries'):
- return self.get_libs(key, '')
+ if hasattr(self, '_lib_names'):
+ return self.get_libs(key, default=self._lib_names)
+ else:
+ return self.get_libs(key, '')
def library_extensions(self):
static_exts = ['.a']