Created attachment 465778 [details] Tentative librespot ebuild Hi! Please find attached a proposal for librespot-9999.ebuild together with librespot.service and librespot.conf. Librespot seems to be by far the most convenient way to make a raspberry pi play spotify premium. It allows you to remotely control the music playing from the pi using official spotify clients from any platform. Furthermore, it doesn't hog the audio device when music us not playing. In order to build it requires rust >= 1.15 and cargo. This is slightly problematic as currently rust and cargo in portage are not keyworded for arm. I have used rust-bin-1.15.1 from portage (after massaging it to also work for armv7) and cargo-bin-1.15.1 (adapted similarly from the cargo-bin ebuild in the rust overlay). The systemd service file and librespot.conf file are taken from Arch Linux. Bram
Created attachment 465780 [details] systemd service
Created attachment 465782 [details] Template configuration file
Are you interested in maintaining this package at all? https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers
Hey Michael, I am interested in maintaining the librespot package itself. It's just a live e-build for now, there are no releases. So it should not be too much work. The e-build itself requires some more work to also make it suitable for other arm flavours and/or x86/amd64. I would need some help there. However I am a bit concerned about the rust dependencies. For my RPi2 I strongly prefer rust-bin, since it does not require llvm (and rust does). Llvm is a real pain to compile on the RPi2. So basically it seems to be a pre-requisite that there is support for rust-bin and cargo-bin in portage (for arm), together with some virtuals in order to correctly specify dependencies (like in the rust overlay). So it seems there is some ground to cover before this package is ready for inclusion. Bram
I see that upstream also provides rust-bin binaries for arm, but I'm not sure how to handle the hardfloat/softfloat variants in the ebuild - I'll ask around.
I filed bug #611756 with a patch for adding arm support to rust-bin.
Created attachment 524266 [details] Tentative librespot ebuild The original librespot project is dead upstream. There is now a new active fork at https://github.com/librespot-org. The ebuild has been adapted.
Created attachment 524268 [details] systemd service The systemd service file has been adjusted to follow the standard for systemd configuration files on gentoo.
Created attachment 524270 [details] Template configuration file
Created attachment 535240 [details] Tentative librespot ebuild Modified the e-build to depend on virtual/rust and dev-util/cargo from portage.
Created attachment 628118 [details] Ebuild for librespot-0.1.1
Created attachment 628120 [details] systemd service
Created attachment 628122 [details] Template configuration file
Created attachment 628124 [details] Template configuration file
- Compared to the situation of 2017, by now the v0.1.1 ebuild works with all dependencies from portage, tested both on arm and on amd64. - It is based upon a skeleton generated using cargo-ebuild-0.2.0. The only oddity being that, in cargo_src_unpack, I had to work around tar not being able to unpack archives that have timestamps from other platforms. For those, Linux tar seems to unpack them but exits with an error status, which breaks the stock cargo_src_unpack. For some funny reason cargo wants to know about dependencies from other platforms.
Created attachment 685350 [details] Ebuild for librespot-0.1.3 Updated the ebuild to librespot-0.1.3. Tested on a RPi 4.
Created attachment 708141 [details] Updated ebuild for librespot-0.2.0 Tested on arm64
Created attachment 760935 [details] Updated ebuild for librespot-0.3.1. Tested on arm64 using the alsa backend.
For those interested, a new ebuild for librespot-0.4.2 can be found in the menelkir overlay.