summaryrefslogtreecommitdiff
path: root/libre/icedove-l10n/PKGBUILD
blob: 82491e20fce200169e736545d76aed47b973ab16 (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
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
# Maintainer: Andreas Grapentin <andreas@grapentin.org>
# Contributor: André Silva <emulatorman@hyperbola.info>
# Contributor: Márcio Silva <coadde@hyperbola.info>

_pkgbase=icedove
pkgbase=$_pkgbase-l10n
_calbase=iceowl

epoch=1
pkgver=52.7.0
pkgrel=1
# look here: https://developer.mozilla.org/en-US/docs/Mozilla/Calendar/Calendar_Versions
_calver=5.4.7

arch=('any')

pkgdesc="Language pack for ${_pkgbase^} and ${_calbase}."
url="http://packages.debian.org/sid/$_pkgbase"
license=('MPL' 'GPL')

depends=("$_pkgbase=$epoch:$pkgver")
makedepends=('unzip' 'zip' 'mozilla-searchplugins')

_languages=(
  'ar     "Arabic"'
  'ast    "Asturian"'
  'be     "Belarusian"'
  'bg     "Bulgarian"'
  'bn-BD  "Bengali (Bangladesh)"'
  'br     "Breton"'
  'ca     "Catalan"'
  'cs     "Czech"'
  'cy     "Welsh"'
  'da     "Danish"'
  'de     "German"'
  'dsb    "Lower Sorbian"'
  'el     "Greek"'
  'en-GB  "English (British)"'
  'en-US  "English (US)"'
  'es-AR  "Spanish (Argentina)"'
  'es-ES  "Spanish (Spain)"'
  'et     "Estonian"'
  'eu     "Basque"'
  'fi     "Finnish"'
  'fr     "French"'
  'fy-NL  "Frisian"'
  'ga-IE  "Irish"'
  'gd     "Gaelic (Scotland)"'
  'gl     "Galician"'
  'he     "Hebrew"'
  'hr     "Croatian"'
  'hsb    "Upper Sorbian"'
  'hu     "Hungarian"'
  'hy-AM  "Armenian"'
  'id     "Indonesian"'
  'is     "Icelandic"'
  'it     "Italian"'
  'ja     "Japanese"'
  'kab    "Kabyle"'
  'ko     "Korean"'
  'lt     "Lithuanian"'
  'nb-NO  "Norwegian (Bokmål)"'
  'nl     "Dutch"'
  'nn-NO  "Norwegian (Nynorsk)"'
  'pa-IN  "Punjabi (India)"'
  'pl     "Polish"'
  'pt-BR  "Portuguese (Brazilian)"'
  'pt-PT  "Portuguese (Portugal)"'
  'rm     "Romansh"'
  'ro     "Romanian"'
  'ru     "Russian"'
  'si     "Sinhala"'
  'sk     "Slovak"'
  'sl     "Slovenian"'
  'sq     "Albanian"'
  'sr     "Serbian"'
  'sv-SE  "Swedish"'
  'ta-LK  "Tamil (Sri Lanka)"'
  'tr     "Turkish"'
  'uk     "Ukrainian"'
  'vi     "Vietnamese"'
  'zh-CN  "Chinese (Simplified)"'
  'zh-TW  "Chinese (Traditional)"'
)

pkgname=()
source=('brand.dtd' 'brand.properties' 'region.properties')
_url=https://ftp.mozilla.org/pub/mozilla.org/thunderbird/releases/$pkgver/linux-i686/xpi
_calurl=https://ftp.mozilla.org/pub/calendar/lightning/candidates/$_calver-candidates/build1/linux-i686

for _lang in "${_languages[@]}"; do
  _locale=${_lang%% *}
  _pkgname=$pkgbase-${_locale,,}

  pkgname+=($_pkgname)
  source+=("$pkgbase-$pkgver-$_locale.xpi::$_url/$_locale.xpi"
           "$_calbase-l10n-$_calver-$_locale.xpi::$_calurl/lightning-$_calver.$_locale.linux-i686.xpi")
  eval "package_$_pkgname() {
    _package $_lang
  }"
