Announcements
The Spotify Stars Program: Celebrating Values Week!

Help Wizard

Step 1

NEXT STEP

[Linux] Fedora RPM package for F17-F19

Solved!

[Linux] Fedora RPM package for F17-F19

Current method to install the spotify rpm is based on the rpmfusion lpf-spotify-client package. Basically, this automates the process of downloading, building and installing a spotity rpm based on the official Debian packages.

 

EDIT: Bug reported (page 19), temporary work-around published.

 

EDIT: New solution based on the rpmfusion lpf-spotify-client package. Old  method deprecated but still available.

 

EDIT: updated for new upstream release: 0.9.4.183.g644e24e.428-2

 

EDIT: Solution updated for 0.9.1.55.

 

EDIT: Downgrading procedure to 0.8.4 published

 

EDIT: Update header to include F19

 

EDIT: Solution updated for 0.9.0.133

 

EDIT: updating link

 

EDIT: new solution for 0.8.8 published.

Reply

Accepted Solutions
Marked as solution

There is now a new, simpler method based on a rpmfusion package. To use this, you must first enable the rpmfusion repository[1] if you haven't done this already:

# sudo yum localinstall --nogpgcheck   http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm

 After that, the simple procedure is

# yum install lpf-spotify-client
$ lpf update

 This will guide you through the process of downloading, building and installing the spotify rpm through some GUI dialogs (screenshots at [2]). If you want a pure command line  operation without any GUI dialogs use

$ DISPLAY= lpf update

This method is based on the brand new lpf framework[2]. Expect bugs. If you find one, please report it at the lpf upstream [2] or in the regular rpmfusion bugzilla [3]. There is  lpf -h and man lpf with more info on lpf.

 

As a temporary work-around to fix local playback of files do:

# yum install ffmpeg-compat

 

 

[1] http://rpmfusion.org/

[2] https://github.com/leamas/lpf

[3] https://bugzilla.rpmfusion.org

 

EDIT Updated for now rpmfusion package lpf-spotify-client. Deprecating old method, changing EDIT list to latest first.

 

EDIT: Updated for new  release: 0.9.4.183.g644e24e.428-2. Same procedure and links.

 

EDIT: Making specfile available through a generic 'latest' version - these instructions are copy-pasted all over the net and will otherwise not work as soon there is an update.

 

EDIT: Updated for 0.9.1.55. This time the old 0.9.0 are still present in the download repo. Still, keep the old rpms around if you want to downgrade. As traditional, no real testing done beyond that it starts and plays me a song.

 

EDIT: Downgrading procedure to 0.8.4 added

 

EDIT: Updated for 0.9.0.133. Once again the old version is gone, keep your old rpms so you can downgrade if needed!

 


 

The old, deprecated method still works:

# yum install wget rpmdevtools rpm-build yum-utils
$ rpmdev-setuptree
$ cd $(rpm --eval %_sourcedir)
$ wget http://leamas.fedorapeople.org/spotify/latest/spotify-client.spec
$ spectool -g spotify-client.spec
# yum-builddep spotify-client.spec
$ env QA_RPATHS=$((0x10|0x08)) rpmbuild -bb spotify-client.spec

  This will consume some time, CPU-cycles, hard-disk space and also produce a lot of output. In the end you will find a line like (but not the same!):

Wrote:  /home/leamas/rpmbuild/RPMS/i686/spotify-client-0.9.4.183.g644e24e.428-2.fc19.i686.rpm

  Here you have a RPM file you can install, in my case by doing:

# yum install \
/home/leamas/rpmbuild/RPMS/i686/spotify-client-0.9.4.183.g644e24e.428-2.fc19.i686.rpm

 Again, your case is similar but not the same 🙂

View solution in original post

Marked as solution

I have updated the spec to release 3. Same instructions and links. Changes:

  • Install desktop icons properly.
  • Wipe ~/.cache/spotify first run w this version

View solution in original post

Marked as solution

Simply speaking I haven't the faintest idea of what you are hitting... Some basic questions:

  • What are you running on (F17, F18..., i386/x86_64)?
  • Can you run other players such as rhythmbox and vlc?
  • Is your user member of the 'audio' group?

EDIT: Also, after running as root you might run into problems with the ~/.cache/spotify and ~/.config/spotify directories. Remove them (as root) before running as regular user.

View solution in original post

Marked as solution

Lovely. Got it working thanks.

I perhaps should have mentioned that I did have Spotify (0.8.8) working just fine under Fedora 17, then I used FedUp to get from F17->F19 and, as Spotify no longer worked, updated Spotify to the current release too.

 

Anyway, following your advice I uninstalled Spotify, deleted the intermediate files, made sure that my Fedora installation was pukka by doing

   yum --releasever=19 distro-sync --assumeyes

 

