numpy: fixed build (patch by Konrad Hinsen)

svn path=/nixpkgs/trunk/; revision=33941
This commit is contained in:
Peter Simons 2012-04-28 14:14:16 +00:00
parent ce7f9e1d14
commit 6c37520d2a
2 changed files with 31 additions and 2 deletions

View File

@ -0,0 +1,28 @@
diff -ur numpy-1.6.1-orig/numpy/distutils/system_info.py numpy-1.6.1/numpy/distutils/system_info.py
--- numpy-1.6.1-orig/numpy/distutils/system_info.py 2011-07-01 17:31:13.000000000 -0400
+++ numpy-1.6.1/numpy/distutils/system_info.py 2012-04-27 14:10:38.000000000 -0400
@@ -189,18 +189,12 @@
default_x11_lib_dirs = []
default_x11_include_dirs = []
else:
- default_lib_dirs = libpaths(['/usr/local/lib','/opt/lib','/usr/lib',
- '/opt/local/lib','/sw/lib'], platform_bits)
- default_include_dirs = ['/usr/local/include',
- '/opt/include', '/usr/include',
- '/opt/local/include', '/sw/include',
- '/usr/include/suitesparse']
- default_src_dirs = ['.','/usr/local/src', '/opt/src','/sw/src']
-
- default_x11_lib_dirs = libpaths(['/usr/X11R6/lib','/usr/X11/lib',
- '/usr/lib'], platform_bits)
- default_x11_include_dirs = ['/usr/X11R6/include','/usr/X11/include',
- '/usr/include']
+ default_lib_dirs = []
+ default_include_dirs = []
+ default_src_dirs = ['.']
+
+ default_x11_lib_dirs = []
+ default_x11_include_dirs = []
if os.path.join(sys.prefix, 'lib') not in default_lib_dirs:
default_lib_dirs.insert(0,os.path.join(sys.prefix, 'lib'))

View File

@ -1081,9 +1081,10 @@ let pythonPackages = python.modules // rec {
sha256 = "1pawfmf7j7pd3mjzhmmw9hkglc2qdirrkvv29m5nsmpf2b3ip2vq";
};
# TODO: add ATLAS=${pkgs.atlas}
patches = [ ../development/python-modules/numpy/no_default_dirs.patch ];
installCommand = ''
export BLAS=${pkgs.blas} LAPACK=${pkgs.liblapack}
export BLAS=${pkgs.blas} LAPACK=${pkgs.liblapack} ATLAS=${pkgs.atlas}
python setup.py build --fcompiler="gnu95"
python setup.py install --prefix=$out
'';