1 |
# $Header: /magellan-cvs/smage/include/mozilla_i18n.sminc,v 1.7 2007-11-05 18:43:32 niro Exp $ |
# $Id$ |
2 |
# functions for mozilla i18n |
# functions for mozilla i18n |
3 |
# |
# |
4 |
# MOZ_SUITE, MOZ_LANG, STATE, PVER and PBUILD must be given |
# MOZ_SUITE, MOZ_LANG, STATE, PVER and PBUILD must be given |
8 |
PNAME="mozilla-${MOZ_SUITE}-i18n-${MOZ_LANG}" |
PNAME="mozilla-${MOZ_SUITE}-i18n-${MOZ_LANG}" |
9 |
|
|
10 |
case ${MOZ_SUITE} in |
case ${MOZ_SUITE} in |
11 |
firefox) PCATEGORIE="net-www" ;; |
firefox) PCAT="net-www" ;; |
12 |
thunderbird) PCATEGORIE="net-mail" ;; |
thunderbird) PCAT="net-mail" ;; |
13 |
esac |
esac |
14 |
|
|
15 |
DESCRIPTION="Mozilla ${MOZ_SUITE} ${PVER} - ${MOZ_LANG} language files." |
DESCRIPTION="Mozilla ${MOZ_SUITE} ${PVER} - ${MOZ_LANG} language files." |
16 |
HOMEPAGE="http://www.mozilla.org/products/${MOZ_SUITE}/" |
HOMEPAGE="http://www.mozilla.org/products/${MOZ_SUITE}/" |
17 |
|
|
18 |
DEPEND="== ${PCATEGORIE}/mozilla-${MOZ_SUITE}-${PVER}" |
DEPEND="== ${PCAT}/mozilla-${MOZ_SUITE}-${PVER}" |
19 |
|
|
20 |
SDEPEND=">= app-arch/unzip-5 |
SDEPEND=">= app-arch/unzip-5 |
21 |
>= sys-apps/sed-4" |
>= sys-apps/sed-4" |
34 |
{ |
{ |
35 |
install -d ${SRCDIR} |
install -d ${SRCDIR} |
36 |
munpack ${SRCFILE} ${SRCDIR} || die |
munpack ${SRCFILE} ${SRCDIR} || die |
|
cd ${SRCDIR} |
|
|
|
|
|
# fix location in manifest file |
|
|
sed -i "s|jar:chrome/${MOZ_LANG}.jar|jar:${MOZ_LANG}.jar|" chrome.manifest || die |
|
37 |
} |
} |
38 |
|
|
39 |
mozilla_i18n_src_install() |
mozilla_i18n_src_install() |
40 |
{ |
{ |
41 |
cd ${SRCDIR} |
cd ${SRCDIR} |
42 |
|
|
43 |
# needed directories |
# get install id for the extension |
44 |
minstalldir ${MOZ_HOME}/chrome || die |
local id="$(sed -n -e '/install-manifest/,$ { /em:id/!d; s/.*[\">]\([^\"<>]*\)[\"<].*/\1/; p; q }' install.rdf)" |
45 |
|
|
46 |
minstallfile chrome/${MOZ_LANG}.jar ${MOZ_HOME}/chrome/ || die |
# needed directories |
47 |
minstallfile chrome.manifest ${MOZ_HOME}/chrome/${MOZ_LANG}.manifest || die |
minstalldir ${MOZ_HOME}/extensions/${id} || die |
48 |
|
cp -Rv ${SRCDIR}/* ${BINDIR}/${MOZ_HOME}/extensions/${id} || die |
49 |
} |
} |
50 |
|
|
51 |
export_inherits mozilla_i18n src_prepare src_install |
export_inherits mozilla_i18n src_prepare src_install |