Lines 4-10
Link Here
|
4 |
|
4 |
|
5 |
WANT_AUTOCONF="2.1" |
5 |
WANT_AUTOCONF="2.1" |
6 |
|
6 |
|
7 |
inherit flag-o-matic toolchain-funcs eutils mozconfig-2 mozilla-launcher makeedit multilib fdo-mime mozextension autotools |
7 |
inherit flag-o-matic toolchain-funcs eutils mozconfig-2 mozilla-launcher makeedit multilib fdo-mime autotools |
8 |
|
8 |
|
9 |
PATCH="${PN}-2.0.0.4-patches-0.2" |
9 |
PATCH="${PN}-2.0.0.4-patches-0.2" |
10 |
LANGS="af ar be bg ca cs da de el en-GB es-AR es-ES eu fi fr fy-NL ga-IE gu-IN he hu it ja ka ko ku lt mk mn nb-NO nl nn-NO pa-IN pl pt-BR pt-PT ro ru sk sl sv-SE tr zh-CN zh-TW" |
10 |
LANGS="af ar be bg ca cs da de el en-GB es-AR es-ES eu fi fr fy-NL ga-IE gu-IN he hu it ja ka ko ku lt mk mn nb-NO nl nn-NO pa-IN pl pt-BR pt-PT ro ru sk sl sv-SE tr zh-CN zh-TW" |
Lines 20-44
Link Here
|
20 |
|
20 |
|
21 |
MOZ_URI="http://releases.mozilla.org/pub/mozilla.org/firefox/releases/${PV}" |
21 |
MOZ_URI="http://releases.mozilla.org/pub/mozilla.org/firefox/releases/${PV}" |
22 |
SRC_URI="${MOZ_URI}/source/firefox-${PV}-source.tar.bz2 |
22 |
SRC_URI="${MOZ_URI}/source/firefox-${PV}-source.tar.bz2 |
|
|
23 |
mirror://gentoo/firefox-${PV}-l10n.tar.bz2 |
23 |
mirror://gentoo/${PATCH}.tar.bz2" |
24 |
mirror://gentoo/${PATCH}.tar.bz2" |
24 |
|
25 |
|
25 |
# These are in |
|
|
26 |
# |
27 |
# http://releases.mozilla.org/pub/mozilla.org/firefox/releases/${PV}/linux-i686/xpi/ |
28 |
# |
29 |
# for i in $LANGS $SHORTLANGS; do wget $i.xpi -O ${P}-$i.xpi; done |
30 |
for X in ${LANGS} ; do |
31 |
SRC_URI="${SRC_URI} |
32 |
linguas_${X/-/_}? ( http://dev.gentooexperimental.org/~armin76/dist/${P}-xpi/${P}-${X}.xpi )" |
33 |
IUSE="${IUSE} linguas_${X/-/_}" |
34 |
# english is handled internally |
35 |
if [ "${#X}" == 5 ] && ! has ${X} ${NOSHORTLANGS}; then |
36 |
SRC_URI="${SRC_URI} |
37 |
linguas_${X%%-*}? ( http://dev.gentooexperimental.org/~armin76/dist/${P}-xpi/${P}-${X}.xpi )" |
38 |
IUSE="${IUSE} linguas_${X%%-*}" |
39 |
fi |
40 |
done |
41 |
|
42 |
RDEPEND="java? ( virtual/jre ) |
26 |
RDEPEND="java? ( virtual/jre ) |
43 |
>=www-client/mozilla-launcher-1.39 |
27 |
>=www-client/mozilla-launcher-1.39 |
44 |
>=sys-devel/binutils-2.16.1 |
28 |
>=sys-devel/binutils-2.16.1 |
Lines 100-114
Link Here
|
100 |
} |
84 |
} |
101 |
|
85 |
|
102 |
src_unpack() { |
86 |
src_unpack() { |
103 |
unpack firefox-${PV}-source.tar.bz2 ${PATCH}.tar.bz2 |
87 |
unpack firefox-${PV}-{source,l10n}.tar.bz2 ${PATCH}.tar.bz2 |
104 |
|
|
|
105 |
linguas |
106 |
for X in ${linguas}; do |
107 |
[[ ${X} != "en" ]] && xpi_unpack "${P}-${X}.xpi" |
108 |
done |
109 |
if [[ ${linguas} != "" ]]; then |
110 |
einfo "Selected language packs (first will be default): ${linguas}" |
111 |
fi |
112 |
|
88 |
|
113 |
# Apply our patches |
89 |
# Apply our patches |
114 |
cd "${S}" || die "cd failed" |
90 |
cd "${S}" || die "cd failed" |
Lines 129-134
Link Here
|
129 |
mozconfig_init |
105 |
mozconfig_init |
130 |
mozconfig_config |
106 |
mozconfig_config |
131 |
|
107 |
|
|
|
108 |
# Can this be replaced with [ -f ${WORKDIR}/l10n/${LINGUAS} ] ? |
109 |
# seems redundant to keep a copy of the linguas in the ebuild |
110 |
linguas |
111 |
local LANG=${linguas%% *} |
112 |
elog "Setting default locale to ${LANG}" |
113 |
mozconfig_annotate '' --enable-ui-locale=${LANG} |
132 |
mozconfig_annotate '' --enable-application=browser |
114 |
mozconfig_annotate '' --enable-application=browser |
133 |
mozconfig_annotate '' --enable-image-encoder=all |
115 |
mozconfig_annotate '' --enable-image-encoder=all |
134 |
mozconfig_annotate '' --enable-canvas |
116 |
mozconfig_annotate '' --enable-canvas |
Lines 213-232
Link Here
|
213 |
dodir "${MOZILLA_FIVE_HOME}" |
195 |
dodir "${MOZILLA_FIVE_HOME}" |
214 |
cp -RL "${S}"/dist/bin/* "${D}"/"${MOZILLA_FIVE_HOME}"/ || die "cp failed" |
196 |
cp -RL "${S}"/dist/bin/* "${D}"/"${MOZILLA_FIVE_HOME}"/ || die "cp failed" |
215 |
|
197 |
|
216 |
linguas |
|
|
217 |
for X in ${linguas}; do |
218 |
[[ ${X} != "en" ]] && xpi_install "${WORKDIR}"/"${P}-${X}" |
219 |
done |
220 |
|
221 |
local LANG=${linguas%% *} |
222 |
if [[ -n ${LANG} && ${LANG} != "en" ]]; then |
223 |
elog "Setting default locale to ${LANG}" |
224 |
dosed -e "s:general.useragent.locale\", \"en-US\":general.useragent.locale\", \"${LANG}\":" \ |
225 |
"${MOZILLA_FIVE_HOME}"/defaults/pref/firefox.js \ |
226 |
"${MOZILLA_FIVE_HOME}"/defaults/pref/firefox-l10n.js || \ |
227 |
die "sed failed to change locale" |
228 |
fi |
229 |
|
230 |
# Create /usr/bin/firefox |
198 |
# Create /usr/bin/firefox |
231 |
install_mozilla_launcher_stub firefox "${MOZILLA_FIVE_HOME}" |
199 |
install_mozilla_launcher_stub firefox "${MOZILLA_FIVE_HOME}" |
232 |
|
200 |
|