forked from ros-infrastructure/ros_buildfarm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
60 lines (53 loc) · 1.86 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
import os
from setuptools import find_packages
from setuptools import setup
# Get a list of scripts to install
scripts = []
for root, dirnames, filenames in os.walk('scripts'):
# don't install the wrapper scripts
# since they would overlay Python packages with the same name
if 'wrapper' in dirnames:
dirnames.remove('wrapper')
for filename in filenames:
if not filename.endswith('.py'):
continue
scripts.append(os.path.join(root, filename))
# Get the long description out of the readme.md
with open(os.path.join(os.path.dirname(__file__), 'README.md'), 'r') as f:
long_description = f.read()
kwargs = {
'name': 'ros_buildfarm',
# same version as in:
# - ros_buildfarm/__init__.py
# - stdeb.cfg
'version': '2.0.2-master',
'packages': find_packages(exclude=['test']),
'scripts': scripts,
'include_package_data': True,
'zip_safe': False,
'install_requires': [
'empy',
'PyYAML'],
'author': 'Dirk Thomas',
'author_email': '[email protected]',
'maintainer': 'Dirk Thomas',
'maintainer_email': '[email protected]',
'url': 'https://github.com/ros-infrastructure/ros_buildfarm',
'keywords': ['ROS', 'buildfarm', 'catkin'],
'classifiers': [
'Programming Language :: Python',
'License :: OSI Approved :: Apache Software License'],
'description': "Build farm used to build the ROS ecosystem's packages.",
'long_description': long_description,
'license': 'Apache 2.0',
}
if os.sys.version_info[0] == 2:
kwargs['install_requires'].append('configparser')
if 'SKIP_PYTHON_MODULES' in os.environ:
kwargs['packages'] = []
elif 'SKIP_PYTHON_SCRIPTS' in os.environ:
kwargs['name'] += '_modules'
kwargs['scripts'] = []
else:
kwargs['install_requires'] += ['catkin_pkg >= 0.2.6', 'rosdistro >= 0.4.0']
setup(**kwargs)