File tree 2 files changed +18
-10
lines changed
2 files changed +18
-10
lines changed Original file line number Diff line number Diff line change @@ -711,11 +711,19 @@ class Numpy(SetupPackage):
711
711
712
712
@staticmethod
713
713
def include_dirs_hook ():
714
- import __builtin__
715
- if hasattr (__builtin__ , '__NUMPY_SETUP__' ):
716
- del __builtin__ .__NUMPY_SETUP__
717
- import numpy
718
- reload (numpy )
714
+ if sys .version_info [0 ] >= 3 :
715
+ import builtins
716
+ if hasattr (builtins , '__NUMPY_SETUP__' ):
717
+ del builtins .__NUMPY_SETUP__
718
+ import imp
719
+ import numpy
720
+ imp .reload (numpy )
721
+ else :
722
+ import __builtin__
723
+ if hasattr (__builtin__ , '__NUMPY_SETUP__' ):
724
+ del __builtin__ .__NUMPY_SETUP__
725
+ import numpy
726
+ reload (numpy )
719
727
720
728
ext = Extension ('test' , [])
721
729
ext .include_dirs .append (numpy .get_include ())
Original file line number Diff line number Diff line change @@ -13,12 +13,12 @@ python.tmp/bin/python setup.py install
13
13
python.tmp/bin/python -c " import matplotlib"
14
14
rm -rf python.tmp
15
15
16
- # Tests that pip works
17
-
16
+ set -e
17
+ cd ..
18
18
rm -rf build
19
19
rm -rf numpy*
20
20
rm -rf python.tmp
21
- python unit/virtualenv.py python.tmp
22
- python.tmp/bin/pip install .
23
- python.tmp/bin/python -c " import matplotlib"
21
+ python3 unit/virtualenv.py python.tmp
22
+ python.tmp/bin/python3 setup.py install
23
+ python.tmp/bin/python3 -c " import matplotlib"
24
24
rm -rf python.tmp
You can’t perform that action at this time.
0 commit comments