summaryrefslogtreecommitdiff
path: root/libre/icedove-l10n/PKGBUILD
blob: 249290f51c4ba66a19632ae6749f2185d6077b94 (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
# Maintainer: André Silva <emulatorman@parabola.nu>
# Contributor: Márcio Silva <coadde@parabola.nu>

epoch=1
_pkgbase=icedove
pkgbase=$_pkgbase-l10n
_pkgver=45.8.0
pkgver=45.8.0.deb3
pkgrel=1
pkgdesc="Language pack for Debian ${_pkgbase^}."
arch=('any')
url="http://packages.debian.org/sid/icedove"
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"'
  '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

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

  pkgname+=($_pkgname)
  source+=("$pkgbase-$_pkgver-$_locale.xpi::$_url/$_locale.xpi")
  eval "package_$_pkgname() {
    _package $_lang
  }"
done

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

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

  unzip icedove-l10n-$_pkgver-$1.xpi -d $1
  rm -v icedove-l10n-$_pkgver-$1.xpi
  install -vDm644 $srcdir/brand.dtd $1/chrome/$1/locale/$1/branding
  install -vDm644 $srcdir/brand.properties $1/chrome/$1/locale/$1/branding
  install -vDm644 $srcdir/region.properties $1/chrome/$1/locale/$1/messenger-region
  sed -i -e 's/thunderbird/icedove/' $1/install.rdf
  rm -rv $1/chrome/$1/locale/$1/global-platform/{mac,win}
  rm -rv $1/chrome/$1/locale/$1/messenger/searchplugins
  cp -av /usr/lib/mozilla/searchplugins $1/chrome/$1/locale/$1/messenger

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

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

