2015-05-07 15:51:45 +02:00
|
|
|
pkgname=btsync
|
|
|
|
version=2.0.105
|
|
|
|
revision=1
|
|
|
|
repository=nonfree
|
|
|
|
short_desc="Automatically sync files via secure, distributed technology"
|
|
|
|
maintainer="Juhani Imberg <juhani@imberg.fi>"
|
2015-05-07 19:55:18 +02:00
|
|
|
license="Proprietary license"
|
2015-05-07 15:51:45 +02:00
|
|
|
homepage="https://www.getsync.com"
|
|
|
|
|
|
|
|
case "${XBPS_TARGET_MACHINE}" in
|
|
|
|
x86_64)
|
|
|
|
_type=x64
|
|
|
|
_hash=9e1427b7a6c6e960a378b97ac458ad53c445457ed0e5c8bf693f446597377b78
|
|
|
|
;;
|
|
|
|
i686)
|
|
|
|
_type=i386
|
|
|
|
_hash=4d446255ff6332da9a244737d6c20e7dcd32d24a8eaabffbaf73147e5898ed8f
|
|
|
|
;;
|
|
|
|
arm*)
|
|
|
|
_type=arm
|
|
|
|
_hash=c63fccb76ba3f5dd1197f33bfb8427747faaca9c030f9d8c7f5dfc016d293807
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
2015-05-07 18:07:49 +02:00
|
|
|
_filename="BitTorrent-Sync_${_type}.tar.gz"
|
|
|
|
distfiles="https://download-cdn.getsyncapp.com/${version}/linux-${_type}/${_filename}"
|
2015-05-07 15:51:45 +02:00
|
|
|
checksum="$_hash"
|
2015-05-07 18:07:49 +02:00
|
|
|
skip_extraction=$_filename
|
|
|
|
create_wrksrc=yes
|
2015-05-07 19:55:18 +02:00
|
|
|
system_accounts="btsync"
|
2015-05-08 21:40:52 +02:00
|
|
|
btsync_homedir="/var/lib/btsync"
|
|
|
|
conf_files="/etc/btsync.conf"
|
2015-05-07 18:07:49 +02:00
|
|
|
|
|
|
|
do_fetch() {
|
|
|
|
mkdir -p $wrksrc
|
|
|
|
cd $wrksrc
|
|
|
|
xbps-uhelper fetch $distfiles
|
|
|
|
echo "$checksum $_filename" | sha256sum -c || { sha256sum "$_filename"; return 1; }
|
|
|
|
}
|
|
|
|
|
|
|
|
do_extract() {
|
|
|
|
:
|
|
|
|
}
|
|
|
|
|
|
|
|
do_build() {
|
|
|
|
sed \
|
|
|
|
-e "s|%BTSYNC_URL%|${distfiles}|" \
|
|
|
|
-e "s|%BTSYNC_CHECKSUM%|${checksum}|" \
|
2015-05-07 18:09:19 +02:00
|
|
|
${FILESDIR}/btsync-vars.sh.in > btsync-vars.sh
|
2015-05-07 18:07:49 +02:00
|
|
|
}
|
2015-05-07 15:51:45 +02:00
|
|
|
|
|
|
|
do_install() {
|
2015-05-07 18:09:19 +02:00
|
|
|
vmkdir "usr/lib/btsync"
|
2015-05-07 18:07:49 +02:00
|
|
|
vcopy btsync-vars.sh "usr/lib/btsync"
|
|
|
|
|
2015-05-08 21:40:52 +02:00
|
|
|
vconf "${FILESDIR}/btsync.conf"
|
|
|
|
|
2015-05-07 18:07:49 +02:00
|
|
|
vlicense "${FILESDIR}/LICENSE"
|
2015-05-07 15:51:45 +02:00
|
|
|
|
|
|
|
vsv btsync
|
|
|
|
}
|