Home of the Squeezebox™ & Transporter® network music players.
Results 1 to 7 of 7
  1. #1

    Squeezlite on Alpine Linux

    I tested squeezelite on Alpine Linux tonight on my Pi3 B+. Working good via HDMI audio to my Denon A/V receiver.

    I've only got a few hours of experience with Alpine Linux but so far I'm really impressed. It has similarities with piCore Linux in that it runs entirely in RAM by default (though you can change that) and it uses a utility called "lbu" to store user changes in a tar.gz file that gets overlayed into ram on each reboot, similar to piCore's filetool.sh script. One major difference is that Alpine actually seems to be maintained :/

    Code:
    4.14.89-0-rpi2 #1-Alpine SMP Tue Dec 18 17:49:49 UTC 2018 armv7l Linux
    The only thing not in the Alpine Linux repos was squeezelite itself. I built it on the Pi using Alpine's "alpine-sdk" package. I did have to make one modification to the output_alsa.c file in the squeezelite source code in order to get the build to complete successfully, I found the solution here:

    http://lists.busybox.net/pipermail/b...ry/152227.html

    Basically, use mallopt only with GLIBC (Alpine uses musl libc):

    Code:
    #ifdef __GLIBC__
      mallopt(M_TRIM_THRESHOLD, -1);
      mallopt(M_MMAP_MAX, 0);
    #endif
    I didn't really need to take a lot of notes, but here's a list of the packages I installed to build squeezelite:

    Code:
    alpine-sdk
    flac-dev
    alsa-lib-dev
    faad2-dev
    mpg123-dev
    libvorbis-dev
    libmad-dev
    Last edited by sodface; 2019-01-10 at 20:21.

  2. #2
    Senior Member ralphy's Avatar
    Join Date
    Jan 2006
    Location
    Canada
    Posts
    2,232
    I've applied the musl glibc patch to squeezelite.

    Thanks.
    Ralphy

    1-Touch, 5-Classics, 3-Booms, 1-UE Radio
    Squeezebox client builds donations always appreciated.

  3. #3
    1130 builds fine, thanks.

  4. #4
    If anyone is interested in rolling your own pi based squeezelite player using Alpine Linux, I've worked on a couple of things that may be of some help. First is a wiki write up for installation of the OS image on the pi zero w:

    https://wiki.alpinelinux.org/wiki/Ra...-_Installation

    It's not especially well written and it's based on notes I was taking for getting my temperature sensor project ported over to Alpine from PiCore so you probably want to skip some (all?) of the steps marked as being "optional". You might be asking why a guide would be needed - don't you just unpack the download to an SD card and boot? Yes, but there is a "setup-alpine" script that walks you through basic setup, incuding connecting to wifi, and the wifi bit didn't work for me, which is problematic on the pi zero w. Enabling the hardware random number generator with the rngd-tools packages (not part of the base OS file set) fixed that as well as any issues with wifi reconnecting at boot time. It's not immediately obvious to me how to download packages with anything other than Alpine's apk package management tool. I already had an alpine chroot build environment setup on my Fedora laptop so it wasn't a big deal for me to get the needed packages. I'm not sure how to get them outside of a working Alpine instance. I can provide if anyone needs them.

    Also, I put together an aport to build squeezelite into three packages, squeezelite itself, an openrc init script package, and a doc package. I submitted it to the mailing list to be added to the repos but I haven't had any feedback on it:

    http://lists.alpinelinux.org/alpine-aports/6326.html

    In the meantime, if anyone would like the packages let me know, I have them built for both armhf and armv7. Earlier versions of the armhf OS (3.8.2) ran on the raspberry pi 3 B+ but the latest Alpine downloads (3.9.2 as of this post) appear to remove support for the pi 3 from the armhf version, so I needed both package sets, armhf for my zero w and armv7 for my pi 3 (I upgraded to Alpine 3.9.2 on both pi's).
    Last edited by sodface; 2019-03-21 at 04:13.

  5. #5
    Quote Originally Posted by sodface View Post
    Also, I put together an aport to build squeezelite into three packages, squeezelite itself, an openrc init script package, and a doc package. I submitted it to the mailing list to be added to the repos but I haven't had any feedback on it:

    http://lists.alpinelinux.org/alpine-aports/6326.html

    In the meantime, if anyone would like the packages let me know, I have them built for both armhf and armv7. Earlier versions of the armhf OS (3.8.2) ran on the raspberry pi 3 B+ but the latest Alpine downloads (3.9.2 as of this post) appear to remove support for the pi 3 from the armhf version, so I needed both package sets, armhf for my zero w and armv7 for my pi 3 (I upgraded to Alpine 3.9.2 on both pi's).
    Nice work. Alpine has recently gone through changes and their PR process has been streamlined to use git pull requests. May I suggest you resubmit it using github?

    Cheers!

  6. #6
    Junior Member
    Join Date
    Mar 2017
    Posts
    25
    Quote Originally Posted by sodface View Post
    If anyone is interested in rolling your own pi based squeezelite player using Alpine Linux, I've worked on a couple of things that may be of some help. First is a wiki write up for installation of the OS image on the pi zero w:
    Hi. Is it possible to make a extra packages from this git.

    This squeezelite has a GUI to Controll LCDs.

    Regards droidbox

  7. #7
    I'm not sure that I'll be able to create an APKBUILD that would be accepted by the distro for inclusion into the official repos, I'll probably try again but I suspect the lack of a versioned squeezelite "release" package would probably get it rejected? There's probably also some packaging/formatting guidelines I'm not following exactly, not sure.

    In the meantime I thought I'd post the patch to modify the aports tree locally so you can build it yourself if you want. I did this back when I first posted this thread and then did it again this week for the new versions of Alpine and squeezelite that have been released since.

    You'll want to put the diff file in the root of your local aports repo and then apply the patch:
    Code:
    git apply squeezelite.diff
    See this Alpine wiki article on Creating an Alpine Package.

    You'll probably need to edit the apkbuild file located at aports/testing/squeezelite/ and change version numbers etc. as needed. If the build is successful you should get three packages in your home directory:
    Code:
    packages
        └── testing
            └── armhf
                ├── APKINDEX.tar.gz
                ├── squeezelite-1.9.6.1198-r0.apk
                ├── squeezelite-doc-1.9.6.1198-r0.apk
                └── squeezelite-openrc-1.9.6.1198-r0.apk
    Attached Files Attached Files
    Last edited by sodface; 2019-12-07 at 08:23.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •