I have one big question in regards of snaps. Is it sharing libraries? The reason why I ask is because that was one of the things that I was so impressed by when starting with ubuntu, that it was sharing libraries, and therefore saves space on the disk. Does snaps still do this? or am I totally wrong about apt?
There is no guarantee with either snaps nor apt/dpkg, that the app you are using, is relying on system-wide shared libraries, for every dependency they have.
Depending on how a snap is built, it may be using some libraries shared with other snaps (the core snap includes a libc and libstdc++ for example), but neither direction is as simple as it might seem, when it comes down to stability, security, and ensuring users get the latest features in apps.
For the current state of my system:
This command will answer your question for MY system, at this time:
Use
find
to find all the "executable" files under/snap
.Ask
file
- are the files scripts or execuables or what?We only care about "ELF" files, as they're the ones using shared libraries.
file
outputs the filename, a colon, some blanks and the description. All I want is the filename.Then I use
xargs
to feed the filenames, one at a time (-n 1
) toldd
to list the dynamic libraries used by each ELF executable.Are any of the libraries in
/snap
?Nothings I see (other than "what if the other, library-containing snap isn't installed?") prevents it,