...and then ran the Spotify installer script from this thread.

 

This time everything works as it should.

 

Many thanks for your help.

 

View solution in original post

Marked as solution


Jamiroph wrote:

[cut]
+ /usr/bin/rm -rf /home/jsanders/rpmbuild/BUILDROOT/spotify-client-0.9.4.183.g644e24e.428-3.fc19.x86_64

 

[cut]


That does not remove the rpm, just the temporary build directory 🙂 

 

Isn't  /home/jsanders/rpmbuild/RPMS/x86_64/spotify-client-0.9.4.183.g644e24e.428-3.fc19.x86_64.rpm  there?

View solution in original post

Marked as solution


@Vespa wrote:

I was getting the skin.xml error as well. It looks like spotify no longer uses a symbolic link for the data directory in /usr/lib64/spotify-client. So I recreated it manually as a symbolic link:


 

[root@localhost ~]# cp /usr/lib64/spotify-client/Data/SpotifyHelper /usr/share/spotify-client/Data/
[root@localhost ~]# cd /usr/lib64/spotify-client/
[root@localhost spotify-client]# rm -Rf Data
[root@localhost spotify-client]# ln -s ../../share/spotify-client/Data Data

This fixed it, thanks! 

View solution in original post

Marked as solution

This update is, well, less successful.

 

Anyway, I have pushed a new version 0.9.4.183.g644e24e.428-4 which seems to fix at least some of these problems. Same links and procedure.

 

You might run into conflict problems when trying to upgrade. If so, just remove the old package before installing the new. This is an old rpm issue when a directory is replaced with a symlink.

View solution in original post

Marked as solution

As I was fighting with this, I continued looking for solutions and stumbled upon http://negativo17.org/spotify-client/

It worked immediately and IMHO it's a much more straightforward solution.

View solution in original post

Marked as solution

Can confirm.

 

The solution at http://negativo17.org/spotify-client/ worked effortlessly for me on F24 x86_64.

View solution in original post

223 Replies

There's now a review request, and thus also a source rpm.

Review request: https://bugzilla.rpmfusion.org/show_bug.cgi?id=2565

Source rpm: https://dl.dropbox.com/u/17870887/spotify/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.src.rpm

 

EDIT: The source RPM cannot be distributed due to clarified licensing terms. See new instructions below how to build the RPM from the spec file.

 

On F-18, you also need

# yum install libpng12 GConf2

 

EDIT: this is now irrelevant. Use instructions below to build from spec file instead.

Hi,

 

Could you post your ~/.rpmmacros ?

Not really, I have some signing stuff there... but the commands above  works also with the vanilla ~/.rpmmacros  installed by rpmdev-setuptree below. You can just just move your ~/rpmmacros to a backup copy and the run rpmdev-setuptree. This will not change your current configuration, but since it will not find ~/rpmmacros it will generate a new, fresh one which is likely to be better than my version.

 

$ cat ~/.rpmmacros

%_topdir %(echo $HOME)/rpmbuild

%_smp_mflags %( \
    [ -z "$RPM_BUILD_NCPUS" ] \\\
        && RPM_BUILD_NCPUS="`/usr/bin/nproc 2>/dev/null || \\\
                             /usr/bin/getconf _NPROCESSORS_ONLN`"; \\\
    if [ "$RPM_BUILD_NCPUS" -gt 16 ]; then \\\
        echo "-j16"; \\\
    elif [ "$RPM_BUILD_NCPUS" -gt 3 ]; then \\\
        echo "-j$RPM_BUILD_NCPUS"; \\\
    else \\\
        echo "-j3"; \\\
    fi )

%__arch_install_post \
    [ "%{buildarch}" = "noarch" ] || QA_CHECK_RPATHS=1 ; \
    case "${QA_CHECK_RPATHS:-}" in [1yY]*) /usr/lib/rpm/check-rpaths ;; esac \
    /usr/lib/rpm/check-buildroot

 

 

 

Trying to build your src.rpm with the following errors:

