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.1054.ebuild opera-next-12.00.1020.ebuild opera-next-12.00.1033.ebuild opera-next-12.00.1033-r1.ebuild opera-next-12.00.1017.ebuild opera-next-11.50.1074.ebuild opera-next-12.00.1039.ebuild opera-next-12.00.1027.ebuild
Date: Fri, 02 Sep 2011 15:50:33
Message-Id: 20110902155023.943F42004C@flycatcher.gentoo.org
1 jer 11/09/02 15:50:23
2
3 Modified: ChangeLog
4 Added: opera-next-12.00.1054.ebuild
5 Removed: opera-next-12.00.1020.ebuild
6 opera-next-12.00.1033.ebuild
7 opera-next-12.00.1033-r1.ebuild
8 opera-next-12.00.1017.ebuild
9 opera-next-11.50.1074.ebuild
10 opera-next-12.00.1039.ebuild
11 opera-next-12.00.1027.ebuild
12 Log:
13 http://my.opera.com/desktopteam/blog/2011/09/02/new-wahoo-12-00-build-with-updated-core-and-speed-dial
14
15 (Portage version: 2.2.0_alpha51/cvs/Linux x86_64)
16
17 Revision Changes Path
18 1.39 www-client/opera-next/ChangeLog
19
20 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/ChangeLog?rev=1.39&view=markup
21 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/ChangeLog?rev=1.39&content-type=text/plain
22 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/ChangeLog?r1=1.38&r2=1.39
23
24 Index: ChangeLog
25 ===================================================================
26 RCS file: /var/cvsroot/gentoo-x86/www-client/opera-next/ChangeLog,v
27 retrieving revision 1.38
28 retrieving revision 1.39
29 diff -u -r1.38 -r1.39
30 --- ChangeLog 16 Aug 2011 19:59:48 -0000 1.38
31 +++ ChangeLog 2 Sep 2011 15:50:23 -0000 1.39
32 @@ -1,6 +1,16 @@
33 # ChangeLog for www-client/opera-next
34 # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
35 -# $Header: /var/cvsroot/gentoo-x86/www-client/opera-next/ChangeLog,v 1.38 2011/08/16 19:59:48 jer Exp $
36 +# $Header: /var/cvsroot/gentoo-x86/www-client/opera-next/ChangeLog,v 1.39 2011/09/02 15:50:23 jer Exp $
37 +
38 +*opera-next-12.00.1054 (02 Sep 2011)
39 +
40 + 02 Sep 2011; Jeroen Roovers <jer@g.o> -opera-next-11.50.1074.ebuild,
41 + -opera-next-12.00.1017.ebuild, -opera-next-12.00.1020.ebuild,
42 + -opera-next-12.00.1027.ebuild, -opera-next-12.00.1033.ebuild,
43 + -opera-next-12.00.1033-r1.ebuild, -opera-next-12.00.1039.ebuild,
44 + +opera-next-12.00.1054.ebuild:
45 + http://my.opera.com/desktopteam/blog/2011/09/02/new-wahoo-12-00-build-with-up
46 + dated-core-and-speed-dial
47
48 *opera-next-12.00.1047 (16 Aug 2011)
49
50
51
52
53 1.1 www-client/opera-next/opera-next-12.00.1054.ebuild
54
55 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/opera-next-12.00.1054.ebuild?rev=1.1&view=markup
56 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/opera-next/opera-next-12.00.1054.ebuild?rev=1.1&content-type=text/plain
57
58 Index: opera-next-12.00.1054.ebuild
59 ===================================================================
60 # Copyright 1999-2011 Gentoo Foundation
61 # Distributed under the terms of the GNU General Public License v2
62 # $Header: /var/cvsroot/gentoo-x86/www-client/opera-next/opera-next-12.00.1054.ebuild,v 1.1 2011/09/02 15:50:23 jer Exp $
63
64 EAPI="4"
65
66 inherit eutils fdo-mime gnome2-utils multilib pax-utils versionator
67
68 DESCRIPTION="A fast and secure web browser and Internet suite"
69 HOMEPAGE="http://www.opera.com/"
70
71 SLOT="0"
72 LICENSE="OPERA-11 LGPL-2 LGPL-3"
73 KEYWORDS="~amd64 ~x86 ~x86-fbsd"
74 IUSE="elibc_FreeBSD gtk kde +gstreamer"
75
76 O_V="$(get_version_component_range 1-2)" # Major version, i.e. 11.00
77 O_B="$(get_version_component_range 3)" # Build version, i.e. 1156
78
79 O_D="twelvereturns_${O_V}-${O_B}"
80 O_P="${PN}-${O_V}-${O_B}"
81 O_U="http://snapshot.opera.com/unix/"
82
83 SRC_URI="
84 amd64? ( ${O_U}${O_D}/${O_P}.x86_64.linux.tar.xz )
85 x86? ( ${O_U}${O_D}/${O_P}.i386.linux.tar.xz )
86 x86-fbsd? ( ${O_U}${O_D}/${O_P}.i386.freebsd.tar.xz )
87 "
88
89 OPREFIX="/usr/$(get_libdir)"
90
91 QA_DT_HASH="${OPREFIX}/${PN}/.*"
92 QA_PRESTRIPPED="${OPREFIX}/${PN}/.*"
93
94 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
95 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
96 th tl tr uk uz vi zh-CN zh-TW zu"
97
98 for O_LINGUA in ${O_LINGUAS}; do
99 IUSE="${IUSE} linguas_${O_LINGUA/-/_}"
100 done
101
102 DEPEND="
103 >=sys-apps/sed-4
104 app-arch/xz-utils
105 "
106 GTKRDEPEND="
107 dev-libs/atk
108 dev-libs/glib:2
109 x11-libs/cairo
110 x11-libs/gdk-pixbuf
111 x11-libs/gtk+:2
112 x11-libs/pango
113 x11-libs/pixman
114 "
115 KDERDEPEND="
116 kde-base/kdelibs
117 x11-libs/qt-core
118 x11-libs/qt-gui
119 "
120 GSTRDEPEND="
121 dev-libs/glib
122 dev-libs/libxml2
123 media-plugins/gst-plugins-meta
124 media-libs/gstreamer
125 "
126 RDEPEND="
127 media-libs/fontconfig
128 media-libs/freetype
129 sys-apps/util-linux
130 sys-libs/zlib
131 virtual/opengl
132 x11-libs/libICE
133 x11-libs/libSM
134 x11-libs/libX11
135 x11-libs/libXext
136 x11-libs/libXft
137 x11-libs/libXrender
138 gtk? ( ${GTKRDEPEND} )
139 kde? ( ${KDERDEPEND} )
140 gstreamer? ( ${GSTRDEPEND} )
141 "
142
143 pkg_setup() {
144 echo -e \
145 " ${GOOD}****************************************************${NORMAL}"
146 elog "If you seek support, please file a bug report at"
147 elog "https://bugs.gentoo.org and post the output of"
148 elog " \`emerge --info =${CATEGORY}/${P}'"
149 echo -e \
150 " ${GOOD}****************************************************${NORMAL}"
151 }
152
153 src_unpack() {
154 unpack ${A}
155 mv -v ${PN}* "${S}" || die
156 }
157
158 src_prepare() {
159 local LNGDIR="share/${PN}/locale"
160
161 # Count linguas
162 count() { echo ${#}; }
163 local lingua_count=$(count ${O_LINGUAS} en)
164 local locale_count=$(count ${LNGDIR}/*)
165 [[ ${lingua_count} = ${locale_count} ]] \
166 || die "Number of LINGUAS does not match number of locales"
167 unset count
168
169 # Remove unwanted linguas
170 einfo "Keeping these locales (linguas): ${LINGUAS}."
171 for LINGUA in ${O_LINGUAS}; do
172 if ! use linguas_${LINGUA/-/_}; then
173 LINGUA=$(find "${LNGDIR}" -maxdepth 1 -type d -iname ${LINGUA/_/-})
174 rm -r "${LINGUA}" || die "The list of linguas needs to be fixed"
175 fi
176 done
177
178 # Remove doc directory but keep the LICENSE under another name (bug #315473)
179 mv share/doc/${PN}/LICENSE share/${PN}/defaults/license.txt
180 rm -rf share/doc
181 for locale in share/${PN}/locale/*; do
182 rm -f "${locale}/license.txt"
183 ln -sn /usr/share/${PN}/defaults/license.txt "${locale}/license.txt" \
184 || die "ln -sn license.txt"
185 done
186
187 # Remove package directory
188 rm -rf share/${PN}/package
189
190 # Leave libopera*.so only if the user chooses
191 if ! use gtk; then
192 rm lib/${PN}/liboperagtk2.so || die "rm liboperagtk.so failed"
193 fi
194 if ! use kde; then
195 rm lib/${PN}/liboperakde4.so || die "rm liboperakde4.so failed"
196 fi
197
198 # Unzip the man pages before sedding
199 gunzip share/man/man1/* || die "gunzip failed"
200
201 # Replace PREFIX, SUFFIX and PN in various files
202 sed -i \
203 -e "s:@@{PREFIX}:/usr:g" \
204 -e "s:@@{SUFFIX}::g" \
205 -e "s:@@{_SUFFIX}::g" \
206 -e "s:@@{USUFFIX}::g" \
207 -e "s:opera:${PN}:g" \
208 share/man/man1/* \
209 share/applications/${PN}-*.desktop \
210 || die "sed failed"
211
212 # Replace "Opera" with "Opera Next"
213 if [[ ${PN} = opera-next ]]; then
214 sed -i share/applications/${PN}-*.desktop \
215 -e "/^Name=Opera\|^ Next/s:Opera:& Next:" || die
216 fi
217
218 # Create /usr/bin/opera wrapper
219 echo '#!/bin/sh' > ${PN}
220 echo 'export OPERA_DIR=/usr/share/'"${PN}" >> ${PN}
221 echo 'export OPERA_PERSONALDIR=${OPERA_PERSONALDIR:-"${HOME}/.'${PN}'"}' \
222 >> ${PN}
223 echo 'exec '"${OPREFIX}/${PN}/${PN}"' "$@"' >> ${PN}
224
225 # Fix libdir in defaults/pluginpath.ini
226 sed -i \
227 share/${PN}/defaults/pluginpath.ini \
228 -e "s|/usr/lib32|${OPREFIX}|g" \
229 -e '/netscape/{s|[0-1]|2|g}' \
230 || die "sed pluginpath.ini failed"
231
232 # Change libz.so.3 to libz.so.1 for gentoo/freebsd
233 if use elibc_FreeBSD; then
234 scanelf -qR -N libz.so.3 -F "#N" lib/${PN}/ | \
235 while read i; do
236 if [[ $(strings "$i" | fgrep -c libz.so.3) -ne 1 ]];
237 then
238 export SANITY_CHECK_LIBZ_FAILED=1
239 break
240 fi
241 sed -i \
242 "$i" \
243 -e 's/libz\.so\.3/libz.so.1/g'
244 done
245 [[ "$SANITY_CHECK_LIBZ_FAILED" = "1" ]] \
246 && die "failed to change libz.so.3 to libz.so.1"
247 fi
248 }
249
250 src_install() {
251 # We install into usr instead of opt as Opera does not support the latter
252 dodir /usr
253 mv lib/ "${D}/${OPREFIX}" || die "mv lib/ failed"
254 mv share/ "${D}/usr/" || die "mv share/ failed"
255
256 # Install startup scripts
257 dobin ${PN}
258
259 # Stop revdep-rebuild from checking opera binaries
260 dodir /etc/revdep-rebuild
261 echo "SEARCH_DIRS_MASK=\"${OPREFIX}/${PN}\"" \
262 > "${D}"/etc/revdep-rebuild/90${PN}
263
264 # Set PaX markings for hardened/PaX (bug #344267)
265 pax-mark m \
266 "${D}/${OPREFIX}/${PN}/${PN}" \
267 "${D}/${OPREFIX}/${PN}/operaplugincleaner" \
268 "${D}/${OPREFIX}/${PN}/operapluginwrapper"
269 }
270
271 pkg_preinst() {
272 gnome2_icon_savelist
273 }
274
275 pkg_postinst() {
276 if use elibc_FreeBSD; then
277 elog
278 elog "To improve shared memory usage please set:"
279 elog "$ sysctl kern.ipc.shm_allow_removed=1"
280 fi
281
282 # Update desktop file database and gtk icon cache (bug #334993)
283 gnome2_icon_cache_update
284 fdo-mime_desktop_database_update
285 }
286
287 pkg_postrm() {
288 # Update desktop file database and gtk icon cache (bug #334993)
289 gnome2_icon_cache_update
290 fdo-mime_desktop_database_update
291 }