2019-06-24 10:22:46 +00:00
|
|
|
name: qelectrotech
|
|
|
|
title: QElectroTech
|
|
|
|
base: core18
|
|
|
|
adopt-info: qelectrotech
|
2019-06-25 20:10:23 +00:00
|
|
|
license: GPL-2.0
|
2019-06-24 10:22:46 +00:00
|
|
|
summary: Electrical diagram editor
|
|
|
|
description: |
|
|
|
|
QElectroTech, or QET in short, is a libre and open source desktop application
|
|
|
|
to create diagrams and schematics.
|
|
|
|
|
2019-06-26 07:55:06 +00:00
|
|
|
grade: stable
|
2019-06-24 10:22:46 +00:00
|
|
|
confinement: strict
|
|
|
|
|
|
|
|
layout:
|
|
|
|
/usr/local/share/qelectrotech:
|
|
|
|
bind: $SNAP/usr/local/share/qelectrotech
|
2019-06-24 15:06:13 +00:00
|
|
|
/usr/share/libdrm/amdgpu.ids:
|
|
|
|
bind-file: $SNAP/usr/share/libdrm/amdgpu.ids
|
2019-06-24 10:22:46 +00:00
|
|
|
|
|
|
|
plugs:
|
|
|
|
gtk-3-themes:
|
|
|
|
interface: content
|
|
|
|
target: $SNAP/data-dir/themes
|
|
|
|
default-provider: gtk-common-themes
|
|
|
|
icon-themes:
|
|
|
|
interface: content
|
|
|
|
target: $SNAP/data-dir/icons
|
|
|
|
default-provider: gtk-common-themes
|
|
|
|
sound-themes:
|
|
|
|
interface: content
|
|
|
|
target: $SNAP/data-dir/sounds
|
|
|
|
default-provider: gtk-common-themes
|
|
|
|
|
|
|
|
apps:
|
|
|
|
qelectrotech:
|
|
|
|
adapter: full
|
|
|
|
command: usr/local/bin/qelectrotech
|
|
|
|
command-chain:
|
|
|
|
- bin/desktop-launch
|
|
|
|
- bin/qelectrotech-launch
|
|
|
|
desktop: usr/local/share/applications/qelectrotech.desktop
|
2019-08-06 11:05:18 +02:00
|
|
|
plugs: &plugs [opengl, x11, unity7, wayland, desktop, desktop-legacy, home, removable-media, gsettings, network, cups-control]
|
2019-06-24 10:22:46 +00:00
|
|
|
environment: &env
|
|
|
|
__EGL_VENDOR_LIBRARY_DIRS: $SNAP/usr/share/glvnd/egl_vendor.d
|
|
|
|
QT_QPA_PLATFORMTHEME: gtk3
|
|
|
|
QT_AUTO_SCREEN_SCALE_FACTOR: 1
|
|
|
|
DISABLE_WAYLAND: 1
|
|
|
|
TCL_LIBRARY: $SNAP/usr/share/tcltk/tcl8.6
|
|
|
|
|
|
|
|
qet-tb-generator:
|
|
|
|
command: desktop-launch $SNAP/bin/qet_tb_generator
|
|
|
|
plugs: *plugs
|
|
|
|
environment: *env
|
|
|
|
|
|
|
|
dxf-to-qet:
|
|
|
|
command: desktop-launch $SNAP/bin/DXFtoQET
|
|
|
|
plugs: *plugs
|
|
|
|
environment: *env
|
|
|
|
|
|
|
|
parts:
|
|
|
|
launchers:
|
|
|
|
plugin: dump
|
2020-02-13 17:41:01 +01:00
|
|
|
source: build-aux/snap/local/launchers
|
2019-06-24 10:22:46 +00:00
|
|
|
organize:
|
|
|
|
'*': bin/
|
|
|
|
|
|
|
|
desktop-qt5:
|
|
|
|
source: https://github.com/ubuntu/snapcraft-desktop-helpers.git
|
|
|
|
source-subdir: qt
|
|
|
|
plugin: make
|
|
|
|
make-parameters: ["FLAVOR=qt5"]
|
|
|
|
build-packages:
|
|
|
|
- build-essential
|
|
|
|
- qtbase5-dev
|
|
|
|
- dpkg-dev
|
|
|
|
stage-packages:
|
|
|
|
- libxkbcommon0
|
|
|
|
- ttf-ubuntu-font-family
|
|
|
|
- dmz-cursor-theme
|
|
|
|
- light-themes
|
|
|
|
- adwaita-icon-theme
|
|
|
|
- gnome-themes-standard
|
|
|
|
- shared-mime-info
|
|
|
|
- libqt5gui5
|
|
|
|
- libgdk-pixbuf2.0-0
|
|
|
|
- libqt5svg5 # for loading icon themes which are svg
|
|
|
|
- try: [appmenu-qt5] # not available on core18
|
|
|
|
- locales-all
|
|
|
|
- xdg-user-dirs
|
|
|
|
- fcitx-frontend-qt5
|
2019-08-07 13:22:02 +02:00
|
|
|
- cups-bsd # for lpr used for printing in general (needs cups-control)
|
2019-06-24 10:22:46 +00:00
|
|
|
|
|
|
|
qet-tb-generator:
|
|
|
|
after: [desktop-qt5]
|
|
|
|
plugin: python
|
|
|
|
python-version: python3
|
2019-06-24 15:06:13 +00:00
|
|
|
source: https://github.com/qelectrotech/qet_tb_generator.git
|
2019-06-24 10:22:46 +00:00
|
|
|
stage-packages:
|
|
|
|
- python3-lxml
|
|
|
|
- python3-tk
|
|
|
|
- libtk8.6
|
|
|
|
|
|
|
|
dxf-to-qet:
|
|
|
|
after: [desktop-qt5]
|
|
|
|
plugin: qmake
|
2019-06-24 15:06:13 +00:00
|
|
|
source: https://github.com/qelectrotech/DXFtoQET.git
|
2019-06-24 10:22:46 +00:00
|
|
|
build-packages:
|
|
|
|
- qtbase5-dev
|
|
|
|
override-build: |
|
|
|
|
snapcraftctl build
|
|
|
|
mkdir -p "$SNAPCRAFT_PART_INSTALL/bin"
|
|
|
|
cp DXFtoQET "$SNAPCRAFT_PART_INSTALL/bin/"
|
|
|
|
|
|
|
|
qelectrotech:
|
|
|
|
after: [desktop-qt5]
|
|
|
|
plugin: qmake
|
|
|
|
source: .
|
|
|
|
override-pull: |
|
|
|
|
snapcraftctl pull
|
2019-08-07 16:19:14 +02:00
|
|
|
snap_version=$(git describe --dirty)
|
2019-06-26 07:55:06 +00:00
|
|
|
modified_displayed_version=$snap_version".snap"
|
|
|
|
sed -i -E "s|const QString displayedVersion =.*|const QString displayedVersion =\"$modified_displayed_version\";|" sources/qet.h
|
|
|
|
snapcraftctl set-version "$snap_version"
|
2019-06-24 10:22:46 +00:00
|
|
|
override-stage: |
|
|
|
|
snapcraftctl stage
|
|
|
|
# patch desktop file with correct icon path
|
|
|
|
SED_CMD="sed -i -E s|^Icon=(.*)|Icon=\${SNAP}/usr/local/share/icons/hicolor/128x128/apps/\1.png|g"
|
|
|
|
$SED_CMD usr/local/share/applications/qelectrotech.desktop
|
|
|
|
build-packages:
|
|
|
|
- g++
|
|
|
|
- qttools5-dev-tools
|
|
|
|
- libqt5svg5-dev
|
|
|
|
- libkf5widgetsaddons-dev
|
|
|
|
- libkf5coreaddons-dev
|
2019-06-26 07:55:06 +00:00
|
|
|
- git
|
2019-06-24 10:22:46 +00:00
|
|
|
stage-packages:
|
|
|
|
- qtwayland5
|
|
|
|
- qt5-gtk-platformtheme
|
|
|
|
- libkf5coreaddons5
|
|
|
|
- libkf5widgetsaddons5
|
|
|
|
- libqt5concurrent5
|
|
|
|
- libqt5printsupport5
|
|
|
|
- libqt5sql5
|
|
|
|
- libqt5xml5
|
|
|
|
- libfam0
|
|
|
|
- libqt5sql5-sqlite
|
|
|
|
- libdrm2
|