Repository navigation
Expand file tree
/
Copy pathsetup.py
More file actions
executable file
·70 lines (62 loc) · 1.98 KB
/
Copy pathsetup.py
File metadata and controls
executable file
·70 lines (62 loc) · 1.98 KB
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
66
67
68
69
70
#!/usr/bin/env python
import sys
from distutils.core import setup
import os
def ls_r(dir):
def do_reduce(a, b):
files = []
for f in b[2]:
files.append(os.path.join(b[0], f))
a.append((b[0], files))
return a
return reduce(do_reduce, os.walk(dir), [])
packages = ['lanshark']
try:
import simplejson
except ImportError:
packages += ['simplejson']
kwargs = {
'name': 'lanshark',
'version': "1.0.0 beta",
'description': 'A P2P Filesharing tool for local area networks',
'author': 'Jonas Wagner',
'author_email': 'veers@gmx.ch',
'url': 'http://lanshark.29a.ch',
'packages': packages,
'scripts': ['bin/lansharkgui', 'bin/lansharkc', 'bin/lansharkd'],
'options': {'py2exe':{
'packages': 'encodings',
'includes': 'cairo, pango, pangocairo, atk, gobject',
'dist_dir': 'dist/win32',
'optimize': 2,
}},
'license': 'GNU GPL v3',
'data_files': ls_r('share'),
#install_requires=["pygtk >= 2.10"],
'classifiers': ['Development Status :: 4 - Beta',
'Environment :: Console',
'Environment :: No Input/Output (Daemon)',
'Environment :: Web Environment',
'Environment :: X11 Applications :: GTK',
'Intended Audience :: End Users/Desktop',
'License :: OSI Approved :: GNU General Public License (GPL)',
'Natural Language :: English',
'Natural Language :: German',
'Operating System :: POSIX',
'Operating System :: Microsoft',
'Programming Language :: Python',
'Topic :: Communications :: File Sharing']
}
try:
import simplejson
except ImportError:
kwargs['packages'] += ["simplejson"]
kwargs['package_dir']['simplejson'] = 'src/simplejson'
try:
import py2exe
kwargs['windows'] = [{'script': 'src/lansharkgui',
'icon_resources': [(1, 'lanshark.ico')],
'dest_base': 'lanshark'}]
except ImportError:
pass
setup(**kwargs)