forked from rcwoolley/device-cloud-python
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
executable file
·81 lines (74 loc) · 3.19 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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
'''
Copyright (c) 2016-2017 Wind River Systems, Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at:
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed
under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES
OR CONDITIONS OF ANY KIND, either express or implied.
'''
from setuptools import setup
import sys, os
pyver = sys.version_info
ret = []
def addDir(filedir):
abspath = os.path.dirname(os.path.abspath(__file__))+os.sep+filedir
for filename in os.listdir(abspath):
if os.path.isdir(abspath+os.sep+filename):
addDir(filedir+os.sep+filename)
else:
path = filedir+os.sep+filename
key = ("share/device_cloud/"+filedir, [path])
ret.append(key)
return ret
if pyver < (2,7,9) or (pyver > (3,0,0) and pyver < (3,4,0)):
print("Sorry, your Python version ({}.{}.{}) is not supported by device_cloud!".format(pyver[0], pyver[1], pyver[2]))
sys.exit('Please upgrade to Python 2.7.9 or 3.4 and try again.')
setup(
name='device_cloud',
version='17.12.06',
description='Python library for Wind River\'s Helix Device Cloud',
author='Wind River Systems',
author_email='',
packages=['device_cloud','device_cloud._core','device_cloud.test'],
data_files = [('share/device_cloud/docs', ['docs/paho-mqtt-QOS.md']),
('share/device_cloud/demo', ['demo/action.bat',
'demo/action.sh',
'demo/iot-simple-actions.py',
'demo/iot-simple-location.py',
'demo/iot-simple-telemetry.py']),
('share/device_cloud', ['generate_config.py',
'device_manager.py',
'iot.cfg',
'COPYING.txt',
'README.md',
'README.macOSX.md',
'README.style.md'])] + addDir("share"),
install_requires=[
'certifi',
'paho-mqtt',
'PySocks',
'queues',
'requests',
'simplejson',
'urllib3',
'websocket',
'websocket-client'
],
maintainer='Paul Barrette',
maintainer_email='paul.barrette@windriver.com',
url='http://www.windriver.com/products/helix/',
license='Apache License, Version 2.0',
classifiers=[
'Development Status :: 4 - Beta',
'Intended Audience :: Developers',
'Natural Language :: English',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.4',
'Operating System :: Microsoft :: Windows :: Windows 7',
'Operating System :: Microsoft :: Windows :: Windows 10',
'Operating System :: POSIX :: Linux',
'Topic :: Software Development :: Libraries :: Python Modules'
]
)