Gentoo Archives: gentoo-commits

From: "Lars Wendler (polynomial-c)" <polynomial-c@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in www-client/icecat: ChangeLog icecat-10.0.ebuild
Date: Wed, 08 Feb 2012 14:29:47
Message-Id: 20120208142937.256732004B@flycatcher.gentoo.org
1 polynomial-c 12/02/08 14:29:37
2
3 Modified: ChangeLog
4 Added: icecat-10.0.ebuild
5 Log:
6 Version bump
7
8 (Portage version: 2.2.0_alpha85/cvs/Linux x86_64)
9
10 Revision Changes Path
11 1.109 www-client/icecat/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/ChangeLog?rev=1.109&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/ChangeLog?rev=1.109&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/ChangeLog?r1=1.108&r2=1.109
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/www-client/icecat/ChangeLog,v
20 retrieving revision 1.108
21 retrieving revision 1.109
22 diff -u -r1.108 -r1.109
23 --- ChangeLog 3 Jan 2012 00:17:54 -0000 1.108
24 +++ ChangeLog 8 Feb 2012 14:29:37 -0000 1.109
25 @@ -1,6 +1,11 @@
26 # ChangeLog for www-client/icecat
27 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/www-client/icecat/ChangeLog,v 1.108 2012/01/03 00:17:54 polynomial-c Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/www-client/icecat/ChangeLog,v 1.109 2012/02/08 14:29:37 polynomial-c Exp $
30 +
31 +*icecat-10.0 (08 Feb 2012)
32 +
33 + 08 Feb 2012; Lars Wendler <polynomial-c@g.o> +icecat-10.0.ebuild:
34 + Version bump
35
36 *icecat-9.0.1 (03 Jan 2012)
37
38
39
40
41 1.1 www-client/icecat/icecat-10.0.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/icecat-10.0.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/icecat-10.0.ebuild?rev=1.1&content-type=text/plain
45
46 Index: icecat-10.0.ebuild
47 ===================================================================
48 # Copyright 1999-2012 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/www-client/icecat/icecat-10.0.ebuild,v 1.1 2012/02/08 14:29:37 polynomial-c Exp $
51
52 EAPI="3"
53 VIRTUALX_REQUIRED="pgo"
54 WANT_AUTOCONF="2.1"
55
56 # This list can be updated with scripts/get_langs.sh from the mozilla overlay
57 MOZ_LANGS=(af ak ar as ast be bg bn-BD bn-IN br bs ca cs csb cy da de el en
58 en-GB en-US en-ZA eo es-AR es-CL es-ES es-MX et eu fa fi fr fy-NL ga-IE gd gl
59 gu-IN he hi-IN hr hu hy-AM id is it ja kk kn ko ku lg lt lv mai mk ml mr nb-NO
60 nl nn-NO nso or pa-IN pl pt-BR pt-PT rm ro ru si sk sl son sq sr sv-SE ta ta-LK
61 te th tr uk vi zh-CN zh-TW zu)
62
63 # Convert the ebuild version to the upstream mozilla version, used by mozlinguas
64 MOZ_PV="${PV/_alpha/a}" # Handle alpha for SRC_URI
65 MOZ_PV="${MOZ_PV/_beta/b}" # Handle beta for SRC_URI
66 MOZ_PV="${MOZ_PV/_rc/rc}" # Handle rc for SRC_URI
67
68 # Patch version
69 PATCH="firefox-10.0-patches-0.4"
70 # Upstream ftp release URI that's used by mozlinguas.eclass
71 # We don't use the http mirror because it deletes old tarballs.
72 MOZ_FTP_URI="ftp://ftp.mozilla.org/pub/firefox/releases"
73
74 inherit check-reqs flag-o-matic toolchain-funcs eutils gnome2-utils mozconfig-3 multilib pax-utils fdo-mime autotools python virtualx nsplugins mozlinguas
75
76 DESCRIPTION="GNU project's edition of Mozilla Firefox"
77 HOMEPAGE="http://www.gnu.org/software/gnuzilla/"
78
79 KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
80 SLOT="0"
81 LICENSE="|| ( MPL-1.1 GPL-2 LGPL-2.1 )"
82 IUSE="+crashreporter +ipc pgo selinux system-sqlite +webm"
83
84 # More URIs appended below...
85 SRC_URI="${SRC_URI}
86 mirror://gnu/gnuzilla/${MOZ_PV}/${PN}-${MOZ_PV}.tar.xz
87 http://dev.gentoo.org/~anarchy/mozilla/patchsets/${PATCH}.tar.xz"
88
89 ASM_DEPEND=">=dev-lang/yasm-1.1"
90
91 # Mesa 7.10 needed for WebGL + bugfixes
92 RDEPEND="
93 >=sys-devel/binutils-2.16.1
94 >=dev-libs/nss-3.13.1
95 >=dev-libs/nspr-4.8.8
96 >=dev-libs/glib-2.26:2
97 >=media-libs/mesa-7.10
98 media-libs/libpng[apng]
99 virtual/libffi
100 system-sqlite? ( >=dev-db/sqlite-3.7.7.1[fts3,secure-delete,threadsafe,unlock-notify,debug=] )
101 webm? ( >=media-libs/libvpx-0.9.7
102 media-libs/alsa-lib )
103 crashreporter? ( net-misc/curl )
104 selinux? ( sec-policy/selinux-mozilla )"
105 # We don't use PYTHON_DEPEND/PYTHON_USE_WITH for some silly reason
106 DEPEND="${RDEPEND}
107 dev-util/pkgconfig
108 pgo? (
109 =dev-lang/python-2*[sqlite]
110 >=sys-devel/gcc-4.5 )
111 webm? ( x86? ( ${ASM_DEPEND} )
112 amd64? ( ${ASM_DEPEND} ) )"
113
114 QA_PRESTRIPPED="usr/$(get_libdir)/${PN}/${PN}"
115
116 pkg_setup() {
117 moz_pkgsetup
118
119 # Avoid PGO profiling problems due to enviroment leakage
120 # These should *always* be cleaned up anyway
121 unset DBUS_SESSION_BUS_ADDRESS \
122 DISPLAY \
123 ORBIT_SOCKETDIR \
124 SESSION_MANAGER \
125 XDG_SESSION_COOKIE \
126 XAUTHORITY
127
128 if use pgo ; then
129 einfo
130 ewarn "You will do a double build for profile guided optimization."
131 ewarn "This will result in your build taking at least twice as long as before."
132 fi
133
134 # Ensure we have enough disk space to compile
135 if use pgo || use debug || use test ; then
136 CHECKREQS_DISK_BUILD="8G"
137 else
138 CHECKREQS_DISK_BUILD="4G"
139 fi
140 check-reqs_pkg_setup
141 }
142
143 src_unpack() {
144 unpack ${A}
145
146 # Unpack language packs
147 mozlinguas_src_unpack
148 }
149
150 src_prepare() {
151 # Fix preferences location
152 sed -i 's|defaults/pref/|defaults/preferences/|' browser/installer/packages-static || die "sed failed"
153 # Apply our patches
154 EPATCH_EXCLUDE="2000-firefox_gentoo_install_dirs.patch" \
155 EPATCH_SUFFIX="patch" \
156 EPATCH_FORCE="yes" \
157 epatch "${WORKDIR}/firefox"
158
159 epatch "${FILESDIR}"/2000-icecat-6_gentoo_install_dirs.patch
160
161 # Allow user to apply any additional patches without modifing ebuild
162 epatch_user
163
164 # Fix rebranding
165 sed -i 's|\$(DIST)/bin/firefox|\$(DIST)/bin/icecat|' browser/app/Makefile.in
166
167 # Enable gnomebreakpad
168 if use debug ; then
169 sed -i -e "s:GNOME_DISABLE_CRASH_DIALOG=1:GNOME_DISABLE_CRASH_DIALOG=0:g" \
170 "${S}"/build/unix/run-mozilla.sh || die "sed failed!"
171 fi
172
173 # Disable gnomevfs extension
174 sed -i -e "s:gnomevfs::" "${S}/"browser/confvars.sh \
175 -e "s:gnomevfs::" "${S}/"xulrunner/confvars.sh \
176 || die "Failed to remove gnomevfs extension"
177
178 # Ensure that are plugins dir is enabled as default
179 sed -i -e "s:/usr/lib/mozilla/plugins:/usr/$(get_libdir)/nsbrowser/plugins:" \
180 "${S}"/xpcom/io/nsAppFileLocationProvider.cpp || die "sed failed to replace plugin path!"
181
182 # Fix sandbox violations during make clean, bug 372817
183 sed -e "s:\(/no-such-file\):${T}\1:g" \
184 -i "${S}"/config/rules.mk \
185 -i "${S}"/js/src/config/rules.mk \
186 -i "${S}"/nsprpub/configure{.in,} \
187 || die
188
189 #Fix compilation with curl-7.21.7 bug 376027
190 sed -e '/#include <curl\/types.h>/d' \
191 -i "${S}"/toolkit/crashreporter/google-breakpad/src/common/linux/http_upload.cc \
192 -i "${S}"/toolkit/crashreporter/google-breakpad/src/common/linux/libcurl_wrapper.cc \
193 -i "${S}"/config/system-headers \
194 -i "${S}"/js/src/config/system-headers || die "Sed failed"
195
196 eautoreconf
197 }
198
199 src_configure() {
200 # We will build our own .mozconfig
201 rm "${S}"/.mozconfig
202
203 MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
204 MEXTENSIONS="default"
205
206 ####################################
207 #
208 # mozconfig, CFLAGS and CXXFLAGS setup
209 #
210 ####################################
211
212 mozconfig_init
213 mozconfig_config
214
215 # It doesn't compile on alpha without this LDFLAGS
216 use alpha && append-ldflags "-Wl,--no-relax"
217
218 # Specific settings for icecat
219 echo "export MOZ_PHOENIX=1" >> "${S}"/.mozconfig
220 echo "mk_add_options MOZ_PHOENIX=1" "${S}"/.mozconfig
221 mozconfig_annotate '' --with-branding=browser/branding/unofficial
222 mozconfig_annotate '' --disable-official-branding
223 mozconfig_annotate '' --with-user-appdir=.icecat
224
225 mozconfig_annotate '' --prefix="${EPREFIX}"/usr
226 mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
227 mozconfig_annotate '' --enable-extensions="${MEXTENSIONS}"
228 mozconfig_annotate '' --disable-gconf
229 mozconfig_annotate '' --disable-mailnews
230 mozconfig_annotate '' --enable-canvas
231 mozconfig_annotate '' --enable-safe-browsing
232 mozconfig_annotate '' --with-system-png
233 mozconfig_annotate '' --enable-system-ffi
234
235 # Other browser-specific settings
236 mozconfig_annotate '' --with-default-mozilla-five-home=${MOZILLA_FIVE_HOME}
237 mozconfig_annotate '' --target="${CTARGET:-${CHOST}}"
238
239 mozconfig_use_enable system-sqlite
240
241 # Allow for a proper pgo build
242 if use pgo ; then
243 echo "mk_add_options PROFILE_GEN_SCRIPT='\$(PYTHON) \$(OBJDIR)/_profile/pgo/profileserver.py'" >> "${S}"/.mozconfig
244 fi
245
246 # Finalize and report settings
247 mozconfig_final
248
249 if [[ $(gcc-major-version) -lt 4 ]]; then
250 append-cxxflags -fno-stack-protector
251 elif [[ $(gcc-major-version) -gt 4 || $(gcc-minor-version) -gt 3 ]]; then
252 if use amd64 || use x86; then
253 append-flags -mno-avx
254 fi
255 fi
256 }
257
258 src_compile() {
259 if use pgo; then
260 addpredict /root
261 addpredict /etc/gconf
262 # Reset and cleanup environment variables used by GNOME/XDG
263 gnome2_environment_reset
264
265 # icecat tries to use dri stuff when it's run, see bug 380283
266 shopt -s nullglob
267 cards=$(echo -n /dev/dri/card* | sed 's/ /:/g')
268 if test -n "${cards}"; then
269 # FOSS drivers are fine
270 addpredict "${cards}"
271 else
272 cards=$(echo -n /dev/ati/card* /dev/nvidiactl* | sed 's/ /:/g')
273 if test -n "${cards}"; then
274 # Binary drivers seem to cause access violations anyway, so
275 # let's use software rendering so that the device files aren't
276 # touched at all. See bug 394715.
277 export LIBGL_ALWAYS_SOFTWARE=1
278 fi
279 fi
280 shopt -u nullglob
281
282 CC="$(tc-getCC)" CXX="$(tc-getCXX)" LD="$(tc-getLD)" \
283 MOZ_MAKE_FLAGS="${MAKEOPTS}" \
284 Xemake -f client.mk profiledbuild || die "Xemake failed"
285 else
286 CC="$(tc-getCC)" CXX="$(tc-getCXX)" LD="$(tc-getLD)" \
287 MOZ_MAKE_FLAGS="${MAKEOPTS}" \
288 emake -f client.mk || die "emake failed"
289 fi
290
291 }
292
293 src_install() {
294 MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
295
296 # MOZ_BUILD_ROOT, and hence OBJ_DIR change depending on arch, compiler, pgo, etc.
297 local obj_dir="$(echo */config.log)"
298 obj_dir="${obj_dir%/*}"
299 cd "${S}/${obj_dir}"
300
301 # Pax mark xpcshell for hardened support, only used for startupcache creation.
302 pax-mark m "${S}/${obj_dir}"/dist/bin/xpcshell
303
304 # Add our default prefs for firefox + xulrunner
305 cp "${FILESDIR}"/gentoo-default-prefs.js-1 \
306 "${S}/${obj_dir}/dist/bin/defaults/pref/all-gentoo.js" || die
307
308 MOZ_MAKE_FLAGS="${MAKEOPTS}" \
309 emake DESTDIR="${D}" install || die "emake install failed"
310
311 # Install language packs
312 mozlinguas_src_install
313
314 local size sizes icon_path icon name
315
316 sizes="16 32 48"
317 icon_path="${S}/browser/branding/unofficial"
318
319 # Install icons and .desktop for menu entry
320 for size in ${sizes}; do
321 insinto "/usr/share/icons/hicolor/${size}x${size}/apps"
322 newins "${icon_path}/default${size}.png" "${PN}.png" || die
323 done
324 # The 128x128 icon has a different name
325 insinto "/usr/share/icons/hicolor/128x128/apps"
326 newins "${icon_path}/mozicon128.png" "${PN}.png" || die
327 # Install a 48x48 icon into /usr/share/pixmaps for legacy DEs
328 newicon "${icon_path}/content/icon48.png" "${PN}.png" || die
329 newmenu "${FILESDIR}/icon/${PN}.desktop" "${PN}.desktop" || die
330 sed -e "/^Icon/s:${PN}-icon:${PN}:" -i \
331 "${ED}/usr/share/applications/${PN}.desktop" || die
332
333 # Add StartupNotify=true bug 237317
334 if use startup-notification ; then
335 echo "StartupNotify=true" >> "${ED}/usr/share/applications/${PN}.desktop"
336 fi
337
338 # Required in order to use plugins and even run firefox on hardened.
339 pax-mark m "${ED}"${MOZILLA_FIVE_HOME}/{${PN}{,-bin},plugin-container}
340
341 # Plugins dir
342 share_plugins_dir
343 }
344
345 pkg_preinst() {
346 gnome2_icon_savelist
347 }
348
349 pkg_postinst() {
350 # Update mimedb for the new .desktop file
351 fdo-mime_desktop_database_update
352 gnome2_icon_cache_update
353 }
354
355 pkg_postrm() {
356 gnome2_icon_cache_update
357 }