changeset 218:9634eefd2063

Minor changes to the setup script
author Thibaut Girka <thib@sitedethib.com>
date Mon, 05 Dec 2011 23:57:58 +0100
parents 577f45454402
children 091301805cce
files eclviewer.py setup.py
diffstat 1 files changed, 13 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/setup.py	Sat Dec 17 21:18:39 2011 +0100
+++ b/setup.py	Mon Dec 05 23:57:58 2011 +0100
@@ -1,10 +1,11 @@
 # -*- encoding: utf-8 -*-
 
 import os, sys
-#import shutil
 from distutils.core import setup
 from distutils.extension import Extension
 
+
+# Cython is needed
 try:
     from Cython.Distutils import build_ext
 except ImportError:
@@ -12,6 +13,7 @@
           'copy from www.cython.org and install it')
     sys.exit(1)
 
+
 packages = []
 extensions = []
 
@@ -20,14 +22,18 @@
     packages.append(package)
     for filename in files:
         if filename.endswith('.pyx'):
-            extensions.append(Extension('%s.%s' % (package, filename[:-4]),
-                                        ['%s/%s' % (directory, filename)]))
+            extension_name = '%s.%s' % (package, os.path.splitext(filename)[0])
+            extensions.append(Extension(extension_name,
+                                        [os.path.join(directory, filename)]))
 
-#TODO: put eclviewer.py in /usr/bin/ the right way
-#shutil.copyfile('eclviewer.py', 'pytouhou/pytouhou')
 
 setup(name='PyTouhou',
+      author='Thibaut Girka',
+      author_email='thib@sitedethib.com',
+      url='http://hg.sitedethib.com/touhou/',
+      license='GPLv3',
       packages=packages,
       ext_modules=extensions,
-      #scripts=['pytouhou/pytouhou'],
-      cmdclass = {'build_ext': build_ext})
+      cmdclass = {'build_ext': build_ext}
+     )
+