rpmbuild --rebuild spotify-client-0.8.4.103.g9cb177b.260-1.fc17.src.rpm
Installing spotify-client-0.8.4.103.g9cb177b.260-1.fc17.src.rpm
warning: user leamas does not exist - using root
warning: group leamas does not exist - using root
warning: user leamas does not exist - using root
warning: group leamas does not exist - using root
warning: user leamas does not exist - using root
warning: group leamas does not exist - using root
warning: user leamas does not exist - using root
warning: group leamas does not exist - using root
warning: user leamas does not exist - using root
warning: group leamas does not exist - using root
warning: user leamas does not exist - using root
warning: group leamas does not exist - using root
warning: user leamas does not exist - using root
warning: group leamas does not exist - using root
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.BII2FE
+ umask 022
+ cd /home/effbiai/rpmbuild/BUILD
+ '[' -d spotify ']'
+ mkdir spotify
+ cd spotify
+ rm -rf '*'
+ ar p /home/effbiai/rpmbuild/SOURCES/spotify-client_0.8.4.103.g9cb177b.260-1_amd64.deb data.tar.gz
+ tar zx
+ cat
+ chmod 755 spotify.sh
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.bkMWqa
+ umask 022
+ cd /home/effbiai/rpmbuild/BUILD
+ chrpath --replace /usr/lib64/spotify-client spotify/usr/share/spotify/spotify
spotify/usr/share/spotify/spotify: RPATH=/usr/share/spotify
spotify/usr/share/spotify/spotify: new RPATH: /usr/lib64/spotify-client
+ exit 0
Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.NVsAfG
+ umask 022
+ cd /home/effbiai/rpmbuild/BUILD
+ cd spotify
+ cp -ar ./usr /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64
+ app_libdir=/home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64/usr/lib64/spotify-client
+ mkdir -p /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64/usr/lib64/spotify-client
+ mv '/home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64/usr/share/spotify/lib*.so*' /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64/usr/lib64/spotify-client
mv: cannot stat '/home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64/usr/share/spotify/lib*.so*': No such file or directory
error: Bad exit status from /var/tmp/rpm-tmp.NVsAfG (%install)


RPM build errors:
    user leamas does not exist - using root
    group leamas does not exist - using root
    user leamas does not exist - using root
    group leamas does not exist - using root
    user leamas does not exist - using root
    group leamas does not exist - using root
    user leamas does not exist - using root
    group leamas does not exist - using root
    user leamas does not exist - using root
    group leamas does not exist - using root
    user leamas does not exist - using root
    group leamas does not exist - using root
    user leamas does not exist - using root
    group leamas does not exist - using root
    Bad exit status from /var/tmp/rpm-tmp.NVsAfG (%install)

 Seems like the "/home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64/usr/share/spotify/lib*.so*" path doesn't exist, which make me thinking about the "cp -ar ./usr /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64" doesnt copy any files.

 

If I do a ls on "/home/effbiai/rpmbuild/BUILD/spotify/usr" there's a lot of files there.

What about moving "mkdir -p /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.x86_64/usr/lib64/spotify-client" to before the copy?

Odd... But since I cannot distribute this source RPM anymore due to licensing concerns, I just preparing new intructions. Hang on...

Due to new licensing information in this post, I cannot re-distribute the spotify client. Although this might change, this is the current situation. Besides that the rpm cannot be part of rpmfusion for these reasons, it also means  modified instructions to build the rpm manually:

# yum install wget rpmdevtools rpm-build yum-utils
$ rpmdev-setuptree
$ cd $(rpm --eval %_sourcedir)
$ wget http://leamas.fedorapeople.org/spotify/spotify-client.spec
$ spectool -g spotify-client.spec
# yum-builddep spotify-client.spec
$ env QA_RPATHS=2 rpmbuild -bb spotify-client.spec

  This will consume some time, CPU-cycles, hard-disk space and also produce a lot of output. In the end you will find a line like (but not the same!):

Wrote: /home/leamas/rpmbuild/RPMS/i686/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.i686.rpm

  Here you have a RPM file you can install, in my case by doing:

# yum install /home/leamas/rpmbuild/RPMS/i686/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.i686.rpm

 Again, your case is similar but not the same 🙂 I might add that this spec file has been revised during the now stalled review process.

 

EDIT: after the 0.8.8 release this doesn't  work any more. I will try to fix this for the new package, and have also asked spotify to publish links to the old 0.8.4 version for some time to bridge the gap until spec is updated. But ATM nothing of this is in place, and the spec doesn't work.

 

EDIT: I have published a new spec for 0.8.8, see page 3

same error;

$ env QA_RPATHS=2 rpmbuild -bb spotify-client.spec
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.hUExjL
+ umask 022
+ cd /home/effbiai/rpmbuild/BUILD
+ '[' -d spotify ']'
+ mkdir spotify
+ cd spotify
+ rm -rf '*'
+ cp -a /home/effbiai/rpmbuild/SOURCES/spotify.sh spotify.sh
+ cp -a /home/effbiai/rpmbuild/SOURCES/spotify.1 spotify.1
+ ar p /home/effbiai/rpmbuild/SOURCES/spotify-client_0.8.4.103.g9cb177b.260-1_amd64.deb data.tar.gz
+ tar zx
+ chmod 755 ./usr/share/spotify/libcef.so
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.4EQWDn
+ umask 022
+ cd /home/effbiai/rpmbuild/BUILD
+ versioned_libs='libnspr4.so.0d libplc4.so.0d libsmime3.so.1d 
          libnssutil3.so.1d libnss3.so.1d'
