Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Seems must define list of extensions earlier for them to be installed…

… on Python 3.1
  • Loading branch information...
commit 48d1716e2a39b493cbb9e7179865ae015f03e795 1 parent 9f893f1
@peterjc peterjc authored
Showing with 22 additions and 21 deletions.
  1. +22 −21 setup.py
View
43 setup.py
@@ -151,27 +151,6 @@ class build_ext_biopython(build_ext):
def run(self):
if not check_dependencies_once():
return
- # add software that requires NumPy to install
- if is_Numpy_installed():
- import numpy
- numpy_include_dir = numpy.get_include()
- self.extensions.append(
- Extension('Bio.Cluster.cluster',
- ['Bio/Cluster/clustermodule.c',
- 'Bio/Cluster/cluster.c'],
- include_dirs=[numpy_include_dir],
- ))
- self.extensions.append(
- Extension('Bio.KDTree._CKDTree',
- ["Bio/KDTree/KDTree.c",
- "Bio/KDTree/KDTreemodule.c"],
- include_dirs=[numpy_include_dir],
- ))
- self.extensions.append(
- Extension('Bio.Motif._pwm',
- ["Bio/Motif/_pwm.c"],
- include_dirs=[numpy_include_dir],
- ))
build_ext.run(self)
@@ -324,6 +303,28 @@ def is_Numpy_installed():
),
]
+#Add extensions that requires NumPy to build
+if is_Numpy_installed():
+ import numpy
+ numpy_include_dir = numpy.get_include()
+ EXTENSIONS.append(
+ Extension('Bio.Cluster.cluster',
+ ['Bio/Cluster/clustermodule.c',
+ 'Bio/Cluster/cluster.c'],
+ include_dirs=[numpy_include_dir],
+ ))
+ EXTENSIONS.append(
+ Extension('Bio.KDTree._CKDTree',
+ ["Bio/KDTree/KDTree.c",
+ "Bio/KDTree/KDTreemodule.c"],
+ include_dirs=[numpy_include_dir],
+ ))
+ EXTENSIONS.append(
+ Extension('Bio.Motif._pwm',
+ ["Bio/Motif/_pwm.c"],
+ include_dirs=[numpy_include_dir],
+ ))
+
#We now define the Biopython version number in Bio/__init__.py
#Here we can't use "import Bio" then "Bio.__version__" as that would
Please sign in to comment.
Something went wrong with that request. Please try again.