I want to learn making snap packages but I have a very rough time understanding it. I’m on my 3rd attempt, hopefully 3rd is a charm.
My test package is a simple Qt Quick Controls2 Hello World application(the basic you get for new project), but have no ideea how to package it.
Building it from scratch isn’t worth it since it’s pulling an entire OS to build it, it doesn’t use the Qt version I need because the Ubuntu 16.04 repositories contains Qt 5.5(or 5.6, can’t remember), it doesn’t seem to download packages for other version of Qt even though I tell snapcraft to build with qt59(from ppa) by putting those qt59 packages in build section of the part.
I tried dump plugin but it it works weird and still the application won’t run, I add organize attribute but it copies the files directories 2 times, once it goes and copy everything from the directory where the snapcraft.yaml lies but also those which I mention in organize.
I have managed to make a structure to dump everything but when I run the application it says:
QStandardPaths: XDG_RUNTIME_DIR points to non-existing path ‘/run/user/1000/snap.snap-test’, please create it with 0700 permissions. Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed
Here is the snapcraft.yaml file for it:
name: snap-test
version: 1.0.0
summary: snap test
description: |
test snapcraft
grade: devel
confinement: devmode
parts:
snap-test:
plugin: dump
apps:
snap-test:
command: usr/bin/snap-test
I have read the doc start to end a couple of times, and seems easy until I get into building it…then nothing I do works.
I need to deploy the binary, the libraries, the qml files and the plugins needed for the apps to run.