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

epoch=1
_pkgbase=icedove
pkgbase=$_pkgbase-l10n
_pkgver=45.3.0
pkgver=45.3.0.deb1
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')

_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
  rm -rv $1/chrome/$1/locale/$1/global-platform/{mac,win}
  sed -i -e 's/thunderbird/icedove/' $1/install.rdf
  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'
            '14e8349dd5c9d44870b31c12831878c41b3346065aef9dfa0b1e53afa01b86d3'
            'b029c48931513e7983c6f031b2d9f68e1d2a8b0265807af914c598ed35e69247'
            '6a2690f13e4182de6aaae74f27acf40d77b0a478e361aad34de838a7f959641f'
            '4ab4c475533f96bc68e2e01a9963fbcc64ca8908d2803d849eaec9dd6e3833b7'
            '499f06af305abcbbffa82eed89b986d0322ea221839d438109caf0a5144f3d20'
            'fab61235a4808ca07de9cc91193dc1d9a2ae4d0f461bb8df6bcc51436506eba8'
            '95ecc9a3189c1cb80debaa00270ce59175c8517d3a69ed26f53f66ccfc8a5a50'
            '89b1fa9550587167d23cd24c6c5eafd3425dda60d0c3beeb930820eb492d70ca'
            '47e089e89d005b7bea32e02bcffeac9792f1758fc66217bf6b3acffd38e031fd'
            'ae4bc970266f6b889a004e73f77ba9633f4657e51eae26cb51d2a5b4164b4818'
            '661eb6b901f1a28b9c00862413768482443bd45a148d6bbe47dd52b832a63b29'
            '6b5c9ec06b853de794121c9bcbc7c6ae1f8e0406b6d84dde0ad171fac0979474'
            '8a8ba1b597e0da878dea8f97338137b252c907cf7a44b14ba702e332b3db370d'
            '710e441f1c0c89069a1c7f81a07d1a71dfb95bae1969ba0848d07dd1c9171abb'
            '5629d6da99a5c0b7d4a074dd82a085d46edcd9abdceea5520d5b71270a53265b'
            'ab48d70b5cd131fe3603857bc1df424b8b65e6c5644512ec53e0f685565ac83b'
            'a2273d1a286c4a8d079306060171a930fb16185852ae8392cb42838227e0863a'
            'b7a399f8b8503da2dfcee62f9bc842a0e7564881fa80a82b036c6dd5fbdb1f33'
            'd5ae34ab7078242c839ed4e3dd686b2a99db0b6469803195fdd9b76dc7d146dd'
            'be29bac660dc23679e2b7170a9ad6cf41f0e4de7fac1b00b499cb1e3d7da7f11'
            '809106596fbdb70f5d1b078504b90a99a8fe47e6b149a6b44939087d575ef9df'
            'edd06a5b3a09a96559fb3b598579d738e725045e47be97e3a1ec4c2a864680f0'
            '88fe8fd6460aeff54d873b0ef8ee3be276e4b2b9ae484a418a615523c484c9ff'
            'c5412c25359a46887a29d6139cf7fd2295ff5aea03411d1eb54e517b8df096c0'
            '2b560084c1ea28d68073990689dc519c0a87c5c9a3e97e651c65017c4ad027ec'
            'e2885e37ca31ece37f80f0aabaf9cb9d4c343ae6493f5a74933d0101b25931d4'
            '9f2f6d27922fb18bc973637ff16ff8bfee13260846124eded83e9bd4ac259386'
            'aa962ab31211f26cadcab83cf53b4702d36ec0aaf254f90501bc61dece171207'
            '31d83972095cb91b2f800d425d86898c1267734cdd130c4f5b6dee508b7f74af'
            '519cc05757b2c3d1b5469cd41b7ca8509061f5ff1a0cce3c172905fc22e414f3'
            'ca5fadd3bd46423dfea5c8311b53a2e0ee5c13ababf46d7f403c0db1dcc11ebb'
            '1e2d34ea4eb7aedadcaa19f78fd181fd300bbde09d77acef22d3d98cedfc4eef'
            'cec2d6d74a6009fac0ae32a003eeecaf92764ef64e04cabaab9991f4df0e3f8a'
            '12c51b7609d66aca80ae5ad182e9f9c7f53b858710e8984c2719bbb3d5fb7424'
            'bd0136777a199afdc65ba973824a331c73fb179cb48ac97145e6b765e4cc7804'
            'b58979478eb925bfb89c8bd5af244d4cf7e00f6f6552d502e46d798d78b52c8e'
            'e4ab9385fce486a3db941d7bcdb940c30aec48799fd99f8c4bd5b49d912e18a4'
            '500fa2ff7d7383c0d177e6ac2d6dcfd6bfabe60f691c9c6eb4f38c5a04f74f6a'
            '0bd32c709071e81e057eabec5c0c5bf5a5eba916b78ce09f093427dcb7900ab8'
            'ac6f3f94d26f9476f994f40079093e2f40fad8a224821685145b15a7cabd45fd'
            'cb3ce60d3a7a1b99f7f63e39de4e136aef86d23b2a32d444c2830389237f3110'
            '97a55b58a2d9e174a3a09c817cbb269efd45857b0a44ffd495acd7128f8c8e83'
            '35a3e8a67a58da58ba21c6e5788ba408ff42706998becbfe2fc2919981a11e9b'
            '76400f0ca680672b3dda2a7471cbd153ed012f46f25772476b26cd5133b8f196'
            '339dcae1301575b2e80f62513ff0a7fa80bda0bbd2e1768a4b46b0967ed68cbe'
            'a9f177a77be928bdf6b766f28a318c59059952a9eaa255d301487e04011e0ea4'
            '6220c44dfc6063c40b31bcbb38d3ba631af1cb8ce83ab56a6650d233a8224273'
            'e3dcc38d2fb6f99bdb61c05b668a8ac9f9edafd39367f7187beb6de0c0fbc6b9'
            '634e6cc802bb959161605d3debce6e42a788f123d8fcb553a5d31710c1905afb'
            'e5a979709fa05c77b317c314d4cd4480fb4ebc515edae875741240c9ca776d7e'
            'ed293a2e16420aa71783d0e100696a0ad80d5c901647073703df9f9e04eac89d'
            'a02ae56d7fd8918f018724d08af56f095a0e7f9dd5caf2dabbf09b811d807c8f'
            '981f7d8ebe94e3333340b1b87b4f58d8616df0961ce3593fd22b070372f6da70'
            'afe590afdb4c4b82a4bce715f06dacd2b67ec748b173ee164b046711128f2a8a'
            '521d71834e427f2e7302533f76290e7f3da4195955cb7a63f3fa193806856ff3'
            '36325c156df4a34a581fe8fc0e5c013364f40e4057cc2ba60701a02bdda7fe1e'
            'cf53c911e587360f7acf1756dc714d975b3691b3521f49d409b6a5f5b3b1b016'
            '0c2d483534b394fd27cf934e80537d0c789023b4f67eef87965679278d6a6e7c')