forked from OpenMTC/OpenMTC
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup-sdk.py
executable file
·75 lines (65 loc) · 2.11 KB
/
setup-sdk.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
66
67
68
69
70
71
72
73
74
75
#!/usr/bin/env python3
from setuptools import setup
from distutils.core import setup
from utils import get_packages, OpenMTCSdist
# name and version
NAME = "sdk"
SETUP_NAME = "openmtc-" + NAME
SETUP_VERSION = "1.3.0"
SETUP_DESCRIPTION = "The OpenMTC Python SDK"
# meta
SETUP_AUTHOR = "Konrad Campowsky"
SETUP_AUTHOR_EMAIL = "[email protected]"
SETUP_URL = "http://www.openmtc.org"
SETUP_LICENSE = "Fraunhofer FOKUS proprietary"
# requirements
SETUP_REQUIRES = [
"urllib3", "gevent (>=1.0)", "iso8601 (>=0.1.5)", "werkzeug (>=0.9)",
"blist", "simplejson", "ujson", "python_socketio", "gevent_websocket",
"flask", "enum34", "geventhttpclient"
]
SETUP_INSTALL_REQUIRES = [
"urllib3", "gevent >= 1.0", "iso8601 >= 0.1.5", "werkzeug >= 0.9",
"blist", "simplejson", "ujson", "python_socketio", "gevent_websocket",
"flask", "enum34", "geventhttpclient"
]
# packages
PACKAGES = ["aplus", "openmtc", "openmtc_onem2m", "futile", "openmtc_app"]
PACKAGE_DIR = {
"": "common/openmtc/lib",
"openmtc": "common/openmtc/src/openmtc",
"openmtc_onem2m": "common/openmtc-onem2m/src/openmtc_onem2m",
"openmtc_app": "openmtc-app/src/openmtc_app",
"futile": "futile/src/futile"
}
all_packages = []
for package in PACKAGES:
all_packages.extend(get_packages(package, PACKAGE_DIR))
# scripts
SETUP_SCRIPTS = []
# package data
PACKAGE_DATA = {NAME: []}
# data files
DATA_FILES = []
# cmd class
CMD_CLASS = {'sdist': OpenMTCSdist}
if __name__ == "__main__":
############################################################################
# setup
setup(name=SETUP_NAME,
version=SETUP_VERSION,
description=SETUP_DESCRIPTION,
author=SETUP_AUTHOR,
author_email=SETUP_AUTHOR_EMAIL,
url=SETUP_URL,
license=SETUP_LICENSE,
requires=SETUP_REQUIRES,
install_requires=SETUP_INSTALL_REQUIRES,
package_dir=PACKAGE_DIR,
packages=all_packages,
scripts=SETUP_SCRIPTS,
package_data=PACKAGE_DATA,
data_files=DATA_FILES,
cmdclass=CMD_CLASS,
py_modules=["pyio"]
)