source: setup.py@ 24:cd794f1c6ff0

Last change on this file since 24:cd794f1c6ff0 was 20:c2c47ea02649, checked in by István Váradi <ivaradi@…>, 13 years ago

Added support for creating an installer package

File size: 1.7 KB
RevLine 
[20]1# -*- coding: iso-8859-2 -*-
2
3import sys
4import os
5from glob import glob
6from distutils.core import setup
7
8sys.path.insert(0, os.path.join(os.path.dirname(sys.argv[0]), "src"))
9
10import const
11
12data_files = []
13if os.name=="nt":
14 import py2exe
15
16 msvcrDir = os.environ["MSVCRDIR"] if "MSVCRDIR" in os.environ else None
17 if msvcrDir:
18 data_files.append(("Microsoft.VC90.CRT", glob(os.path.join(msvcrDir, "*.*"))))
19
20 gtkRuntimeDir = os.environ["GTKRTDIR"] if "GTKRTDIR" in os.environ else None
21 if gtkRuntimeDir:
22 path = os.path.join("lib", "gtk-2.0", "2.10.0", "engines")
23 data_files.append((path, [os.path.join(gtkRuntimeDir, path, "libwimp.dll")]))
24
25 path = os.path.join("share", "themes", "MS-Windows", "gtk-2.0")
26 data_files.append((path, glob(os.path.join(gtkRuntimeDir, path, "*"))))
27
28 with open("mlx-common.nsh", "wt") as f:
29 print >>f, '!define MLX_VERSION "%s"' % (const.VERSION)
30 f.close()
31
32long_description="""MAVA Logger X
33
34This is a program to log and evaluate the actions
35of a pilot flying a virtual Malév flight operated
36by MAVA."""
37
38setup(name = "mlx",
39 version = const.VERSION,
40 description = "MAVA Logger X",
41 long_description = long_description,
42 author = "István Váradi",
43 author_email = "ivaradi@gmail.com",
44 url = "http://mlx.varadiistvan.hu",
45 package_dir = { "" : "src" },
46 packages = [""],
47 requires = ["pyuipc"],
48 windows = [{ "script" : "src/runmlx.py" }],
49 options = { "py2exe" : { "includes": "gio, pango, atk, pangocairo"} },
50 data_files = data_files,
51 platforms = ["Win32", "Linux"],
52 license = "Public Domain"
53 )
Note: See TracBrowser for help on using the repository browser.