When trying to load Node-RED snap from beta channel (673) to Pi3 (arm7) I get the following in the logs
2021-02-12T21:01:03Z node-red.node-red[4841]: ERROR: ld.so: object '/usr/lib/arm-linux-gnueabihf/libarmmem-${PLATFORM}.so' from /etc/ld.so.preload cannot be preloaded (cannot open shared object file): ignored.
2021-02-12T21:01:03Z node-red.node-red[4841]: /snap/node-red/673/bin/node: error while loading shared libraries: libatomic.so.1: cannot open shared object file: No such file or directory
I can see files called libarmmem-v6l.so and libarmmem-v7l.so in that directory -so where / why isn’t the PLATFORM getting substituted correctly ?
this looks suspiciously like this snap was built in an unclean environment on something like raspiOS, libarmmem is a piOS hack to preload certain functions that library (or any calls to it) should not be inside the snap at all.
EDIT: OOPS, forgot to answer the actual question, libatomic is in the libatomic1 package which should be added to the stage-packages … (perhaps that snapcraft.yaml gives a few more ideas )
section - but yes adding it to stage-packages does seem to fix it…
(well it fixes it up to the point where there is another issue re file permissions - that is being sorted in snapd 29.1…)
are you by chance actually just running the snap on a raspiOS install ?
IIRC they add an awful hack to forcefully LD_PRELOAD the lib systemwide to each and every executed binary … you’d have to fix it in the OS (somewhere in /etc/ld.so.preload) itself … there is nothing you could do on the snap side …
(note: you will likely see it for all snaps you execute if i’m correct)