source: setup.py@ 287:67387621c61b

Last change on this file since 287:67387621c61b was 287:67387621c61b, checked in by David Fraser <davidf@…>, 9 years ago

Added requirements.txt and use it from setup.py

  • Property exe set to *
File size: 3.6 KB
Line 
1# setup.py
2# -*- coding: utf8 -*-
3# vim:fileencoding=utf8 ai ts=4 sts=4 et sw=4
4
5"""Setuptools setup.py file for nagslang."""
6
7from setuptools import setup, find_packages
8
9try:
10 import py2exe
11 py2exe # To make pyflakes happy.
12except ImportError:
13 pass
14
15try:
16 from pip.req import parse_requirements
17 import os
18 install_reqs = parse_requirements(os.path.join(os.path.dirname(__file__), 'requirements.txt'))
19 reqs = [str(ir.req) for ir in install_reqs]
20except ImportError:
21 reqs = []
22
23# This should probably be pulled from constants.py
24VERSION_STR = "0.1a"
25
26setup(
27 name="nagslang",
28 version=VERSION_STR,
29 description="naglsang: Game for PyWeek 17",
30
31 author=(", ".join([
32 "Simon Cross",
33 "Oliver Hambsch",
34 "Anna Malczyk",
35 "Neil Muller",
36 "Adrianna Pinska",
37 "Stefano Rivera",
38 "David Sharpe",
39 "Jeremy Thurgood",
40 ])),
41 author_email="ctpug@googlegroups.com",
42
43 maintainer="Nagslang Team",
44 maintainer_email="ctpug@googlegroups.com",
45
46 url="http://ctpug.org.za/",
47 download_url="https://ctpug.org.za/hg/nagslang/",
48
49 license="MIT",
50
51 classifiers=[
52 'Development Status :: 4 - Beta',
53 'Environment :: MacOS X',
54 'Environment :: Win32 (MS Windows)',
55 'Environment :: X11 Applications',
56 'Intended Audience :: End Users/Desktop',
57 'License :: OSI Approved :: MIT License',
58 'Natural Language :: English',
59 'Operating System :: Microsoft :: Windows',
60 'Operating System :: POSIX',
61 'Operating System :: MacOS :: MacOS X',
62 'Programming Language :: Python :: 2.5',
63 'Programming Language :: Python :: 2.6',
64 'Topic :: Games/Entertainment :: Role-Playing',
65 'Topic :: Games/Entertainment :: Arcade',
66 ],
67
68 platforms=[
69 'Linux',
70 'Mac OS X',
71 'Windows',
72 ],
73
74 # Dependencies
75 install_requires=reqs,
76
77 # Files
78 packages=find_packages(),
79 scripts=[
80 'scripts/nagslang',
81 ],
82
83 # py2exe
84 console=['scripts/testconsole.py'],
85 windows=[{
86 'script': 'scripts/nagslang',
87 'icon_resources': [(0, "data/icons/program/icon.ico")],
88 }],
89 app=['scripts/nagslang'],
90 options={
91 'py2exe': {
92 'skip_archive': 1,
93 'dist_dir': 'dist/nagslang-%s' % VERSION_STR,
94 'packages': [
95 'logging', 'encodings', 'nagslang',
96 ],
97 'includes': [
98 'pygame',
99 ],
100 'excludes': [
101 'numpy',
102 ],
103 'ignores': [
104 # all database modules
105 'pgdb', 'Sybase', 'adodbapi',
106 'kinterbasdb', 'psycopg', 'psycopg2', 'pymssql',
107 'sapdb', 'pysqlite2', 'sqlite', 'sqlite3',
108 'MySQLdb', 'MySQLdb.connections',
109 'MySQLdb.constants.CR', 'MySQLdb.constants.ER',
110 # old datetime equivalents
111 'DateTime', 'DateTime.ISO',
112 'mx', 'mx.DateTime', 'mx.DateTime.ISO',
113 # email modules
114 'email.Generator', 'email.Iterators', 'email.Utils',
115 ],
116 },
117 'py2app': {
118 'app': ['run_game.py'],
119 'argv_emulation': True,
120 'iconfile': 'data/icons/program/icon.icns',
121 'packages': [
122 'logging', 'encodings', 'pygame', 'nagslang', 'data',
123 ],
124 'excludes': ['numpy'],
125 }},
126 data_files=[
127 # 'COPYRIGHT',
128 'LICENSE.txt',
129 'README.txt',
130 ],
131 include_package_data=True,
132)
Note: See TracBrowser for help on using the repository browser.