snapcraft 2.27 has been released

Alberto Mardegan alberto.mardegan at canonical.com
Fri Feb 17 14:33:56 UTC 2017


On 17/02/2017 16:56, Sergio Schvezov wrote:
>> file. I simply copied your example above, with 2.27 on Xenial.
>> Am I looking in the wrong place?
> 
> That is not where they should end up, they end up in meta/snap.yaml and snapd takes care of the rest.

OK, thanks. Still, if I add this line:

============
apps:
  CloudCompare:
    command: launch CloudCompare
    environment:
      LD_LIBRARY_PATH: $SNAP/lib/cloudcompare:$LD_LIBRARY_PATH
    plugs: [home, x11, mir, opengl, unity7]
============

Then I get this when starting the app (and I didn't get it before):

/snap/cloudcompare-mardy/x5/command-CloudCompare.wrapper: 6: export:
:/snap/cloudcompare-mardy/x5/lib:/snap/cloudcompare-mardy/x5/usr/lib:/snap/cloudcompare-mardy/x5/lib/x86_64-linux-gnu:/snap/cloudcompare-mardy/x5/usr/lib/x86_64-linux-gnu:
bad variable name

This is weird, because the wrapper itself seems rather harmless:
=============
#!/bin/sh
export PATH="$SNAP/usr/sbin:$SNAP/usr/bin:$SNAP/sbin:$SNAP/bin:$PATH"
export
LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$SNAP/lib:$SNAP/usr/lib:$SNAP/lib/x86_64-linux-gnu:$SNAP/usr/lib/x86_64-linux-gnu"
export
LD_LIBRARY_PATH="$SNAP/usr/lib/x86_64-linux-gnu/mesa:$SNAP/usr/lib/x86_64-linux-gnu/mesa-egl:$LD_LIBRARY_PATH"
export
LD_LIBRARY_PATH="$SNAP/usr/lib/x86_64-linux-gnu:$SNAP/usr/lib/x86_64-linux-gnu/mesa:$SNAP/usr/lib/x86_64-linux-gnu/mesa-egl:$LD_LIBRARY_PATH"
export LD_LIBRARY_PATH=$SNAP_LIBRARY_PATH:$LD_LIBRARY_PATH # line 6
exec "launch" CloudCompare "$@"
=============

I get the same error if I try to start the script from a "snap run
--shell <snap name>" console, but the error goes away if I run it as

  $ bash command-CloudCompare.wrapper

(note the usage of "bash" vs "sh")

Any idea on what's happening here?

Ciao,
  Alberto




More information about the Snapcraft-announce mailing list