sha256sums=('49b419449431d8d64e20427a2e7105e3ac1ffc41e677a5f9a8eb276f5b82df4a'
            'acc2cf95661be7cb8928fca89e08d0681685409ff2428e4e3d25baf1af427b38'
            'e6edcc7c478d73ca5a17e4889acd302d55201ec5c29de545d3f44165201923db'
            '4b8787643041672aad90d1297eacad510ec88d04461d19680d38e004add14f21'
            '0ead56ad0cd11503a60d5f75cd181c0c85eb7ccbc42fa69c76d3cd64f29a0cd9'
            '2836d2485234e541fe2d227af8f8c477173051d6bd6a9db5bab6c64a74fefd04'
            'b0cb9a7684809eb71e3d79ffab9b6422c97a4dcf4cb8cbff14a403c79a425980'
            '2c34a6f9a28605551953d40ec868ed42eb605d85ea6012bb868adc2251f18158'
            '058d05618dd1c83dd854203e043c328ec1f6937f5b85f9ff50245f7e428b3c01'
            '89e8c63dfeeb9a8a68f28278302143c2f1b71193bfefacbbbcdf70cb47357046'
            '50e02729a1a4740a3964b085572b8d17c551cf71438d24e8d1845073d5048ad2'
            '46f2549f8568db23e734fb95bc3836335e104867b1467086058f062f2471552f'
            'b7fdb27246d5bd78d3ffccd83bdf437fe791f820ca5ba38cad19f5286c7380c8'
            '41814028f2aad3d30ab245935095d5f7c2ffc97f79d731eed9977f1cf03b0018'
            '161dde3ccedcbcb879ea77fc3b43bd16b331c0317f513d8479158b0f48349a63'
            '1daf788364a9d738fb2a8324814076d8a058cff96884ccb0a24cb440fdb9f42e'
            'cf1fce9ed3442c4eb2e669968757077f79c68499ad12bebedae86259c8b83153'
            '3dcc363eaefa81dfa9d0aea4a03798339ed3e12ceea8d56cbd766c756f9cbf29'
            '20a757a4ee8f349e5578a0da2daa94b0ecd4c5b06315aa928ed429d9bab03d89'
            '2f4872efacab2e2ffa9c561f882eb6f6e323f02a7e3606efda0d0aef7af38516'
            '44a8c625290a5a306c9d1946c1084a307b83595dec6cc75cfe809428f490fca7'
            'a5d9f300bb05cf0c3e5eddff963ee790a28ba7706530697eb7464f202434923a'
            '5c0ea0d794d4fc35d1281f5ab14d6725d8c42180b242da9d65005bfd036467db'
            'b0cc458c6e5605cdd3ec237cfd679c14550b3a7c1397637602cf273a600a013f'
            '6a2f11240be608e90938c61fad09c460490f7c4418da71326ec3cc8a57ce01cb'
            '4725d113908caad379a0a360b55ceb94c192e9b5475b497778ab39b8e8124c4c'
            'a9958f7c2383923e317c9cfa52fd2a853f8acb2673425206a1a6ec5e9172796b'
            '9ebedd43676f8b2d4a5de96e092b01642f5a325da872d7881b2515bc7dfa09b4'
            'a476c22a63fda28330c4e03957cf1abe407f9ac7041f73a9c157185441e7e5e3'
            'a434724f0977c9caea5abf63ce8f5587d0b8496aabd18403ee26deac0dabdf1b'
            'e806a0b1a6652fbe48e7a8bb9eba60194c94188931a5ca03e50d6fbc4fbbca92'
            '1cf236e60fb7097842d27d2f791821c63eee3e62323e73d9a288a9b888ad5fa5'
            '52d988c204b8e0cb421f9fdfac1ec4a21c18cd6a40b43e8573494396d516a652'
            '2ca9d5d178c1dbb5559e93702b4b0d7049f3f35dac01e616a79316b825251360'
            'e5692f833bcee4cd1abccc0a5e9d64dc0f51f30b515c9e4e821bbc2e87549209'
            '7a551f3c72330531723f97c1d94aa9ec21ba2191f68f172134c95a830d8cd19d'
            '2f2bc3f468490efc0443743c05c41ce37058ab4c6d8b5c515f068990134336c2'
            '397dd7ef1002f3a861757a49abaf77ed4b5809c5370c85031ccdf0465b4504b8'
            'b3cbf1f89527f6e4ab642843bddb85abfd650d0e1318664d9d899dfb0eeb071e'
            '4063b519f2e61dcca7d8f121f0664dbbd4f70afe3cbf6b2c9e5c4d95baaaa94d'
            '1297c46ba1690567bccc33d085f2deb0871447ce664959f3ee9dafa028d80688'
            '2e3b52591317080d5e0296eb18f4ebe78166eff1c5c8f7466ee483a0b9cfad16'
            '9f114808ab6733d9c2299153a1e361cb98617b97e286a12579e09abf3f9d2975'
            '52e1fa5935e439a7845c947e3ae9ba0b883da02bb6976e66aad9677c103aab17'
            'c0b2966560a53b11355d241d50337772bd000ccbe518bc2ba7b2942107057744'
            '8c69f5a3911917284a715625acc4cfb9dd18884de3cfb841271a957dbd9a54aa'
            'd948b70df148a6f220ae1a92ea3126c4246c2f4c5edaf1eaa7876142a61ac6b2'
            'cdf68888750bc9c5a87c0424a60e33afc075a09f9ef68b5fadd24d9ae2cad48b'
            'cc6f6236f43e22b101296a4b67879ef6c1c58ea6c78f69fcf4e6d17e5d1439d8'
            'a7c66be4bcb3220101f6b234f2e6ae1f468c0894ec5391896be20caf17f8cc45'
            'c8dee9828ad164f3deb3dbb42a003ef3cc97ba2fb509289a9f10277fa9827495'
            '45c6d8f89d1f83e37890a1dd915579ac3cd4cc28d57bc2ab6d31e63a63411d29'
            '1cbf09a27eeb122b00992ad9cadd4a2bd74fcdf6a4dacc33e89b99a3558d66d6'
            '1374da12111a405d4c366d3bbdf71ddc8a5baeeb580ae12bde50867829e628f1'
            '1980c0e617df8d91a525e1df378d49cea5a0c09fd74bca0e3e57e90c891d52ac'
            '66d949eb3fb687e71a019c558ea45de24932d6b7b04937ed0b32e4f82e6f0b6d'
            '8e116a53f97624e3e9f27705a2a37efa8d7f2d25dad3dcf58a9d9fb1c3019472'
            '168d7efd879e77f7ad7c3e4b736e486110f1a8225f487a440e63df412e013df1'
            '39f64a6acdc7c916ab73c279db67f0f51db77d756f2154ca22420695e8e5f95c'
            '05f2e3d25501ef42422e9e2624f15ea61f48a355148d867c29626af1b09a769d'
            '7de83d5ec93a97bfebe8a692313998c02479c8bef705983d3f976360a4a02094')