# Template build file for 'spotify'.
pkgname=spotify
version=1.0.55
revision=1
short_desc="Proprietary music streaming client"
maintainer="Stefan Mühlinghaus <jazzman@alphabreed.com>"
homepage="https://www.spotify.com"
license="Proprietary"
create_wrksrc=yes
only_for_archs="x86_64 i686"
repository=nonfree
build_style=fetch
depends="binutils gtk+ nss GConf libXScrnSaver xz"

if [ "${XBPS_TARGET_MACHINE}" = "x86_64" ]; then
	_sversion=".487.g256699aa-16_amd64"
	_schecksum="20073ba6fdf7d960361d4cb2afa6453e7a2108bd84df8f9cdf2cdf7225a83027"
else
	_sversion=".487.g256699aa-16_i386"
	_schecksum="183f87b930b75d85ecb34cef2b26b0355a3a18ffa38e0e0a476bfb190972b74d"
fi

do_install() {
	vbin ${FILESDIR}/spotify
	vmkdir usr/share/spotify
	echo "export SVERSION=\"${version}${_sversion}\"" >"${DESTDIR}/usr/share/spotify/pkgdata"
	echo "export SCHECKSUM=\"${_schecksum}\"" >>"${DESTDIR}/usr/share/spotify/pkgdata"
}
