summaryrefslogtreecommitdiff
path: root/libre/icedove-l10n/PKGBUILD
blob: 0638b1e867fc087470d9ed2e132b0b9c15b0ad55 (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@riseup.net>
# Contributor: Márcio Silva <coadde@riseup.net>

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

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

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')
_pkgurl=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::$_pkgurl/$_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'
            'a96dbaed8c14e113c2e2295422c4346ed97cbba349f6464532d4585ab6a5be88'
            'b6b22878c66f4e242b7132626edbf8c546c45d6e8fe16201b3d4a1481926eb18'
            'eb2614092cebafb0d326ac318bbd76d5e35a6865fe4f0be72bad871bc703584f'
            '9a266ea1308e8c269c7c34b1fcbffcffe48ae5cbafced7e796421b3027bd4329'
            'b412a5cb7f2752d1d72325356b9d0fa124af03f29e45ceeafe3b0b9fc0c7e28b'
            '7404e86d45a9b5ca60216c2ae87e18e9c4151febf278a67e49b4b6baa1e172c4'
            'ff093e353378ae63727aca8b95578d89d369c6b86e48a030d893a9cd8ad77922'
            '7462b0f3f68047f0274ebffbcd23be71ebff30b8a95ada6a021a89a2af71bb14'
            'eaebfde95c33aafa0c7aa649fca093a25ed93db58e8fed3485589b9326806270'
            '2de843b8523f6b47d85fcf70f6a50fa1c7c2af5e7e30cc37c05ff4abe5ad63b5'
            '87819d6762d57ce02564ec3cdb195158eed635ba27a3165dfc862553f53f188a'
            'a614aeab8710dde46de8810d5509a1e92309f8e7a46737da75706e5cb9f4146b'
            '9dffc936fd1dda855d19eb464ce01b22bfb667585b983b3c7b0a74ea10e298ce'
            'b6dcd1ba34ee49f843b277f0ab814862cce1026bea1d278fd932b60cdb5ca010'
            'eb0412f1fcf7a7c96e434d114d5763c56322317633bb8790dfa3362df03be870'
            'df0cebcaf1a41d192ae882ef529134e75d1ce7c59cef4a460a233f28775dd562'
            '1a000f677941f4c28186d4e58bf6df79f4d8a47e2a7a338005bad91604e8c388'
            'bd85ab8bd0625bace4e24be9e77a26ebfb4b9bfba8156f1020d3d92544c6cf23'
            '583fd8b1d6034739477cc5d935a766242b7d1e4bdb869545645f893d4d80cd70'
            '4d2b96e8f947f4c7caa7cd0c3e02e6051e397018c94c8ddaeec3336f003a6d03'
            '48cf4ae0856b286f4f5788abcfec66b8817dbd836102236907e826cb2ed555b3'
            'f2b0b3db267ca9412c83fe25295b67acbbcdea43943bca34656684e93d991e17'
            '7e4333f45af142b59c401b303cd4111bd5e92a4f3a4aaf0a9287a224283087b3'
            '80ff21270e1889f92b7561f3919962802f81ead8c59301feffdd5345aa509b26'
            '554a62ec5d5ae4cca3d093273b8df7357b649f0b853a05714a7990667d1e8e7c'
            'ee49224f5fe146d71c23481abe5757a266eef16d2fc39962a8eea31ae10c4c20'
            '2cf73f099a49cba6301ac60da05e6bafa495e9363d6c0bf84caecc1a928bde8e'
            '0537474934d2aa63c0c4f83d59c680f94bcbcb12573216d2f6e115b26b4de6d3'
            'fb145187f2917838897130f23159e6a643cd134aaea1278f0e968436cdf6c30c'
            '73b1f8e211e0e6b8b240cbac1cc93792c0a85453e8c5fb9fbfe900dddb7853e8'
            'f4b32effba6b458346067eb3ccf1c0de6d30cc4170d0918b013e43cac476037f'
            '67e59ad297cb084f1c57725c76a911bd3247919feb2cd31cbe70ea9c2bef51e8'
            'ba01837ab8f6e520fab791c65b9897e7194e2297a073c9c1388e45f02f2cd9a4'
            '00441bbcb00de8bc8aa9346e5d3fca098513970d2570251a580520c2505789da'
            '1fab98e403dae9cc5a890b5f36759e6c9c10c88d150f5c0d1fa97dc5f822b0df'
            '37efc1da52dcea07945fa08f59c7a774a57af3d9dee27df4d5db06d656b0eb7b'
            '891ca411246628ac63e41cc5e1316afcf9ace1c62eaf69e2a23777f24f4b2c29'
            '71d8c5654ffb3d50bb5386ec0465a42bd6329c989b0283a374b1cabf6f1111d5'
            '83944d311d4230f8e17682f1a1248cab3713e7825b87ab0511d5293772c053bf'
            '50c872baaad698962e69e75920903163839e8701ae5a931fedd9f2baba7024f3'
            'e9a81424c9af8e0fe21abc94deb53a20f83d6ec7f4484ae4ab2816cd4aa9022f'
            'ad781a2621fcdf71593fb7265bf4476d6b722e480e664ae5da1006e13a654671'
            '671f0d00c544b500b420375c385e8232354fe364f4e78dbf027ba319745ed61b'
            '4b33aa5479679f1e4d56a8d5e4b247f6d7e4a2041ec1961d90f58bb2fe7ba010'
            '5fbc249bff62b9cd732fd3ed26af3308ac25bb7ca71e5522e1b9213e22ff8e21'
            'e010792a43ee58f5f2c3dac68687b0919d374895207082b084dd5138450ea4fd'
            'fc384ea05422569d075e13c8e4063fc613f37cec50e99a63deb8c0b88c12af8a'
            '817413dd77483bd2858775583e47b0bbc34deae4e7e17cd9728e18a0bcbc1c4f'
            'c4d9c4c7ab51985e265b7f4aaa9af7f7f798923dc9cc2796409cd912a437526e'
            '7371c97d9e857a78d1a423b3b53237646032658a7357181d81a5b504de27b652'
            'd9d6cc59c40257d7b4f47ffec7e0f8b7025f219ac08a45e5b30f645c68ebce9e'
            '6ce75f6373a7caaedc48a5d05a44a0b5ff737cf89cd5278d15f9b2f0d1f85e8b'
            'a72bfb410e1a492a1f43cfa44b851b659d275a49ea930063c977501799f3367e'
            '2fbbef65eb63aa3eb0bcae7a078dfa8ba6f52a490709b748d4b6bde59a83357c'
            'd9972fe797d7b30b642ef8950dbccc81f8ef4f7230df6d9f49983528edbcac84'
            'c869c91601f16ad523d82c3870f34e021427d6552503f04ef244f22e8c4eb055'
            'a10bb179def63b0795e871268396e8091583adaff141b06ae1ea84caf014814d'
            'df102389dfd79f99a8a1d73a2ed37a9359c1eb7bec9b23c0ed779c6beab0e913'
            'b78d7432de20a474bcdbb847a35c60622ec48af5a9d17692b3d5d4b06514b9b5'
            'caeff4e3721cfce15b7e6718ea6f5c58d363f75819f72ee5326cbc1f7333afc8'
            '06de6a7000509f8f1a9aaf1438a5ff1133a00b513a6ef868c861256463e7fff2'
            '163024040f94564f6abcc3a9a2255aa06d1455e02dd53b077edcc69f284e8ae7'
            '8dafb8e5fd1c967ce613893c12e553aca11d82a5880822e010941f7d02e3e457'
            '86284991e7d7b29c2f5fca8692a2e0b27758fd567cade8b9ab512e7efa4918b1'
            '3987ec1092b72806eddad880b5ee25d1fd930be2ade91c8277fca50de21f8322'
            '0fdef6353a3abf59d0568194c808bcfbf45ae87f623ff20f70c5195881cfc2c9'
            '7024ed0f72065e103dc72c388162f4dba5102bcb96b2fb6384b46503fdc28057'
            '772afc258d892b42ee997b7021c5ff9488ebc841178312ec2a3d4236a1dabf2a'
            'c4996d2ac0ca0622fc68af5154b5a8105156d72aacdbe8c971c6dcd169ae9647'
            '6c19f095db187a6be6170935a8dccc3ff73748dc1c08448c8430a6bbf21392ba'
            '816fbb26a0a21a88633b1ffd236a73c5fb31da5a21a28d3bfb9d4cb5f9c2b7c8'
            'ece5bf76101e0a64d3e3d2cc3080255c49fa86fd6e763834325e08caff535be4'
            'a8505ea9138478c30e839fffe1949d63e536f2a812c2777a315a59f30bd1ddb2'
            '43428ce08a66d1a33052b27ea8860d21545fa2642e18cff91e97e00cb43b5931'
            'c1c15dc37d85a4912ab467e9bf9aef814ae432eff338032b41c1fd49eae13010'
            '614748c07488e5a5250958ae6acbf53ed615c18cbaf02c736ef0fcba45f467c4'
            'c713a6dbeebb1c8dd77634dfba6b7dda3b422fb28a55329e2d8afa8ce60484ce'
            '2ca29a09834b8157753d5d5ddf33677c9d96e5f5693b46fb6ace2eab50f9d9b7'
            'a0b5cc0aa1c7017e8030fbc8c4b6573ddd3db4d6f15c97e9aa2eeeacba9c95e5'
            '2de3258dbbb4971ba4682f4f2003589978d5255da95f12d80c4307563ddd65d1'
            'bcb38080fe3aed04631029947050f12a5c5abf3a9a8710d36ef10f2186108c52'
            '6ac01921e4ff6ab0ab94883ef4514e76beb321fd38c4fb37af03e395d4138b4d'
            'b67d804febd8b5c2ac18fd1eb16e958113b8b240d69ce4b80bcd14f9b3afd220'
            'fcbd610d61d61b69660f90c88847da7c850c0a9b37111716d057ed0b324808b0'
            '01e6248cfd1939ef66a8f7f1ad682a5735392b6ee41fdefe92e7cfa5aafed5a6'
            '8e9af304d5bb52f745b6741ade19b4ae2c2d1890323443de17057eb9ad4535d4'
            'f02da1da4e3d5edc7b1f903470c7bf02f06026d0acfce6d064a15233a21c0e00'
            '24d334ca2ee369007dc8b149b90d93a80d13c15bba03e00551f6c959507b8ed6'
            '3df2eb933ed20ccd66c8da61bdb74670e7b5e5a2def1c8a9a45fc2a25c55a03c'
            '8ae0e2f19463062c3278d55ba07bd520b29670b783104bf8fc9fe3d136af3f2b'
            '4bbeb7ea8eedfc8e0a5bf2517d38fdd9aab6a29a7d88cb68c454e3fdf80d3413'
            '0b696f46454de87096bef7bfb6112310bd96c84819e6ef6ecab07672fda4357e'
            '0692791c71ff37b7b1c141f68ffb985d2a565edd4085b2dc3456ef3a3c45e2e3'
            'e4766b69a380687468f703ccedc68b79449d65b28135c0160809b2f7d8049424'
            '09af36243360b498a6352f10eb28c78f855d87ce0ef5fbfbc11f13bb45465462'
            'bd69a01235636473f21baabb764802c94fa4567fb9bbd7777ce6da7b3edd8451'
            '6450c19ddad79bab8b059a992b844fd362d4e6cdd58e31d63bafe25f7e73ab31'
            '19685531dbe58fb31bc2f80f29a2e43fce2230c06f414972351b0c86c2d7b251'
            '190ed15658855a1438b46614209d723bf27fb90864ca64dc21482fb52f5718b4'
            '41cee3aefb63f4f6fe9590a07fce02d463953b52e8cbaaea50d7d0012415e86d'
            'a68c843f7d755ab2b03a8c23018f17be1664279659f9fa9bcbae207ad27d309c'
            '3ff7b080b735b21d142cd2823a5425c0ffc9822925e04c3e5bf1bea1fc60fcc9'
            '194e63cc0eac946214adeb1a45b046a07ce5f7dbe3d16c1dc960dae07f3215ef'
            'bf5c769866615ff7635effb9af194081a5eb4eb8bbfb9555e3eb08140b79df9b'
            'ab9811adb9abf588119d7854ba79a6fb6204eeef3724a0a615a3815fbe8ebfd8'
            '05c38a4a141229ac417d5ff6707e5ab82be22a859cbff3926226927a850eb3c2'
            '62d4a70fc6b8c93a44e9de6d810a3c62561eead83b8abfb545b0bb22f500fec3'
            'c08ada15eb914fdfe24191c5fe6722b42b85c59a53b9af1fa131c12ffd8c802d'
            '4ef6bcf07c756a4da0c3aabe41c8d32962b72fb224ff93ea475d2f1270ceb061'
            '7ae3d7c81bc098252ff6ac7919335270189b6163f636acbfb56f76eb51a6cbb8'
            'b6eaa27d994bb265b621f5df1b288d4d97e0f543e1806d9fd988c7a563f683a1'
            'a683879b3adc94ba1bd83b41ad59eeff29d96f63cca97cf0036d20b9f7f65e1d'
            '98fa9c475af8c5a4dfe132ef5f27bf3ae0b550cce46c6bf7125608beb965aa06'
            'a0a4b506d4c3e6aaf00738fe6745778e0b42442b5ead0b86575907f53909dc02'
            '2c5beb3ba1bebc339ae4124fcee79fad375ebba7d97251dac83ff1eed1042bad'
            '795e4a8747e0540259efcfddecb1ca8d4e0be85739f2e3553a78935ebb0191f9'
            '2279205d7288313d59be7c2eadcc572988e063fbb570e76802cb681bdc262e0e'
            'fbb61e96a3d9e9f5509c4e74aff0f24b6e10259299bcee99febf63732d0c0b7b')