view setup.py @ 215:ab6e6909ce04

Don’t scale texture instead of shifting it, fix ANM’s 28th opcode.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Wed, 07 Dec 2011 13:23:02 +0100
parents 9bdf116bb2a5
children 9634eefd2063
line wrap: on
line source

# -*- encoding: utf-8 -*-

import os, sys
#import shutil
from distutils.core import setup
from distutils.extension import Extension

try:
    from Cython.Distutils import build_ext
except ImportError:
    print('You don’t seem to have Cython installed. Please get a '
          'copy from www.cython.org and install it')
    sys.exit(1)

packages = []
extensions = []

for directory, _, files in os.walk('pytouhou'):
    package = directory.replace(os.path.sep, '.')
    packages.append(package)
    for filename in files:
        if filename.endswith('.pyx'):
            extensions.append(Extension('%s.%s' % (package, filename[:-4]),
                                        ['%s/%s' % (directory, filename)]))

#TODO: put eclviewer.py in /usr/bin/ the right way
#shutil.copyfile('eclviewer.py', 'pytouhou/pytouhou')

setup(name='PyTouhou',
      packages=packages,
      ext_modules=extensions,
      #scripts=['pytouhou/pytouhou'],
      cmdclass = {'build_ext': build_ext})