-
Notifications
You must be signed in to change notification settings - Fork 0
/
ee.ria.qdigidoc4.yml
199 lines (186 loc) · 6.86 KB
/
ee.ria.qdigidoc4.yml
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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
app-id: ee.ria.qdigidoc4
command: run.sh
runtime: org.kde.Platform
runtime-version: '6.7'
sdk: org.kde.Sdk
rename-icon: qdigidoc4
rename-desktop-file: qdigidoc4.desktop
rename-mime-file: qdigidoc4.xml
rename-mime-icons: ["application-x-cdoc","application-vnd.etsi.asic-e+zip"]
finish-args:
# libdigidocpp stores tsl files here
- --persist=.digidocpp
# Network is needed for some parts of the application's functionality
- --share=network
# Wayland
- --socket=wayland
# X11
- --socket=fallback-x11
- --share=ipc
# Smartcard
- --socket=pcsc
- --device=all
cleanup:
- /include
- /lib/cmake
- /lib/pkgconfig
- /etc/bash_completion.d
- /share/doc
- /share/man
modules:
- name: flatbuffers
buildsystem: cmake-ninja
sources:
- type: archive
url: https://github.com/google/flatbuffers/archive/refs/tags/v24.3.25.zip
sha256: e706f5eb6ca8f78e237bf3f7eccffa1c5ec9a96d3c1c938f08dc09aab1884528
- name: xerces-c
buildsystem: cmake-ninja
sources:
- type: archive
url: https://github.com/apache/xerces-c/archive/refs/tags/v3.2.4.tar.gz
sha256: 8dfaa30d6a641bda113625ef65e43c433e8ffd94fadd3b8d39dfe6faf450f26d
- name: xalan-c
buildsystem: cmake-ninja
sources:
- type: archive
url: https://github.com/apache/xalan-c/releases/download/Xalan-C_1_12_0/xalan_c-1.12.tar.gz
sha256: ee7d4b0b08c5676f5e586c7154d94a5b32b299ac3cbb946e24c4375a25552da7
- type: patch
path: xalan-c/CMakeLists.patch
- name: xsd
buildsystem: simple
build-commands:
- make CXXFLAGS=-std=c++11 -j
- make install install_prefix=/app
sources:
- type: archive
url: https://www.codesynthesis.com/download/xsd/4.0/xsd-4.0.0+dep.tar.bz2
sha256: eca52a9c8f52cdbe2ae4e364e4a909503493a0d51ea388fc6c9734565a859817
- type: patch
path: xsd/missing-include.patch
- name: xml-security-c
buildsystem: autotools
config-opts:
# TODO: we actually do have xalan in the build tree, so we could use it?
- --with-xalan=no
sources:
- type: archive
url: https://downloads.apache.org/santuario/c-library/xml-security-c-2.0.4.tar.gz
sha256: a78da6720f6c2ba14100d2426131e0d33eac5a2dba5cc11bdd04974b7eb89003
- name: xxd
buildsystem: simple
build-commands:
- cd src && make installtools prefix=/app
cleanup:
- /share/vim
sources:
- type: archive
url: https://github.com/vim/vim/archive/refs/tags/v9.0.1677.tar.gz
sha256: c5750a1d47b514d60d59d9956e2953fb1673d1dd797bfec09c1bff721743e55c
- name: libdigidocpp
buildsystem: cmake-ninja
sources:
- type: archive
url: https://github.com/open-eid/libdigidocpp/releases/download/v3.17.0/libdigidocpp-3.17.0.tar.gz
sha256: 72513d8b6371556deb4faa2ecbb86d35746e71ee30cf12020a31fafcbffcc272
- name: openldap
buildsystem: autotools
config-opts:
- --disable-backends
- --disable-overlays
- --disable-slapd
- --disable-debug
- --enable-dynamic
- --without-threads
- --with-tls=gnutls
cleanup:
- /bin
- /share/man
sources:
- type: archive
url: https://www.openldap.org/software/download/OpenLDAP/openldap-release/openldap-2.6.6.tgz
sha256: 082e998cf542984d43634442dbe11da860759e510907152ea579bdc42fe39ea0
- type: script
dest-filename: autogen.sh
commands:
- AUTOMAKE=/bin/true autoreconf -vfi
- shared-modules/libusb/libusb.json
- name: pcsc-lite
config-opts:
- --disable-libudev
- --disable-libsystemd
- --without-systemdsystemunitdir
- --disable-serial
- --disable-usb
- --disable-documentation
cleanup:
- /sbin
sources:
- type: archive
url: https://github.com/LudovicRousseau/PCSC/archive/refs/tags/2.0.0.tar.gz
sha256: 04f5b9d966b2ada91f699f0b968dd716b381b08ae3cf804832c310f65d329066
- name: opensc
cleanup:
- /share/applications/org.opensc.notify.desktop
sources:
- type: archive
url: https://github.com/OpenSC/OpenSC/releases/download/0.23.0/opensc-0.23.0.tar.gz
sha256: a4844a6ea03a522ecf35e49659716dacb6be03f7c010a1a583aaf3eb915ed2e0
- name: qdigidoc4
buildsystem: cmake-ninja
sources:
- type: archive
url: https://github.com/open-eid/DigiDoc4-Client/releases/download/v4.5.1/qdigidoc4_4.5.1.4455-2004.tar.xz
sha256: 2d61b10c121aaf45c6a6c1b00862645c39d7dab5e6a15b115239541df9b42600
- type: patch
path: qdigidoc4/QPKCS11.patch
- type: patch
path: qdigidoc4/client-CMakeLists.patch
- type: file
path: ee.ria.qdigidoc4.metainfo.xml
# See guide for building in a sandboxed environment:
# https://github.com/open-eid/DigiDoc4-Client/wiki/DeveloperTips#building-in-sandboxed-environment
- type: file
url: https://ec.europa.eu/tools/lotl/eu-lotl.xml
sha256: 83bfb2f565a5f84ca8a40ab4fb61077c29d27283b2f59766201602b98a3466c4
dest: client
dest-filename: eu-lotl.xml
- type: file
url: https://sr.riik.ee/tsl/estonian-tsl.xml
sha256: 472d248b30c849873173c6dee0a3de417996110c2704cf5a261bca99d3c0d1d4
dest: client
dest-filename: EE.xml
- type: file
path: qdigidoc4/TSL.qrc
dest: client
dest-filename: TSL.qrc
- type: file
url: https://id.eesti.ee/config.json
sha256: 2ce5693a53db2280239dab0aed36cd1a6befc5bf81639319c481c11f172bd159
dest: common
dest-filename: config.json
- type: file
url: https://id.eesti.ee/config.rsa
sha256: f036793c18e7b97f49727e25a68b3c730b35d83d3c6bee534fde90650397ce66
dest: common
dest-filename: config.rsa
- type: file
url: https://id.eesti.ee/config.pub
sha256: 29e05778ce98b5197963266bdc292af80a9406cccc3fe5ef7ca2b75b1beb34eb
dest: common
dest-filename: config.pub
- type: patch
path: qdigidoc4/common-CMakeLists.patch
# qdigidoc4 saves files in $TMPDIR before opening them. Since this is inaccessible, we provide a wrapper script,
# as advised here: https://docs.flatpak.org/en/latest/sandbox-permissions.html#filesystem-access
- type: script
dest-filename: run.sh
commands:
- env TMPDIR="$XDG_RUNTIME_DIR/app/$FLATPAK_ID" qdigidoc4 "$@"
post-install:
- install run.sh "${FLATPAK_DEST}/bin/run.sh"
- install -Dm644 ee.ria.qdigidoc4.metainfo.xml $FLATPAK_DEST/share/metainfo/ee.ria.qdigidoc4.metainfo.xml
- ln -s $FLATPAK_DEST/share/locale/et/LC_MESSAGES/nautilus-qdigidoc.mo $FLATPAK_DEST/share/locale/et/nautilus-qdigidoc.mo
- ln -s $FLATPAK_DEST/share/locale/ru/LC_MESSAGES/nautilus-qdigidoc.mo $FLATPAK_DEST/share/locale/ru/nautilus-qdigidoc.mo
- desktop-file-edit --set-key=Exec --set-value="run.sh" /app/share/applications/qdigidoc4.desktop