Gentoo Archives: gentoo-commits

From: "Jeroen Roovers (jer)" <jer@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in www-client/opera-next: ChangeLog opera-next-12.00.1318.ebuild opera-next-12.00.1317.ebuild
Date: Tue, 28 Feb 2012 17:55:48
Message-Id: 20120228175538.652982004B@flycatcher.gentoo.org
1 jer 12/02/28 17:55:38
2
3 Modified: ChangeLog
4 Added: opera-next-12.00.1318.ebuild
5 opera-next-12.00.1317.ebuild
6 Log:
7 http://my.opera.com/desktopteam/blog/2012/02/28/precision-engine
8
9 (Portage version: 2.2.0_alpha89/cvs/Linux x86_64)
10
11 Revision Changes Path
12 1.67 www-client/opera-next/ChangeLog
13
14 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/ChangeLog?rev=1.67&view=markup
15 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/ChangeLog?rev=1.67&content-type=text/plain
16 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/ChangeLog?r1=1.66&r2=1.67
17
18 Index: ChangeLog
19 ===================================================================
20 RCS file: /var/cvsroot/gentoo-x86/www-client/opera-next/ChangeLog,v
21 retrieving revision 1.66
22 retrieving revision 1.67
23 diff -u -r1.66 -r1.67
24 --- ChangeLog 24 Feb 2012 06:06:17 -0000 1.66
25 +++ ChangeLog 28 Feb 2012 17:55:38 -0000 1.67
26 @@ -1,6 +1,13 @@
27 # ChangeLog for www-client/opera-next
28 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
29 -# $Header: /var/cvsroot/gentoo-x86/www-client/opera-next/ChangeLog,v 1.66 2012/02/24 06:06:17 jer Exp $
30 +# $Header: /var/cvsroot/gentoo-x86/www-client/opera-next/ChangeLog,v 1.67 2012/02/28 17:55:38 jer Exp $
31 +
32 +*opera-next-12.00.1318 (28 Feb 2012)
33 +*opera-next-12.00.1317 (28 Feb 2012)
34 +
35 + 28 Feb 2012; Jeroen Roovers <jer@g.o> +opera-next-12.00.1317.ebuild,
36 + +opera-next-12.00.1318.ebuild:
37 + http://my.opera.com/desktopteam/blog/2012/02/28/precision-engine
38
39 *opera-next-12.00.1312 (24 Feb 2012)
40
41
42
43
44 1.1 www-client/opera-next/opera-next-12.00.1318.ebuild
45
46 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/opera-next-12.00.1318.ebuild?rev=1.1&view=markup
47 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/opera-next-12.00.1318.ebuild?rev=1.1&content-type=text/plain
48
49 Index: opera-next-12.00.1318.ebuild
50 ===================================================================
51 # Copyright 1999-2012 Gentoo Foundation
52 # Distributed under the terms of the GNU General Public License v2
53 # $Header: /var/cvsroot/gentoo-x86/www-client/opera-next/opera-next-12.00.1318.ebuild,v 1.1 2012/02/28 17:55:38 jer Exp $
54
55 EAPI="4"
56
57 inherit eutils fdo-mime gnome2-utils multilib pax-utils versionator
58
59 DESCRIPTION="A fast and secure web browser and Internet suite"
60 HOMEPAGE="http://www.opera.com/"
61
62 SLOT="0"
63 LICENSE="OPERA-11 LGPL-2 LGPL-3"
64 KEYWORDS="~amd64"
65 IUSE="elibc_FreeBSD gtk gtk3 kde +gstreamer"
66
67 O_V="$(get_version_component_range 1-2)" # Major version, i.e. 11.00
68 O_B="$(get_version_component_range 3)" # Build version, i.e. 1156
69
70 O_D="retentionrate_${O_V}-1317"
71 O_P="${PN}-${O_V}-${O_B}"
72 O_U="http://snapshot.opera.com/unix/"
73
74 SRC_URI="
75 amd64? ( ${O_U}${O_D}/${O_P}.x86_64.linux.tar.xz )
76 "
77
78 OPREFIX="/usr/$(get_libdir)"
79
80 QA_DT_HASH="${OPREFIX}/${PN}/.*"
81 QA_PRESTRIPPED="${OPREFIX}/${PN}/.*"
82
83 O_LINGUAS="af az be bg bn cs da de el en-GB es-ES es-LA et fi fr fr-CA fy gd hi
84 hr hu id it ja ka ko lt me mk ms nb nl nn pa pl pt pt-BR ro ru sk sr sv sw ta te
85 th tl tr uk uz vi zh-CN zh-TW zu"
86
87 for O_LINGUA in ${O_LINGUAS}; do
88 IUSE="${IUSE} linguas_${O_LINGUA/-/_}"
89 done
90
91 DEPEND="
92 >=sys-apps/sed-4
93 app-arch/xz-utils
94 "
95 GTKRDEPEND="
96 dev-libs/atk
97 dev-libs/glib:2
98 x11-libs/cairo
99 x11-libs/gdk-pixbuf
100 gtk? ( x11-libs/gtk+:2 )
101 gtk3? ( x11-libs/gtk+:3 )
102 x11-libs/pango
103 x11-libs/pixman
104 "
105 KDERDEPEND="
106 kde-base/kdelibs
107 x11-libs/qt-core
108 x11-libs/qt-gui
109 "
110 GSTRDEPEND="
111 dev-libs/glib:2
112 dev-libs/libxml2
113 media-libs/gst-plugins-base
114 media-libs/gstreamer
115 media-plugins/gst-plugins-meta
116 "
117 RDEPEND="
118 media-libs/fontconfig
119 media-libs/freetype
120 sys-apps/util-linux
121 sys-libs/zlib
122 virtual/opengl
123 x11-libs/libICE
124 x11-libs/libSM
125 x11-libs/libX11
126 x11-libs/libXext
127 x11-libs/libXft
128 x11-libs/libXrender
129 x11-libs/libXt
130 gtk? ( ${GTKRDEPEND} )
131 gtk3? ( ${GTKRDEPEND} )
132 kde? ( ${KDERDEPEND} )
133 gstreamer? ( ${GSTRDEPEND} )
134 "
135 src_unpack() {
136 unpack ${A}
137 mv -v ${PN}* "${S}" || die
138 }
139
140 src_prepare() {
141 local LNGDIR="share/${PN}/locale"
142
143 # Count linguas
144 count() { echo ${#}; }
145 local lingua_count=$(count ${O_LINGUAS} en)
146 local locale_count=$(count ${LNGDIR}/*)
147 [[ ${lingua_count} = ${locale_count} ]] \
148 || die "Number of LINGUAS does not match number of locales"
149 unset count
150
151 # Remove unwanted linguas
152 einfo "Keeping these locales (linguas): ${LINGUAS}."
153 for LINGUA in ${O_LINGUAS}; do
154 if ! use linguas_${LINGUA/-/_}; then
155 LINGUA=$(find "${LNGDIR}" -maxdepth 1 -type d -iname ${LINGUA/_/-})
156 rm -r "${LINGUA}" || die "The list of linguas needs to be fixed"
157 fi
158 done
159
160 # Remove doc directory but keep the LICENSE under another name (bug #315473)
161 mv share/doc/${PN}/LICENSE share/${PN}/defaults/license.txt
162 rm -rf share/doc
163 for locale in share/${PN}/locale/*; do
164 rm -f "${locale}/license.txt"
165 ln -sn /usr/share/${PN}/defaults/license.txt "${locale}/license.txt" \
166 || die
167 done
168
169 # Remove package directory
170 rm -rf share/${PN}/package
171
172 # Optional libraries
173 if ! use gtk; then
174 rm lib/${PN}/liboperagtk2.so || die
175 fi
176 if ! use gtk3; then
177 rm lib/${PN}/liboperagtk3.so || die
178 fi
179 if ! use kde; then
180 rm lib/${PN}/liboperakde4.so || die
181 fi
182 if ! use gstreamer; then
183 rm -r lib/${PN}/gstreamer || die
184 fi
185
186 # Unzip the man pages before sedding
187 gunzip share/man/man1/* || die
188
189 # Replace PREFIX, SUFFIX and PN in various files
190 sed -i \
191 -e "s:@@{PREFIX}:/usr:g" \
192 -e "s:@@{SUFFIX}::g" \
193 -e "s:@@{_SUFFIX}::g" \
194 -e "s:@@{USUFFIX}::g" \
195 -e "s:opera:${PN}:g" \
196 share/man/man1/* \
197 share/applications/${PN}-*.desktop \
198 || die
199
200 # Replace "Opera" with "Opera Next"
201 if [[ ${PN} = opera-next ]]; then
202 sed -i share/applications/${PN}-*.desktop \
203 -e "/^Name=Opera\|^ Next/s:Opera:& Next:" || die
204 fi
205
206 # Create /usr/bin/opera wrapper
207 echo '#!/bin/sh' > ${PN}
208 echo 'export OPERA_DIR="/usr/share/'"${PN}"'"' >> ${PN}
209 echo 'export OPERA_PERSONALDIR=${OPERA_PERSONALDIR:-"${HOME}/.'${PN}'"}' \
210 >> ${PN}
211 echo 'exec '"${OPREFIX}/${PN}/${PN}"' "$@"' >> ${PN}
212
213 # Change libz.so.3 to libz.so.1 for gentoo/freebsd
214 if use elibc_FreeBSD; then
215 scanelf -qR -N libz.so.3 -F "#N" lib/${PN}/ | \
216 while read i; do
217 if [[ $(strings "$i" | fgrep -c libz.so.3) -ne 1 ]];
218 then
219 export SANITY_CHECK_LIBZ_FAILED=1
220 break
221 fi
222 sed -i \
223 "$i" \
224 -e 's/libz\.so\.3/libz.so.1/g'
225 done
226 [[ "$SANITY_CHECK_LIBZ_FAILED" = "1" ]] && die
227 fi
228 }
229
230 src_install() {
231 # We install into usr instead of opt as Opera does not support the latter
232 dodir /usr
233 mv lib/ "${D}/${OPREFIX}" || die
234 mv share/ "${D}/usr/" || die
235
236 # Install startup scripts
237 dobin ${PN}
238
239 # Stop revdep-rebuild from checking opera binaries
240 dodir /etc/revdep-rebuild
241 echo "SEARCH_DIRS_MASK=\"${OPREFIX}/${PN}\"" \
242 > "${D}"/etc/revdep-rebuild/90${PN}
243
244 # Set PaX markings for hardened/PaX (bug #344267)
245 pax-mark m "${D}"/${OPREFIX}/${PN}/opera*
246 }
247
248 pkg_preinst() {
249 gnome2_icon_savelist
250 }
251
252 pkg_postinst() {
253 if use elibc_FreeBSD; then
254 elog
255 elog "To improve shared memory usage please set:"
256 elog "$ sysctl kern.ipc.shm_allow_removed=1"
257 fi
258
259 # Update desktop file database and gtk icon cache (bug #334993)
260 gnome2_icon_cache_update
261 fdo-mime_desktop_database_update
262 }
263
264 pkg_postrm() {
265 # Update desktop file database and gtk icon cache (bug #334993)
266 gnome2_icon_cache_update
267 fdo-mime_desktop_database_update
268 }
269
270
271
272 1.1 www-client/opera-next/opera-next-12.00.1317.ebuild
273
274 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/opera-next-12.00.1317.ebuild?rev=1.1&view=markup
275 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/opera-next-12.00.1317.ebuild?rev=1.1&content-type=text/plain
276
277 Index: opera-next-12.00.1317.ebuild
278 ===================================================================
279 # Copyright 1999-2012 Gentoo Foundation
280 # Distributed under the terms of the GNU General Public License v2
281 # $Header: /var/cvsroot/gentoo-x86/www-client/opera-next/opera-next-12.00.1317.ebuild,v 1.1 2012/02/28 17:55:38 jer Exp $
282
283 EAPI="4"
284
285 inherit eutils fdo-mime gnome2-utils multilib pax-utils versionator
286
287 DESCRIPTION="A fast and secure web browser and Internet suite"
288 HOMEPAGE="http://www.opera.com/"
289
290 SLOT="0"
291 LICENSE="OPERA-11 LGPL-2 LGPL-3"
292 KEYWORDS="~x86 ~x86-fbsd"
293 IUSE="elibc_FreeBSD gtk gtk3 kde +gstreamer"
294
295 O_V="$(get_version_component_range 1-2)" # Major version, i.e. 11.00
296 O_B="$(get_version_component_range 3)" # Build version, i.e. 1156
297
298 O_D="retentionrate_${O_V}-${O_B}"
299 O_P="${PN}-${O_V}-${O_B}"
300 O_U="http://snapshot.opera.com/unix/"
301
302 SRC_URI="
303 x86? ( ${O_U}${O_D}/${O_P}.i386.linux.tar.xz )
304 x86-fbsd? ( ${O_U}${O_D}/${O_P}.i386.freebsd.tar.xz )
305 "
306
307 OPREFIX="/usr/$(get_libdir)"
308
309 QA_DT_HASH="${OPREFIX}/${PN}/.*"
310 QA_PRESTRIPPED="${OPREFIX}/${PN}/.*"
311
312 O_LINGUAS="af az be bg bn cs da de el en-GB es-ES es-LA et fi fr fr-CA fy gd hi
313 hr hu id it ja ka ko lt me mk ms nb nl nn pa pl pt pt-BR ro ru sk sr sv sw ta te
314 th tl tr uk uz vi zh-CN zh-TW zu"
315
316 for O_LINGUA in ${O_LINGUAS}; do
317 IUSE="${IUSE} linguas_${O_LINGUA/-/_}"
318 done
319
320 DEPEND="
321 >=sys-apps/sed-4
322 app-arch/xz-utils
323 "
324 GTKRDEPEND="
325 dev-libs/atk
326 dev-libs/glib:2
327 x11-libs/cairo
328 x11-libs/gdk-pixbuf
329 gtk? ( x11-libs/gtk+:2 )
330 gtk3? ( x11-libs/gtk+:3 )
331 x11-libs/pango
332 x11-libs/pixman
333 "
334 KDERDEPEND="
335 kde-base/kdelibs
336 x11-libs/qt-core
337 x11-libs/qt-gui
338 "
339 GSTRDEPEND="
340 dev-libs/glib:2
341 dev-libs/libxml2
342 media-libs/gst-plugins-base
343 media-libs/gstreamer
344 media-plugins/gst-plugins-meta
345 "
346 RDEPEND="
347 media-libs/fontconfig
348 media-libs/freetype
349 sys-apps/util-linux
350 sys-libs/zlib
351 virtual/opengl
352 x11-libs/libICE
353 x11-libs/libSM
354 x11-libs/libX11
355 x11-libs/libXext
356 x11-libs/libXft
357 x11-libs/libXrender
358 x11-libs/libXt
359 gtk? ( ${GTKRDEPEND} )
360 gtk3? ( ${GTKRDEPEND} )
361 kde? ( ${KDERDEPEND} )
362 gstreamer? ( ${GSTRDEPEND} )
363 "
364 src_unpack() {
365 unpack ${A}
366 mv -v ${PN}* "${S}" || die
367 }
368
369 src_prepare() {
370 local LNGDIR="share/${PN}/locale"
371
372 # Count linguas
373 count() { echo ${#}; }
374 local lingua_count=$(count ${O_LINGUAS} en)
375 local locale_count=$(count ${LNGDIR}/*)
376 [[ ${lingua_count} = ${locale_count} ]] \
377 || die "Number of LINGUAS does not match number of locales"
378 unset count
379
380 # Remove unwanted linguas
381 einfo "Keeping these locales (linguas): ${LINGUAS}."
382 for LINGUA in ${O_LINGUAS}; do
383 if ! use linguas_${LINGUA/-/_}; then
384 LINGUA=$(find "${LNGDIR}" -maxdepth 1 -type d -iname ${LINGUA/_/-})
385 rm -r "${LINGUA}" || die "The list of linguas needs to be fixed"
386 fi
387 done
388
389 # Remove doc directory but keep the LICENSE under another name (bug #315473)
390 mv share/doc/${PN}/LICENSE share/${PN}/defaults/license.txt
391 rm -rf share/doc
392 for locale in share/${PN}/locale/*; do
393 rm -f "${locale}/license.txt"
394 ln -sn /usr/share/${PN}/defaults/license.txt "${locale}/license.txt" \
395 || die
396 done
397
398 # Remove package directory
399 rm -rf share/${PN}/package
400
401 # Optional libraries
402 if ! use gtk; then
403 rm lib/${PN}/liboperagtk2.so || die
404 fi
405 if ! use gtk3; then
406 rm lib/${PN}/liboperagtk3.so || die
407 fi
408 if ! use kde; then
409 rm lib/${PN}/liboperakde4.so || die
410 fi
411 if ! use gstreamer; then
412 rm -r lib/${PN}/gstreamer || die
413 fi
414
415 # Unzip the man pages before sedding
416 gunzip share/man/man1/* || die
417
418 # Replace PREFIX, SUFFIX and PN in various files
419 sed -i \
420 -e "s:@@{PREFIX}:/usr:g" \
421 -e "s:@@{SUFFIX}::g" \
422 -e "s:@@{_SUFFIX}::g" \
423 -e "s:@@{USUFFIX}::g" \
424 -e "s:opera:${PN}:g" \
425 share/man/man1/* \
426 share/applications/${PN}-*.desktop \
427 || die
428
429 # Replace "Opera" with "Opera Next"
430 if [[ ${PN} = opera-next ]]; then
431 sed -i share/applications/${PN}-*.desktop \
432 -e "/^Name=Opera\|^ Next/s:Opera:& Next:" || die
433 fi
434
435 # Create /usr/bin/opera wrapper
436 echo '#!/bin/sh' > ${PN}
437 echo 'export OPERA_DIR="/usr/share/'"${PN}"'"' >> ${PN}
438 echo 'export OPERA_PERSONALDIR=${OPERA_PERSONALDIR:-"${HOME}/.'${PN}'"}' \
439 >> ${PN}
440 echo 'exec '"${OPREFIX}/${PN}/${PN}"' "$@"' >> ${PN}
441
442 # Change libz.so.3 to libz.so.1 for gentoo/freebsd
443 if use elibc_FreeBSD; then
444 scanelf -qR -N libz.so.3 -F "#N" lib/${PN}/ | \
445 while read i; do
446 if [[ $(strings "$i" | fgrep -c libz.so.3) -ne 1 ]];
447 then
448 export SANITY_CHECK_LIBZ_FAILED=1
449 break
450 fi
451 sed -i \
452 "$i" \
453 -e 's/libz\.so\.3/libz.so.1/g'
454 done
455 [[ "$SANITY_CHECK_LIBZ_FAILED" = "1" ]] && die
456 fi
457 }
458
459 src_install() {
460 # We install into usr instead of opt as Opera does not support the latter
461 dodir /usr
462 mv lib/ "${D}/${OPREFIX}" || die
463 mv share/ "${D}/usr/" || die
464
465 # Install startup scripts
466 dobin ${PN}
467
468 # Stop revdep-rebuild from checking opera binaries
469 dodir /etc/revdep-rebuild
470 echo "SEARCH_DIRS_MASK=\"${OPREFIX}/${PN}\"" \
471 > "${D}"/etc/revdep-rebuild/90${PN}
472
473 # Set PaX markings for hardened/PaX (bug #344267)
474 pax-mark m "${D}"/${OPREFIX}/${PN}/opera*
475 }
476
477 pkg_preinst() {
478 gnome2_icon_savelist
479 }
480
481 pkg_postinst() {
482 if use elibc_FreeBSD; then
483 elog
484 elog "To improve shared memory usage please set:"
485 elog "$ sysctl kern.ipc.shm_allow_removed=1"
486 fi
487
488 # Update desktop file database and gtk icon cache (bug #334993)
489 gnome2_icon_cache_update
490 fdo-mime_desktop_database_update
491 }
492
493 pkg_postrm() {
494 # Update desktop file database and gtk icon cache (bug #334993)
495 gnome2_icon_cache_update
496 fdo-mime_desktop_database_update
497 }