desktop/syncthing/PKGBUILD

58 lines
2.4 KiB
Bash
Raw Normal View History

2015-05-22 05:39:40 +08:00
# Contributions from Arch Linux: https://www.archlinux.org/packages/community/x86_64/syncthing/
pkgname=syncthing
2015-12-29 23:29:25 +08:00
pkgver=0.12.10
2015-08-23 22:03:33 +08:00
pkgrel=1
pkgdesc="Open Source Continuous Replication / Cluster Synchronization Thing"
url="http://syncthing.net/"
2015-05-12 01:23:48 +08:00
license=('MPLv2')
arch=('x86_64')
screenshot='http://syncthing.net/screenshot.jpg'
depends=('glibc')
2015-05-09 00:03:55 +08:00
makedepends=('go' 'inetutils' 'sed')
2015-05-12 01:23:48 +08:00
source=("$pkgname-$pkgver::https://github.com/syncthing/syncthing/releases/download/v${pkgver}/syncthing-source-v${pkgver}.tar.gz"
"syncthing.1"
2015-05-09 00:03:55 +08:00
"syncthing.desktop"
2015-06-11 06:07:27 +08:00
"syncthing.png")
2015-12-29 23:29:25 +08:00
sha512sums=('fab7ac66de0cab50a48741f0ad838ee9b27ace835a80db2091c610d5ca8b89d7508bfd5be43d4c3ab6335b4203938485514bd08fe5e050cef3a48b902ae39028'
2015-05-09 00:03:55 +08:00
'dafadb0c87b1f5b20c337cc0171f254586cc195304ad9b471392247537be06a98cac29575649109a176aa66ea8cee2809a051557352b86a117151e868d8392b3'
'121613768221627bb1d2e1ea8621f5ac5d2bc82a990c9f81bdc834d1348f122dbd5396b4ef3c6a7845ea492187d377dbed096683b942c64ef6c6218c28188868'
'3f93800b022a0e1d1d2b462cf1dfbc1f38a4e91ebba2b8b9a95b764617bf3303fdac91c2ceb1df3b5431523a556f3e482cf491e57e76983766aab381f96e3368')
install=${pkgname}.install
prepare() {
cd "${srcdir}"
mkdir -p "src/github.com/syncthing"
2015-05-12 01:23:48 +08:00
mv "${pkgname}" "src/github.com/syncthing/${pkgname}"
}
build() {
export GOPATH="${srcdir}"
cd "${srcdir}/src/github.com/syncthing/${pkgname}"
go run build.go -no-upgrade build
}
2015-05-22 05:39:40 +08:00
check() {
export GOPATH="${srcdir}"
cd "${srcdir}/src/github.com/syncthing/${pkgname}"
#go run build.go -no-upgrade test
}
package() {
cd "${srcdir}/src/github.com/syncthing/${pkgname}"
install -D -m 755 ${pkgname} "${pkgdir}/usr/bin/${pkgname}"
install -D -m 644 README.md "${pkgdir}/usr/share/doc/${pkgname}/README.md"
install -D -m 644 "etc/linux-systemd/system/${pkgname}@.service" "${pkgdir}/usr/lib/systemd/system/${pkgname}@.service"
install -D -m 644 "etc/linux-systemd/user/${pkgname}.service" "${pkgdir}/usr/lib/systemd/user/${pkgname}.service"
install -D -m 644 "${srcdir}/${pkgname}.1" "${pkgdir}/usr/share/man/man1/${pkgname}.1"
2015-05-22 05:39:40 +08:00
# license
install -Dm644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
# Desktop icon
install -Dm644 "${srcdir}/${pkgname}.desktop" "$pkgdir/usr/share/applications/${pkgname}.desktop"
2015-06-11 06:07:27 +08:00
install -Dm644 "../../../../syncthing.png" "$pkgdir/usr/share/pixmaps/${pkgname}.png"
}