mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-01-24 02:22:13 +08:00
39 lines
1.3 KiB
Bash
39 lines
1.3 KiB
Bash
_langs=(afr amh ara asm aze aze_cyrl bel ben bod bos bul cat ceb ces
|
|
chi_sim chi_tra chr cym dan dan_frak deu deu_frak dzo ell eng enm epo
|
|
equ est eus fas fin fra frk frm gle glg grc guj hat heb hin hrv hun
|
|
iku ind isl ita ita_old jav jpn kan kat kat_old kaz khm kir kor kur
|
|
lao lat lav lit mal mar mkd mlt msa mya nep nld nor ori pan pol
|
|
por pus ron rus san sin slk slk_frak slv spa spa_old sqi srp srp_latn
|
|
swa swe syr tam tel tgk tgl tha tir tur uig ukr urd uzb uzb_cyrl vie yid)
|
|
|
|
pkgbase=tesseract-data
|
|
pkgname=($(for l in ${_langs[@]}; do echo tesseract-data-${l}; done))
|
|
pkgver=4.00
|
|
pkgrel=1
|
|
pkgdesc="An OCR programm"
|
|
arch=('x86_64')
|
|
url="https://github.com/tesseract-ocr/tessdata"
|
|
license=("APACHE")
|
|
depends=()
|
|
source=($pkgbase-$pkgver.tar.gz::https://github.com/tesseract-ocr/tessdata/archive/$pkgver.tar.gz)
|
|
sha256sums=('35909b14d735ba21457eb1b81c19167f9cba94e062a04af34afc1ee1e8a65361')
|
|
|
|
build() {
|
|
true
|
|
}
|
|
|
|
# Declare the package functions for data
|
|
for l in ${_langs[@]}; do
|
|
eval "
|
|
package_tesseract-data-${l}(){
|
|
pkgdesc=\"Tesseract OCR data ($l)\"
|
|
depends=('tesseract')
|
|
groups=('tesseract-data')
|
|
|
|
mkdir -p \$pkgdir/usr/share/tessdata
|
|
cp \$srcdir/tessdata-$pkgver/${l}.* \$pkgdir/usr/share/tessdata/
|
|
find \$pkgdir/usr/share/tessdata -type f -exec chmod 0644 {} \;
|
|
}
|
|
"
|
|
done
|