Snapping imv image viewer for Ubuntu Core

I am trying to get imv running on Ubuntu Core with mir-kiosk.

The non daemon version (the imv part in the apps segment below) works fine on my standard Ubuntu 20.04 desktop computer but running imv-kiosk on the Raspberry Pi segfaults.

It doesn’t work on my Ubuntu Core 18 (Raspberry Pi 3) system with the edge version of mir-kiosk installed. Not the imv-kiosk command, nor the daemon one form the snapcraft.yaml below.

name: imv-kiosk
adopt-info: imv
summary: TODO
description: TODO
base: core18
grade: stable
confinement: strict

      - bin/run-daemon
      - bin/wayland-launch
    command: usr/bin/imv -f -t 5 -r /var/snap/imv-kiosk/common/images/
    extensions: [gnome-3-28]
    daemon: simple
    restart-condition: always

      - bin/wayland-launch
    command: usr/bin/imv -f -t 5 -r /var/snap/imv-kiosk/common/images/
    extensions: [gnome-3-28]

    source-tag: "v4.1.0"
    source-type: git
    source-depth: 1
    plugin: make
    override-build: |
      VER="$(git tag|tail -1)"
      echo "setting version to $VER"
      snapcraftctl set-version $VER
      snapcraftctl build
      - asciidoc
      - docbook-xsl
      - libcmocka-dev
      - libegl1-mesa-dev
      - libfontconfig1-dev
      - libfreeimage-dev
      - libglu1-mesa-dev
      - libinih-dev
      - libpango1.0-dev
      - librsvg2-dev
      - libwayland-dev
      - libxkbcommon-x11-dev
      - xsltproc
      - libcroco3
      - libegl1
      - libfreeimage3
      - libgdk-pixbuf2.0-0
      - libglu1-mesa
      - libgomp1
      - libicu60
      - libilmbase12
      - libjxr0
      - libopenexr22
      - libopenjp2-7
      - libpangocairo-1.0-0
      - libraw16
      - librsvg2-2
      - libwayland-client0
      - libwayland-egl1
      - libwebpmux3
      - libxcb-xkb1
      - libxkbcommon-x11-0
      - libxml2

    plugin: dump
    override-build: $SNAPCRAFT_PART_BUILD/ opengl pulseaudio wayland
      - inotify-tools

The log output after installing or restarting the imv-kiosk snap:

systemd[1]: Started Service for snap application imv-kiosk.daemon.
imv-kiosk.daemon[4046]: + snapctl get daemon
imv-kiosk.daemon[4046]: + [ true = true ]
imv-kiosk.daemon[4046]: + exec /snap/imv-kiosk/41/bin/wayland-launch /snap/imv-kiosk/41/usr/bin/imv -f -t 5 -r /var/snap/imv-kiosk/common/images/
imv-kiosk.daemon[4046]: + snapctl is-connected wayland
imv-kiosk.daemon[4046]: + dirname /run/user/0/snap.imv-kiosk
imv-kiosk.daemon[4046]: + real_xdg_runtime_dir=/run/user/0
imv-kiosk.daemon[4046]: + real_wayland=/run/user/0/wayland-0
imv-kiosk.daemon[4046]: + [ ! -O /run/user/0/wayland-0 ]
imv-kiosk.daemon[4046]: + mkdir -p /run/user/0/snap.imv-kiosk -m 700
imv-kiosk.daemon[4046]: + ln -sf /run/user/0/wayland-0 /run/user/0/snap.imv-kiosk
imv-kiosk.daemon[4046]: + ln -sf /run/user/0/wayland-0.lock /run/user/0/snap.imv-kiosk
imv-kiosk.daemon[4046]: + unset DISPLAY
imv-kiosk.daemon[4046]: + exec /snap/imv-kiosk/41/usr/bin/imv -f -t 5 -r /var/snap/imv-kiosk/common/images/
systemd[1]: snap.imv-kiosk.daemon.service: Main process exited, code=killed, status=11/SEGV
systemd[1]: snap.imv-kiosk.daemon.service: Failed with result 'signal'.
systemd[1]: snap.imv-kiosk.daemon.service: Service hold-off time over, scheduling restart.
systemd[1]: snap.imv-kiosk.daemon.service: Scheduled restart job, restart counter is at 1.
systemd[1]: Stopped Service for snap application imv-kiosk.daemon.

Any ideas?

Thanks to ogra for his help with snapping imv!

try this:

source is at:

1 Like

@ogra This is awesome! Compared to the hours I tried making this work you make it look too simple. :wink: I can confirm it runs perfectly fine with mir-kiosk (candidate) on a Raspberry Pi BTW.

Is there a way I can buy you a (virtual) coffee to say thanks?