forked from sipeed/MaixPy3
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
55 lines (47 loc) · 1.38 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
#!/usr/bin/env python
"""
setup.py file for MaixPy3
"""
import sys
import platform
from setuptools import setup, Extension, find_packages
ext_modules = []
data_files = []
py_modules = []
sysstr = platform.system()
if (sysstr == "Windows"):
from envs.windows import _maix_modules, _maix_data_files, _maix_py_modules
elif (sysstr == "Linux"):
if 'maix_v831' in sys.argv:
sys.argv.remove('maix_v831')
from envs.maix_v831 import _maix_modules, _maix_data_files, _maix_py_modules
else:
from envs.general import _maix_modules, _maix_data_files, _maix_py_modules
ext_modules.extend(_maix_modules)
data_files.extend(_maix_data_files)
py_modules.extend(_maix_py_modules)
setup(
name='MaixPy3',
version='0.3.0',
license='MIT',
author='Sipeed',
author_email="[email protected]",
url='https://github.com/sipeed/MaixPy3',
description="MaixPy Python3 library",
long_description=open('README.md', 'r', encoding='UTF-8').read(),
long_description_content_type='text/markdown',
install_requires=py_modules,
ext_modules=ext_modules,
packages = find_packages(
exclude=['envs'] # remove from build
), # find __init__.py packages
classifiers=[
'Programming Language :: Python :: 3',
],
entry_points={"console_scripts": ["maixpy3_rpycs=maix.rpycs:start"]},
include_package_data=True,
package_data = {
'': ['*.so'],
},
data_files=data_files,
)