forked from LibreCAD/LibreCAD
-
Notifications
You must be signed in to change notification settings - Fork 2
/
snapcraft.yaml
100 lines (95 loc) · 3.74 KB
/
snapcraft.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
name: librecad
version: '2.2.1-beta'
grade: stable
base: core22
confinement: strict
license: GPL-2.0
summary: "librecad: is a 2D open source CAD"
description: |
LibreCAD is a cross-platform 2D CAD program written in C++17. It can read DXF/DWG files
and can write DXF/PDF/SVG files. It supports point/line/circle/ellipse/parabola/spline
primitives. The user interface is highly customizable, and has dozens of translations.
Code repository:
https://www.github.com/LibreCAD/LibreCAD
environment:
LD_LIBRARY_PATH: $SNAP/usr/local/lib/:$SNAP/usr/lib/x86_64-linux-gnu/:$SNAP/usr/lib64/:$LD_LIBRARY_PATH
apps:
librecad:
command: usr/bin/librecad
parts:
librecad:
plugin: qmake
source: .
build-packages:
- qtbase5-dev
- qttools5-dev
- qttools5-dev-tools
- librsvg2-bin
- libfreetype6-dev
- libicu-dev
- libqt5opengl5-dev
- git
- g++
- libcairo2-dev
- libpango-1.0-0
- libpango1.0-dev
- libboost-dev
- libqt5svg5-dev
- libgtest-dev
- libcurl4-gnutls-dev
- libgtk-3-dev
- libbz2-dev
stage-packages:
- g++
- git
- glibc-tools
- libboost-dev
- libbz2-dev
- libc-bin
- libc6
- libcairo2
- libcairo2-dev
- libcurl4-gnutls-dev
- libfreetype6
- libfreetype6-dev
- libgcc1
- libgtest-dev
- libgtk-3-dev
- libicu-dev
- libicu70
- libpango-1.0-0
- libpango1.0-dev
- libqt5opengl5-dev
- libqt5svg5-dev
- libqt5widgets5
- librsvg2-bin
- qt5-qmake
- qttools5-dev
- qttools5-dev-tools
override-stage: |
echo "1"
echo $PWD
find .. -type f -name librecad
export SRC_DIR=../parts/librecad/build/unix
echo "2"
echo $SNAPCRAFT_STAGE
mkdir -p $SNAPCRAFT_STAGE/usr/bin
mkdir -p $SNAPCRAFT_STAGE/usr/share/librecad
mkdir -p usr/bin
mkdir -p usr/share/librecad
cp -a $SRC_DIR/librecad $SNAPCRAFT_STAGE/usr/bin/
cp -a $SRC_DIR/ttf2lff $SNAPCRAFT_STAGE/usr/bin/
cp -a $SRC_DIR/resources/* $SNAPCRAFT_STAGE/usr/share/librecad/
snapcraftctl stage
override-prime: |
echo "1"
echo $PWD
cp -a ../stage/* ./
snapcraftctl prime
#For 18.04
#configflags:
# - "-DCMAKE_STAGE_PREFIX=/usr"
# - "-DBUILD_SHARED_LIBS=On"
#For 18.04
#configflags:
# - "-DBUILD_SHARED_LIBS=On"