++ ldd spotify
++ awk '/so[.][0-2][a-f]/ {print $1}'
ldd: ./spotify: not regular file
+ exit 0
Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.Lkr63Z
+ umask 022
+ cd /home/effbiai/rpmbuild/BUILD
+ cd spotify
+ rm ./usr/bin/spotify
+ cp -ar ./usr /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64
+ app_libdir=/home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/lib64/spotify-client
+ install -pd /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/bin /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/share/man/man1 /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/lib64/spotify-client
+ install -pm 755 spotify.sh /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/bin/spotify
+ install -pm 644 spotify.1 /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/share/man/man1
+ mv '/home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/share/spotify/lib*.so*' /home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/lib64/spotify-client
mv: cannot stat '/home/effbiai/rpmbuild/BUILDROOT/spotify-client-0.8.4.103.g9cb177b.260-2.fc18.x86_64/usr/share/spotify/lib*.so*': No such file or directory
error: Bad exit status from /var/tmp/rpm-tmp.Lkr63Z (%install)


RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.Lkr63Z (%install)

 

Fixed with adding "mkdir -p %{buildroot}" on line numer 90, before "cp -ar  ./usr  %{buildroot}".

Please test and update spec file.

Indeed, and this has slipped through my own and my reviewers tests. Thanks for help! New specfile available (same link)), would appreciate if also you tested it.

 

EDIT: Actually, the spec was based on the wrong version, and contained all sorts of errors. They should now be fixed, release 4 is uploaded to same location. Sorry for the mess.

Tested, result; OK.

Please update the first post to include the guide.

This worked for me on fedora 17 (64bit).

Great work, thanks!

Tested on F18 (64bit)... Worked fine.. Thanks...

It works for me on Linux ****** 3.6.10-2.fc17.i686 #1 SMP Tue Dec 11 18:33:15 UTC 2012 i686 i686 i386 GNU/Linux

 

Thank's!

On Fedora 18 (i686) it fails with following message:

 

Not supported architecture: i386

 

Then I tried to manually change this line:

 

ExclusiveArch:  i686 x86_64

 

to

 

ExclusiveArch:  i386 i686 x86_64

 

But then I got following error:

 

Ejecutando(%prep): /bin/sh -e /var/tmp/rpm-tmp.6Vc2cA
+ umask 022
+ cd /root/rpmbuild/BUILD
+ '[' -d spotify ']'
+ cd spotify
+ rm -rf spotify.1 spotify.sh
+ cp -a /root/rpmbuild/SOURCES/spotify.sh spotify.sh
+ cp -a /root/rpmbuild/SOURCES/spotify.1 spotify.1
+ chmod 755 ./usr/share/spotify/libcef.so
chmod: cannot access './usr/share/spotify/libcef.so': No such file or directory

If you make that change, you must also change the %ifarch statements....

 

Indeed, F-18 is using i386 for the architecture instead of previous versions which have been using 1686 for a long time. I'll try toupdate the spec to handle this. Stay tuned...

 

EDIT: I have uploaded release 5 which supposedly solves this issue. Could you please test?

Brilliant! It works perfectly! Thank you very much for your excellent work!


@leamas wrote:

Due to new licensing information in this post, I cannot re-distribute the spotify client. Although this might change, this is the current situation. Besides that the rpm cannot be part of rpmfusion for these reasons, it also means  modified instructions to build the rpm manually:

# yum install wget rpmdevtools rpm-build yum-utils
$ rpmdev-setuptree
$ cd $(rpm --eval %_sourcedir)
$ wget http://leamas.fedorapeople.org/spotify/spotify-client.spec
$ spectool -g spotify-client.spec
# yum-builddep spotify-client.spec
$ env QA_RPATHS=2 rpmbuild -bb spotify-client.spec

  This will consume some time, CPU-cycles, hard-disk space and also produce a lot of output. In the end you will find a line like (but not the same!):

Wrote: /home/leamas/rpmbuild/RPMS/i686/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.i686.rpm

  Here you have a RPM file you can install, in my case by doing:

# yum install /home/leamas/rpmbuild/RPMS/i686/spotify-client-0.8.4.103.g9cb177b.260-1.fc17.i686.rpm

 Again, your case is similar but not the same 🙂 I might add that this spec file has been revised during the now stalled review process.


Followed these instructions on Fedora 17 x64 and it worked like a charm, thanks.

Since the Debian/Ubuntu repo only contains the latest version, the spec file needs to be updated each time a new version is released. The current version, 0.8.8.323.gd143501.250-1 doesn't seem to build with the current spec file, however. Everything seems to be under /opt/spotify/spotify-client/ instead of /usr/share/spotify/. I've tried editing the spec file myself, but haven't got it working, yet.

 

Suggested posts