blob: a086e0890bb00ed9718df7468ee3f858d0fa292d (
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
|
# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
pkgname=saber-bin
_appname="com.adilhanney.${pkgname%-bin}"
_pkgname=Saber
pkgver=0.25.2
pkgrel=1
pkgdesc="The cross-platform open-source app built for handwriting.(Prebuilt version)"
arch=(
'aarch64'
'x86_64'
)
url="https://github.com/adil192/saber"
license=('GPL-3.0-only')
provides=("${pkgname%-bin}=${pkgver}")
conflicts=("${pkgname%-bin}")
depends=(
'gtk3'
'libsecret'
'gstreamer'
'gst-plugins-base-libs'
'webkit2gtk-4.1'
'libxmu'
)
options=('!strip')
noextract=("${pkgname%-bin}-${pkgver}-${CARCH}.tar.gz")
source_aarch64=("${pkgname%-bin}-${pkgver}-aarch64.tar.gz::${url}/releases/download/v${pkgver}/${_pkgname}_v${pkgver}_Linux_arm64.tar.gz")
source_x86_64=("${pkgname%-bin}-${pkgver}-x86_64.tar.gz::${url}/releases/download/v${pkgver}/${_pkgname}_v${pkgver}_Linux_x86_64.tar.gz")
source=("${pkgname%-bin}.sh")
sha256sums=('3b8311438e88f47eb507322a43c7a4156bfebb8c0f6e7b7436ef70842fb4c745')
sha256sums_aarch64=('7e0159c8ce5d5c3f66a4b471db7f98837e6dbae77876b5140fc8096354af4061')
sha256sums_x86_64=('2616fa16c0afe7d308a95655774c88746d43353d490e5e290d4c9b010cc3162b')
build() {
sed -e "
s/@appname@/${pkgname%-bin}/g
s/@runname@/${pkgname%-bin}/g
" -i "${srcdir}/${pkgname%-bin}.sh"
install -Dm755 -d "${srcdir}/usr/lib/${pkgname%-bin}"
bsdtar -xf "${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.tar.gz" -C "${srcdir}/usr/lib/${pkgname%-bin}"
rm -rf "${srcdir}/usr/lib/${pkgname%-bin}/usr"
sed -i "s/${_appname}/${pkgname%-bin}/g" "${srcdir}/usr/lib/${pkgname%-bin}/share/applications/${_appname}.desktop"
sed -i "s/${_appname}/${pkgname%-bin}/g" "${srcdir}/usr/lib/${pkgname%-bin}/share/metainfo/${_appname}.metainfo.xml"
}
package() {
install -Dm755 "${srcdir}/${pkgname%-bin}.sh" "${pkgdir}/usr/bin/${pkgname%-bin}"
cp -Pr --no-preserve=ownership "${srcdir}/usr" "${pkgdir}"
install -Dm644 "${srcdir}/usr/lib/${pkgname%-bin}/share/icons/hicolor/scalable/apps/${_appname}.svg" \
"${pkgdir}/usr/share/hicolor/scalable/apps/${pkgname%-bin}.svg"
install -Dm644 "${srcdir}/usr/lib/${pkgname%-bin}/share/applications/${_appname}.desktop" "${pkgdir}/usr/share/applications/${pkgname%-bin}.desktop"
install -Dm644 "${srcdir}/usr/lib/${pkgname%-bin}/share/metainfo/${_appname}.metainfo.xml" "${pkgdir}/usr/share/metainfo/${pkgname%-bin}.metainfo.xml"
}
|