mirror of
https://github.com/wassname/scikit-image.git
synced 2026-06-27 17:17:07 +08:00
Warn if user tries to build with older Cython version
This commit is contained in:
+5
-1
@@ -1,7 +1,7 @@
|
||||
import sys
|
||||
import os
|
||||
import hashlib
|
||||
import subprocess
|
||||
from distutils.version import LooseVersion
|
||||
|
||||
# WindowsError is not defined on unix systems
|
||||
try:
|
||||
@@ -25,6 +25,10 @@ def cython(pyx_files, working_path=''):
|
||||
return
|
||||
|
||||
try:
|
||||
from Cython import __version__
|
||||
if LooseVersion(__version__) < '0.23':
|
||||
raise RuntimeError('Cython >= 0.23 needed to build scikit-image')
|
||||
|
||||
from Cython.Build import cythonize
|
||||
except ImportError:
|
||||
# If cython is not found, we do nothing -- the build will make use of
|
||||
|
||||
Reference in New Issue
Block a user