### this file is sourced not run
PKGVER=1.52.3
PKGBUILD=1
PKGARCH=x86_64

# source: james
TARBALL=rclone-v${PKGVER}-linux-amd64.zip
MD5SUM=4ea3f0c5242f75264b8dbdcbd985e478
SRC_URL=https://downloads.rclone.org/v${PKGVER}/$TARBALL
BUNDLE=

SLACKREQ=
SLACKDESC="rclone: rclone $PKGVER (Cloud storage manager)
rclone: 
rclone: Rclone is a command line program to manage files on cloud storage. It 
rclone: is a feature rich alternative to cloud vendors' web storage 
rclone: interfaces. Over 40 cloud storage products support rclone including 
rclone: S3 object stores, business & consumer file storage services, as well 
rclone: as standard transfer protocols.
rclone: 
rclone: Note: this is packaged from the official binary.
rclone: 
rclone: https://rclone.org/
"

### default pkg_download
### prepare
pkg_prepare() {
	if pkg_check $SRC_DIR $TARBALL $MD5SUM; then
		unzip $SRC_DIR/$TARBALL -d tmp
	else
		return 1
	fi
}

### default pkg_package
### build
pkg_build() {
	cd /tmp/rclone* &&

	# get to work
	install -m755 rclone /usr/bin/rclone &&
	mkdir -p /usr/share/man/man1 /usr/share/doc/rclone-$PKGVER &&
	install -m644 rclone.1 /usr/share/man/man1 &&
	install -m644 README* /usr/share/doc/rclone-$PKGVER &&
	
	pkg_build_slackdesc
}


