summaryrefslogtreecommitdiff
path: root/libre/iceweasel-l10n/PKGBUILD
blob: 07a3ff94c0c8b4c69d3826a63482452f08f9526d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
# Maintainer: André Silva <emulatorman@parabola.nu>
# Maintainer: Márcio Silva <coadde@lavabit.com>
# Contributor: Luke Shumaker <lukeshu@sbcglobal.net>
# Contributor: fauno <fauno@kiwwwi.com.ar>
# Contributor: Figue <ffigue@gmail.com>
# Based on icecat-i18n package, which is in turn based on firefox-i18n

# When updating to a newer upstream release:
# - Edit variables in in Makefile.
# - (optionally) edit PKGBUILD.in
# - Run 'make'. It will take care of everything else for you.

_debname=iceweasel
_debver=27.0
_debrel=deb1
_debrepo=http://ftp.debian.org/debian/pool/main/
debfile() { echo $@|sed -r 's@(.).*@\1/&/&@'; }

_langpacks=(ach af an ar as ast be bg bn-BD br bs ca cs csb cy da de el en-GB en-ZA eo es-AR es-CL es-ES es-MX et eu fa ff fi fr fy-NL ga-IE gd gl gu-IN he hi-IN hr hu hy-AM id is it ja kk km kn ko lij lt lv mai mk ml mr nb-NO nl nn-NO or pa-IN pl pt-BR pt-PT rm ro ru si sk sl sq sr sv-SE ta te th tr uk vi xh zh-CN zh-TW)

pkgbase=iceweasel-l10n
pkgname=($(for lang in ${_langpacks[@]}
        do echo $pkgbase-$lang | tr A-Z a-z
        done))
epoch=1
pkgver=$_debver.$_debrel
pkgrel=2

pkgdesc="Language packs for Debian Iceweasel."
arch=('any')
url="http://packages.debian.org/experimental/iceweasel"
license=('MPL' 'GPL')
depends=("iceweasel-libre>=$epoch:$pkgver")
makedepends=('unzip' 'zip')
source=('brand.dtd' 'brand.properties' 'region.properties')
for lang in ${_langpacks[@]}
do
    source+=("${_debrepo}/`debfile ${_debname}`-l10n-$(echo $lang | tr A-Z a-z)_${_debver}-${_debrel#deb}_all.deb")
done

_path="/usr/lib/iceweasel/browser/extensions/"

build() {
  cd "${srcdir}"
  for f in *.deb
  do
      bsdtar xf $f
      bsdtar xf data.tar.xz
  done

  cd $srcdir/$_path

  for i in ${_langpacks[@]}
  do
    cd $srcdir/$_path
    unzip -q langpack-$i@iceweasel.mozilla.org.xpi -d $i
    rm langpack-$i@iceweasel.mozilla.org.xpi
    install -Dm644 $srcdir/brand.dtd $i/browser/chrome/$i/locale/branding
    install -Dm644 $srcdir/brand.properties $i/browser/chrome/$i/locale/branding
    install -Dm644 $srcdir/region.properties $i/browser/chrome/$i/locale/browser-region
    cd $i
    zip -q -r $srcdir/$_path/langpack-$i@iceweasel.mozilla.org.xpi .
  done

  cd $srcdir
}

for lang in ${_langpacks[@]}
do
    eval "
package_iceweasel-l10n-$(echo $lang | tr A-Z a-z)() {
  replaces=(firefox-i18n-$(echo $lang | tr A-Z a-z) iceweasel-i18n-$(echo $lang | tr A-Z a-z) iceweasel-libre-l10n-$(echo $lang | tr A-Z a-z))
  conflicts=(firefox-i18n-$(echo $lang | tr A-Z a-z) iceweasel-i18n-$(echo $lang | tr A-Z a-z) iceweasel-libre-l10n-$(echo $lang | tr A-Z a-z))
  provides=(firefox-i18n-$(echo $lang | tr A-Z a-z) iceweasel-i18n-$(echo $lang | tr A-Z a-z) iceweasel-libre-l10n-$(echo $lang | tr A-Z a-z))
  install -Dm644 \"\$srcdir$_path/langpack-$lang@iceweasel.mozilla.org.xpi\" \"\$pkgdir$_path/langpack-$lang@iceweasel.mozilla.org.xpi\"
}
"
done