done

# Don't extract anything
noextract=(${source[@]%%::*})

_package() {
  pkgdesc="$2 language pack for Icedove and Iceowl."
  replaces=(thunderbird-i18n-${1,,} $_pkgbase-l18n-${1,,})
  conflicts=(thunderbird-i18n-${1,,} $_pkgbase-l18n-${1,,})
  provides=(thunderbird-i18n-${1,,})

  mkdir $1

  unzip $_pkgbase-l10n-$pkgver-$1.xpi -d $1/$_pkgbase
  rm -v $_pkgbase-l10n-$pkgver-$1.xpi

  unzip $_calbase-l10n-$_calver-$1.xpi -d $1/$_calbase
  rm -v $_calbase-l10n-$_calver-$1.xpi

  install -vDm644 $srcdir/brand.dtd $1/$_pkgbase/chrome/$1/locale/$1/branding
  install -vDm644 $srcdir/brand.properties $1/$_pkgbase/chrome/$1/locale/$1/branding
  install -vDm644 $srcdir/region.properties $1/$_pkgbase/chrome/$1/locale/$1/messenger-region

  cp -R $1/$_calbase/chrome/calendar-$1 $1/$_pkgbase/chrome/
  cp -R $1/$_calbase/chrome/lightning-$1 $1/$_pkgbase/chrome/

  cat >> $1/$_pkgbase/chrome/de.manifest << EOF
locale calendar de calendar-de/locale/de/calendar/
locale lightning de lightning-de/locale/de/lightning/
EOF

  sed -i -e 's/thunderbird/icedove/' $1/$_pkgbase/install.rdf
  rm -rv $1/$_pkgbase/chrome/$1/locale/$1/global-platform/{mac,win}
  rm -rv $1/$_pkgbase/chrome/$1/locale/$1/messenger/searchplugins
  cp -av /usr/lib/mozilla/searchplugins $1/$_pkgbase/chrome/$1/locale/$1/messenger

  cd $1/$_pkgbase
  zip -r langpack-$1@$_pkgbase.mozilla.org.xpi .
  mv -v langpack-$1@$_pkgbase.mozilla.org.xpi $srcdir
  cd ../..
  rm -rv $1

  install -vDm644 langpack-$1@$_pkgbase.mozilla.org.xpi \
    "$pkgdir/usr/lib/$_pkgbase/extensions/langpack-$1@$_pkgbase.mozilla.org.xpi"
}

