Gentoo Archives: gentoo-commits

From: "Tiziano Müller" <dev-zero@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] dev/dev-zero:master commit in: www-misc/mozilla-sync-server-core/files/, www-misc/mozilla-sync-server-core/
Date: Mon, 02 Dec 2013 06:21:39
Message-Id: 1385965285.6fc14b60c8959907874592c2743c60627d515f61.dev-zero@gentoo
1 commit: 6fc14b60c8959907874592c2743c60627d515f61
2 Author: Tiziano Müller <dev-zero <AT> gentoo <DOT> org>
3 AuthorDate: Mon Dec 2 06:21:25 2013 +0000
4 Commit: Tiziano Müller <dev-zero <AT> gentoo <DOT> org>
5 CommitDate: Mon Dec 2 06:21:25 2013 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=dev/dev-zero.git;a=commit;h=6fc14b60
7
8 Add mozilla-sync-server-core, based on ebuilds by klondike and Stijn Tintel
9
10 ---
11 www-misc/mozilla-sync-server-core/Manifest | 4 +
12 .../files/2.15.1-sqlalchemy-0.8.patch | 65 +++++++++++++++++
13 .../files/2.15.1-wsgiproxy2.patch | 60 +++++++++++++++
14 .../mozilla-sync-server-core-2.15.1.ebuild | 85 ++++++++++++++++++++++
15 4 files changed, 214 insertions(+)
16
17 diff --git a/www-misc/mozilla-sync-server-core/Manifest b/www-misc/mozilla-sync-server-core/Manifest
18 new file mode 100644
19 index 0000000..911bb1f
20 --- /dev/null
21 +++ b/www-misc/mozilla-sync-server-core/Manifest
22 @@ -0,0 +1,4 @@
23 +AUX 2.15.1-sqlalchemy-0.8.patch 2555 SHA256 aefde0bdd4be89b6d45ff4e3256183d48a72beba998c71a5a3a37cb23ea30cbb SHA512 55c435835f7f6a2c134b4e94921959973216bb310f4405c6915069b71be286b9b7bb3c13579bc91e3e38b04a5f15c128b737c72d87d56bcb8cad9ea0ef335661 WHIRLPOOL 95aa6cb47620a4a36999bdc4df69fb13fd67d69f2b963b9fedd7027ec187b86aaa4d25427402c962dba3c47984f5cbc7917f95a595914e1fdd882134afbebbea
24 +AUX 2.15.1-wsgiproxy2.patch 1857 SHA256 d9dfd99d4162015eb762ebef46012ecd4f931cd104f40c4e53f653925811121f SHA512 f47ad6886415eb154437e336a8455f3a5a796cdb3ae5bb64a0326fb9deb8fcbabaa5e9425e55aeb08b55362e0bc4b2f5f5e71f34cc55cd5f8007ce42385f4307 WHIRLPOOL 0f2c5c2a195b27bef3c251125f0e388f64e413dfc4876e28b3531ac84c42ccf8c96ffaf2125ec65cdb4aab0c60154303ba93b59f851236447edeeedcf2170a59
25 +DIST server-core-rpm-2.15-1.tar.bz2 72312 SHA256 6976aa1d86dcfd9e06ac4b23ed1c8b72c2255886da473d219e9745fac90712f0 SHA512 aa172c7dd9ae92730c1fc7540c8fe440e1fc45a4f3314a85589213749acda642dbe37118500250d4aa5930c3d035b75bb44edd9a16f017f5b64fb341c41524cb WHIRLPOOL c4864922684a7b5100e2c0be9171c17071f9547fb01e5585751c813849250d2af96ad52306ac81007c1ef4918d8a6e09566f042e43ded02fd32b434b363c26c6
26 +EBUILD mozilla-sync-server-core-2.15.1.ebuild 2647 SHA256 76858f022827215a6121cc240d7897a98f077e6952d2eb574480e81481c85ce0 SHA512 2cd7c9fd7bac7a35d7072018ae9e6015730cc04745eb0226e8eb03f3f4c59a9ddf320f8731c33e3390c8ff8bd53a63965f9c86b93cde17da346e48d382d2cf46 WHIRLPOOL dd6e474162b6c84bb77f7d8426d4cfba8eb0ca23066c2cbbe9396f9e7507f2eb09bda4c59c6b8e8480a3834a7a8142b9d2bdd05ad96f13e5c8896db3955e18a6
27
28 diff --git a/www-misc/mozilla-sync-server-core/files/2.15.1-sqlalchemy-0.8.patch b/www-misc/mozilla-sync-server-core/files/2.15.1-sqlalchemy-0.8.patch
29 new file mode 100644
30 index 0000000..afff2cf
31 --- /dev/null
32 +++ b/www-misc/mozilla-sync-server-core/files/2.15.1-sqlalchemy-0.8.patch
33 @@ -0,0 +1,65 @@
34 +diff -r 4daa9cf904bb services/auth/ldapsql.py
35 +--- a/services/auth/ldapsql.py Fri Sep 27 10:28:41 2013 +1000
36 ++++ b/services/auth/ldapsql.py Sun Dec 01 16:40:21 2013 +0100
37 +@@ -42,7 +42,8 @@
38 +
39 + import ldap
40 +
41 +-from sqlalchemy.ext.declarative import declarative_base, Column
42 ++from sqlalchemy.ext.declarative import declarative_base
43 ++from sqlalchemy.schema import Column
44 + from sqlalchemy import Integer, String, SmallInteger
45 + from sqlalchemy.sql import select, insert, update, and_
46 +
47 +diff -r 4daa9cf904bb services/auth/resetcode.py
48 +--- a/services/auth/resetcode.py Fri Sep 27 10:28:41 2013 +1000
49 ++++ b/services/auth/resetcode.py Sun Dec 01 16:40:21 2013 +0100
50 +@@ -41,7 +41,8 @@
51 + """
52 + import datetime
53 +
54 +-from sqlalchemy.ext.declarative import declarative_base, Column
55 ++from sqlalchemy.ext.declarative import declarative_base
56 ++from sqlalchemy.schema import Column
57 + from sqlalchemy import String, DateTime
58 + from sqlalchemy.sql import bindparam, select, insert, delete
59 +
60 +diff -r 4daa9cf904bb services/auth/sqlmappers.py
61 +--- a/services/auth/sqlmappers.py Fri Sep 27 10:28:41 2013 +1000
62 ++++ b/services/auth/sqlmappers.py Sun Dec 01 16:40:21 2013 +0100
63 +@@ -36,7 +36,8 @@
64 + """ SQL Mappers
65 + """
66 + from sqlalchemy.schema import UniqueConstraint
67 +-from sqlalchemy.ext.declarative import declarative_base, Column
68 ++from sqlalchemy.ext.declarative import declarative_base
69 ++from sqlalchemy.schema import Column
70 + from sqlalchemy import Integer, String, DateTime, Text
71 +
72 + _Base = declarative_base()
73 +diff -r 4daa9cf904bb services/resetcodes/rc_sql.py
74 +--- a/services/resetcodes/rc_sql.py Fri Sep 27 10:28:41 2013 +1000
75 ++++ b/services/resetcodes/rc_sql.py Sun Dec 01 16:40:21 2013 +0100
76 +@@ -42,7 +42,8 @@
77 + """
78 + import datetime
79 +
80 +-from sqlalchemy.ext.declarative import declarative_base, Column
81 ++from sqlalchemy.ext.declarative import declarative_base
82 ++from sqlalchemy.schema import Column
83 + from sqlalchemy import String, DateTime
84 + from sqlalchemy.sql import bindparam, select, insert, delete, and_
85 +
86 +diff -r 4daa9cf904bb services/user/sql.py
87 +--- a/services/user/sql.py Fri Sep 27 10:28:41 2013 +1000
88 ++++ b/services/user/sql.py Sun Dec 01 16:40:21 2013 +0100
89 +@@ -43,7 +43,8 @@
90 +
91 + from sqlalchemy import Integer, String
92 + from sqlalchemy.interfaces import PoolListener
93 +-from sqlalchemy.ext.declarative import declarative_base, Column
94 ++from sqlalchemy.ext.declarative import declarative_base
95 ++from sqlalchemy.schema import Column
96 + from sqlalchemy.sql import bindparam, select, insert, update, delete
97 + from sqlalchemy.sql import text as sqltext
98 + from sqlalchemy.exc import IntegrityError
99
100 diff --git a/www-misc/mozilla-sync-server-core/files/2.15.1-wsgiproxy2.patch b/www-misc/mozilla-sync-server-core/files/2.15.1-wsgiproxy2.patch
101 new file mode 100644
102 index 0000000..980f016
103 --- /dev/null
104 +++ b/www-misc/mozilla-sync-server-core/files/2.15.1-wsgiproxy2.patch
105 @@ -0,0 +1,60 @@
106 +diff -r ffdac52d215a Makefile
107 +--- a/Makefile Fri Apr 12 15:17:15 2013 +1000
108 ++++ b/Makefile Tue Apr 23 13:48:15 2013 +0200
109 +@@ -58,7 +58,7 @@
110 + build_extras:
111 + $(INSTALL) MySQL-python
112 + $(INSTALL) recaptcha-client
113 +- $(INSTALL) wsgiproxy
114 ++ $(INSTALL) wsgiproxy2
115 + $(INSTALL) wsgi_intercept
116 + $(INSTALL) "python-ldap == 2.3.13"
117 + $(INSTALL) coverage
118 +diff -r ffdac52d215a dev-reqs.txt
119 +--- a/dev-reqs.txt Fri Apr 12 15:17:15 2013 +1000
120 ++++ b/dev-reqs.txt Tue Apr 23 13:48:15 2013 +0200
121 +@@ -14,7 +14,7 @@
122 + PyMySQL
123 + pymysql_sa
124 + pylibmc
125 +-WSGIProxy
126 ++WSGIProxy2
127 + recaptcha-client
128 + metlog-py >= 0.9.5
129 + metlog-cef
130 +diff -r ffdac52d215a prod-reqs.txt
131 +--- a/prod-reqs.txt Fri Apr 12 15:17:15 2013 +1000
132 ++++ b/prod-reqs.txt Tue Apr 23 13:48:15 2013 +0200
133 +@@ -14,7 +14,7 @@
134 + PyMySQL == 0.5
135 + pymysql_sa == 1.0
136 + pylibmc == 1.2.3
137 +-WSGIProxy == 0.2.2
138 ++WSGIProxy2 == 0.1
139 + recaptcha-client == 1.0.6
140 + metlog-py == 0.9.8
141 + metlog-cef == 0.2
142 +diff -r ffdac52d215a services/tests/support.py
143 +--- a/services/tests/support.py Fri Apr 12 15:17:15 2013 +1000
144 ++++ b/services/tests/support.py Tue Apr 23 13:48:15 2013 +0200
145 +@@ -223,7 +223,7 @@
146 + If TEST_REMOTE is set in the environ, will run against a real server.
147 + """
148 + import urlparse
149 +- from wsgiproxy.exactproxy import proxy_exact_request
150 ++ from wsgiproxy2.exactproxy import proxy_exact_request
151 + from webtest import TestApp
152 +
153 + # runs over a proxy
154 +diff -r ffdac52d215a setup.py
155 +--- a/setup.py Fri Apr 12 15:17:15 2013 +1000
156 ++++ b/setup.py Tue Apr 23 13:48:15 2013 +0200
157 +@@ -38,7 +38,7 @@
158 + from setuptools import setup, find_packages
159 +
160 + install_requires = ['SQLAlchemy', 'Paste', 'PasteDeploy', 'WebOb',
161 +- 'Routes', 'simplejson', 'cef', 'wsgiproxy', 'metlog-py']
162 ++ 'Routes', 'simplejson', 'cef', 'wsgiproxy2', 'metlog-py']
163 +
164 +
165 + # extracting the version number from the .spec file
166
167 diff --git a/www-misc/mozilla-sync-server-core/mozilla-sync-server-core-2.15.1.ebuild b/www-misc/mozilla-sync-server-core/mozilla-sync-server-core-2.15.1.ebuild
168 new file mode 100644
169 index 0000000..72c224b
170 --- /dev/null
171 +++ b/www-misc/mozilla-sync-server-core/mozilla-sync-server-core-2.15.1.ebuild
172 @@ -0,0 +1,85 @@
173 +# Copyright 1999-2013 Gentoo Foundation
174 +# Distributed under the terms of the GNU General Public License v2
175 +# $Header: $
176 +
177 +EAPI=5
178 +
179 +PYTHON_COMPAT=(python2_{6,7})
180 +
181 +MY_PN="server-core"
182 +
183 +case ${PV} in
184 +9999)
185 + inherit distutils-r1 mercurial
186 + EHG_REVISION="default"
187 + EHG_REPO_URI="https://hg.mozilla.org/services/server-core"
188 + ;;
189 +*)
190 + inherit distutils-r1 versionator
191 + MY_PV="rpm-$(replace_version_separator 2 '-')"
192 + MY_P="${MY_PN}-${MY_PV}"
193 + SRC_URI="https://hg.mozilla.org/services/${MY_PN}/archive/${MY_PV}.tar.bz2 -> ${MY_P}.tar.bz2"
194 + S="${WORKDIR}/${MY_P}"
195 + ;;
196 +esac
197 +
198 +
199 +DESCRIPTION="Mozilla Sync Server Core libraries"
200 +HOMEPAGE="https://hg.mozilla.org/services/server-core/"
201 +
202 +LICENSE="MPL-1.1"
203 +SLOT="0"
204 +KEYWORDS="~amd64 ~x86"
205 +IUSE="ldap memcached test"
206 +
207 +# keep the same order as in prod-reqs.txt
208 +RDEPEND=">=dev-python/webob-1.0.7[${PYTHON_USEDEP}]
209 + >=dev-python/paste-1.7.5.1[${PYTHON_USEDEP}]
210 + >=dev-python/pastescript-1.7.5[${PYTHON_USEDEP}]
211 + >=dev-python/simplejson-2.6.2[${PYTHON_USEDEP}]
212 + >=dev-python/routes-1.13[${PYTHON_USEDEP}]
213 + >=dev-python/sqlalchemy-0.8[${PYTHON_USEDEP}]
214 + >=dev-python/wsgiproxy2-0.1[${PYTHON_USEDEP}]
215 + >=dev-python/recaptcha-client-1.0.6[${PYTHON_USEDEP}]
216 + >=dev-python/metlog-py-0.9.8[${PYTHON_USEDEP}]
217 + >=dev-python/metlog-cef-0.2[${PYTHON_USEDEP}]
218 + >=dev-python/repoze-who-2.0[${PYTHON_USEDEP}]
219 + >=dev-python/scrypt-0.6.1[${PYTHON_USEDEP}]
220 + >=dev-python/greenlet-0.4[${PYTHON_USEDEP}]
221 + >=dev-python/gevent-0.13.8[${PYTHON_USEDEP}]
222 + >=net-zope/zope-interface-4.0.1[${PYTHON_USEDEP}]
223 + ldap? ( >=dev-python/python-ldap-2.3.13[${PYTHON_USEDEP}] )
224 + memcached? ( >=dev-python/pylibmc-1.2.3[${PYTHON_USEDEP}]
225 + >=dev-python/python-memcached-1.48[${PYTHON_USEDEP}] )"
226 +DEPEND="${RDEPEND}
227 + test? ( dev-python/nose[${PYTHON_USEDEP}]
228 + dev-python/wsgiintercept[${PYTHON_USEDEP}] )
229 + dev-python/setuptools[${PYTHON_USEDEP}]"
230 +
231 +# filtered out from prod-reqs.txt since not really required or optional:
232 +# >=dev-python/pastedeploy-1.5.0[${PYTHON_USEDEP}] (not required)
233 +# >=dev-python/repoze-lru-0.6[${PYTHON_USEDEP}] (not required)
234 +# mysql-python (not directly required)
235 +# pymysql_sa (not directly required)
236 +# mako (not required)
237 +# docopt (not required directly)
238 +# cef (not required directly)
239 +# markupsafe (not required)
240 +# beaker (not required)
241 +
242 +PATCHES=(
243 + "${FILESDIR}/${PV}-wsgiproxy2.patch"
244 + "${FILESDIR}/${PV}-sqlalchemy-0.8.patch"
245 + )
246 +
247 +python_prepare_all() {
248 + # remove tests mostly depending on running LDAP or memcached
249 + rm services/tests/test_user.py || die
250 +
251 + distutils-r1_python_prepare_all
252 +}
253 +
254 +python_test() {
255 + # exclude one more test trying to hit a running memcached
256 + nosetests -e reset_code_memcache || die
257 +}