summaryrefslogtreecommitdiff
path: root/branding/templates
diff options
context:
space:
mode:
authorKali Kaneko (leap communications) <kali@leap.se>2019-12-04 17:38:18 +0100
committerKali Kaneko (leap communications) <kali@leap.se>2019-12-05 17:08:29 +0100
commit505f11bff3ce7cd7048c9da1510137e6a6c0e7c5 (patch)
treecf40a9ca34dfb0ece033b83b9142c96398537a4c /branding/templates
parente7323f2e3845a4287096520b5cc8787b32913dd5 (diff)
[pkg] use plugs in snap
with this we can get rid of ugly hack that got gtk environment inside the snap manually, and forced us to stage libc6 into the snap because of linker incompatibility problems. seems whatever problem made me go that way is already solved by snap.
Diffstat (limited to 'branding/templates')
-rw-r--r--branding/templates/snap/snapcraft-template.yaml33
1 files changed, 13 insertions, 20 deletions
diff --git a/branding/templates/snap/snapcraft-template.yaml b/branding/templates/snap/snapcraft-template.yaml
index 26a3ae5..4b97e93 100644
--- a/branding/templates/snap/snapcraft-template.yaml
+++ b/branding/templates/snap/snapcraft-template.yaml
@@ -7,25 +7,11 @@ description: |
any way. The service is paid for entirely by donations from users like you.
grade: stable
confinement: classic
-icon: snap/gui/icon.svg
+icon: icon.svg
base: core18
parts:
- desktop-gtk3:
- plugin: nil
- stage-packages:
- - libc6
- prime:
- - '*'
- - -usr/include
- - -usr/lib/locale
- - -usr/share/X11/locale
- - -usr/share/doc
- - -usr/share/locale
- - -usr/share/man
-
bitmask-root:
- after: [desktop-gtk3]
plugin: dump
source: ../../helpers/
override-prime: |
@@ -37,20 +23,19 @@ parts:
plugin: nil
stage-packages:
- openvpn
- - libc6
prime:
- -usr/share/doc
- -usr/share/man
bitmask-vpn:
- after: [desktop-gtk3]
plugin: go
source: ../../cmd/bitmask-vpn
go-importpath: 0xacab.org/leap/bitmask-vpn/cmd/bitmask-vpn
go-packages:
- 0xacab.org/leap/bitmask-vpn/cmd/bitmask-vpn
override-build: |
- cp $SNAPCRAFT_STAGE/../snap/local/${binaryName}.desktop $SNAPCRAFT_PRIME/${binaryName}.desktop
+ mkdir -p $SNAPCRAFT_PRIME/usr/share/applications
+ cp $SNAPCRAFT_STAGE/../snap/local/${binaryName}.desktop $SNAPCRAFT_PRIME/usr/share/applications/${binaryName}.desktop
snapcraftctl build
override-prime: |
rm -rf $SNAPCRAFT_PRIME/../snap/hooks/.mypy_cache
@@ -62,7 +47,6 @@ parts:
- libappindicator3-dev
- libgtk-3-dev
stage-packages:
- - libc6
- libpcre3
- libappindicator3-1
- zlib1g
@@ -70,9 +54,18 @@ parts:
apps:
launcher:
command: bin/bitmask-vpn
- desktop: ${binaryName}.desktop
+ command-chain: [snap/command-chain/desktop-launch]
+ desktop: usr/share/applications/${binaryName}.desktop
environment:
LD_LIBRARY_PATH: "$SNAP/usr/lib/$(gcc -print-multiarch):$SNAP/lib/$(gcc -print-multiarch):$LD_LIBRARY_PATH"
+ plugs:
+ - desktop
+ - desktop-legacy
+ - home
+ - network
+ - unity7
+ - wayland
+ - x11
openvpn:
command: usr/sbin/openvpn
bitmask-root: