Score:0

Haruna video player (snap) not working - libmsrpc3.so.0 error

br flag

I wanted to try the latest Haruna player (0.10.3), but it is not available as apt installation (that is 0.9.3), and after installing the snap version I get this:

env BAMF_DESKTOP_FILE_HINT=/var/lib/snapd/desktop/applications/haruna_haruna.desktop /snap/bin/haruna %u /snap/haruna/11/usr/bin/haruna: error while loading shared libraries: libmsrpc3.so.0: cannot open shared object file: No such file or directory

I read here that I could try sudo apt-get install --reinstall samba-libs, but that didn't work.


Note after accepting answer:

  • the intended version 0.10 was not available on snapstore, but only on flathub; the flatpak version 0.10 is not affected by this problem;
  • the accepted answer refers to the only snap version available at the moment of the question (0.9), the one affected by the problem
David avatar
cn flag
Do you know for sure this version of the app works with what ever version of Ubuntu you are using? It reads like it does not.
br flag
@David - Indeed now I see that the snapstore has 0.9.1, unlike what I thought. I don't need the snap anyway then, it provides the same version as Ubuntu repos.
br flag
@David - As said, in fact version 0.10 is not available on snapstore (0.9 is but broken). But what do you mean that a snap app could not be working with a certain Ubuntu version? Aren't snap and flatpak meant to avoid this problem in the first place? I have never seen a snap defined as Linux-version specific. If snap/snapd itself is installable, then all snaps should work. Isn't that so? - And by the way: 0.10 is available on flathub, just like 0.9 is from apt/Ubuntu repos, and both work on ubuntu 22.10. The one that doesn't (0.9 snap) is broken anyway.
Score:1
pl flag

Confirmed the snapped application is broken. The "missing" library is indeed shipped in the snap, but it's not somewhere in a path that the application will look in.

$ ls -l /snap/haruna/current/usr/lib/x86_64-linux-gnu/samba/libmsrpc3.so.0 
-rw-r--r-- 1 root root 145712 Jul 18  2022 /snap/haruna/current/usr/lib/x86_64-linux-gnu/samba/libmsrpc3.so.0

The publisher needs to modify the LD_LIBRARY_PATH in the environment section of their snapcraft.yaml to something like this:

LD_LIBRARY_PATH: $LD_LIBRARY_PATH:$SNAP/usr/lib/$SNAPCRAFT_ARCH_TRIPLET/:$SNAP/usr/lib/$SNAPCRAFT_ARCH_TRIPLET/samba/

Alternatively, as a workaround, you can fix it locally, temporarily.

Download the snap

$ mkdir ~/harunatemp
$ cd ~/harunatemp
$ snap download haruna --candidate
Fetching snap "haruna"
Fetching assertions for "haruna"
Install the snap with:
   snap ack haruna_11.assert
   snap install haruna_11.snap

Unpack the snap

$ unsquashfs haruna_11.snap
Parallel unsquashfs: Using 16 processors
2267 inodes (4522 blocks) to write

[===========================|] 6789/6789 100%

created 1971 files
created 280 directories
created 280 symlinks
created 0 devices
created 0 fifos
created 0 sockets
created 16 hardlinks

Modify the snap

I use nano but you could use whatever text editor you like.

$ nano ~/harunasnap/squashfs-root/meta/snap.yaml

Change this line:

LD_LIBRARY_PATH: $LD_LIBRARY_PATH:$SNAP/usr/lib/x86_64-linux-gnu/

To this:

LD_LIBRARY_PATH: $LD_LIBRARY_PATH:$SNAP/usr/lib/$SNAPCRAFT_ARCH_TRIPLET/:$SNAP/usr/lib/x86_64-linux-gnu/samba/

Note: Be careful to preserve the indentation, yaml is picky.

The CTRL+X to save.

Repack the snap

$ snap pack squashfs-root
built: haruna_0.9.1_amd64.snap

Install the snap

$snap install ./haruna_0.9.1_amd64.snap --dangerous
haruna 0.9.1 installed

Run the snap

$ snap run haruna

Great success!

Haruna screenshot

Although this doesn't give you the version you want, it hopefully explains to you or anyone else how to bodge fix a snap :D

br flag
Now I've realized that the latest version is not available in snapstore, just flathub.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.