This version of my snapcraft.yaml snaps and runs fine when built in a 16.04 LXD container: https://github.com/jsseidel/jgalaxian/blob/master/snap/snapcraft.yaml
Today, I wanted to add a simple feature and decided to take the opportunity to try and get it building in my local bionic environment (
snap install snapcraft --classic,
snap install --beta multipass --classic). I therefore added
base: core18 to snapcraft.yaml.
The build worked, but I had no pulseaudio sound. I searched the forum and discovered that I might need to add ‘libpulse0’ to my staged-packages. Still no sound (and no errors). I tried adding a desktop environment so that I could launch it with desktop-launch, in the unlikely event I needed a codec from gstreamer or something. Still no sound (and no errors).
I then removed
base: core18 and tried building in my 18.04 environment. It fails. Here’s a bit of relevant output:
Priming jgalaxian The linker version '2.23' used by the base 'core' is incompatible with files in this snap: /home/jsseidel/PersonalWorkspace/git/jgalaxian/prime/lib/x86_64-linux-gnu/libbsd.so.0.8.7 (2.25)
I had assumed that removing
base: core18 would make snapcraft build in a 16.04 multipass VM. This is obviously not what happens, so fine. But can you see why this is confusing? When I have
base: core18 specified, snapcraft builds in a multipass VM even tho I’m running snapcraft in bionic. When I remove that, presumably to enable a 16.04 core, snapcraft tries to link against newer bionic libraries (I guess). I’ve probably made a bad assumption here (or, more likely, several bad assumptions).
So 2 questions:
What do I need to get pulseaudio sound working in core18?
Why doesn’t the build work at all when running snapcraft in a bionic enviroment without core18 specified in snapcraft.yaml?
Thanks as always for the info!