fix imports
authorTomas Musil <tomik.musil@gmail.com>
Fri, 18 Jul 2014 16:50:13 +0000 (18:50 +0200)
committerTomas Musil <tomik.musil@gmail.com>
Fri, 18 Jul 2014 16:50:32 +0000 (18:50 +0200)
makefile
src/imago.py
src/linef.py

index 9818e31..a6b9454 100644 (file)
--- a/makefile
+++ b/makefile
@@ -1,4 +1,4 @@
 install: pcf.c
-       gcc -O3 -fPIC -shared -I/usr/include/python2.7/ pcf.c -lpython2.7 -o src/pcf.so
+       gcc -Ofast -fPIC -shared -I/usr/include/python2.7/ pcf.c -lpython2.7 -o src/pcf.so
 clean:
        rm -f src/pcf.so src/*.pyc
index b87da99..93f2f3f 100755 (executable)
@@ -11,12 +11,11 @@ import argparse
 import pickle
 
 try:
-    import Image, ImageDraw
+    from PIL import Image, ImageDraw
 except ImportError, msg:
     print >> sys.stderr, msg
     sys.exit(1)
 
-import im_debug
 import linef
 import manual
 import intrsc
@@ -76,6 +75,7 @@ def main():
         do_something = Imsave("saved/" + args.files[0][:-4] + "_" +
                                str(image.size[0]) + "/").save
     else:
+        import im_debug
         do_something = im_debug.show
 
     if verbose:
index 8ebb702..aa9921b 100644 (file)
@@ -5,7 +5,7 @@ import sys
 from math import sin, cos, pi
 
 try:
-    import Image, ImageDraw
+    from PIL import Image, ImageDraw
 except ImportError, msg:
     print >> sys.stderr, msg
     sys.exit(1)