My Snap (Elisa music player) won't run due to missing library after building it (though it exists)

Here’s the output:

$ snap run elisa
elisa: error while loading shared libraries: libelisaLib.so.0: cannot open shared object file: No such file or directory
$ find /snap/elisa/ -name libelisaLib.so.0
/snap/elisa/x1/usr/lib/x86_64-linux-gnu/elisa/libelisaLib.so.0

Any idea what went wrong?

Here’s the YAML file.

try to use an environment: entry in your apps: section and extend LD_LIBRARY_PATH with $SNAP/usr/lib/$SNAPCRAFT_ARCH_TRIPLET/elisa your library lives in a subdirectory of the default library path so you need to tell the linker to take a look there.

so it’s

apps:
  elisa:
     environment:

or

apps:
  elisa:
  environment:

Tried both but none worked

It is the former one, can you show us what you tried so that we can help you more?

apps:
  elisa:
    command: kf5-launch elisa
    plugs:
      - kde-frameworks-5-plug
      - desktop
      - desktop-legacy
      - unity7
      - home
      - x11
      - opengl
      - pulseaudio
      - network-bind
      - wayland
    environment: /usr/lib/$SNAPCRAFT_ARCH_TRIPLET/elisa

Here’s the output when I ran it:

root@neon-container:/workspace# snapcraft --destructive-mode
Using 'snapcraft.yaml': Project assets will be searched for from the 'snap' directory.
Issues while validating snapcraft.yaml: The 'apps/elisa/environment' property does not match the required schema: '/usr/lib/$SNAPCRAFT_ARCH_TRIPLET/elisa' is not of type 'object'

Ok, this explains is.

Environment is a mapping from environment variables to values. What others mentioned before is to extend the LD_LIBRARY_PATH. This would look like:

environment:
  LD_LIBRARY_PATH: $LD_LIBRARY_PATH:$SNAP/usr/lib/$SNAP_ARCH_TRIPLET/elisa

Try this please

This time, it crashed. Here’s the output.

Do I add layout:?

No, you debug Cannot mix incompatible Qt library (version 0x50c00) with this library (version 0x50c03) and understand what happened there. I’m sorry but I’m not familiar with Qt.

Figured it out. Took out most of the build & stage packages. Forgot I got kde-frameworks-5 plug.

I now need to force the app to use Breeze Icons because, right now, I got a another icons pack (Suru++) enabled.

1 Like

Is there a way to autoconnect kde-frameworks-5-plug to kde-frameworks-5-slot?

There is the default-provider thing, look at The content interface

EDIT: This is not so much about auto-connecting but getting the viable connection peer installed.