-
Notifications
You must be signed in to change notification settings - Fork 57
/
setup.py
65 lines (50 loc) · 1.91 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# Copyright 2007 The Spitfire Authors. All Rights Reserved.
#
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
import os.path
import platform
from setuptools import Extension
from setuptools import setup
import spitfire
NAME = 'spitfire'
DESCRIPTION = 'text-to-python template language'
VERSION = spitfire.__version__
AUTHOR = spitfire.__author__
AUTHOR_EMAIL = spitfire.__author_email__
LICENSE = spitfire.__license__
PLATFORMS = ['Posix', 'MacOS X', 'Windows']
CLASSIFIERS = ['Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Code Generators',
'Topic :: Text Processing']
PACKAGES = ['spitfire',
'spitfire.compiler',
'spitfire.compiler.macros',
'spitfire.runtime']
PY_MODULES = ['third_party.yapps2.yappsrt']
SCRIPTS = ['scripts/crunner.py', 'scripts/spitfire-compile']
EXT_MODULES = [Extension('spitfire.runtime._baked',
[os.path.join('spitfire', 'runtime', '_baked.c')]),
Extension('spitfire.runtime._template',
[os.path.join('spitfire', 'runtime', '_template.c')]),
Extension('spitfire.runtime._udn',
[os.path.join('spitfire', 'runtime', '_udn.c')])]
# Disable C extensions for PyPy.
if platform.python_implementation() == 'PyPy':
EXT_MODULES = None
setup(name=NAME,
description=DESCRIPTION,
version=VERSION,
author=AUTHOR,
author_email=AUTHOR_EMAIL,
license=LICENSE,
platforms=PLATFORMS,
classifiers=CLASSIFIERS,
packages=PACKAGES,
py_modules=PY_MODULES,
scripts=SCRIPTS,
ext_modules=EXT_MODULES)