Gentoo Archives: gentoo-commits

From: "Jory Pratt (anarchy)" <anarchy@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in www-client/icecat: ChangeLog icecat-3.6.8-r1.ebuild
Date: Sun, 01 Aug 2010 17:02:57
Message-Id: 20100801161008.665242CE15@corvid.gentoo.org
1 anarchy 10/08/01 16:10:08
2
3 Modified: ChangeLog
4 Added: icecat-3.6.8-r1.ebuild
5 Log:
6 Fix bug #325469, new useflag to control printing support
7 (Portage version: 2.1.8.3/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.35 www-client/icecat/ChangeLog
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/ChangeLog?rev=1.35&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/ChangeLog?rev=1.35&content-type=text/plain
14 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/ChangeLog?r1=1.34&r2=1.35
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/www-client/icecat/ChangeLog,v
19 retrieving revision 1.34
20 retrieving revision 1.35
21 diff -u -r1.34 -r1.35
22 --- ChangeLog 31 Jul 2010 23:23:41 -0000 1.34
23 +++ ChangeLog 1 Aug 2010 16:10:08 -0000 1.35
24 @@ -1,6 +1,11 @@
25 # ChangeLog for www-client/icecat
26 # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/www-client/icecat/ChangeLog,v 1.34 2010/07/31 23:23:41 polynomial-c Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/www-client/icecat/ChangeLog,v 1.35 2010/08/01 16:10:08 anarchy Exp $
29 +
30 +*icecat-3.6.8-r1 (01 Aug 2010)
31 +
32 + 01 Aug 2010; Jory A. Pratt <anarchy@g.o> +icecat-3.6.8-r1.ebuild:
33 + Fix bug #325469, new useflag to control printing support
34
35 *icecat-3.6.8 (31 Jul 2010)
36
37
38
39
40 1.1 www-client/icecat/icecat-3.6.8-r1.ebuild
41
42 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/icecat-3.6.8-r1.ebuild?rev=1.1&view=markup
43 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/icecat/icecat-3.6.8-r1.ebuild?rev=1.1&content-type=text/plain
44
45 Index: icecat-3.6.8-r1.ebuild
46 ===================================================================
47 # Copyright 1999-2010 Gentoo Foundation
48 # Distributed under the terms of the GNU General Public License v2
49 # $Header: /var/cvsroot/gentoo-x86/www-client/icecat/icecat-3.6.8-r1.ebuild,v 1.1 2010/08/01 16:10:08 anarchy Exp $
50 EAPI="2"
51 WANT_AUTOCONF="2.1"
52
53 inherit flag-o-matic toolchain-funcs eutils mozconfig-3 makeedit multilib pax-utils fdo-mime autotools mozextension java-pkg-opt-2
54
55 LANGS="af ar as be bg bn-BD bn-IN ca cs cy da de el en en-GB en-US eo es-AR
56 es-CL es-ES es-MX et eu fa fi fr fy-NL ga-IE gl gu-IN he hi-IN hr hu id is it ja
57 ka kk kn ko ku lt lv mk ml mr nb-NO nl nn-NO oc or pa-IN pl pt-BR pt-PT rm ro
58 ru si sk sl sq sr sv-SE ta te th tr uk vi zh-CN zh-TW"
59 # Malformed install.rdf: ta-LK
60
61 NOSHORTLANGS="en-GB es-AR es-CL es-MX pt-BR zh-CN zh-TW"
62
63 MAJ_XUL_PV="1.9.2"
64 MAJ_PV="${PV/_*/}" # Without the _rc and _beta stuff
65 DESKTOP_PV="3.6"
66 MY_PV="${PV/_rc/rc}" # Handle beta for SRC_URI
67 XUL_PV="${MAJ_XUL_PV}${MAJ_PV/${DESKTOP_PV}/}" # Major + Minor version no.s
68 FIREFOX_PN="mozilla-firefox"
69 FIREFOX_P="${FIREFOX_PN}-${PV}"
70 PATCH="${FIREFOX_PN}-3.6-patches-0.6"
71
72 DESCRIPTION="GNU project's edition of Mozilla Firefox"
73 HOMEPAGE="http://www.gnu.org/software/gnuzilla/"
74
75 KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
76 SLOT="0"
77 LICENSE="|| ( MPL-1.1 GPL-2 LGPL-2.1 )"
78 IUSE="+alsa +cups +ipc java libnotify system-sqlite wifi"
79
80 SRC_URI="mirror://gnu/gnuzilla/${MY_PV}/${PN}-${MY_PV}.tar.bz2
81 http://dev.gentoo.org/~anarchy/dist/${PATCH}.tar.bz2"
82 LANGPACK_URI="http://gnuzilla.gnu.org/download/langpacks/"
83
84 for X in ${LANGS} ; do
85 if [ "${X}" != "en" ] && [ "${X}" != "en-US" ]; then
86 SRC_URI="${SRC_URI}
87 linguas_${X/-/_}? ( ${LANGPACK_URI}/${MY_PV}/${X}.xpi -> ${P}-${X}.xpi )"
88 fi
89 IUSE="${IUSE} linguas_${X/-/_}"
90 # english is handled internally
91 if [ "${#X}" == 5 ] && ! has ${X} ${NOSHORTLANGS}; then
92 if [ "${X}" != "en-US" ]; then
93 SRC_URI="${SRC_URI}
94 linguas_${X%%-*}? ( ${LANGPACK_URI}/${MY_PV}/${X}.xpi -> ${P}-${X}.xpi )"
95 fi
96 IUSE="${IUSE} linguas_${X%%-*}"
97 fi
98 done
99
100 RDEPEND="
101 >=sys-devel/binutils-2.16.1
102 >=dev-libs/nss-3.12.4
103 >=dev-libs/nspr-4.8
104 >=app-text/hunspell-1.2
105 system-sqlite? ( >=dev-db/sqlite-3.6.22-r2[fts3,secure-delete] )
106 alsa? ( media-libs/alsa-lib )
107 >=x11-libs/cairo-1.8.8[X]
108 x11-libs/pango[X]
109 wifi? ( net-wireless/wireless-tools )
110 libnotify? ( >=x11-libs/libnotify-0.4 )
111 cups? ( net-print/cups[gnutls] )
112 ~net-libs/xulrunner-${XUL_PV}[ipc=,java=,wifi=,libnotify=,system-sqlite=]"
113
114 DEPEND="${RDEPEND}
115 java? ( >=virtual/jdk-1.4 )
116 dev-util/pkgconfig"
117
118 RDEPEND="${RDEPEND} java? ( >=virtual/jre-1.4 )"
119
120 QA_PRESTRIPPED="usr/$(get_libdir)/${PN}/${PN}"
121
122 linguas() {
123 local LANG SLANG
124 for LANG in ${LINGUAS}; do
125 if has ${LANG} en en_US; then
126 has en ${linguas} || linguas="${linguas:+"${linguas} "}en"
127 continue
128 elif has ${LANG} ${LANGS//-/_}; then
129 has ${LANG//_/-} ${linguas} || linguas="${linguas:+"${linguas} "}${LANG//_/-}"
130 continue
131 elif [[ " ${LANGS} " == *" ${LANG}-"* ]]; then
132 for X in ${LANGS}; do
133 if [[ "${X}" == "${LANG}-"* ]] && \
134 [[ " ${NOSHORTLANGS} " != *" ${X} "* ]]; then
135 has ${X} ${linguas} || linguas="${linguas:+"${linguas} "}${X}"
136 continue 2
137 fi
138 done
139 fi
140 ewarn "Sorry, but ${PN} does not support the ${LANG} LINGUA"
141 done
142 }
143
144 pkg_setup() {
145 # Ensure we always build with C locale.
146 export LANG="C"
147 export LC_ALL="C"
148 export LC_MESSAGES="C"
149 export LC_CTYPE="C"
150
151 java-pkg-opt-2_pkg_setup
152 }
153
154 src_unpack() {
155 #xz -dc -- "${DISTDIR}/icecat-${MY_PV}.tar.xz" | tar xof - || die "failed to unpack"
156 unpack ${A} #${PATCH}.tar.bz2
157
158 linguas
159 for X in ${linguas}; do
160 # FIXME: Add support for unpacking xpis to portage
161 [[ ${X} != "en" ]] && xpi_unpack "${P}-${X}.xpi"
162 done
163 }
164
165 src_prepare() {
166 # Integrate rebranding
167 sed -i "s|/mozilla-firefox|/icecat|" \
168 "${WORKDIR}"/001-firefox_gentoo_install_dirs.patch
169
170 # Fix preferences location
171 sed -i 's|defaults/pref/|defaults/preferences/|' browser/installer/packages-static || die "sed failed"
172
173 # Apply our patches
174 EPATCH_SUFFIX="patch" \
175 EPATCH_FORCE="yes" \
176 EPATCH_EXCLUDE="137-bz460917_att350845_reload_new_plugins-gentoo-update.patch" \
177 epatch "${WORKDIR}"
178
179 # The patch excluded above failed, ported patch is applied below
180 epatch "${FILESDIR}/137-bz460917_reload_new_plugins-gentoo-update-3.6.4.patch"
181
182 # Enable tracemonkey for amd64 (bug #315997)
183 epatch "${FILESDIR}/801-enable-x86_64-tracemonkey.patch"
184
185 # Fix rebranding
186 sed -i 's|\$(DIST)/bin/firefox|\$(DIST)/bin/icecat|' browser/app/Makefile.in
187
188 eautoreconf
189
190 cd js/src
191 eautoreconf
192 }
193
194 src_configure() {
195 # We will build our own .mozconfig
196 rm "${S}"/.mozconfig
197
198 MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
199 MEXTENSIONS="default"
200
201 ####################################
202 #
203 # mozconfig, CFLAGS and CXXFLAGS setup
204 #
205 ####################################
206
207 mozconfig_init
208 mozconfig_config
209
210 # It doesn't compile on alpha without this LDFLAGS
211 use alpha && append-ldflags "-Wl,--no-relax"
212
213 # Specific settings for icecat
214 echo "export MOZ_PHOENIX=1" >> "${S}"/.mozconfig
215 echo "mk_add_options MOZ_PHOENIX=1" "${S}"/.mozconfig
216 mozconfig_annotate '' --with-branding=browser/branding/unofficial
217 mozconfig_annotate '' --disable-official-branding
218 mozconfig_annotate '' --with-user-appdir=.icecat
219
220 mozconfig_annotate '' --enable-extensions="${MEXTENSIONS}"
221 mozconfig_annotate '' --enable-application=browser
222 mozconfig_annotate '' --disable-mailnews
223 mozconfig_annotate 'broken' --disable-crashreporter
224 mozconfig_annotate '' --enable-image-encoder=all
225 mozconfig_annotate '' --enable-canvas
226 mozconfig_annotate 'gtk' --enable-default-toolkit=cairo-gtk2
227 # Bug 60668: Galeon doesn't build without oji enabled, so enable it
228 # regardless of java setting.
229 mozconfig_annotate '' --enable-oji --enable-mathml
230 mozconfig_annotate 'places' --enable-storage --enable-places
231 mozconfig_annotate '' --enable-safe-browsing
232
233 # Build mozdevelop permately
234 mozconfig_annotate '' --enable-jsd --enable-xpctools
235
236 # System-wide install specs
237 mozconfig_annotate '' --disable-installer
238 mozconfig_annotate '' --disable-updater
239 mozconfig_annotate '' --disable-strip
240 mozconfig_annotate '' --disable-install-strip
241
242 # Use system libraries
243 mozconfig_annotate '' --enable-system-cairo
244 mozconfig_annotate '' --enable-system-hunspell
245 mozconfig_annotate '' --with-system-nspr
246 mozconfig_annotate '' --with-system-nss
247 mozconfig_annotate '' --with-system-bz2
248 mozconfig_annotate '' --with-system-libxul
249 mozconfig_annotate '' --with-libxul-sdk=/usr/$(get_libdir)/xulrunner-devel-${MAJ_XUL_PV}
250
251 mozconfig_use_enable ipc # +ipc, upstream default
252 mozconfig_use_enable libnotify
253 mozconfig_use_enable java javaxpcom
254 mozconfig_use_enable wifi necko-wifi
255 mozconfig_use_enable alsa ogg
256 mozconfig_use_enable alsa wave
257 mozconfig_use_enable system-sqlite
258 mozconfig_use_enable cups printing
259
260 # Other browser-specific settings
261 mozconfig_annotate '' --with-default-mozilla-five-home=${MOZILLA_FIVE_HOME}
262
263 # Finalize and report settings
264 mozconfig_final
265
266 if [[ $(gcc-major-version) -lt 4 ]]; then
267 append-cxxflags -fno-stack-protector
268 fi
269
270 ####################################
271 #
272 # Configure and build
273 #
274 ####################################
275
276 CC="$(tc-getCC)" CXX="$(tc-getCXX)" LD="$(tc-getLD)" econf
277 }
278
279 src_compile() {
280 # Should the build use multiprocessing? Not enabled by default, as it tends to break
281 [ "${WANT_MP}" = "true" ] && jobs=${MAKEOPTS} || jobs="-j1"
282 emake ${jobs} || die
283 }
284
285 src_install() {
286 MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
287
288 emake DESTDIR="${D}" install || die "emake install failed"
289
290 linguas
291 for X in ${linguas}; do
292 [[ ${X} != "en" ]] && xpi_install "${WORKDIR}"/"${P}-${X}"
293 done
294
295 # Install icon and .desktop for menu entry
296 newicon "${S}"/browser/branding/unofficial/default48.png icecat-icon.png
297 newmenu "${FILESDIR}"/icon/icecat.desktop ${PN}-${DESKTOP_PV}.desktop
298
299 # Add StartupNotify=true bug 237317
300 if use startup-notification ; then
301 echo "StartupNotify=true" >> "${D}"/usr/share/applications/${PN}-${DESKTOP_PV}.desktop
302 fi
303
304 pax-mark m "${D}"/${MOZILLA_FIVE_HOME}/${PN}
305
306 # Enable very specific settings not inherited from xulrunner
307 cp "${FILESDIR}"/firefox-default-prefs.js \
308 "${D}/${MOZILLA_FIVE_HOME}/defaults/preferences/all-gentoo.js" || \
309 die "failed to cp icecat-default-prefs.js"
310 # Plugins dir
311 dosym ../nsbrowser/plugins "${MOZILLA_FIVE_HOME}"/plugins \
312 || die "failed to symlink"
313 }
314
315 pkg_postinst() {
316 ewarn "All the packages built against ${PN} won't compile,"
317 ewarn "any package that fails to build warrants a bug report."
318 elog
319
320 # Update mimedb for the new .desktop file
321 fdo-mime_desktop_database_update
322 }