Error while loading shared libraries Golang app

Well I was going to give up and then saw that post about extensions. It’s close to working now but not 100%.

The app now opens briefly and crashes (I’m guessing because of audio).
After looking at the mentioned extensions link, my yaml now looks like this:


---
name: myapp
license: GPL-3.0+
version: git
summary: my summary
icon: snap/gui/logo.png
description:  some description
confinement: devmode
base: core18
parts:
  myapp:
plugin: go
go-importpath: github.com/myname/myapp
source: .
source-type: git
build-packages:
  - gcc
  - make
  - libsdl1.2-dev
  - libpng-dev
  - libsdl-net1.2-dev
  - libc6-dev
  - libgl1-mesa-dev
  - libxcursor-dev
  - libxi-dev
  - libxinerama-dev
  - libxrandr-dev
  - libxxf86vm-dev
  - pkg-config
stage-packages:
  - libasound2-dev
  - libgl1
  - libglvnd0
  - libglx0
  - libx11-6
  - libxau6
  - libxcb1
  - libxdmcp6
  - libglib2.0-bin
  - mesa-utils
  - libgl1-mesa-glx
  - libgl1-mesa-dri
  - libglu1-mesa
  - libgles2-mesa
  - libflac8
  - libxcursor1
  - libxi6
  - libxinerama1
  - libxrandr2
  - libxrender1
  - libasound2
  - libasyncns0
  - libogg0
  - libpulse0
  - libsndfile1
  - libtheora0
  - libvorbis0a
  - libvorbisenc2
  - libvorbisfile3
  - libwebp6
apps:
  myapp:
    extensions: [gnome-3-28]
    command: bin/myapp
    plugs:
      - audio-playback
      - desktop
      - desktop-legacy
      - home
      - x11
      - unity7
      - browser-support
      - network
      - gsettings
      - pulseaudio
      - alsa
      - opengl
...

I now get this when the app crashes:

ALSA lib conf.c:3916:(snd_config_update_r) Cannot access file /usr/share/alsa/alsa.conf
ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM default

And inside of my logs:

2020/10/02 17:31:22 oto: ALSA error: No such file or directory

I found this link Cannot access file /usr/share/alsa/alsa.conf if not using --devmode flag but I’m not sure if it is applicable. I’m running with --devmode and I “think” that I have the appropriate extensions.