setup.py
changeset 151 dfd8022d000e
parent 132 0260aeca943c
child 160 9953c5fe3629
--- a/setup.py	Mon Sep 15 01:34:42 2014 +0300
+++ b/setup.py	Mon Sep 15 01:48:29 2014 +0300
@@ -10,10 +10,10 @@
 except ImportError :
     CYTHON = False
 
-if CYTHON:
-    pypngtile_sources = [ "python/pypngtile.pyx" ]
+if CYTHON and os.path.exists('python/pypngtile.pyx'):
+    pypngtile_sources = [ 'python/pypngtile.pyx' ]
 elif os.path.exists("python/pypngtile.c"):
-    pypngtile_sources = [ "python/pypngtile.c" ]
+    pypngtile_sources = [ 'python/pypngtile.c' ]
 else:
     raise Exception("Building from source requires Cython")