Gentoo Archives: gentoo-commits

From: "PaweA Hajdan (phajdan.jr)" <phajdan.jr@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in www-client/chromium: chromium-8.0.552.215.ebuild ChangeLog chromium-8.0.552.208.ebuild
Date: Fri, 03 Dec 2010 07:16:32
Message-Id: 20101203071622.B50CE20054@flycatcher.gentoo.org
1 phajdan.jr 10/12/03 07:16:22
2
3 Modified: ChangeLog
4 Added: chromium-8.0.552.215.ebuild
5 Removed: chromium-8.0.552.208.ebuild
6 Log:
7 Version bump for stable channel release. Remove old.
8
9 (Portage version: 2.1.9.24/cvs/Linux i686)
10
11 Revision Changes Path
12 1.233 www-client/chromium/ChangeLog
13
14 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?rev=1.233&view=markup
15 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?rev=1.233&content-type=text/plain
16 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?r1=1.232&r2=1.233
17
18 Index: ChangeLog
19 ===================================================================
20 RCS file: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v
21 retrieving revision 1.232
22 retrieving revision 1.233
23 diff -u -r1.232 -r1.233
24 --- ChangeLog 2 Dec 2010 10:12:46 -0000 1.232
25 +++ ChangeLog 3 Dec 2010 07:16:22 -0000 1.233
26 @@ -1,6 +1,12 @@
27 # ChangeLog for www-client/chromium
28 # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
29 -# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v 1.232 2010/12/02 10:12:46 phajdan.jr Exp $
30 +# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v 1.233 2010/12/03 07:16:22 phajdan.jr Exp $
31 +
32 +*chromium-8.0.552.215 (03 Dec 2010)
33 +
34 + 03 Dec 2010; Pawel Hajdan jr <phajdan.jr@g.o>
35 + -chromium-8.0.552.208.ebuild, +chromium-8.0.552.215.ebuild:
36 + Version bump for stable channel release. Remove old.
37
38 *chromium-9.0.597.0 (02 Dec 2010)
39
40
41
42
43 1.1 www-client/chromium/chromium-8.0.552.215.ebuild
44
45 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/chromium-8.0.552.215.ebuild?rev=1.1&view=markup
46 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/chromium-8.0.552.215.ebuild?rev=1.1&content-type=text/plain
47
48 Index: chromium-8.0.552.215.ebuild
49 ===================================================================
50 # Copyright 1999-2010 Gentoo Foundation
51 # Distributed under the terms of the GNU General Public License v2
52 # $Header: /var/cvsroot/gentoo-x86/www-client/chromium/chromium-8.0.552.215.ebuild,v 1.1 2010/12/03 07:16:22 phajdan.jr Exp $
53
54 EAPI="2"
55
56 inherit eutils flag-o-matic multilib pax-utils portability toolchain-funcs
57
58 DESCRIPTION="Open-source version of Google Chrome web browser"
59 HOMEPAGE="http://chromium.org/"
60 SRC_URI="http://build.chromium.org/buildbot/official/${P}.tar.bz2"
61
62 LICENSE="BSD"
63 SLOT="0"
64 KEYWORDS="~amd64 ~arm ~x86"
65 IUSE="cups +gecko-mediaplayer gnome gnome-keyring system-sqlite system-v8"
66
67 RDEPEND="app-arch/bzip2
68 system-sqlite? (
69 >=dev-db/sqlite-3.6.23.1[fts3,icu,secure-delete,threadsafe]
70 )
71 system-v8? ( ~dev-lang/v8-2.4.9.13 )
72 >=dev-libs/icu-4.4.1
73 >=dev-libs/libevent-1.4.13
74 dev-libs/libxml2
75 dev-libs/libxslt
76 >=dev-libs/nss-3.12.3
77 >=gnome-base/gconf-2.24.0
78 gnome-keyring? ( >=gnome-base/gnome-keyring-2.28.2 )
79 >=media-libs/alsa-lib-1.0.19
80 virtual/jpeg
81 media-libs/libpng
82 >=media-video/ffmpeg-0.6_p25423[threads]
83 cups? ( >=net-print/cups-1.3.11 )
84 sys-libs/zlib
85 >=x11-libs/gtk+-2.14.7
86 x11-libs/libXScrnSaver"
87 DEPEND="${RDEPEND}
88 dev-lang/perl
89 >=dev-util/gperf-3.0.3
90 >=dev-util/pkgconfig-0.23
91 sys-devel/flex"
92 RDEPEND+="
93 || (
94 x11-themes/gnome-icon-theme
95 x11-themes/oxygen-molecule
96 x11-themes/tango-icon-theme
97 x11-themes/xfce4-icon-theme
98 )
99 x11-misc/xdg-utils
100 virtual/ttf-fonts
101 gecko-mediaplayer? ( !www-plugins/gecko-mediaplayer[gnome] )"
102
103 remove_bundled_lib() {
104 einfo "Removing bundled library $1 ..."
105 local out
106 out="$(find $1 -type f \! -iname '*.gyp' -print -delete)" \
107 || die "failed to remove bundled library $1"
108 if [[ -z $out ]]; then
109 die "no files matched when removing bundled library $1"
110 fi
111 }
112
113 pkg_setup() {
114 CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser"
115
116 # Make sure the build system will use the right tools, bug #340795.
117 tc-export AR CC CXX RANLIB
118
119 # Prevent user problems like bug #299777.
120 if ! grep -q /dev/shm <<< $(get_mounts); then
121 ewarn "You don't have tmpfs mounted at /dev/shm."
122 ewarn "${PN} may fail to start in that configuration."
123 ewarn "Please uncomment the /dev/shm entry in /etc/fstab,"
124 ewarn "and run 'mount /dev/shm'."
125 fi
126 if [ `stat -c %a /dev/shm` -ne 1777 ]; then
127 ewarn "/dev/shm does not have correct permissions."
128 ewarn "${PN} may fail to start in that configuration."
129 ewarn "Please run 'chmod 1777 /dev/shm'."
130 fi
131 }
132
133 src_prepare() {
134 # Small fix to the system-provided icu support,
135 # to be upstreamed.
136 epatch "${FILESDIR}"/${PN}-system-icu-r1.patch
137
138 # Enable optional support for gecko-mediaplayer.
139 epatch "${FILESDIR}"/${PN}-gecko-mediaplayer-r0.patch
140
141 # Backport a fix for bug #343971.
142 epatch "${FILESDIR}"/${PN}-locale-glib-r1.patch
143
144 remove_bundled_lib "third_party/bzip2"
145 remove_bundled_lib "third_party/codesighs"
146 remove_bundled_lib "third_party/icu"
147 remove_bundled_lib "third_party/jemalloc"
148 remove_bundled_lib "third_party/lcov"
149 remove_bundled_lib "third_party/libevent"
150 remove_bundled_lib "third_party/libjpeg"
151 remove_bundled_lib "third_party/libpng"
152 remove_bundled_lib "third_party/libxml"
153 remove_bundled_lib "third_party/libxslt"
154 remove_bundled_lib "third_party/lzma_sdk"
155 remove_bundled_lib "third_party/molokocacao"
156 remove_bundled_lib "third_party/ocmock"
157 remove_bundled_lib "third_party/pyftpdlib"
158 remove_bundled_lib "third_party/simplejson"
159 remove_bundled_lib "third_party/tlslite"
160 # TODO: also remove third_party/ffmpeg (needs to be compile-tested).
161 # TODO: also remove third_party/zlib. For now the compilation fails if we
162 # remove it (minizip-related).
163
164 if use system-sqlite; then
165 remove_bundled_lib "third_party/sqlite/src"
166 remove_bundled_lib "third_party/sqlite/preprocessed"
167 fi
168
169 if use system-v8; then
170 # Provide our own gyp file that links with the system v8.
171 # TODO: move this upstream.
172 cp "${FILESDIR}"/v8.gyp v8/tools/gyp || die
173
174 remove_bundled_lib "v8"
175
176 # The implementation files include v8 headers with full path,
177 # like #include "v8/include/v8.h". Make sure the system headers
178 # will be used.
179 # TODO: find a solution that can be upstreamed.
180 rmdir v8/include || die
181 ln -s /usr/include v8/include || die
182 fi
183 }
184
185 src_configure() {
186 local myconf=""
187
188 # Never tell the build system to "enable" SSE2, it has a few unexpected
189 # additions, bug #336871.
190 myconf+=" -Ddisable_sse2=1"
191
192 # Use system-provided libraries.
193 # TODO: use_system_hunspell (upstream changes needed).
194 # TODO: use_system_ssl (need to consult upstream).
195 myconf+="
196 -Duse_system_bzip2=1
197 -Duse_system_ffmpeg=1
198 -Duse_system_icu=1
199 -Duse_system_libevent=1
200 -Duse_system_libjpeg=1
201 -Duse_system_libpng=1
202 -Duse_system_libxml=1
203 -Duse_system_zlib=1"
204
205 if use system-sqlite; then
206 myconf+=" -Duse_system_sqlite=1"
207 fi
208
209 # The dependency on cups is optional, see bug #324105.
210 if use cups; then
211 myconf+=" -Duse_cups=1"
212 else
213 myconf+=" -Duse_cups=0"
214 fi
215
216 if use "gnome-keyring"; then
217 myconf+=" -Duse_gnome_keyring=1 -Dlinux_link_gnome_keyring=1"
218 else
219 # TODO: we should also disable code trying to dlopen
220 # gnome-keyring in that case.
221 myconf+=" -Duse_gnome_keyring=0 -Dlinux_link_gnome_keyring=0"
222 fi
223
224 # Enable sandbox.
225 myconf+="
226 -Dlinux_sandbox_path=${CHROMIUM_HOME}/chrome_sandbox
227 -Dlinux_sandbox_chrome_path=${CHROMIUM_HOME}/chrome"
228
229 if host-is-pax; then
230 # Prevent the build from failing (bug #301880). The performance
231 # difference is very small.
232 myconf+=" -Dv8_use_snapshot=0"
233 fi
234
235 if use gecko-mediaplayer; then
236 # Disable hardcoded blacklist for gecko-mediaplayer.
237 # When www-plugins/gecko-mediaplayer is compiled with USE=gnome, it causes
238 # the browser to hang. We can handle the situation via dependencies,
239 # thus making it possible to use gecko-mediaplayer.
240 append-flags -DGENTOO_CHROMIUM_ENABLE_GECKO_MEDIAPLAYER
241 fi
242
243 # Our system ffmpeg should support more codecs than the bundled one
244 # for Chromium.
245 myconf+=" -Dproprietary_codecs=1"
246
247 # Use target arch detection logic from bug #296917.
248 local myarch="$ABI"
249 [[ $myarch = "" ]] && myarch="$ARCH"
250
251 if [[ $myarch = amd64 ]] ; then
252 myconf+=" -Dtarget_arch=x64"
253 elif [[ $myarch = x86 ]] ; then
254 myconf+=" -Dtarget_arch=ia32"
255 elif [[ $myarch = arm ]] ; then
256 # TODO: check this again after
257 # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39509 is fixed.
258 append-flags -fno-tree-sink
259
260 myconf+=" -Dtarget_arch=arm -Ddisable_nacl=1 -Dlinux_use_tcmalloc=0"
261 else
262 die "Failed to determine target arch, got '$myarch'."
263 fi
264
265 if [[ "$(gcc-major-version)$(gcc-minor-version)" == "44" ]]; then
266 myconf+=" -Dno_strict_aliasing=1 -Dgcc_version=44"
267 fi
268
269 # Work around a likely GCC bug, see bug #331945.
270 if [[ "$(gcc-major-version)$(gcc-minor-version)" == "45" ]]; then
271 append-flags -fno-ipa-cp
272 fi
273
274 # Make sure that -Werror doesn't get added to CFLAGS by the build system.
275 # Depending on GCC version the warnings are different and we don't want
276 # the build to fail because of that.
277 myconf+=" -Dwerror="
278
279 build/gyp_chromium --depth=. ${myconf} || die
280 }
281
282 src_compile() {
283 emake chrome chrome_sandbox BUILDTYPE=Release V=1 || die
284 }
285
286 src_install() {
287 exeinto "${CHROMIUM_HOME}"
288 pax-mark m out/Release/chrome
289 doexe out/Release/chrome
290 doexe out/Release/chrome_sandbox || die
291 fperms 4755 "${CHROMIUM_HOME}/chrome_sandbox"
292 doexe out/Release/xdg-settings || die
293 doexe "${FILESDIR}"/chromium-launcher.sh || die
294
295 insinto "${CHROMIUM_HOME}"
296 doins out/Release/chrome.pak || die
297 doins out/Release/resources.pak || die
298
299 doins -r out/Release/locales || die
300 doins -r out/Release/resources || die
301
302 # chrome.1 is for chromium --help
303 newman out/Release/chrome.1 chrome.1 || die
304 newman out/Release/chrome.1 chromium.1 || die
305
306 # Chromium looks for these in its folder
307 # See media_posix.cc and base_paths_linux.cc
308 dosym /usr/$(get_libdir)/libavcodec.so.52 "${CHROMIUM_HOME}" || die
309 dosym /usr/$(get_libdir)/libavformat.so.52 "${CHROMIUM_HOME}" || die
310 dosym /usr/$(get_libdir)/libavutil.so.50 "${CHROMIUM_HOME}" || die
311
312 # Install icon and desktop entry.
313 newicon out/Release/product_logo_48.png ${PN}-browser.png || die
314 dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium || die
315 make_desktop_entry chromium "Chromium" ${PN}-browser "Network;WebBrowser" \
316 "MimeType=text/html;text/xml;application/xhtml+xml;"
317 sed -e "/^Exec/s/$/ %U/" -i "${D}"/usr/share/applications/*.desktop || die
318
319 # Install GNOME default application entry (bug #303100).
320 if use gnome; then
321 dodir /usr/share/gnome-control-center/default-apps || die
322 insinto /usr/share/gnome-control-center/default-apps
323 doins "${FILESDIR}"/chromium.xml || die
324 fi
325 }