summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDoug Newgard2016-08-25 10:37:16 -0500
committerDoug Newgard2016-08-25 10:37:16 -0500
commit037feb5c1983847ef52812874ce5d011adc57e65 (patch)
treece599c77cf9ca2784419375d7ade23edbd6aeb46
parente6922c20c40e4b961b380e431ee610fdb489265b (diff)
downloadaur-037feb5c1983847ef52812874ce5d011adc57e65.tar.gz
Rewrite
-rw-r--r--.SRCINFO23
-rw-r--r--PKGBUILD35
-rw-r--r--spotify-legacy.install52
3 files changed, 34 insertions, 76 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 7838522362c8..988bb478aa41 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,29 +1,30 @@
pkgbase = spotify-legacy
pkgdesc = A proprietary music streaming service.
pkgver = 0.9.17
- pkgrel = 1
+ pkgrel = 2
url = https://www.spotify.com/download/linux/
- install = spotify-legacy.install
arch = x86_64
- license = custom:Copyright (c) 2014 Spotify AB
- depends = binutils
- depends = desktop-file-utils
- depends = ffmpeg-compat
+ license = custom
+ depends = alsa-lib
depends = gconf
- depends = libgcrypt11
+ depends = gtk2
+ depends = glib2
+ depends = nss
+ depends = libgcrypt15
+ depends = libsystemd
depends = libxss
- depends = openssl
- depends = python2-xdg
depends = qt4
- depends = wget
- depends = xdg-utils
+ optdepends = ffmpeg0.10: Support for playback of local files
+ optdepends = zenity: Support for importing local files
provides = spotify=0.9.17
conflicts = spotify
conflicts = spotify-beta
conflicts = spotify094
conflicts = spotify-stable
source = http://repository-origin.spotify.com/pool/non-free/s/spotify/spotify-client-0.9.17_0.9.17.8.gd06432d.31-1_amd64.deb
+ source = spotify-LICENSE.html::https://www.spotify.com/us/legal/end-user-agreement/
md5sums = 69a320368ded33cfcc4e3bb4cc71575c
+ md5sums = SKIP
pkgname = spotify-legacy
diff --git a/PKGBUILD b/PKGBUILD
index 503bb9998922..3328b4f36518 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,22 +1,31 @@
-# Maintainer: Ole Jon Bjørkum <mail at olejon dot net>
+# Contributor: Doug Newgard <scimmia at archlinux dot info>
+# Contributor: Ole Jon Bjørkum <mail at olejon dot net>
pkgname=spotify-legacy
pkgver=0.9.17
-pkgrel=1
+pkgrel=2
pkgdesc="A proprietary music streaming service."
arch=('x86_64')
url="https://www.spotify.com/download/linux/"
-license=('custom:Copyright (c) 2014 Spotify AB')
-depends=('binutils' 'desktop-file-utils' 'ffmpeg-compat' 'gconf' 'libgcrypt11' 'libxss' 'openssl' 'python2-xdg' 'qt4' 'wget' 'xdg-utils')
-provides=('spotify=0.9.17')
+license=('custom')
+depends=('alsa-lib' 'gconf' 'gtk2' 'glib2' 'nss' 'libgcrypt15' 'libsystemd' 'libxss' 'qt4')
+optdepends=('ffmpeg0.10: Support for playback of local files'
+ 'zenity: Support for importing local files')
+provides=("spotify=$pkgver")
conflicts=('spotify' 'spotify-beta' 'spotify094' 'spotify-stable')
-install=$pkgname.install
-source=('http://repository-origin.spotify.com/pool/non-free/s/spotify/spotify-client-0.9.17_0.9.17.8.gd06432d.31-1_amd64.deb')
-md5sums=('69a320368ded33cfcc4e3bb4cc71575c')
+source=("http://repository-origin.spotify.com/pool/non-free/s/spotify/spotify-client-${pkgver}_${pkgver}.8.gd06432d.31-1_amd64.deb"
+ 'spotify-LICENSE.html::https://www.spotify.com/us/legal/end-user-agreement/')
+md5sums=('69a320368ded33cfcc4e3bb4cc71575c'
+ 'SKIP')
-package()
-{
- mkdir -p $pkgdir/opt
- tar -xf $srcdir/data.tar.xz
- cp -rp $srcdir/opt/spotify /tmp/spotify-stable
+package() {
+ bsdtar -xf data.tar.xz -C "$pkgdir"
+ install -Dm644 spotify-LICENSE.html "$pkgdir/usr/share/licenses/$pkgname/LICENSE.html"
+
+ cd "$pkgdir/opt/spotify/spotify-client/"
+ install -Dm644 spotify.desktop -t "$pkgdir/usr/share/applications/"
+ for res in 16 22 24 32 48 64 128 256 512; do
+ install -Dm644 Icons/spotify-linux-$res.png "$pkgdir/usr/share/icons/hicolor/${res}x${res}/apps/spotify-client.png"
+ done
+ install -Dm644 licenses.xhtml -t "$pkgdir/usr/share/licenses/$pkgname/"
}
diff --git a/spotify-legacy.install b/spotify-legacy.install
deleted file mode 100644
index c75d498b95c2..000000000000
--- a/spotify-legacy.install
+++ /dev/null
@@ -1,52 +0,0 @@
-post_install()
-{
- echo -e "\nInstalling Spotify..."
-
- mv /tmp/spotify-stable /opt/spotify
- chown -R root.root /opt/spotify
- ln -s /opt/spotify/spotify-client/spotify /usr/bin/spotify
-
- echo "Installing Spotify icons..."
-
- xdg-icon-resource install --size 16 /opt/spotify/spotify-client/Icons/spotify-linux-16.png "spotify-client"
- xdg-icon-resource install --size 22 /opt/spotify/spotify-client/Icons/spotify-linux-22.png "spotify-client"
- xdg-icon-resource install --size 24 /opt/spotify/spotify-client/Icons/spotify-linux-24.png "spotify-client"
- xdg-icon-resource install --size 32 /opt/spotify/spotify-client/Icons/spotify-linux-32.png "spotify-client"
- xdg-icon-resource install --size 48 /opt/spotify/spotify-client/Icons/spotify-linux-48.png "spotify-client"
- xdg-icon-resource install --size 64 /opt/spotify/spotify-client/Icons/spotify-linux-64.png "spotify-client"
- xdg-icon-resource install --size 128 /opt/spotify/spotify-client/Icons/spotify-linux-128.png "spotify-client"
- xdg-icon-resource install --size 256 /opt/spotify/spotify-client/Icons/spotify-linux-256.png "spotify-client"
- xdg-icon-resource install --size 512 /opt/spotify/spotify-client/Icons/spotify-linux-512.png "spotify-client"
-
- echo "Adding Spotify to applications menu..."
-
- cp -p /opt/spotify/spotify-client/spotify.desktop /usr/share/applications/
-
- echo "Adding license URL to /usr/share/licenses/spotify-stable/LICENSE..."
-
- mkdir -p /usr/share/licenses/spotify-stable
- echo "https://www.spotify.com/legal/end-user-agreement/" > /usr/share/licenses/spotify-stable/LICENSE
-
- echo -e "Spotify installed!\n"
-}
-
-pre_remove()
-{
- echo -e "\nUninstalling Spotify..."
-
- xdg-icon-resource uninstall --size 16 /opt/spotify/spotify-client/Icons/spotify-linux-16.png "spotify-client"
- xdg-icon-resource uninstall --size 22 /opt/spotify/spotify-client/Icons/spotify-linux-22.png "spotify-client"
- xdg-icon-resource uninstall --size 24 /opt/spotify/spotify-client/Icons/spotify-linux-24.png "spotify-client"
- xdg-icon-resource uninstall --size 32 /opt/spotify/spotify-client/Icons/spotify-linux-32.png "spotify-client"
- xdg-icon-resource uninstall --size 48 /opt/spotify/spotify-client/Icons/spotify-linux-48.png "spotify-client"
- xdg-icon-resource uninstall --size 64 /opt/spotify/spotify-client/Icons/spotify-linux-64.png "spotify-client"
- xdg-icon-resource uninstall --size 128 /opt/spotify/spotify-client/Icons/spotify-linux-128.png "spotify-client"
- xdg-icon-resource uninstall --size 256 /opt/spotify/spotify-client/Icons/spotify-linux-256.png "spotify-client"
- xdg-icon-resource uninstall --size 512 /opt/spotify/spotify-client/Icons/spotify-linux-512.png "spotify-client"
-
- rm -f /usr/share/applications/spotify.desktop
- rm -f /usr/bin/spotify
- rm -rf /opt/spotify
-
- echo -e "Spotify uninstalled!\n"
-}