Gentoo Archives: gentoo-commits

From: "Tim Harder (radhermit)" <radhermit@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-libs/protobuf: ChangeLog protobuf-2.6.1-r2.ebuild protobuf-2.5.0-r3.ebuild
Date: Thu, 26 Feb 2015 04:48:34
Message-Id: 20150226044828.749431291D@oystercatcher.gentoo.org
1 radhermit 15/02/26 04:48:28
2
3 Modified: ChangeLog
4 Added: protobuf-2.6.1-r2.ebuild protobuf-2.5.0-r3.ebuild
5 Log:
6 Add zlib use flag (bug #541396).
7
8 (Portage version: 2.2.15/cvs/Linux x86_64, signed Manifest commit with key 4AB3E85B4F064CA3)
9
10 Revision Changes Path
11 1.78 dev-libs/protobuf/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/protobuf/ChangeLog?rev=1.78&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/protobuf/ChangeLog?rev=1.78&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/protobuf/ChangeLog?r1=1.77&r2=1.78
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/dev-libs/protobuf/ChangeLog,v
20 retrieving revision 1.77
21 retrieving revision 1.78
22 diff -u -r1.77 -r1.78
23 --- ChangeLog 26 Jan 2015 09:37:24 -0000 1.77
24 +++ ChangeLog 26 Feb 2015 04:48:28 -0000 1.78
25 @@ -1,6 +1,13 @@
26 # ChangeLog for dev-libs/protobuf
27 # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/protobuf/ChangeLog,v 1.77 2015/01/26 09:37:24 ago Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/dev-libs/protobuf/ChangeLog,v 1.78 2015/02/26 04:48:28 radhermit Exp $
30 +
31 +*protobuf-2.6.1-r2 (26 Feb 2015)
32 +*protobuf-2.5.0-r3 (26 Feb 2015)
33 +
34 + 26 Feb 2015; Tim Harder <radhermit@g.o> +protobuf-2.5.0-r3.ebuild,
35 + +protobuf-2.6.1-r2.ebuild:
36 + Add zlib use flag (bug #541396).
37
38 26 Jan 2015; Agostino Sarubbo <ago@g.o> protobuf-2.5.0-r2.ebuild:
39 Stable for x86, wrt bug #536794
40
41
42
43 1.1 dev-libs/protobuf/protobuf-2.6.1-r2.ebuild
44
45 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/protobuf/protobuf-2.6.1-r2.ebuild?rev=1.1&view=markup
46 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/protobuf/protobuf-2.6.1-r2.ebuild?rev=1.1&content-type=text/plain
47
48 Index: protobuf-2.6.1-r2.ebuild
49 ===================================================================
50 # Copyright 1999-2015 Gentoo Foundation
51 # Distributed under the terms of the GNU General Public License v2
52 # $Header: /var/cvsroot/gentoo-x86/dev-libs/protobuf/protobuf-2.6.1-r2.ebuild,v 1.1 2015/02/26 04:48:28 radhermit Exp $
53
54 EAPI=5
55 AUTOTOOLS_AUTORECONF=1
56 AUTOTOOLS_PRUNE_LIBTOOL_FILES=all
57 JAVA_PKG_IUSE="source"
58 PYTHON_COMPAT=( python2_7 )
59 DISTUTILS_OPTIONAL=1
60
61 inherit autotools-multilib eutils flag-o-matic distutils-r1 java-pkg-opt-2 elisp-common
62
63 DESCRIPTION="Google's Protocol Buffers -- an efficient method of encoding structured data"
64 HOMEPAGE="http://code.google.com/p/protobuf/ https://github.com/google/protobuf/"
65 SRC_URI="https://github.com/google/${PN}/releases/download/${PV}/${P}.tar.bz2"
66
67 LICENSE="Apache-2.0"
68 SLOT="0/9" # subslot = soname major version
69 KEYWORDS="~amd64 ~arm -hppa ~mips -ppc -ppc64 ~x86 ~amd64-linux ~arm-linux ~x86-linux ~x64-macos ~x86-macos"
70 IUSE="emacs examples java python static-libs vim-syntax zlib"
71
72 CDEPEND="emacs? ( virtual/emacs )
73 python? ( ${PYTHON_DEPS} )
74 zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )"
75 DEPEND="${CDEPEND}
76 java? ( >=virtual/jdk-1.5 )
77 python? (
78 dev-python/google-apputils[${PYTHON_USEDEP}]
79 dev-python/setuptools[${PYTHON_USEDEP}]
80 )"
81 RDEPEND="${CDEPEND}
82 java? ( >=virtual/jre-1.5 )"
83
84 src_prepare() {
85 append-cxxflags -DGOOGLE_PROTOBUF_NO_RTTI
86
87 # breaks Darwin, bug #472514
88 [[ ${CHOST} != *-darwin* ]] && epatch "${FILESDIR}"/${PN}-2.3.0-asneeded-2.patch
89
90 # fix build with emacs-24.4 (bug #524100)
91 epatch "${FILESDIR}"/${PN}-2.5.0-emacs-24.4.patch
92
93 autotools-multilib_src_prepare
94
95 if use python; then
96 cd python && distutils-r1_src_prepare
97 fi
98 }
99
100 src_configure() {
101 local myeconfargs=(
102 $(use_with zlib)
103 )
104 autotools-multilib_src_configure
105 }
106
107 multilib_src_compile() {
108 default
109
110 if multilib_is_native_abi; then
111 if use python; then
112 einfo "Compiling Python library ..."
113 pushd "${S}"/python >/dev/null
114 PROTOC="${BUILD_DIR}"/src/protoc distutils-r1_src_compile
115 popd >/dev/null
116 fi
117
118 if use java; then
119 einfo "Compiling Java library ..."
120 pushd "${S}" >/dev/null
121 "${BUILD_DIR}"/src/protoc --java_out=java/src/main/java --proto_path=src src/google/protobuf/descriptor.proto
122 mkdir java/build
123 pushd java/src/main/java >/dev/null
124 ejavac -d ../../../build $(find . -name '*.java') || die "java compilation failed"
125 popd >/dev/null
126 jar cf ${PN}.jar -C java/build . || die "jar failed"
127 popd >/dev/null
128 fi
129 fi
130 }
131
132 src_compile() {
133 autotools-multilib_src_compile
134
135 if use emacs; then
136 elisp-compile "${S}"/editors/protobuf-mode.el
137 fi
138 }
139
140 src_test() {
141 autotools-multilib_src_test check
142
143 if use python; then
144 pushd python >/dev/null
145 distutils-r1_src_test
146 popd >/dev/null
147 fi
148 }
149
150 src_install() {
151 autotools-multilib_src_install
152
153 dodoc CHANGES.txt CONTRIBUTORS.txt README.md
154
155 if use python; then
156 pushd python >/dev/null
157 distutils-r1_src_install
158 popd >/dev/null
159 fi
160
161 if use java; then
162 java-pkg_dojar ${PN}.jar
163 use source && java-pkg_dosrc java/src/main/java/*
164 fi
165
166 if use vim-syntax; then
167 insinto /usr/share/vim/vimfiles/syntax
168 doins editors/proto.vim
169 insinto /usr/share/vim/vimfiles/ftdetect/
170 doins "${FILESDIR}"/proto.vim
171 fi
172
173 if use emacs; then
174 elisp-install ${PN} editors/protobuf-mode.el*
175 elisp-site-file-install "${FILESDIR}"/70${PN}-gentoo.el
176 fi
177
178 if use examples; then
179 dodoc -r examples
180 docompress -x /usr/share/doc/${PF}/examples
181 fi
182 }
183
184 pkg_postinst() {
185 use emacs && elisp-site-regen
186 }
187
188 pkg_postrm() {
189 use emacs && elisp-site-regen
190 }
191
192
193
194 1.1 dev-libs/protobuf/protobuf-2.5.0-r3.ebuild
195
196 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/protobuf/protobuf-2.5.0-r3.ebuild?rev=1.1&view=markup
197 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/protobuf/protobuf-2.5.0-r3.ebuild?rev=1.1&content-type=text/plain
198
199 Index: protobuf-2.5.0-r3.ebuild
200 ===================================================================
201 # Copyright 1999-2015 Gentoo Foundation
202 # Distributed under the terms of the GNU General Public License v2
203 # $Header: /var/cvsroot/gentoo-x86/dev-libs/protobuf/protobuf-2.5.0-r3.ebuild,v 1.1 2015/02/26 04:48:28 radhermit Exp $
204
205 EAPI=5
206 AUTOTOOLS_AUTORECONF=1
207 AUTOTOOLS_PRUNE_LIBTOOL_FILES=all
208 JAVA_PKG_IUSE="source"
209 PYTHON_COMPAT=( python2_7 )
210 DISTUTILS_OPTIONAL=1
211
212 inherit autotools-multilib eutils flag-o-matic distutils-r1 java-pkg-opt-2 elisp-common
213
214 DESCRIPTION="Google's Protocol Buffers -- an efficient method of encoding structured data"
215 HOMEPAGE="http://code.google.com/p/protobuf/"
216 SRC_URI="http://protobuf.googlecode.com/files/${P}.tar.bz2"
217
218 LICENSE="Apache-2.0"
219 SLOT="0/8" # subslot = soname major version
220 KEYWORDS="~amd64 ~arm -hppa ~ia64 ~mips -ppc -ppc64 ~x86 ~amd64-linux ~arm-linux ~x86-linux ~x64-macos ~x86-macos"
221 IUSE="emacs examples java python static-libs vim-syntax zlib"
222
223 CDEPEND="emacs? ( virtual/emacs )
224 python? ( ${PYTHON_DEPS} )
225 zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )"
226 DEPEND="${CDEPEND}
227 java? ( >=virtual/jdk-1.5 )
228 python? ( dev-python/setuptools[${PYTHON_USEDEP}] )"
229 RDEPEND="${CDEPEND}
230 java? ( >=virtual/jre-1.5 )"
231
232 src_prepare() {
233 append-cxxflags -DGOOGLE_PROTOBUF_NO_RTTI
234
235 epatch "${FILESDIR}"/${P}-x32.patch
236
237 # breaks Darwin, bug #472514
238 [[ ${CHOST} != *-darwin* ]] && epatch "${FILESDIR}"/${PN}-2.3.0-asneeded-2.patch
239
240 # fix build with emacs-24.4 (bug #524100)
241 epatch "${FILESDIR}"/${P}-emacs-24.4.patch
242
243 autotools-multilib_src_prepare
244
245 if use python; then
246 cd python && distutils-r1_src_prepare
247 fi
248 }
249
250 src_configure() {
251 local myeconfargs=(
252 $(use_with zlib)
253 )
254 autotools-multilib_src_configure
255 }
256
257 multilib_src_compile() {
258 default
259
260 if multilib_is_native_abi; then
261 if use python; then
262 einfo "Compiling Python library ..."
263 pushd "${S}"/python >/dev/null
264 PROTOC="${BUILD_DIR}"/src/protoc distutils-r1_src_compile
265 popd >/dev/null
266 fi
267
268 if use java; then
269 einfo "Compiling Java library ..."
270 pushd "${S}" >/dev/null
271 "${BUILD_DIR}"/src/protoc --java_out=java/src/main/java --proto_path=src src/google/protobuf/descriptor.proto
272 mkdir java/build
273 pushd java/src/main/java >/dev/null
274 ejavac -d ../../../build $(find . -name '*.java') || die "java compilation failed"
275 popd >/dev/null
276 jar cf ${PN}.jar -C java/build . || die "jar failed"
277 popd >/dev/null
278 fi
279 fi
280 }
281
282 src_compile() {
283 autotools-multilib_src_compile
284
285 if use emacs; then
286 elisp-compile "${S}"/editors/protobuf-mode.el
287 fi
288 }
289
290 src_test() {
291 autotools-multilib_src_test check
292
293 if use python; then
294 pushd python >/dev/null
295 distutils-r1_src_test
296 popd >/dev/null
297 fi
298 }
299
300 src_install() {
301 autotools-multilib_src_install
302
303 dodoc CHANGES.txt CONTRIBUTORS.txt README.txt
304
305 if use python; then
306 pushd python >/dev/null
307 distutils-r1_src_install
308 popd >/dev/null
309 fi
310
311 if use java; then
312 java-pkg_dojar ${PN}.jar
313 use source && java-pkg_dosrc java/src/main/java/*
314 fi
315
316 if use vim-syntax; then
317 insinto /usr/share/vim/vimfiles/syntax
318 doins editors/proto.vim
319 insinto /usr/share/vim/vimfiles/ftdetect/
320 doins "${FILESDIR}"/proto.vim
321 fi
322
323 if use emacs; then
324 elisp-install ${PN} editors/protobuf-mode.el*
325 elisp-site-file-install "${FILESDIR}"/70${PN}-gentoo.el
326 fi
327
328 if use examples; then
329 dodoc -r examples
330 docompress -x /usr/share/doc/${PF}/examples
331 fi
332 }
333
334 pkg_postinst() {
335 use emacs && elisp-site-regen
336 }
337
338 pkg_postrm() {
339 use emacs && elisp-site-regen
340 }