Try remove leading /, or even /usr/bin/ from command:. It just tries run executable from root filesystem, not from snap.
From snapcraft.yaml reference:
The command can be in either a snap runtime’s command path, $SNAP/usr/sbin:$SNAP/usr/bin:$SNAP/sbin:$SNAP/bin , or an executable path relative to $SNAP.
You’re running install-dependencies.sh which runs apt to install the packages that the application uses. This should be removed and replaced with build-packages and stage-packages within the snapcraft.yaml, because the snap won’t include any of the files from the relevant packages when installing dependencies with your script.
You can find the packages for each of the build-packages and stage-packages within your repo in the files dependencies-debian-compilation.txt and dependencies-debian-runtime.txt respectively. The entries in the snapcraft.yaml need to be just the package names, without version information, so you can’t simply copy and paste those files into the yaml.
Fair enough, I thought I would be wiser using their script, that way if they add a dependency the next time I pull from the git it would automatically get it.
If I put all the packages in build and stage, what do I do if there are duplicates? Build doesn’t automatically get put in stage right?
Also, if I have two parts requiring the same stage dependencies, do I need both parts to call it out, or is one mention enough for the whole snap?
If a package is used for building and for runtime then it needs to be specified in both lists - the build-packages are installed to the build machine so that you can compile against them, they aren’t copied into the snap. The stage packages are only installed into the snap for runtime use, so can’t be used for building against.
If you have shared dependencies between parts, you can specify the same package in both parts, or you can make sure one part runs after the other and ensure you specify the build-package in the first part, or you can pull out the packages to a third part that just defines the packages with plugin: nil so that it only installs the packages and the make both your original parts run after the dependencies part.