md5sums=('41882dabdc0315962f18d78ee97d5be5'
         '87640dacdbba301feaf1fb30bfa60137'
         'a4593936bf1c7a9ec9368ff249f9cc56'
         'e93e1d1c6c19506280909c9c44381b31'
         'fd6a3c94db2ec15724e0282ad8bbb88b'
         '5f487d08c63467bce76500d476c2e720'
         'b7432c77be0c5140c287e30472e7558c'
         '140b8d771db5186617e900e94ca81e8e'
         'cdc18a87637fc75cd74d1488e9e8014a'
         '7ee9df5caa96cc3496476a8a6b3da382'
         'a5c9f178c37cb613ba02a04e9a5a14a5'
         'c0d36f5bb3db675aa103ebaa6989b3db'
         'd403801bf45498022fb326163325353d'
         'c720ad3bebddfb235bc115bd54df7e53'
         'b6dc0cd09ea300054b7b67ee3e57e426'
         '7fb5774ef19301f09dd7cd2da40b9abb'
         '7705c17405a8fb2200f2eb0f35e5874c'
         '49ae75599defd90f8e78553b66b2d41f'
         '31ee848294ced1516c5652d60604f797'
         'f5123e7c55b69090b1383a8f1d457516'
         '8aac6a53fe7a8f580fc6e3915a1cb867'
         'd4e4e1f7acfe5752b7d9d2b0af966373'
         '3553b70e38157a9367b64d5b9b5c22ce'
         'f3df39d6e307eb1e4f120532a090cd34'
         '3a624c988e1accbd788d864806a552b8'
         'a1385f224c6a01efa08a7536c70e65ae'
         'a7a4987f1fc7a403d5bf950ffcab97ca'
         'c6d5bdd7eefe7e8f971c7f9e21c71cd8'
         '75b2044c67f19c4bb5ce7441603a090d'
         'd5b282183ae094e9cb2930b9d06a2945'
         'e2f680acba50a509f4944d64f0e8b12a'
         '062437e3d5fec69444cf129a69d55800'
         '20e5290717405966bc458c331749457c'
         '68d8e0e0e372f18a6d607df1734bc6b9'
         '096a58d2a00d2cd8cace2d63fa0454ae'
         '7b9e564ced4e5fe060ca85885ae0d441'
         '8e3fc652f5abf4c534d67e819ec996f2'
         'e20ac9d23378ada9f3f3a92e60b2ee93'
         '1c021d9b8acd5fe515b00323e0738ea9'
         '92525a283b5d4742601d8878d8d7bef2'
         '02b2b40f53e0a41e3d1dbf63049ed32d'
         'e4f84a508bce58208846a94b48c1e892'
         '91f73ccc80415f72ae01e095ad062145'
         '5cc74c624f9f27066ca90641d159e632'
         '007ec8847575f4cf81d6a597c8be6d5d'
         '79962353f3fd65b4db090a547391c7d6'
         '4d6b7cde50343d39747f7cfefe7779ff'
         'b3ab5bbaa080770d34a56e16b8f37e7d'
         '1bea7cdc4df0526043041dfcfcbc0a27'
         '40f1faaa2990445ab1d3695e098b5e84'
         'c7c70615a8ca50157659f0003102c1c8'
         '392633fe2681a7cc007e895632e880d7'
         'a51f8c7f674ce2b989e7961dc9b4178b'
         'a036c9497d2a098929367ef29829c355'
         '89a9ec509e38fefaaf93d6d20f7de24e'
         '87eedd063b0670a83ea0801477eb6432'
         '3ac80ae65e573e7af571ad324fc89ec3'
         'f52387d2feda45b58fb7fdabe2e1d3c0'
         'ad14ebdfa234cfc72c47d55dd4705e11'
         '1ae5033d60a54eacea3b54ed3aac2215'
         '5c73173dffe662529fc2953babfdf42e'
         '901f0c97282dbe5a4bbb2130b2a6147e'
         'c951c259bc0b44579e3575ab988a13db'
         '930a0a30ce2ef304a69c5adefb0d4046'
         'c9ab698b523f0bec97462f6a948b1bd1'
         '29cef68ad4ec2380ab4e731cb6d7aa55'
         '878e8a2e9010e7f2f8285d7fe159c324'
         '1fe1bdd0eab73b7380a72a7f803bf6a5'
         '4fcbc7d321a5d233593a78150dd18f1e'
         '706ba0aa5f27e3a7eb327e91d38d2419'
         'c3a828894acd6961f5f324a141ee37c3'
         '8d1ccee2e1ebb515d6a20e5192168499'
         '6fdcc7c1a624608e284000ad3526aaa8'
         '39c18edb12a04849fd5bed795ac1559f'
         'b25714bb9a8686ab83291812f5922a72'
         '0484bb8a9750e5bd99f332412d2473cc'
         '777fc3c6dfa24138d95c41d1ce1d14b9'
         'd47833bbe4ba37c24c1c6d796e829581'
         '8bed0e985e274d47bfc321165df07416'
         '34382f666d44025751e4f6d7bfc84532'
         '57248a792eaeb5ca5def21bbb3e45fcf'
         'a69d513999f3f50b8dcc1101354c99c4'
         '47ba44a2df13e49cc4a07f3529e35497'
         'bde19859f08ff1051b823ae78265a2e7'
         '1412ee3cf88155a42a5b534c96b02f97')