blob: c2884a123d72e24de50486e794ab57f31f6220d1 (
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
|
# Maintainer: Yushun Cheng <chengys339@163.com>
# name
pkgname=lenovo-100-m1520-m1688-series
# version
_srcdate=20210511095611
_pkgver=1.0
_revision=43
_pkgdate=20210420
pkgver=1.0.43
pkgrel=1
# generic
pkgdesc='Lenovo printer driver for 100, m1520, and m1688 series.'
arch=('x86_64')
url='https://www.lenovoimage.com/'
license=('custom:Lenovo')
# dependencies
depends=('cups' 'sane')
makedepends=('tar')
# source
source=("${pkgname}-${_pkgver}.${_revision}.7z::https://lenovo-upload.oss-cn-beijing.aliyuncs.com/drivers/L100_Series_drivers_Lin_${_srcdate}.7z")
# checks
sha256sums=('3ac923c20e25047edb12242ddbbcd626bc77990ec31332de2c84950dc9a1f386')
pkgver() {
echo "${_pkgver}.${_revision}"
}
package() {
# unzip tar
tar -xf "${pkgname}-linux-installer_${_pkgver}-${_revision}_${_pkgdate}.tar.gz"
# unzip deb
cd "lenovo-100-m1520-m1688-series_${_pkgver}-${_revision}"/Installer
ar x "lenovo-100-m1520-m1688-series_${_pkgver}-${_revision}_amd64.deb"
# unzip data.tar.gz
tar -xf data.tar.gz
# package
mkdir $pkgdir/usr
# bin
mv usr/local/bin $pkgdir/usr/bin
# lib
mkdir $pkgdir/usr/lib
mv usr/lib/cups usr/lib/sane usr/lib/*.so $pkgdir/usr/lib
# share
mv usr/share $pkgdir/usr
# etc
mv etc $pkgdir
# license
mkdir -p $pkgdir/usr/share/licenses
mv License $pkgdir/usr/share/licenses/$pkgname
}
|