sha256sums=('49b419449431d8d64e20427a2e7105e3ac1ffc41e677a5f9a8eb276f5b82df4a'
            'acc2cf95661be7cb8928fca89e08d0681685409ff2428e4e3d25baf1af427b38'
            'e6edcc7c478d73ca5a17e4889acd302d55201ec5c29de545d3f44165201923db'
            '8212abdbe942452369dc290b00a98954d7a713c99b60d439b3b513216760fbcb'
            '31f374b8889fecd54e00d0682d9c4f26a1e2dbfee60d4f5d59326c9e60ebd23a'
            '3d49ddaf86b0a0d2909c4fa2fdb1c1a1a150a09e70600dad2b070b6f8a737f42'
            '7ff599945d9089578e70ba062e941090c23930a9c4704b4b3b6e1e812540b14b'
            '52814d6cdd5cebcd44b9df8225d9f185882e56983896f127427b66cfc0116a0a'
            'ea996d25c4b3f395df50c6b94ce289c833cab67bca6e282d467a16b5ff852b3b'
            '39b84ae64b41ae34135e166f32e11ccbc6e1c2fefb3bbde642735c16ce8f9daf'
            'a8fc005ecf149a7f1de54126ac01344e25b1f27db3b3a52792f16fce29afe83b'
            'cf2d10315603e84614052e68044e417513573c6002a2a2c3c37f651fdb52a035'
            'f8a8e652e12c735174651ac7ff4be940d265a734bcd40a7565183dc30fd8971f'
            '5416998b38b8b3b18b62048929de711ca2999f8e8a45ea242c69c2e68bb9cfbd'
            '9eeac9cf1660de3e3fbcf869fb9acc809b10036b36d95373dd59f58f3130002c'
            '87bb623143d2b1f4a2fafb5c7054ffbef7c85fa24f78c415a86f97b28b39e9f0'
            'ea23e118b39e18132db6ae36e6bb428c2ce4310feea6ed9e25e89c186b415718'
            'a2fef472427924f08a759d96bf3bb8986956ed395ee92f0a2f9ed7dee34bb6dd'
            'ecf9c6a9c2736993fcfb6828146306198de87bc9ac1067f3dfbd7602903f7cd1'
            'f34586b7f06c42712158c4766ef3484a6985b9024d51cd546b5b19f241b6ed6f'
            'dac702964fb2ba2d00c7ed32891b85936aa2e1019968e798f26c5c6664563536'
            'b2c6cb1b6668e6aabd2838b4e1db74618db70b8f682de9dfc1a803ffc3b71c5c'
            '1253d7b8f127bf6d99ff0551edcce4687492698f89467214e82507257ee160fb'
            '06b1ec1c4ace0211a51e60bcad7322299bec420d14516186dcfd9ece11548543'
            '1a5c036adcdd787997c95db66ea7e773c77f3b88142b615940b4fd27dd9050d1'
            '9827822895c0f228f9f253ea9434779dbc330d894c653d2821596ccf9bfa88a2'
            'bd766e7f684b660fe940a7ddd75533581864b22dccda300a03990d3bf77b77be'
            '6a02b6c79f8be2ad43a01bdfcd8430451ed3d5ad4e9c9f5012caa98800daf36f'
            'a97d7c9c1bbe5a3e58d8dd9e962db3d75e9163980c3483fdcca9595866122b2a'
            '595a5ef2e64984ece043d0d0d374e3d81a4f7201b632758687b9f03e1e23057c'
            'e0d5ee152e7b607b3d3ae6d029d457295fda2a1126ff93e00fa99b1a01898494'
            '3b55d2377d7790675e3b68eeb4d1338a1913ff22d375183806c2bfa054dfa540'
            'e74315642a35789e8e29e1f85c793f4af2b39cc68e09fd8bf4cda406b10ef0c6'
            '819be79a7473a0f3afd4825b26e3f5ba1dd6b745e7d4fb2fa6ec8bd10236e9aa'
            'b14ffd94b32a1b8370232f322e19b794ac5641672650139693f8ea7e83b82cf1'
            '47d591d366a50ae9f69221be2b1882546b9beaadf3962240b65e6910a9023dd8'
            '42a664b433ea714f5adeef6a497f99b6066f83e0474b130228872ae980e00b03'
            '1afff1eed8ebee534f87f21d675e1d3d76875f1a2bd1c1d8504c2e43e14b1dab'
            'b3bba076a0524b1693aeb7b21d0183d898bffaca3fe232472910fea8fd669c88'
            '0891d434e1ba57a71d0dbfd5a0f54c7bbbf0bbc5b5725671e3243aa9d836fd2c'
            '6ee9034933d0d75a38a56d755b18309666fac341a52eec07e0fecc9c2b298d76'
            '8f63092de10863ee4bf4c66f88e33842c987ad244d73bb2377e386730652f08d'
            'eb5d1042756cb1d6715cc9109057a0b90261a3d48111361619403a8a886ce1d4'
            '0d71ac2f70c3f4d117e8ed41f5c4a82e333bdfa58783e829dae179a901a24093'
            'a268aec9bd81d4c66bb47482404c9be015ceb357e7d8501a15e8728b293138c2'
            '3a7de09335a80a7a846b413479b3ee069a1d74ade1c054e71fa4f4e8261e88d9'
            '94b087f70a1fddc272570175d4e908e9e14ab54f55d09a14cb12db7a312af495'
            '017e9ee7d930637f7f72633b4eeeb8cde9f44fd47cbf4564704ef8d4e6b96616'
            '80103fef0f0c7fd88efb7cca379b463ce963f377398906ed80dba5eb88c6cfaf'
            '314d22069e8f7e5d9dc18a35e8cd8baf4bd80280f4e22e5bb7b4c5c96e482860'
            '917322bc3084d0011ff02adce65a182b3511b0f88ad1bd1138e90b7e7e934a96'
            '16af3293f6b01a80e31525d33c65113b445f53ae0ccd318597cc1ce686bf0cc9'
            'dfa84a32902fe87ae9d6e3aad25a11c81f028dc9ca0abfe1a5ea7432f1563463'
            '143ddad4eaa4eab357eae17b31c86ab0fb33f5f5e112b90e144bd66249f09ec3'
            'f6697b88a5cd066c641d8c3595c384e278b031c55a3b405a2845c80049adf474'
            '8c85aaf66eaaf806229b090665e2d3389dae2f44b96e128605bcec269460ff73'
            '1c85109134727a9bbf1c1906ea0ca215e621cb807e2d72bd1a82a1662d93651b'
            'c14a32839dba703bddaeca917a1b9abaaa254ef1a254aee75fca08bb08de7c76'
            'd8bed392420bca19bb8af1394bbb317810257ac2b05272ed380d4000b679c894'
            '2bdbcb919a81a905a5d29022eceb8f8b4091e1f938a666d5ea757023a27e9b68'
            '6f3ad891c87fc432f4cdb8625591f53de601e03a492b57c624c92423c82e2ba3'
            '01942aacb942e1fe95c119aa6904ec67ea7c2b5e7c3bb41e5678dc558bf8e4c7'
            '820c2529b2c35357621b8648c6e7a50f6d9f09b1996206a938685dd385bf84d1'
            '94bd63d09400796e7001fc9a2e7930a29d0f8e338dc3a79a23368b3daa5827fb'
            '820a90999f45399c9961515ebf0b05471790334d239b250ee95e706fc0647417'
            '8ea8d3f3d7e4dac11688a2215bb512fa0e0adecdea31c391235a36d16ed2b204'
            '89b3c6bce162070d294719d44e8e7dedff57fe4f2d8eb9a2192aa9cc93d14754'
            '6458c381a598cc97513c1b7b83ea2d7092b4b7b729d939d6ba1c51b91a4e1c8b'
            '855a3633945724deb24f31562ab781ad902f12ed8f568206c49425c0d79d4d5d'
            '96feb42e3ae1646d64ad74b2de7952e73a05a4302b7dde5841a32c43be859255'
            '45a95d6d3b27981d9c37533dce544233f64a01ff3173702202aaa7220cf78e73'
            'dea8e31429a2eddb7c40ff1eb6252034285af11dc2bd3f0c9637a494ffd2be36'
            '6ae0c0de858e7782f39db64c081ec2b8828e25ccf6165db348ec3651ae078621'
            '341e891e3aa85199a4da33a716d0d70fde05fba87c7ca165722f7b95f7172a67'
            'b05ba89840bde79fd5746bf9d4ccf43ffd0c2a37d8f218f615cd1976dab3c569'
            '7d2fe137ef7b18056a399a6768f93b9e35d543da8c1b07151d4b34f08bb287af'
            '186598d8f6c1d80190be994968826a6ed6ea722201ece176a26aa33b0e70eccc'
            'bd7df863f1695ac09ababad15f681ecd099d6bf7e33115adfea1be41b53e7f7c'
            '119028236d54c855c06725dd44cd8ab8b7b813eac17dad355f23df2fb12cf5c5'
            '15c4a0bbf3fa30fa970a3870bd1e580b39bcdf217d74723ee4252b57a94be78b'
            '8a34a798c12e0763305e02ee04ca81f961a657380a5ddcc203351533fa27898a'
            '1d70ee7b991f5ab73e5aa627d8f19f93e8771a85da27abda1dc40c98a513a5da'
            '433fc120232c1a525fb38e0b2eb86f819088e3896edf365683a993ddad4fd02e'
            '0becb534e4577903b84aa2fe2ce5d59ae0fc2e7daa9bcbcddf697211b5dae43e'
            'f2578d03157b677188e98a24f074072f798d6603d5a35eb88ded20fd51275d5f'
            'c59eb5cae2f997a886ae0c78ade2178f92d49dfde5ec00949e409fe7eaa04025'
            'b76809c3a74fb4d5b6f488a1ff0e8bef2aff8a0185f61ce37d999c22fcb52ba6'
            'c8948e2776e85e9e3b56e9cf05f5cc7c5f75d325950939f5f542a3d7d4a4a638'
            'c38d4842234b10d9a396fe1bca5287ab8b7f8a0e3729f2c7caed9148b9f62a69'
            '1111fef71a87b7a1921201046cf186909b2fbf7f52f55f6837a2dac510a9b9e8'
            'e56a328815a782eb4ad35502e01ef28795bd2d045769b2083ca40fae6b4104c3'
            'fd0367417943f820620980c832a9b94613020ba9382f1f1b7137daf9e003463b'
            '1c6f7b21e32d80dddad4b9718a55c4f68f9efac7782e2454fece04b26f1436d7'
            '5528eb38e8da8f83264b4387a9b5c9a7444ebb5bda9db7911c4ceeb5febcdba2'
            'fe3930c258090cdf4f2a25986f87f7c7a42b64b6bcc441efe800756c720e0d02'
            '3a6a8680abfa01f696c4dcb25fd88a14b889c6b03866d185909b72d462b901d7'
            '49377b69d53c5742271400552a9d19fe7d8e5a8e5fd79f1b615131f7b0c071a5'
            '815c60141b335c1ecc497668343aa4fb77d378eac475bebddaef4ba4cbf552bb'
            '0026444693f445fdd23b9382de0579bc11330bfd7672efe55ca6ed2eee92b51d'
            'c75343dcc57b2eb13c7affed446d2b59d31ed8f677995479fa37af13615f40f4'
            'c4cc95f7b4854a72df0059df47b8bdab68cf0c095f822f50572c6f1705779de2'
            '591aafe3714e5a0253b9210a054452b0a92a4202029d4016e0e593a54212e3aa'
            '2e54da03eda6df516febd11e5f512c59ac0e2655f4ad268f7aa72981a1648903'
            '7c1f9e88265233d1f39eb2ed79695c3bbeb1b1a7acab02634c0f9eab5e1280a2'
            'bcf8d615d0d6da131370698153040290143046b2b94d736c09529ef3c330990a'
            'f0fa84335f0d15c972aff835a0a887e0a6816eeb14f0a096ccc987d1baf43bbc'
            '5cd3e4eddfb47e2ccdd1a7b48a2235141b73bfea0c04e9223c9a0a0fc783ea89'
            'd41d6e198cc298ed35ee76d98f305b60614069ba8774096f83fefe38cab8ae3b'
            '1e571ebd6843acc1e690e62d04f5c2b411f73d0e3357e6303a89f50fcb6cc042'
            '4fde53c46c3108ecdc077d4908e4c67ee1d2074e1dc793897925f4a218027069'
            'de7525d3344fc701107f7ff84c487c389aa13576120c7d8bf166024eda42e699'
            'ca485aff2aafd544d819ab494119286a70954fead827d86d4158cfd4b493022e'
            'b8d154248b8489ed86a756fbeb9c3214d33160f1e0d477b15fff6cd4dc9da7d6'
            'c6d1de503332abe0129b1bee3fe129f20ffc6f3870058d54d2627fdf420332ad'
            '254a1145d9447257eccc2a8417503edecdfb9ca69a4b9fd50ca0599492ebabe8'
            'b97c479f0e52e8429ad0f3c9195ca3005e01a9a32b1ef6c4fae6efa4e81710eb'
            '8eff1ffd571b4cd5d213bafeddd343007d81c372f31765116c098993d4396a37'
            'c551cc18219c4cf979be3e32adb3dc34b3cfebd036fdde7a1148041d47418533'
            'b2ac08c5c6816e0a3693e397898b68be3191a945b7a124bd08948a1bfe38e6ab'
            '3eda9dd7b4814d142b2a1f74e0c3f9b90321fd8f6b620df83c25c780ae17e780'
            '7bab6788060f9b509d827450e955351f1fff2bc8907fe060413b219318dcdff0')