Help - Desktop (Linux, Mac and Windows)

Showing results for 
Search instead for 
Do you mean 
Reply
Label Star
leamas
Posts: 223
Registered: ‎06-11-2012
I'm a Community Rock Star
Accepted Solution

[Linux] Fedora RPM package for F17-F19

[ Edited ]

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.

Label Star
leamas
Posts: 223
Registered: ‎06-11-2012
I'm a Community Rock Star

Re: Fedora RPM package for F17-F18

[ Edited ]

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.

 

Label Star
leamas
Posts: 223
Registered: ‎06-11-2012
I'm a Community Rock Star

Re: Fedora RPM package for F17-F18

[ Edited ]

On F-18, you also need

# yum install libpng12 GConf2

 

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

Festival Fanatic
effbiai
Posts: 8
Registered: ‎19-11-2012

Re: Fedora RPM package for F17-F18

Hi,

 

Could you post your ~/.rpmmacros ?

Label Star
leamas
Posts: 223
Registered: ‎06-11-2012
I'm a Community Rock Star

Re: Fedora RPM package for F17-F18

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

 

 

 

Festival Fanatic
effbiai
Posts: 8
Registered: ‎19-11-2012

Re: Fedora RPM package for F17-F18

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?

Label Star
leamas
Posts: 223
Registered: ‎06-11-2012
I'm a Community Rock Star

Re: Fedora RPM package for F17-F18

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

Label Star
leamas
Posts: 223
Registered: ‎06-11-2012
I'm a Community Rock Star

Re: Fedora RPM package for F17-F18

[ Edited ]

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

Festival Fanatic
effbiai
Posts: 8
Registered: ‎19-11-2012

Re: Fedora RPM package for F17-F18

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)

 

Festival Fanatic
effbiai
Posts: 8
Registered: ‎19-11-2012

Re: Fedora RPM package for F17-F18

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

Please test and update spec file.

Announcements
Happy Halloween


Want to be a Rock Star?
Read about our Rock Star Program.

Did you know?


More

Please bear in mind that the Community is not an official Spotify support service. It's a place where we all help each other, whether we work for Spotify or not. So please use your discretion when using the forum.