Magellan Linux

Contents of /branches/R11-stable/include/mozilla_i18n.sminc

Parent Directory Parent Directory | Revision Log Revision Log


Revision 17894 - (show annotations) (download)
Wed Jun 26 12:59:01 2013 UTC (10 years, 10 months ago) by niro
File size: 1238 byte(s)
-revert last changes
1 # $Id$
2 # functions for mozilla i18n
3 #
4 # MOZ_SUITE, MOZ_LANG, STATE, PVER and PBUILD must be given
5 #
6
7 MOZ_HOME="/usr/$(mlibdir)/${MOZ_SUITE}"
8 PNAME="${MOZ_SUITE}-lang-${MOZ_LANG}"
9
10 PCAT="app-lang"
11 case ${MOZ_SUITE} in
12 firefox) DEP_PCAT="net-www" ;;
13 thunderbird) DEP_PCAT="net-mail" ;;
14 esac
15
16 DESCRIPTION="Mozilla ${MOZ_SUITE} ${PVER} - ${MOZ_LANG} language files."
17 HOMEPAGE="http://www.mozilla.org/products/${MOZ_SUITE}/"
18
19 DEPEND="== ${DEP_PCAT}/${MOZ_SUITE}-${PVER}"
20
21 SDEPEND=">= app-arch/unzip-5
22 >= virtual/sed"
23
24 SRCFILE="${MOZ_LANG}.xpi"
25 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
26
27 sminclude mtools
28
29 SRC_URI=(
30 ftp://ftp.mozilla.org/pub/mozilla.org/${MOZ_SUITE}/releases/${PVER}/linux-i686/xpi/${SRCFILE}
31 mirror://${PNAME/-${MOZ_LANG}/}/${PVER}/${SRCFILE}
32 )
33
34 mozilla_i18n_src_prepare()
35 {
36 install -d ${SRCDIR}
37 munpack ${SRCFILE} ${SRCDIR} || die
38 }
39
40 mozilla_i18n_src_install()
41 {
42 cd ${SRCDIR}
43
44 # get install id for the extension
45 local id="$(sed -n -e '/install-manifest/,$ { /em:id/!d; s/.*[\">]\([^\"<>]*\)[\"<].*/\1/; p; q }' install.rdf)"
46
47 # needed directories
48 minstalldir ${MOZ_HOME}/extensions/${id} || die
49 cp -Rv ${SRCDIR}/* ${BINDIR}/${MOZ_HOME}/extensions/${id} || die
50 }
51
52 export_inherits mozilla_i18n src_prepare src_install