1 from distutils.core import setup
2 from distutils.sysconfig import get_python_lib
5 from Cython.Compiler.Version import version
7 compiler_dir = os.path.join(get_python_lib(prefix=''), 'Cython/Compiler')
8 if sys.platform == "win32":
9 compiler_dir = compiler_dir[len(sys.prefix)+1:]
13 if sys.version_info < (2,4):
14 compiler_dir = os.path.join(get_python_lib(prefix=''), 'Cython/Compiler')
15 setup_args['data_files'] = [
16 {compiler_dir : ['Cython/Compiler/Lexicon.pickle']}]
18 setup_args['package_data'] = {'Cython.Compiler' : ['Lexicon.pickle']}
20 if os.name == "posix":
21 scripts = ["bin/cython"]
23 scripts = ["cython.py"]
28 url = 'http://www.cython.org',
29 author = 'Greg Ewing, William Stein, Robert Bradshaw, Stefan Behnel, et al.',
30 author_email = 'wstein@gmail.com',
31 description = "The Cython compiler for writing C extensions for the Python language.",
32 long_description = """\
33 The Cython language makes writing C extensions for the Python language as
34 easy as Python itself. Cython is a source code translator based on the
35 well-known Pyrex_, but supports more cutting edge functionality and
38 The Cython language is very close to the Python language (and most Python
39 code is also valid Cython code), but Cython additionally supports calling C
40 functions and declaring C types on variables and class attributes. This
41 allows the compiler to generate very efficient C code from Cython code.
43 This makes Cython the ideal language for writing glue code for external C
44 libraries, and for fast C modules that speed up the execution of Python
47 .. _Pyrex: http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
50 "Development Status :: 5 - Production/Stable",
51 "Intended Audience :: Developers",
52 "License :: OSI Approved :: Python Software Foundation License",
53 "Operating System :: OS Independent",
54 "Programming Language :: Python",
55 "Programming Language :: C",
56 "Topic :: Software Development :: Code Generators",
57 "Topic :: Software Development :: Compilers",
58 "Topic :: Software Development :: Libraries :: Python Modules"