Gentoo Archives: gentoo-commits

From: Alexis Ballier <aballier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ros/rosbridge_server/files/, dev-ros/rosbridge_server/
Date: Sun, 01 Nov 2015 23:10:46
Message-Id: 1446419431.f69842be50589f050caaaed2cc145be489592d5a.aballier@gentoo
1 commit: f69842be50589f050caaaed2cc145be489592d5a
2 Author: Alexis Ballier <aballier <AT> gentoo <DOT> org>
3 AuthorDate: Sun Nov 1 23:10:25 2015 +0000
4 Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org>
5 CommitDate: Sun Nov 1 23:10:31 2015 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f69842be
7
8 dev-ros/rosbridge_server: Unbundle tornado. Bug #564644.
9
10 Package-Manager: portage-2.2.23
11
12 dev-ros/rosbridge_server/files/tornado.patch | 91 ++++++++++++++++++++++
13 ...r1.ebuild => rosbridge_server-0.7.13-r2.ebuild} | 6 +-
14 .../rosbridge_server/rosbridge_server-9999.ebuild | 6 +-
15 3 files changed, 101 insertions(+), 2 deletions(-)
16
17 diff --git a/dev-ros/rosbridge_server/files/tornado.patch b/dev-ros/rosbridge_server/files/tornado.patch
18 new file mode 100644
19 index 0000000..ae23913
20 --- /dev/null
21 +++ b/dev-ros/rosbridge_server/files/tornado.patch
22 @@ -0,0 +1,91 @@
23 +Index: rosbridge_server/setup.py
24 +===================================================================
25 +--- rosbridge_server.orig/setup.py
26 ++++ rosbridge_server/setup.py
27 +@@ -10,85 +10,9 @@ from catkin_pkg.python_setup import gene
28 +
29 + d = generate_distutils_setup(
30 + packages=[
31 +- 'rosbridge_server',
32 +- 'tornado',
33 +- 'tornado.platform'
34 ++ 'rosbridge_server'
35 + ],
36 + package_dir={'': 'src'}
37 + )
38 +
39 +-# The following code is copied from
40 +-# https://github.com/mongodb/mongo-python-driver/blob/master/setup.py
41 +-# to support installing without the extension on platforms where
42 +-# no compiler is available.
43 +-from distutils.command.build_ext import build_ext
44 +-
45 +-class custom_build_ext(build_ext):
46 +- """Allow C extension building to fail.
47 +-
48 +- The C extension speeds up websocket masking, but is not essential.
49 +- """
50 +-
51 +- warning_message = """
52 +-********************************************************************
53 +-WARNING: %s could not
54 +-be compiled. No C extensions are essential for Tornado to run,
55 +-although they do result in significant speed improvements for
56 +-websockets.
57 +-%s
58 +-
59 +-Here are some hints for popular operating systems:
60 +-
61 +-If you are seeing this message on Linux you probably need to
62 +-install GCC and/or the Python development package for your
63 +-version of Python.
64 +-
65 +-Debian and Ubuntu users should issue the following command:
66 +-
67 +- $ sudo apt-get install build-essential python-dev
68 +-
69 +-RedHat, CentOS, and Fedora users should issue the following command:
70 +-
71 +- $ sudo yum install gcc python-devel
72 +-********************************************************************
73 +-"""
74 +-
75 +- def run(self):
76 +- try:
77 +- build_ext.run(self)
78 +- except Exception:
79 +- e = sys.exc_info()[1]
80 +- sys.stdout.write('%s\n' % str(e))
81 +- warnings.warn(self.warning_message % ("Extension modules",
82 +- "There was an issue with "
83 +- "your platform configuration"
84 +- " - see above."))
85 +-
86 +- def build_extension(self, ext):
87 +- name = ext.name
88 +- try:
89 +- build_ext.build_extension(self, ext)
90 +- except Exception:
91 +- e = sys.exc_info()[1]
92 +- sys.stdout.write('%s\n' % str(e))
93 +- warnings.warn(self.warning_message % ("The %s extension "
94 +- "module" % (name,),
95 +- "The output above "
96 +- "this warning shows how "
97 +- "the compilation "
98 +- "failed."))
99 +-
100 +-if (platform.python_implementation() == 'CPython' and
101 +- os.environ.get('TORNADO_EXTENSION') != '0'):
102 +- # This extension builds and works on pypy as well, although pypy's jit
103 +- # produces equivalent performance.
104 +- d['ext_modules'] = [
105 +- Extension('tornado.speedups', sources=['src/tornado/speedups.c']),
106 +- ]
107 +-
108 +- if os.environ.get('TORNADO_EXTENSION') != '1':
109 +- # Unless the user has specified that the extension is mandatory,
110 +- # fall back to the pure-python implementation on any build failure.
111 +- d['cmdclass'] = {'build_ext': custom_build_ext}
112 +-
113 + setup(**d)
114
115 diff --git a/dev-ros/rosbridge_server/rosbridge_server-0.7.13-r1.ebuild b/dev-ros/rosbridge_server/rosbridge_server-0.7.13-r2.ebuild
116 similarity index 85%
117 rename from dev-ros/rosbridge_server/rosbridge_server-0.7.13-r1.ebuild
118 rename to dev-ros/rosbridge_server/rosbridge_server-0.7.13-r2.ebuild
119 index cc30070..de81526 100644
120 --- a/dev-ros/rosbridge_server/rosbridge_server-0.7.13-r1.ebuild
121 +++ b/dev-ros/rosbridge_server/rosbridge_server-0.7.13-r2.ebuild
122 @@ -21,6 +21,10 @@ RDEPEND="
123 dev-ros/rosbridge_library[${PYTHON_USEDEP},${CATKIN_MESSAGES_PYTHON_USEDEP}]
124 dev-ros/rosauth[${PYTHON_USEDEP}]
125 dev-python/backports-ssl-match-hostname[${PYTHON_USEDEP}]
126 + www-servers/tornado[${PYTHON_USEDEP}]
127 "
128 DEPEND="${RDEPEND}"
129 -PATCHES=( "${FILESDIR}/backports-ssl.patch" )
130 +PATCHES=(
131 + "${FILESDIR}/backports-ssl.patch"
132 + "${FILESDIR}/tornado.patch"
133 +)
134
135 diff --git a/dev-ros/rosbridge_server/rosbridge_server-9999.ebuild b/dev-ros/rosbridge_server/rosbridge_server-9999.ebuild
136 index cc30070..de81526 100644
137 --- a/dev-ros/rosbridge_server/rosbridge_server-9999.ebuild
138 +++ b/dev-ros/rosbridge_server/rosbridge_server-9999.ebuild
139 @@ -21,6 +21,10 @@ RDEPEND="
140 dev-ros/rosbridge_library[${PYTHON_USEDEP},${CATKIN_MESSAGES_PYTHON_USEDEP}]
141 dev-ros/rosauth[${PYTHON_USEDEP}]
142 dev-python/backports-ssl-match-hostname[${PYTHON_USEDEP}]
143 + www-servers/tornado[${PYTHON_USEDEP}]
144 "
145 DEPEND="${RDEPEND}"
146 -PATCHES=( "${FILESDIR}/backports-ssl.patch" )
147 +PATCHES=(
148 + "${FILESDIR}/backports-ssl.patch"
149 + "${FILESDIR}/tornado.patch"
150 +)