gnu: All snippets report errors using exceptions, else return #t.
[jackhill/guix/guix.git] / gnu / packages / qt.scm
CommitLineData
bd677c2d 1;;; GNU Guix --- Functional package management for GNU
84ef83dd 2;;; Copyright © 2013, 2014, 2015 Andreas Enge <andreas@enge.fr>
5b490ab5 3;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
31580979 4;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
418c62ff 5;;; Copyright © 2015, 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
c1463145 6;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org>
fc381a33 7;;; Copyright © 2016 Thomas Danckaert <post@thomasdanckaert.be>
3befd0a9
RW
8;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net>
9;;; Copyright © 2017 Quiliro <quiliro@fsfla.org>
8895a968 10;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
04162e83 11;;; Copyright © 2018 Nicolas Goaziou <mail@nicolasgoaziou.fr>
bd677c2d
AE
12;;;
13;;; This file is part of GNU Guix.
14;;;
15;;; GNU Guix is free software; you can redistribute it and/or modify it
16;;; under the terms of the GNU General Public License as published by
17;;; the Free Software Foundation; either version 3 of the License, or (at
18;;; your option) any later version.
19;;;
20;;; GNU Guix is distributed in the hope that it will be useful, but
21;;; WITHOUT ANY WARRANTY; without even the implied warranty of
22;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23;;; GNU General Public License for more details.
24;;;
25;;; You should have received a copy of the GNU General Public License
26;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
27
28(define-module (gnu packages qt)
225941b0 29 #:use-module ((guix licenses) #:prefix license:)
bd677c2d
AE
30 #:use-module (guix packages)
31 #:use-module (guix download)
f198ffd0 32 #:use-module (guix build utils)
9e81af9e 33 #:use-module (guix build-system cmake)
bd677c2d 34 #:use-module (guix build-system gnu)
2456153a 35 #:use-module (guix build-system trivial)
84ef83dd
AE
36 #:use-module (guix packages)
37 #:use-module (guix utils)
1e9ed0e3 38 #:use-module (gnu packages)
b332e366
AE
39 #:use-module (gnu packages bison)
40 #:use-module (gnu packages compression)
2cba3d6f
SB
41 #:use-module (gnu packages cups)
42 #:use-module (gnu packages databases)
aa8c0ada 43 #:use-module (gnu packages documentation)
b332e366 44 #:use-module (gnu packages fontutils)
0009ed71 45 #:use-module (gnu packages flex)
bc8ede01 46 #:use-module (gnu packages freedesktop)
8b6a5e0f 47 #:use-module (gnu packages gl)
b332e366 48 #:use-module (gnu packages glib)
0009ed71
SB
49 #:use-module (gnu packages gnuzilla)
50 #:use-module (gnu packages gperf)
04231311 51 #:use-module (gnu packages gstreamer)
f7fb0ccb 52 #:use-module (gnu packages gtk)
b332e366 53 #:use-module (gnu packages icu4c)
e55354b8 54 #:use-module (gnu packages image)
b332e366 55 #:use-module (gnu packages linux)
04f8decf 56 #:use-module (gnu packages maths)
0009ed71
SB
57 #:use-module (gnu packages pciutils)
58 #:use-module (gnu packages pcre)
b332e366
AE
59 #:use-module (gnu packages perl)
60 #:use-module (gnu packages pkg-config)
39fa8f6c 61 #:use-module (gnu packages pulseaudio)
b332e366 62 #:use-module (gnu packages python)
8b6a5e0f 63 #:use-module (gnu packages ruby)
51519fd3 64 #:use-module (gnu packages sdl)
cc2b77df 65 #:use-module (gnu packages tls)
0009ed71
SB
66 #:use-module (gnu packages xdisorg)
67 #:use-module (gnu packages xorg)
68 #:use-module (gnu packages xml))
bd677c2d 69
aa8c0ada
TD
70(define-public grantlee
71 (package
72 (name "grantlee")
73 (version "5.1.0")
74 (source
75 (origin
76 (method url-fetch)
77 (uri (string-append "https://github.com/steveire/grantlee/archive/v"
78 version ".tar.gz"))
79 (file-name (string-append name "-" version ".tar.gz"))
80 (sha256
81 (base32 "1lf9rkv0i0kd7fvpgg5l8jb87zw8dzcwd1liv6hji7g4wlpmfdiq"))))
82 (native-inputs
868b1a02 83 ;; Optional: lcov and cccc, both are for code coverage
aa8c0ada
TD
84 `(("doxygen" ,doxygen)))
85 (inputs
86 `(("qtbase" ,qtbase)
87 ("qtscript" ,qtscript)))
88 (build-system cmake-build-system)
89 (arguments
90 `(#:phases
91 (modify-phases %standard-phases
868b1a02
HG
92 (add-before 'check 'check-setup
93 (lambda _
94 ;; make Qt render "offscreen", required for tests
95 (setenv "QT_QPA_PLATFORM" "offscreen")
96 #t)))))
aa8c0ada
TD
97 (home-page "https://github.com/steveire/grantlee")
98 (synopsis "Libraries for text templating with Qt")
99 (description "Grantlee Templates can be used for theming and generation of
100other text such as code. The syntax uses the syntax of the Django template
101system, and the core design of Django is reused in Grantlee.")
102 (license license:lgpl2.0+)))
103
b332e366
AE
104(define-public qt
105 (package
106 (name "qt")
418c62ff 107 (version "5.9.4")
5acd59ee 108 (outputs '("out" "examples"))
b332e366
AE
109 (source (origin
110 (method url-fetch)
f7fb0ccb
AE
111 (uri
112 (string-append
113 "http://download.qt.io/official_releases/qt/"
114 (version-major+minor version)
115 "/" version
116 "/single/qt-everywhere-opensource-src-"
117 version ".tar.xz"))
b332e366 118 (sha256
418c62ff
EF
119 (base32
120 "1mblh8k04l13nk9fhhrr43h5bcph1gbz94j5y7csx8zvxb5xkb73"))
14bcc1e1
AE
121 (modules '((guix build utils)))
122 (snippet
bc554b43
AE
123 '(begin
124 ;; Remove qtwebengine, which relies on a bundled copy of
125 ;; chromium. Not only does it fail compilation in qt 5.5:
126 ;; 3rdparty/chromium/ui/gfx/codec/jpeg_codec.cc:362:10:
127 ;; error: cannot convert ‘bool’ to ‘boolean’ in return
128 ;; it might also pose security problems.
129 ;; Alternatively, we could use the "-skip qtwebengine"
130 ;; configuration option.
131 (delete-file-recursively "qtwebengine")
5acd59ee
EF
132 ;; The following snippets are copied from their mondular-qt counterparts.
133 (for-each
134 (lambda (dir)
135 (delete-file-recursively (string-append "qtbase/src/3rdparty/" dir)))
136 (list "double-conversion" "freetype" "harfbuzz-ng"
137 "libpng" "libjpeg" "pcre2" "sqlite" "xcb"
138 "xkbcommon" "zlib"))
139 (for-each
140 (lambda (dir)
141 (delete-file-recursively dir))
142 (list "qtimageformats/src/3rdparty"
143 "qtmultimedia/examples/multimedia/spectrum/3rdparty"
144 "qtwayland/examples"
145 "qtcanvas3d/examples/canvas3d/3rdparty"))
146 ;; Tests depend on this example, which depends on the 3rd party code.
147 (substitute* "qtmultimedia/examples/multimedia/multimedia.pro"
6cbee49d
MW
148 (("spectrum") "#"))
149 #t))))
b332e366 150 (build-system gnu-build-system)
ef0cf53e
AE
151 (propagated-inputs
152 `(("mesa" ,mesa)))
b332e366 153 (inputs
b332e366 154 `(("alsa-lib" ,alsa-lib)
5acd59ee 155 ("bluez" ,bluez)
2cba3d6f 156 ("cups" ,cups)
5acd59ee
EF
157 ("dbus" ,dbus)
158 ("double-conversion" ,double-conversion)
0009ed71 159 ("expat" ,expat)
b332e366
AE
160 ("fontconfig" ,fontconfig)
161 ("freetype" ,freetype)
162 ("glib" ,glib)
5acd59ee
EF
163 ("gstreamer" ,gstreamer)
164 ("gst-plugins-base" ,gst-plugins-base)
f7fb0ccb 165 ("harfbuzz" ,harfbuzz)
b332e366 166 ("icu4c" ,icu4c)
5acd59ee
EF
167 ("jasper" ,jasper)
168 ("libinput" ,libinput-minimal)
f198ffd0 169 ("libjpeg" ,libjpeg)
2cba3d6f 170 ("libmng" ,libmng)
0009ed71 171 ("libpci" ,pciutils)
b332e366 172 ("libpng" ,libpng)
5acd59ee
EF
173 ("libtiff" ,libtiff)
174 ("libwebp" ,libwebp)
b332e366 175 ("libx11" ,libx11)
0009ed71
SB
176 ("libxcomposite" ,libxcomposite)
177 ("libxcursor" ,libxcursor)
5acd59ee 178 ("libxext" ,libxext)
0009ed71 179 ("libxfixes" ,libxfixes)
b332e366 180 ("libxi" ,libxi)
0009ed71 181 ("libxinerama" ,libxinerama)
b332e366 182 ("libxkbcommon" ,libxkbcommon)
0009ed71
SB
183 ("libxml2" ,libxml2)
184 ("libxrandr" ,libxrandr)
b332e366 185 ("libxrender" ,libxrender)
0009ed71
SB
186 ("libxslt" ,libxslt)
187 ("libxtst" ,libxtst)
188 ("mtdev" ,mtdev)
b332e366 189 ("mysql" ,mysql)
0009ed71 190 ("nss" ,nss)
b332e366 191 ("openssl" ,openssl)
2cba3d6f 192 ("postgresql" ,postgresql)
39fa8f6c 193 ("pulseaudio" ,pulseaudio)
5acd59ee 194 ("pcre2" ,pcre2)
0009ed71
SB
195 ("sqlite" ,sqlite)
196 ("udev" ,eudev)
2cba3d6f 197 ("unixodbc" ,unixodbc)
5acd59ee 198 ("wayland" ,wayland)
b332e366
AE
199 ("xcb-util" ,xcb-util)
200 ("xcb-util-image" ,xcb-util-image)
201 ("xcb-util-keysyms" ,xcb-util-keysyms)
202 ("xcb-util-renderutil" ,xcb-util-renderutil)
203 ("xcb-util-wm" ,xcb-util-wm)
204 ("zlib" ,zlib)))
c4c4cc05 205 (native-inputs
0009ed71
SB
206 `(("bison" ,bison)
207 ("flex" ,flex)
208 ("gperf" ,gperf)
0009ed71
SB
209 ("perl" ,perl)
210 ("pkg-config" ,pkg-config)
211 ("python" ,python-2)
212 ("ruby" ,ruby)
ce0614dd 213 ("which" ,(@ (gnu packages base) which))))
b332e366 214 (arguments
5acd59ee 215 `(#:phases
cce28b0c 216 (modify-phases %standard-phases
2470d779
AE
217 (add-after 'configure 'patch-bin-sh
218 (lambda _
5acd59ee 219 (substitute* '("qtbase/configure"
2470d779
AE
220 "qtbase/mkspecs/features/qt_functions.prf"
221 "qtbase/qmake/library/qmakebuiltins.cpp")
222 (("/bin/sh") (which "sh")))
223 #t))
cce28b0c
AE
224 (replace 'configure
225 (lambda* (#:key outputs #:allow-other-keys)
5acd59ee
EF
226 (let ((out (assoc-ref outputs "out"))
227 (examples (assoc-ref outputs "examples")))
cce28b0c
AE
228 (substitute* '("configure" "qtbase/configure")
229 (("/bin/pwd") (which "pwd")))
230 (substitute* "qtbase/src/corelib/global/global.pri"
231 (("/bin/ls") (which "ls")))
232 ;; do not pass "--enable-fast-install", which makes the
233 ;; configure process fail
234 (zero? (system*
235 "./configure"
236 "-verbose"
237 "-prefix" out
5acd59ee 238 "-examplesdir" examples ; 89MiB
cce28b0c
AE
239 "-opensource"
240 "-confirm-license"
5acd59ee 241 ;; Do not build examples; for the time being, we
4dd0a8b6 242 ;; prefer to save the space and build time.
5acd59ee 243 "-no-compile-examples"
cce28b0c
AE
244 ;; Most "-system-..." are automatic, but some use
245 ;; the bundled copy by default.
246 "-system-sqlite"
247 "-system-harfbuzz"
248 ;; explicitly link with openssl instead of dlopening it
249 "-openssl-linked"
250 ;; explicitly link with dbus instead of dlopening it
251 "-dbus-linked"
5acd59ee
EF
252 ;; don't use the precompiled headers
253 "-no-pch"
cce28b0c
AE
254 ;; drop special machine instructions not supported
255 ;; on all instances of the target
256 ,@(if (string-prefix? "x86_64"
257 (or (%current-target-system)
258 (%current-system)))
259 '()
260 '("-no-sse2"))
cce28b0c
AE
261 "-no-mips_dsp"
262 "-no-mips_dspr2"))))))))
2e36f7e6 263 (home-page "https://www.qt.io/")
b332e366
AE
264 (synopsis "Cross-platform GUI library")
265 (description "Qt is a cross-platform application and UI framework for
266developers using C++ or QML, a CSS & JavaScript like language.")
225941b0 267 (license license:lgpl2.1)
f47638a3
LC
268
269 ;; Qt 4: 'QBasicAtomicPointer' leads to build failures on MIPS;
270 ;; see <http://hydra.gnu.org/build/112828>.
271 ;; Qt 5: assembler error; see <http://hydra.gnu.org/build/112526>.
272 (supported-systems (delete "mips64el-linux" %supported-systems))))
1e9ed0e3
AE
273
274(define-public qt-4
275 (package (inherit qt)
d22b9397 276 (version "4.8.7")
1e9ed0e3
AE
277 (source (origin
278 (method url-fetch)
279 (uri (string-append "http://download.qt-project.org/official_releases/qt/"
280 (string-copy version 0 (string-rindex version #\.))
281 "/" version
89059aa1 282 "/qt-everywhere-opensource-src-"
1e9ed0e3
AE
283 version ".tar.gz"))
284 (sha256
285 (base32
d22b9397 286 "183fca7n7439nlhxyg1z7aky0izgbyll3iwakw4gwivy16aj5272"))
fc1adab1 287 (patches (search-patches "qt4-ldflags.patch"))
7431edea
AE
288 (modules '((guix build utils)))
289 (snippet
290 ;; Remove webkit module, which is not built.
6cbee49d
MW
291 '(begin (delete-file-recursively "src/3rdparty/webkit")
292 #t))))
f7fb0ccb
AE
293 (inputs `(,@(alist-delete "harfbuzz"
294 (alist-delete "libjpeg" (package-inputs qt)))
e7e5a4f8
AE
295 ("libjepg" ,libjpeg-8)
296 ("libsm" ,libsm)))
31580979
LC
297
298 ;; Note: there are 37 MiB of examples and a '-exampledir' configure flags,
299 ;; but we can't make them a separate output because "out" and "examples"
300 ;; would refer to each other.
301 (outputs '("out" ;112MiB core + 37MiB examples
302 "doc")) ;280MiB of HTML + code
1e9ed0e3
AE
303 (arguments
304 `(#:phases
cba632c4
LC
305 (modify-phases %standard-phases
306 (replace
1e9ed0e3
AE
307 'configure
308 (lambda* (#:key outputs #:allow-other-keys)
31580979
LC
309 (let ((out (assoc-ref outputs "out"))
310 (doc (assoc-ref outputs "doc")))
1e9ed0e3 311 (substitute* '("configure")
d2984346
LC
312 (("/bin/pwd") (which "pwd")))
313
206a5208
AE
314 (zero? (system*
315 "./configure"
316 "-verbose"
317 "-prefix" out
4b0f2ef7
LC
318 ;; Note: Don't pass '-docdir' since 'qmake' and
319 ;; libQtCore would record its value, thereby defeating
320 ;; the whole point of having a separate output.
ff1989a5
LC
321 "-datadir" (string-append out "/share/qt-" ,version
322 "/data")
323 "-importdir" (string-append out "/lib/qt-4"
324 "/imports")
325 "-plugindir" (string-append out "/lib/qt-4"
326 "/plugins")
327 "-translationdir" (string-append out "/share/qt-" ,version
328 "/translations")
31580979
LC
329 "-demosdir" (string-append out "/share/qt-" ,version
330 "/demos")
331 "-examplesdir" (string-append out "/share/qt-" ,version
332 "/examples")
206a5208
AE
333 "-opensource"
334 "-confirm-license"
ff0a8c59
AE
335 ;; explicitly link with dbus instead of dlopening it
336 "-dbus-linked"
7431edea
AE
337 ;; Skip the webkit module; it fails to build on armhf
338 ;; and, apart from that, may pose security risks.
339 "-no-webkit"
206a5208
AE
340 ;; drop special machine instructions not supported
341 ;; on all instances of the target
342 ,@(if (string-prefix? "x86_64"
343 (or (%current-target-system)
344 (%current-system)))
345 '()
346 '("-no-mmx"
1e9ed0e3
AE
347 "-no-3dnow"
348 "-no-sse"
206a5208
AE
349 "-no-sse2"))
350 "-no-sse3"
351 "-no-ssse3"
352 "-no-sse4.1"
353 "-no-sse4.2"
84811c22 354 "-no-avx")))))
4b0f2ef7
LC
355 (add-after
356 'install 'move-doc
357 (lambda* (#:key outputs #:allow-other-keys)
358 ;; Because of qt4-documentation-path.patch, documentation ends up
359 ;; being installed in OUT. Move it to the right place.
360 (let* ((out (assoc-ref outputs "out"))
361 (doc (assoc-ref outputs "doc"))
362 (olddoc (string-append out "/doc"))
363 (docdir (string-append doc "/share/doc/qt-" ,version)))
364 (mkdir-p (dirname docdir))
365
366 ;; Note: We can't use 'rename-file' here because OUT and DOC are
367 ;; different "devices" due to bind-mounts.
368 (copy-recursively olddoc docdir)
369 (delete-file-recursively olddoc)
370 #t))))))))
84ef83dd 371
7868000f
AE
372(define-public qtbase
373 (package
374 (name "qtbase")
418c62ff 375 (version "5.9.4")
7868000f
AE
376 (source (origin
377 (method url-fetch)
378 (uri (string-append "https://download.qt.io/official_releases/qt/"
379 (version-major+minor version) "/" version
380 "/submodules/" name "-opensource-src-"
381 version ".tar.xz"))
382 (sha256
c7386f4e 383 (base32
418c62ff 384 "1kq422vb2zaic099pgzwk7c0qzgc3xap6qahw5vklrq0mgivvrk9"))
64f390a4
HG
385 ;; Use TZDIR to avoid depending on package "tzdata".
386 (patches (search-patches "qtbase-use-TZDIR.patch"))
7868000f
AE
387 (modules '((guix build utils)))
388 (snippet
924e6ddf 389 ;; corelib uses bundled harfbuzz, md4, md5, sha3
7868000f 390 '(begin
924e6ddf
EF
391 (for-each
392 (lambda (dir)
393 (delete-file-recursively (string-append "src/3rdparty/" dir)))
394 (list "double-conversion" "freetype" "harfbuzz-ng"
395 "libpng" "libjpeg" "pcre2" "sqlite" "xcb"
396 "xkbcommon" "zlib"))
397 #t))))
7868000f 398 (build-system gnu-build-system)
48d4ce6e 399 (propagated-inputs
8075b623
SB
400 `(("mesa" ,mesa)
401 ("which" ,(@ (gnu packages base) which))))
7868000f
AE
402 (inputs
403 `(("alsa-lib" ,alsa-lib)
404 ("cups" ,cups)
405 ("dbus" ,dbus)
04f8decf 406 ("double-conversion" ,double-conversion)
f66970a7 407 ("eudev" ,eudev)
7868000f
AE
408 ("expat" ,expat)
409 ("fontconfig" ,fontconfig)
410 ("freetype" ,freetype)
411 ("glib" ,glib)
412 ("harfbuzz" ,harfbuzz)
413 ("icu4c" ,icu4c)
9ed9b44e 414 ("libinput" ,libinput-minimal)
7868000f
AE
415 ("libjpeg" ,libjpeg)
416 ("libmng" ,libmng)
417 ("libpng" ,libpng)
418 ("libx11" ,libx11)
419 ("libxcomposite" ,libxcomposite)
420 ("libxcursor" ,libxcursor)
421 ("libxfixes" ,libxfixes)
422 ("libxi" ,libxi)
423 ("libxinerama" ,libxinerama)
424 ("libxkbcommon" ,libxkbcommon)
425 ("libxml2" ,libxml2)
426 ("libxrandr" ,libxrandr)
427 ("libxrender" ,libxrender)
428 ("libxslt" ,libxslt)
429 ("libxtst" ,libxtst)
430 ("mtdev" ,mtdev)
431 ("mysql" ,mysql)
432 ("nss" ,nss)
433 ("openssl" ,openssl)
924e6ddf 434 ("pcre2" ,pcre2)
7868000f
AE
435 ("postgresql" ,postgresql)
436 ("pulseaudio" ,pulseaudio)
437 ("sqlite" ,sqlite)
438 ("unixodbc" ,unixodbc)
439 ("xcb-util" ,xcb-util)
440 ("xcb-util-image" ,xcb-util-image)
441 ("xcb-util-keysyms" ,xcb-util-keysyms)
442 ("xcb-util-renderutil" ,xcb-util-renderutil)
443 ("xcb-util-wm" ,xcb-util-wm)
444 ("zlib" ,zlib)))
445 (native-inputs
446 `(("bison" ,bison)
447 ("flex" ,flex)
448 ("gperf" ,gperf)
449 ("perl" ,perl)
450 ("pkg-config" ,pkg-config)
451 ("python" ,python-2)
8075b623 452 ("ruby" ,ruby)))
7868000f
AE
453 (arguments
454 `(#:phases
455 (modify-phases %standard-phases
456 (add-after 'configure 'patch-bin-sh
457 (lambda _
458 (substitute* '("config.status"
459 "configure"
460 "mkspecs/features/qt_functions.prf"
461 "qmake/library/qmakebuiltins.cpp")
462 (("/bin/sh") (which "sh")))
463 #t))
464 (replace 'configure
465 (lambda* (#:key outputs #:allow-other-keys)
466 (let ((out (assoc-ref outputs "out")))
467 (substitute* "configure"
468 (("/bin/pwd") (which "pwd")))
469 (substitute* "src/corelib/global/global.pri"
470 (("/bin/ls") (which "ls")))
7972d8a2
AE
471 ;; The configuration files for other Qt5 packages are searched
472 ;; through a call to "find_package" in Qt5Config.cmake, which
473 ;; disables the use of CMAKE_PREFIX_PATH via the parameter
474 ;; "NO_DEFAULT_PATH". Re-enable it so that the different
475 ;; components can be installed in different places.
476 (substitute* (find-files "." ".*\\.cmake")
477 (("NO_DEFAULT_PATH") ""))
7868000f
AE
478 ;; do not pass "--enable-fast-install", which makes the
479 ;; configure process fail
480 (zero? (system*
481 "./configure"
482 "-verbose"
483 "-prefix" out
6fc0e157
SB
484 "-docdir" (string-append out "/share/doc/qt5")
485 "-headerdir" (string-append out "/include/qt5")
486 "-archdatadir" (string-append out "/lib/qt5")
487 "-datadir" (string-append out "/share/qt5")
488 "-examplesdir" (string-append
489 out "/share/doc/qt5/examples")
7868000f
AE
490 "-opensource"
491 "-confirm-license"
492 ;; Do not build examples; if desired, these could go
493 ;; into a separate output, but for the time being, we
494 ;; prefer to save the space and build time.
924e6ddf 495 "-no-compile-examples"
7868000f
AE
496 ;; Most "-system-..." are automatic, but some use
497 ;; the bundled copy by default.
498 "-system-sqlite"
499 "-system-harfbuzz"
924e6ddf 500 "-system-pcre"
7868000f
AE
501 ;; explicitly link with openssl instead of dlopening it
502 "-openssl-linked"
503 ;; explicitly link with dbus instead of dlopening it
504 "-dbus-linked"
4e825e2d
EF
505 ;; don't use the precompiled headers
506 "-no-pch"
507 ;; drop special machine instructions that do not have
508 ;; runtime detection
7868000f
AE
509 ,@(if (string-prefix? "x86_64"
510 (or (%current-target-system)
511 (%current-system)))
512 '()
513 '("-no-sse2"))
7868000f 514 "-no-mips_dsp"
5ca6ef95 515 "-no-mips_dspr2")))))
8075b623 516 (add-after 'install 'patch-mkspecs
5ca6ef95
SB
517 (lambda* (#:key outputs #:allow-other-keys)
518 (let* ((out (assoc-ref outputs "out"))
8075b623
SB
519 (archdata (string-append out "/lib/qt5"))
520 (mkspecs (string-append archdata "/mkspecs"))
5ca6ef95 521 (qt_config.prf (string-append
6fc0e157 522 mkspecs "/features/qt_config.prf")))
5ca6ef95
SB
523 ;; For each Qt module, let `qmake' uses search paths in the
524 ;; module directory instead of all in QT_INSTALL_PREFIX.
525 (substitute* qt_config.prf
526 (("\\$\\$\\[QT_INSTALL_HEADERS\\]")
6fc0e157 527 "$$clean_path($$replace(dir, mkspecs/modules, ../../include/qt5))")
5ca6ef95 528 (("\\$\\$\\[QT_INSTALL_LIBS\\]")
6fc0e157 529 "$$clean_path($$replace(dir, mkspecs/modules, ../../lib))")
5ca6ef95 530 (("\\$\\$\\[QT_HOST_LIBS\\]")
6fc0e157 531 "$$clean_path($$replace(dir, mkspecs/modules, ../../lib))")
5ca6ef95 532 (("\\$\\$\\[QT_INSTALL_BINS\\]")
6fc0e157 533 "$$clean_path($$replace(dir, mkspecs/modules, ../../bin))"))
8075b623
SB
534
535 ;; Searches Qt tools in the current PATH instead of QT_HOST_BINS.
536 (substitute* (string-append mkspecs "/features/qt_functions.prf")
537 (("cmd = \\$\\$\\[QT_HOST_BINS\\]/\\$\\$2")
538 "cmd = $$system(which $${2}.pl 2>/dev/null || which $${2})"))
539
540 ;; Resolve qmake spec files within qtbase by absolute paths.
541 (substitute*
542 (map (lambda (file)
543 (string-append mkspecs "/features/" file))
544 '("device_config.prf" "moc.prf" "qt_build_config.prf"
545 "qt_config.prf" "winrt/package_manifest.prf"))
546 (("\\$\\$\\[QT_HOST_DATA/get\\]") archdata)
547 (("\\$\\$\\[QT_HOST_DATA/src\\]") archdata))
64f390a4
HG
548 #t)))
549 (add-after 'unpack 'patch-paths
550 ;; Use the absolute paths for dynamically loaded libs, otherwise
551 ;; the lib will be searched in LD_LIBRARY_PATH which typically is
552 ;; not set in guix.
553 (lambda* (#:key inputs #:allow-other-keys)
554 ;; libresolve
555 (let ((glibc (assoc-ref inputs ,(if (%current-target-system)
556 "cross-libc" "libc"))))
557 (substitute* '("src/network/kernel/qdnslookup_unix.cpp"
558 "src/network/kernel/qhostinfo_unix.cpp")
559 (("^\\s*(lib.setFileName\\(QLatin1String\\(\")(resolv\"\\)\\);)" _ a b)
560 (string-append a glibc "/lib/lib" b))))
561 ;; X11/locale (compose path)
562 (substitute* "src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp"
563 ;; Don't search in /usr/…/X11/locale, …
564 (("^\\s*m_possibleLocations.append\\(QStringLiteral\\(\"/usr/.*/X11/locale\"\\)\\);" line)
565 (string-append "// " line))
566 ;; … but use libx11's path
567 (("^\\s*(m_possibleLocations.append\\(QStringLiteral\\()X11_PREFIX \"(/.*/X11/locale\"\\)\\);)" _ a b)
568 (string-append a "\"" (assoc-ref inputs "libx11") b)))
569 ;; libGL
570 (substitute* "src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp"
571 (("^\\s*(QLibrary lib\\(QLatin1String\\(\")(GL\"\\)\\);)" _ a b)
572 (string-append a (assoc-ref inputs "mesa") "/lib/lib" b)))
573 ;; libXcursor
574 (substitute* "src/plugins/platforms/xcb/qxcbcursor.cpp"
575 (("^\\s*(QLibrary xcursorLib\\(QLatin1String\\(\")(Xcursor\"\\), 1\\);)" _ a b)
576 (string-append a (assoc-ref inputs "libxcursor") "/lib/lib" b))
577 (("^\\s*(xcursorLib.setFileName\\(QLatin1String\\(\")(Xcursor\"\\)\\);)" _ a b)
578 (string-append a (assoc-ref inputs "libxcursor") "/lib/lib" b)))
579 #t)))))
5ca6ef95
SB
580 (native-search-paths
581 (list (search-path-specification
582 (variable "QMAKEPATH")
6fc0e157 583 (files '("lib/qt5")))
ed02e1fe
DC
584 (search-path-specification
585 (variable "QML2_IMPORT_PATH")
6fc0e157 586 (files '("lib/qt5/qml")))
ed02e1fe
DC
587 (search-path-specification
588 (variable "QT_PLUGIN_PATH")
6fc0e157 589 (files '("lib/qt5/plugins")))
ed02e1fe
DC
590 (search-path-specification
591 (variable "XDG_DATA_DIRS")
592 (files '("share")))
593 (search-path-specification
594 (variable "XDG_CONFIG_DIRS")
595 (files '("etc/xdg")))))
7868000f
AE
596 (home-page "https://www.qt.io/")
597 (synopsis "Cross-platform GUI library")
598 (description "Qt is a cross-platform application and UI framework for
599developers using C++ or QML, a CSS & JavaScript like language.")
225941b0 600 (license (list license:lgpl2.1 license:lgpl3))))
7868000f 601
19c17631
EF
602(define-public qtsvg
603 (package (inherit qtbase)
604 (name "qtsvg")
418c62ff 605 (version "5.9.4")
19c17631
EF
606 (source (origin
607 (method url-fetch)
608 (uri (string-append "https://download.qt.io/official_releases/qt/"
609 (version-major+minor version) "/" version
610 "/submodules/" name "-opensource-src-"
611 version ".tar.xz"))
612 (sha256
613 (base32
418c62ff 614 "0yh3an9rc7fh013cw3bm318ap6428icsmnj38hhg1w6lpwr2gwm2"))))
48d4ce6e 615 (propagated-inputs `())
19c17631
EF
616 (native-inputs `(("perl" ,perl)))
617 (inputs
618 `(("mesa" ,mesa)
619 ("qtbase" ,qtbase)
620 ("zlib" ,zlib)))
621 (arguments
622 `(#:phases
623 (modify-phases %standard-phases
8075b623 624 (add-before 'configure 'configure-qmake
19c17631 625 (lambda* (#:key inputs outputs #:allow-other-keys)
8075b623
SB
626 (let* ((out (assoc-ref outputs "out"))
627 (qtbase (assoc-ref inputs "qtbase"))
628 (tmpdir (string-append (getenv "TMPDIR")))
629 (qmake (string-append tmpdir "/qmake"))
630 (qt.conf (string-append tmpdir "/qt.conf")))
631 ;; Use qmake with a customized qt.conf to override install
632 ;; paths to $out.
633 (symlink (which "qmake") qmake)
634 (setenv "PATH" (string-append tmpdir ":" (getenv "PATH")))
635 (with-output-to-file qt.conf
636 (lambda ()
637 (format #t "[Paths]
638Prefix=~a
639ArchData=lib/qt5
640Data=share/qt5
641Documentation=share/doc/qt5
642Headers=include/qt5
643Libraries=lib
644LibraryExecutables=lib/qt5/libexec
645Binaries=bin
646Tests=tests
647Plugins=lib/qt5/plugins
648Imports=lib/qt5/imports
649Qml2Imports=lib/qt5/qml
650Translations=share/qt5/translations
651Settings=etc/xdg
652Examples=share/doc/qt5/examples
653HostPrefix=~a
654HostData=lib/qt5
655HostBinaries=bin
656HostLibraries=lib
b000294e
SB
657
658[EffectiveSourcePaths]
659HostPrefix=~a
660HostData=lib/qt5
661" out out qtbase)))
c195b5ba 662 #t)))
8075b623
SB
663 (replace 'configure
664 (lambda* (#:key inputs outputs #:allow-other-keys)
665 ;; Valid QT_BUILD_PARTS variables are:
666 ;; libs tools tests examples demos docs translations
667 (zero? (system* "qmake" "QT_BUILD_PARTS = libs tools tests"))))
668 (add-before 'check 'set-display
669 (lambda _
670 ;; make Qt render "offscreen", required for tests
671 (setenv "QT_QPA_PLATFORM" "offscreen")
672 #t)))))
96412f34
EF
673 (synopsis "Qt module for displaying SVGs")
674 (description "The QtSvg module provides classes for displaying the
675 contents of SVG files.")))
19c17631 676
9b694210
EF
677(define-public qtimageformats
678 (package (inherit qtsvg)
679 (name "qtimageformats")
418c62ff 680 (version "5.9.4")
9b694210
EF
681 (source (origin
682 (method url-fetch)
683 (uri (string-append "https://download.qt.io/official_releases/qt/"
684 (version-major+minor version) "/" version
685 "/submodules/" name "-opensource-src-"
686 version ".tar.xz"))
687 (sha256
688 (base32
418c62ff 689 "1nfxvf96wh1smdmcsk4m9f7zg69fgp844f8772qpv6v4m20p1qb9"))
c04854da 690 (modules '((guix build utils)))
6cbee49d
MW
691 (snippet '(begin (delete-file-recursively "src/3rdparty")
692 #t))))
9b694210
EF
693 (native-inputs `())
694 (inputs
a532a671
EF
695 `(("jasper" ,jasper)
696 ("libmng" ,libmng)
9b694210
EF
697 ("libtiff" ,libtiff)
698 ("libwebp" ,libwebp)
699 ("mesa" ,mesa)
700 ("qtbase" ,qtbase)
96412f34
EF
701 ("zlib" ,zlib)))
702 (synopsis "Additional Image Format plugins for Qt")
703 (description "The QtImageFormats module contains plugins for adding
704support for MNG, TGA, TIFF and WBMP image formats.")))
9b694210 705
f6c13613
EF
706(define-public qtx11extras
707 (package (inherit qtsvg)
708 (name "qtx11extras")
418c62ff 709 (version "5.9.4")
f6c13613
EF
710 (source (origin
711 (method url-fetch)
712 (uri (string-append "https://download.qt.io/official_releases/qt/"
713 (version-major+minor version) "/" version
714 "/submodules/" name "-opensource-src-"
715 version ".tar.xz"))
716 (sha256
717 (base32
418c62ff 718 "1a125fi7lbxfps207i12jammm4cjbiawmp4sqa3bxqah8p21i6w7"))))
c195b5ba
EF
719 (arguments
720 (substitute-keyword-arguments (package-arguments qtsvg)
721 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
f6c13613
EF
722 (native-inputs `(("perl" ,perl)))
723 (inputs
724 `(("mesa" ,mesa)
96412f34
EF
725 ("qtbase" ,qtbase)))
726 (synopsis "Qt Extras for X11")
727 (description "The QtX11Extras module includes the library to access X11
728from within Qt 5.")))
f6c13613 729
98eec712
EF
730(define-public qtxmlpatterns
731 (package (inherit qtsvg)
732 (name "qtxmlpatterns")
418c62ff 733 (version "5.9.4")
98eec712
EF
734 (source (origin
735 (method url-fetch)
736 (uri (string-append "https://download.qt.io/official_releases/qt/"
737 (version-major+minor version) "/" version
738 "/submodules/" name "-opensource-src-"
739 version ".tar.xz"))
740 (sha256
741 (base32
418c62ff 742 "0ybz0i3wblvrm958s9ykp3a79bakjbb7k74q71mqaaswkv9imxgs"))))
c195b5ba
EF
743 (arguments
744 (substitute-keyword-arguments (package-arguments qtsvg)
f66b3e15
EF
745 ((#:phases phases)
746 `(modify-phases ,phases
747 (add-after 'unpack 'disable-network-tests
748 (lambda _ (substitute* "tests/auto/auto.pro"
749 (("qxmlquery") "# qxmlquery")
a20e00dd 750 (("xmlpatterns ") "# xmlpatterns"))
f66b3e15 751 #t))))))
98eec712 752 (native-inputs `(("perl" ,perl)))
96412f34
EF
753 (inputs `(("qtbase" ,qtbase)))
754 (synopsis "Qt XML patterns module")
755 (description "The QtXmlPatterns module is a XQuery and XPath engine for
756XML and custom data models. It contains programs such as xmlpatterns and
757xmlpatternsvalidator.")))
98eec712 758
e3a2ed81
EF
759(define-public qtdeclarative
760 (package (inherit qtsvg)
761 (name "qtdeclarative")
418c62ff 762 (version "5.9.4")
e3a2ed81
EF
763 (source (origin
764 (method url-fetch)
765 (uri (string-append "https://download.qt.io/official_releases/qt/"
766 (version-major+minor version) "/" version
767 "/submodules/" name "-opensource-src-"
768 version ".tar.xz"))
769 (sha256
770 (base32
418c62ff 771 "0r9dhfc6qmxlzn2v9r6z6n2mcq6pv1nmyh91g9hcdlkx40xqlqyw"))))
c195b5ba
EF
772 (arguments
773 (substitute-keyword-arguments (package-arguments qtsvg)
774 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
e3a2ed81
EF
775 (native-inputs
776 `(("perl" ,perl)
777 ("pkg-config" ,pkg-config)
778 ("python" ,python-2)
779 ("qtsvg" ,qtsvg)
780 ("qtxmlpatterns" ,qtxmlpatterns)))
781 (inputs
782 `(("mesa" ,mesa)
96412f34
EF
783 ("qtbase" ,qtbase)))
784 (synopsis "Qt QML module (Quick 2)")
785 (description "The Qt QML module provides a framework for developing
786applications and libraries with the QML language. It defines and implements the
787language and engine infrastructure, and provides an API to enable application
788developers to extend the QML language with custom types and integrate QML code
789with JavaScript and C++.")))
e3a2ed81 790
e98cb96d
EF
791(define-public qtconnectivity
792 (package (inherit qtsvg)
793 (name "qtconnectivity")
418c62ff 794 (version "5.9.4")
e98cb96d
EF
795 (source (origin
796 (method url-fetch)
797 (uri (string-append "https://download.qt.io/official_releases/qt/"
798 (version-major+minor version) "/" version
799 "/submodules/" name "-opensource-src-"
800 version ".tar.xz"))
801 (sha256
802 (base32
418c62ff 803 "12qckqz6ldvn1czkkigadmgl07yk4gs74hy4ifh4hmpm7cv519yv"))))
45f5bc0e
EF
804 (arguments
805 (substitute-keyword-arguments (package-arguments qtsvg)
806 ((#:phases phases)
807 `(modify-phases ,phases
808 (add-after 'unpack 'disable-failing-tests
809 ;; this test fails on armhf and aarch64
810 (lambda _
811 (substitute* "tests/auto/qndefnfcsmartposterrecord/tst_qndefnfcsmartposterrecord.cpp"
812 (("QCOMPARE\\(record.action\\(\\), QNdefNfcSmartPosterRecord::UnspecifiedAction")
813 "//QCOMPARE(record.action(), QNdefNfcSmartPosterRecord::UnspecifiedAction"))
814 #t))))))
e98cb96d
EF
815 (native-inputs
816 `(("perl" ,perl)
817 ("pkg-config" ,pkg-config)
818 ("qtdeclarative" ,qtdeclarative)))
819 (inputs
820 `(("bluez" ,bluez)
96412f34
EF
821 ("qtbase" ,qtbase)))
822 (synopsis "Qt Connectivity module")
823 (description "The Qt Connectivity modules provides modules for interacting
824with Bluetooth and NFC.")))
e98cb96d 825
cac893ec
EF
826(define-public qtwebsockets
827 (package (inherit qtsvg)
828 (name "qtwebsockets")
418c62ff 829 (version "5.9.4")
cac893ec
EF
830 (source (origin
831 (method url-fetch)
832 (uri (string-append "https://download.qt.io/official_releases/qt/"
833 (version-major+minor version) "/" version
834 "/submodules/" name "-opensource-src-"
835 version ".tar.xz"))
836 (sha256
837 (base32
418c62ff 838 "00786d9m8skj68n5x9d8151zmmskx7ckhgcdd08hs9nly04h55vj"))))
c195b5ba
EF
839 (arguments
840 (substitute-keyword-arguments (package-arguments qtsvg)
841 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
cac893ec
EF
842 (native-inputs
843 `(("perl" ,perl)
844 ("qtdeclarative" ,qtdeclarative)))
96412f34
EF
845 (inputs `(("qtbase" ,qtbase)))
846 (synopsis "Qt Web Sockets module")
847 (description "WebSocket is a web-based protocol designed to enable two-way
848communication between a client application and a remote host. The Qt
849WebSockets module provides C++ and QML interfaces that enable Qt applications
850to act as a server that can process WebSocket requests, or a client that can
851consume data received from the server, or both.")))
cac893ec 852
3474767c
EF
853(define-public qtsensors
854 (package (inherit qtsvg)
855 (name "qtsensors")
418c62ff 856 (version "5.9.4")
3474767c
EF
857 (source (origin
858 (method url-fetch)
859 (uri (string-append "https://download.qt.io/official_releases/qt/"
860 (version-major+minor version) "/" version
861 "/submodules/" name "-opensource-src-"
862 version ".tar.xz"))
863 (sha256
864 (base32
418c62ff 865 "0n6lkkn7c9x8vcplmfvkx7jq6najh2mrwnfb3blrmkmpash3lgvr"))))
202afee2
EF
866 (arguments
867 (substitute-keyword-arguments (package-arguments qtsvg)
5ea35b42 868 ((#:parallel-tests? _ #f) #f) ; can lead to race condition
202afee2
EF
869 ((#:phases phases)
870 `(modify-phases ,phases
04162e83 871 (add-after 'unpack 'fix-tests
202afee2
EF
872 (lambda _
873 (substitute* "tests/auto/qsensorgestures_gestures/tst_sensorgestures_gestures.cpp"
04162e83
NG
874 (("2000") "5000") ;lengthen test timeout
875 (("QTest::newRow(\"twist\") << \"twist\"") "")) ;failing test
202afee2 876 #t))))))
3474767c
EF
877 (native-inputs
878 `(("perl" ,perl)
879 ("qtdeclarative" ,qtdeclarative)))
96412f34
EF
880 (inputs `(("qtbase" ,qtbase)))
881 (synopsis "Qt Sensors module")
882 (description "The Qt Sensors API provides access to sensor hardware via QML
883and C++ interfaces. The Qt Sensors API also provides a motion gesture
884recognition API for devices.")))
3474767c 885
15378f93
EF
886(define-public qtmultimedia
887 (package (inherit qtsvg)
888 (name "qtmultimedia")
418c62ff 889 (version "5.9.4")
15378f93
EF
890 (source (origin
891 (method url-fetch)
892 (uri (string-append "https://download.qt.io/official_releases/qt/"
893 (version-major+minor version) "/" version
894 "/submodules/" name "-opensource-src-"
895 version ".tar.xz"))
896 (sha256
897 (base32
418c62ff 898 "0x2f3vpax7rq0lxnncbp5b248bxdicrwn8hv4hsas2g2283s0lj9"))
63d8f08f
EF
899 (modules '((guix build utils)))
900 (snippet
901 '(begin
902 (delete-file-recursively
c195b5ba
EF
903 "examples/multimedia/spectrum/3rdparty")
904 ;; We also prevent the spectrum example from being built.
905 (substitute* "examples/multimedia/multimedia.pro"
6cbee49d
MW
906 (("spectrum") "#"))
907 #t))))
c195b5ba
EF
908 (arguments
909 (substitute-keyword-arguments (package-arguments qtsvg)
04231311
RW
910 ((#:phases phases)
911 `(modify-phases ,phases
912 (replace 'configure
913 (lambda* (#:key outputs #:allow-other-keys)
914 (let ((out (assoc-ref outputs "out")))
915 (zero? (system* "qmake" "QT_BUILD_PARTS = libs tools tests"
916 (string-append "QMAKE_LFLAGS_RPATH=-Wl,-rpath," out "/lib -Wl,-rpath,")
917 (string-append "PREFIX=" out))))))))
918 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
15378f93
EF
919 (native-inputs
920 `(("perl" ,perl)
921 ("pkg-config" ,pkg-config)
922 ("python" ,python-2)
923 ("qtdeclarative" ,qtdeclarative)))
924 (inputs
925 `(("alsa-lib" ,alsa-lib)
926 ("mesa" ,mesa)
927 ("pulseaudio" ,pulseaudio)
04231311
RW
928 ("qtbase" ,qtbase)
929 ;; Gstreamer is needed for the mediaplayer plugin
930 ("gstreamer" ,gstreamer)
96412f34
EF
931 ("gst-plugins-base" ,gst-plugins-base)))
932 (synopsis "Qt Multimedia module")
933 (description "The Qt Multimedia module provides set of APIs to play and
934record media, and manage a collection of media content. It also contains a
935set of plugins for interacting with pulseaudio and GStreamer.")))
15378f93 936
bc8ede01
EF
937(define-public qtwayland
938 (package (inherit qtsvg)
939 (name "qtwayland")
418c62ff 940 (version "5.9.4")
bc8ede01
EF
941 (source (origin
942 (method url-fetch)
943 (uri (string-append "https://download.qt.io/official_releases/qt/"
944 (version-major+minor version) "/" version
945 "/submodules/" name "-opensource-src-"
946 version ".tar.xz"))
947 (sha256
948 (base32
418c62ff 949 "0x4q17k23akf14i3pyllr96s8lvprk1x006wp0mi5rhk4199cx1z"))
924e6ddf
EF
950 (modules '((guix build utils)))
951 (snippet
952 ;; The examples try to build and cause the build to fail
6cbee49d
MW
953 '(begin (delete-file-recursively "examples")
954 #t))))
6fc0e157
SB
955 (arguments
956 (substitute-keyword-arguments (package-arguments qtsvg)
957 ((#:phases phases)
958 `(modify-phases ,phases
959 (add-before 'check 'set-ld-library-path
960 ;; <https://lists.gnu.org/archive/html/guix-devel/2017-09/msg00019.html>
961 ;;
962 ;; Make the uninstalled libQt5WaylandClient.so.5 available to the
963 ;; wayland platform plugin.
964 (lambda _
965 (setenv "LD_LIBRARY_PATH" (string-append (getcwd) "/lib"))
966 #t))))))
bc8ede01
EF
967 (native-inputs
968 `(("glib" ,glib)
969 ("perl" ,perl)
970 ("pkg-config" ,pkg-config)
971 ("qtdeclarative" ,qtdeclarative)))
972 (inputs
973 `(("fontconfig" ,fontconfig)
974 ("freetype" ,freetype)
975 ("libx11" ,libx11)
976 ("libxcomposite" ,libxcomposite)
977 ("libxext" ,libxext)
978 ("libxkbcommon" ,libxkbcommon)
979 ("libxrender" ,libxrender)
980 ("mesa" ,mesa)
981 ("mtdev" ,mtdev)
982 ("qtbase" ,qtbase)
96412f34
EF
983 ("wayland" ,wayland)))
984 (synopsis "Qt Wayland module")
985 (description "The Qt Wayland module provides the QtWayland client and
986compositor libraries.")))
bc8ede01 987
00806f2b
EF
988(define-public qtserialport
989 (package (inherit qtsvg)
990 (name "qtserialport")
418c62ff 991 (version "5.9.4")
00806f2b
EF
992 (source (origin
993 (method url-fetch)
994 (uri (string-append "https://download.qt.io/official_releases/qt/"
995 (version-major+minor version) "/" version
996 "/submodules/" name "-opensource-src-"
997 version ".tar.xz"))
998 (sha256
999 (base32
418c62ff 1000 "172i5cpqnk0c3m0hg08hgj15qvsyd1xvw9yf2dqicg3l10lqwg8c"))))
00806f2b 1001 (native-inputs `(("perl" ,perl)))
33741e16
EF
1002 (inputs
1003 `(("qtbase" ,qtbase)
96412f34 1004 ("eudev" ,eudev)))
042f7c26
HG
1005 (arguments
1006 (substitute-keyword-arguments (package-arguments qtsvg)
1007 ((#:phases phases)
1008 `(modify-phases ,phases
1009 (add-after 'unpack 'patch-dlopen-paths
1010 (lambda* (#:key inputs #:allow-other-keys)
1011 (substitute* "src/serialport/qtudev_p.h"
1012 ;; Use the absolute paths for dynamically loaded libs,
1013 ;; otherwise the lib will be searched in LD_LIBRARY_PATH which
1014 ;; typically is not set in guix.
1015 (("^\\s*(udevLibrary->setFileNameAndVersion\\(QStringLiteral\\(\")(udev\"\\),\\s*[0-9]+\\);)" _ a b)
1016 (string-append a (assoc-ref inputs "eudev") "/lib/lib" b)))
1017 #t))))))
96412f34
EF
1018 (synopsis "Qt Serial Port module")
1019 (description "The Qt Serial Port module provides the library for
1020interacting with serial ports from within Qt.")))
00806f2b 1021
a98ffab5
EF
1022(define-public qtserialbus
1023 (package (inherit qtsvg)
1024 (name "qtserialbus")
418c62ff 1025 (version "5.9.4")
a98ffab5
EF
1026 (source (origin
1027 (method url-fetch)
1028 (uri (string-append "https://download.qt.io/official_releases/qt/"
1029 (version-major+minor version) "/" version
1030 "/submodules/" name "-opensource-src-"
1031 version ".tar.xz"))
1032 (sha256
1033 (base32
418c62ff 1034 "1i6b7w9z30mzzi0dcmrxx1scpzpnnw2fag1igvrnzvw1jwp414ff"))))
a98ffab5
EF
1035 (inputs
1036 `(("qtbase" ,qtbase)
96412f34
EF
1037 ("qtserialport" ,qtserialport)))
1038 (synopsis "Qt Serial Bus module")
1039 (description "The Qt Serial Bus API provides classes and functions to
1040access the various industrial serial buses and protocols, such as CAN, ModBus,
1041and others.")))
a98ffab5 1042
f5377013
EF
1043(define-public qtwebchannel
1044 (package (inherit qtsvg)
1045 (name "qtwebchannel")
418c62ff 1046 (version "5.9.4")
f5377013
EF
1047 (source (origin
1048 (method url-fetch)
1049 (uri (string-append "https://download.qt.io/official_releases/qt/"
1050 (version-major+minor version) "/" version
1051 "/submodules/" name "-opensource-src-"
1052 version ".tar.xz"))
1053 (sha256
1054 (base32
418c62ff 1055 "1acs0fa5rxm3cir0lydc9a8685qagf1786vkssv51wk3v9r3lc4h"))))
f5377013
EF
1056 (native-inputs
1057 `(("perl" ,perl)
1058 ("qtdeclarative" ,qtdeclarative)
1059 ("qtwebsockets" ,qtwebsockets)))
96412f34
EF
1060 (inputs `(("qtbase" ,qtbase)))
1061 (synopsis "Web communication library for Qt")
1062 (description "The Qt WebChannel module enables peer-to-peer communication
1063between the host (QML/C++ application) and the client (HTML/JavaScript
1064application). The transport mechanism is supported out of the box by the two
1065popular web engines, Qt WebKit 2 and Qt WebEngine.")))
f5377013 1066
d5ca54ce
EF
1067(define-public qtlocation
1068 (package (inherit qtsvg)
1069 (name "qtlocation")
418c62ff 1070 (version "5.9.4")
d5ca54ce
EF
1071 (source (origin
1072 (method url-fetch)
1073 (uri (string-append "https://download.qt.io/official_releases/qt/"
1074 (version-major+minor version) "/" version
1075 "/submodules/" name "-opensource-src-"
1076 version ".tar.xz"))
1077 (sha256
1078 (base32
418c62ff 1079 "186jzv19v674n8jmm13v5xwv211lygih5657rlvbhc1s4jq6iv9p"))))
c195b5ba
EF
1080 (arguments
1081 (substitute-keyword-arguments (package-arguments qtsvg)
1082 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
d5ca54ce
EF
1083 (native-inputs
1084 `(("perl" ,perl)
1085 ("qtdeclarative" ,qtdeclarative)
9a935ef2 1086 ("qtquickcontrols" ,qtquickcontrols)
d5ca54ce 1087 ("qtserialport" ,qtserialport)))
924e6ddf
EF
1088 (inputs
1089 `(("icu4c" ,icu4c)
1090 ("openssl" ,openssl)
1091 ("qtbase" ,qtbase)
96412f34
EF
1092 ("zlib" ,zlib)))
1093 (synopsis "Qt Location and Positioning modules")
1094 (description "The Qt Location module provides an interface for location,
1095positioning and geolocation plugins.")))
d5ca54ce 1096
d438c968
EF
1097(define-public qttools
1098 (package (inherit qtsvg)
1099 (name "qttools")
418c62ff 1100 (version "5.9.4")
d438c968
EF
1101 (source (origin
1102 (method url-fetch)
1103 (uri (string-append "https://download.qt.io/official_releases/qt/"
1104 (version-major+minor version) "/" version
1105 "/submodules/" name "-opensource-src-"
1106 version ".tar.xz"))
1107 (sha256
1108 (base32
418c62ff 1109 "11vfk6c8snsqwqj1xk53c0h2mkqr4gfa9kinp8py56x7sn15galm"))))
c195b5ba
EF
1110 (arguments
1111 (substitute-keyword-arguments (package-arguments qtsvg)
1112 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
d438c968
EF
1113 (native-inputs
1114 `(("perl" ,perl)
1115 ("qtdeclarative" ,qtdeclarative)))
1116 (inputs
1117 `(("mesa" ,mesa)
96412f34
EF
1118 ("qtbase" ,qtbase)))
1119 (synopsis "Qt Tools and Designer modules")
1120 (description "The Qt Tools module provides a set of applications to browse
1121the documentation, translate applications, generate help files and other stuff
1122that helps in Qt development.")))
d438c968 1123
4742c4de
EF
1124(define-public qtscript
1125 (package (inherit qtsvg)
1126 (name "qtscript")
418c62ff 1127 (version "5.9.4")
4742c4de
EF
1128 (source (origin
1129 (method url-fetch)
1130 (uri (string-append "https://download.qt.io/official_releases/qt/"
1131 (version-major+minor version) "/" version
1132 "/submodules/" name "-opensource-src-"
1133 version ".tar.xz"))
1134 (sha256
1135 (base32
418c62ff 1136 "0lz0iv1baah7cxrpyiqzqp4fxxf75i21qd06ha7r5d80hq3xlia0"))
7c5cf7a2 1137 (patches (search-patches "qtscript-disable-tests.patch"))))
4742c4de
EF
1138 (native-inputs
1139 `(("perl" ,perl)
1140 ("qttools" ,qttools)))
1141 (inputs
96412f34
EF
1142 `(("qtbase" ,qtbase)))
1143 (synopsis "Qt Script module")
1144 (description "Qt provides support for application scripting with ECMAScript.
1145The following guides and references cover aspects of programming with
1146ECMAScript and Qt.")))
4742c4de 1147
ae0e5133
DC
1148(define-public qtquickcontrols
1149 (package (inherit qtsvg)
1150 (name "qtquickcontrols")
418c62ff 1151 (version "5.9.4")
ae0e5133
DC
1152 (source (origin
1153 (method url-fetch)
1154 (uri (string-append "https://download.qt.io/official_releases/qt/"
1155 (version-major+minor version) "/" version
1156 "/submodules/" name "-opensource-src-"
1157 version ".tar.xz"))
1158 (sha256
1159 (base32
418c62ff 1160 "12yrmv6afjbd1fw3r8zjdrbq5l7cy7k5bxcyiv1m97gykfh0b8hn"))))
c195b5ba
EF
1161 (arguments
1162 (substitute-keyword-arguments (package-arguments qtsvg)
1163 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
ae0e5133
DC
1164 (inputs
1165 `(("qtbase" ,qtbase)
96412f34
EF
1166 ("qtdeclarative" ,qtdeclarative)))
1167 (synopsis "Qt Quick Controls and other Quick modules")
1168 (description "The QtScript module provides classes for making Qt
1169applications scriptable. This module provides a set of extra components that
1170can be used to build complete interfaces in Qt Quick.")))
ae0e5133 1171
42da1492
DC
1172(define-public qtquickcontrols2
1173 (package (inherit qtsvg)
1174 (name "qtquickcontrols2")
418c62ff 1175 (version "5.9.4")
42da1492
DC
1176 (source (origin
1177 (method url-fetch)
1178 (uri (string-append "https://download.qt.io/official_releases/qt/"
1179 (version-major+minor version) "/" version
1180 "/submodules/" name "-opensource-src-"
1181 version ".tar.xz"))
1182 (sha256
1183 (base32
418c62ff 1184 "0334ayansm743kf113rs3k9hi9qb6giscfx9xig3y1z7asisfa0m"))))
c195b5ba
EF
1185 (arguments
1186 (substitute-keyword-arguments (package-arguments qtsvg)
1187 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
42da1492
DC
1188 (inputs
1189 `(("qtbase" ,qtbase)
96412f34
EF
1190 ("qtdeclarative" ,qtdeclarative)))
1191 (synopsis "Qt Quick Controls 2 and other Quick 2 modules")
1192 (description "The Qt Quick Controls 2 module contains the Qt Labs Platform
1193module that provides platform integration: native dialogs, menus and menu bars,
1194and tray icons. It falls back to Qt Widgets when a native implementation is
1195not available.")))
42da1492 1196
4e4ed0ee
DC
1197(define-public qtgraphicaleffects
1198 (package (inherit qtsvg)
1199 (name "qtgraphicaleffects")
418c62ff 1200 (version "5.9.4")
4e4ed0ee
DC
1201 (source (origin
1202 (method url-fetch)
1203 (uri (string-append "https://download.qt.io/official_releases/qt/"
1204 (version-major+minor version) "/" version
1205 "/submodules/" name "-opensource-src-"
1206 version ".tar.xz"))
1207 (sha256
1208 (base32
418c62ff 1209 "1vxq4j7cb5cya1g234rxhfb361n45gp8c70gj8pc03njswkm7xwp"))))
c195b5ba
EF
1210 (arguments
1211 (substitute-keyword-arguments (package-arguments qtsvg)
1212 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
4e4ed0ee
DC
1213 (inputs
1214 `(("qtbase" ,qtbase)
96412f34
EF
1215 ("qtdeclarative" ,qtdeclarative)))
1216 (synopsis "Qt Graphical Effects module")
1217 (description "The Qt Graphical Effects module provides a set of QML types
1218for adding visually impressive and configurable effects to user interfaces.
1219Effects are visual items that can be added to Qt Quick user interface as UI
1220components. The API consists of over 20 effects provided as separate QML
1221types. The effects cover functional areas such as blending, masking, blurring,
1222coloring, and many more.")))
4e4ed0ee 1223
843bdfb7 1224(define-public qtdeclarative-render2d
a20e00dd 1225 ;; As of Qt-5.8.0 this module has been merged into qtdeclarative
843bdfb7
EF
1226 (package (inherit qtsvg)
1227 (name "qtdeclarative-render2d")
1228 (version "5.7.1")
1229 (source (origin
1230 (method url-fetch)
1231 (uri (string-append "https://download.qt.io/official_releases/qt/"
1232 (version-major+minor version) "/" version
1233 "/submodules/" name "-opensource-src-"
1234 version ".tar.xz"))
1235 (sha256
1236 (base32
1237 "0zwch9vn17f3bpy300jcfxx6cx9qymk5j7khx0x9k1xqid4166c3"))
1238 (modules '((guix build utils)))
1239 (snippet
6cbee49d
MW
1240 '(begin (delete-file-recursively "tools/opengldummy/3rdparty")
1241 #t))))
843bdfb7
EF
1242 (native-inputs `())
1243 (inputs
1244 `(("qtbase" ,qtbase)
a20e00dd 1245 ("qtdeclarative" ,qtdeclarative)))
96412f34
EF
1246 (synopsis "Qt Declarative Render module")
1247 (description "The Qt Declarative Render 2D module provides a Raster
1248backend for QtQuick scene graph.")
a20e00dd 1249 (properties `((superseded . ,qtdeclarative)))))
843bdfb7 1250
51519fd3
EF
1251(define-public qtgamepad
1252 (package (inherit qtsvg)
1253 (name "qtgamepad")
418c62ff 1254 (version "5.9.4")
51519fd3
EF
1255 (source (origin
1256 (method url-fetch)
1257 (uri (string-append "https://download.qt.io/official_releases/qt/"
1258 (version-major+minor version) "/" version
1259 "/submodules/" name "-opensource-src-"
1260 version ".tar.xz"))
1261 (sha256
1262 (base32
418c62ff 1263 "1ci6aapq0i8qbzkn9xxvxn1n81z3y28yrlyzw0anqzj9qp97cl6f"))))
51519fd3
EF
1264 (native-inputs
1265 `(("perl" ,perl)
1266 ("pkg-config" ,pkg-config)))
1267 (inputs
1268 `(("fontconfig" ,fontconfig)
1269 ("freetype" ,freetype)
1270 ("libxrender" ,libxrender)
1271 ("sdl2" ,sdl2)
1272 ("qtbase" ,qtbase)
96412f34
EF
1273 ("qtdeclarative" ,qtdeclarative)))
1274 (synopsis "Qt Gamepad module")
1275 (description "The Qt Gamepad module is an add-on library that enables Qt
1276applications to support the use of gamepad hardware and in some cases remote
1277control equipment. The module provides both QML and C++ interfaces. The
1278primary target audience are embedded devices with fullscreen user interfaces,
1279and mobile applications targeting TV-like form factors.")))
51519fd3 1280
56cd88fd
EF
1281(define-public qtscxml
1282 (package (inherit qtsvg)
1283 (name "qtscxml")
418c62ff 1284 (version "5.9.4")
56cd88fd
EF
1285 (source (origin
1286 (method url-fetch)
1287 (uri (string-append "https://download.qt.io/official_releases/qt/"
1288 (version-major+minor version) "/" version
1289 "/submodules/" name "-opensource-src-"
1290 version ".tar.xz"))
1291 (sha256
1292 (base32
418c62ff 1293 "0x8bjp9jzib4kfn7rbricw4qr259qqsdbrz0dw39453s2m7cbv0x"))
56cd88fd
EF
1294 (modules '((guix build utils)))
1295 (snippet
c195b5ba
EF
1296 '(begin
1297 (delete-file-recursively "tests/3rdparty")
1298 ;; the scion test refers to the bundled 3rd party test code.
1299 (substitute* "tests/auto/auto.pro"
6cbee49d
MW
1300 (("scion") "#"))
1301 #t))))
56cd88fd
EF
1302 (inputs
1303 `(("qtbase" ,qtbase)
96412f34
EF
1304 ("qtdeclarative" ,qtdeclarative)))
1305 (synopsis "Qt SCXML module")
1306 (description "The Qt SCXML module provides functionality to create state
1307machines from SCXML files. This includes both dynamically creating state
1308machines (loading the SCXML file and instantiating states and transitions) and
1309generating a C++ file that has a class implementing the state machine. It
1310also contains functionality to support data models and executable content.")))
56cd88fd 1311
de5e0180
EF
1312(define-public qtpurchasing
1313 (package (inherit qtsvg)
1314 (name "qtpurchasing")
418c62ff 1315 (version "5.9.4")
de5e0180
EF
1316 (source (origin
1317 (method url-fetch)
1318 (uri (string-append "https://download.qt.io/official_releases/qt/"
1319 (version-major+minor version) "/" version
1320 "/submodules/" name "-opensource-src-"
1321 version ".tar.xz"))
1322 (sha256
1323 (base32
418c62ff 1324 "08sk8vw16pa1qv36rfr9dsbzlwlv6kznfpsq8wfabhkgbfl6awqs"))))
de5e0180
EF
1325 (inputs
1326 `(("qtbase" ,qtbase)
96412f34
EF
1327 ("qtdeclarative" ,qtdeclarative)))
1328 (synopsis "Qt Purchasing module")
1329 (description "The Qt Purchasing module provides and in-app API for
1330purchasing goods and services.")))
de5e0180 1331
173b54b9
EF
1332(define-public qtcanvas3d
1333 (package (inherit qtsvg)
1334 (name "qtcanvas3d")
418c62ff 1335 (version "5.9.4")
173b54b9
EF
1336 (source (origin
1337 (method url-fetch)
1338 (uri (string-append "https://download.qt.io/official_releases/qt/"
1339 (version-major+minor version) "/" version
1340 "/submodules/" name "-opensource-src-"
1341 version ".tar.xz"))
1342 (sha256
1343 (base32
418c62ff 1344 "0agdxgk7knf6zkjdi6316y2k9zq72wcg5zn3cbhw4hzjw81qadgg"))
173b54b9
EF
1345 (modules '((guix build utils)))
1346 (snippet
6cbee49d
MW
1347 '(begin (delete-file-recursively "examples/canvas3d/3rdparty")
1348 #t))))
c195b5ba
EF
1349 (arguments
1350 (substitute-keyword-arguments (package-arguments qtsvg)
1351 ;; Building the tests depends on the bundled 3rd party javascript files,
1352 ;; and the test phase fails to import QtCanvas3D, causing the phase to
1353 ;; fail, so we skip building them for now.
1354 ((#:phases phases)
1355 `(modify-phases ,phases
1356 (replace 'configure
1357 (lambda* (#:key outputs #:allow-other-keys)
1358 (let ((out (assoc-ref outputs "out")))
1359 (zero? (system* "qmake" "QT_BUILD_PARTS = libs tools"
1360 (string-append "PREFIX=" out))))))))
1361 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
173b54b9
EF
1362 (native-inputs `())
1363 (inputs
1364 `(("qtbase" ,qtbase)
96412f34
EF
1365 ("qtdeclarative" ,qtdeclarative)))
1366 (synopsis "Qt Canvas 3D module")
1367 (description "The Qt Canvas 3D module provides a way to make WebGL-like 3D
1368drawing calls from Qt Quick JavaScript.")))
173b54b9 1369
68bbe14b
EF
1370(define-public qtcharts
1371 (package (inherit qtsvg)
1372 (name "qtcharts")
418c62ff 1373 (version "5.9.4")
68bbe14b
EF
1374 (source (origin
1375 (method url-fetch)
1376 (uri (string-append "https://download.qt.io/official_releases/qt/"
1377 (version-major+minor version) "/" version
1378 "/submodules/" name "-opensource-src-"
1379 version ".tar.xz"))
1380 (sha256
1381 (base32
418c62ff 1382 "1rykb72gr95rxd0rvbl846ys8xvyyhrms1jz7l4hlwp6zn1jkxvm"))))
c195b5ba
EF
1383 (arguments
1384 (substitute-keyword-arguments (package-arguments qtsvg)
1385 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
68bbe14b
EF
1386 (inputs
1387 `(("qtbase" ,qtbase)
96412f34
EF
1388 ("qtdeclarative" ,qtdeclarative)))
1389 (synopsis "Qt Charts module")
1390 (description "The Qt Charts module provides a set of easy to use chart
1391components. It uses the Qt Graphics View Framework, therefore charts can be
1392easily integrated to modern user interfaces. Qt Charts can be used as QWidgets,
1393QGraphicsWidget, or QML types. Users can easily create impressive graphs by
9c2c524d
EF
1394selecting one of the charts themes.")
1395 (license license:gpl3)))
68bbe14b 1396
a69945a7
EF
1397(define-public qtdatavis3d
1398 (package (inherit qtsvg)
1399 (name "qtdatavis3d")
418c62ff 1400 (version "5.9.4")
a69945a7
EF
1401 (source (origin
1402 (method url-fetch)
1403 (uri (string-append "https://download.qt.io/official_releases/qt/"
1404 (version-major+minor version) "/" version
1405 "/submodules/" name "-opensource-src-"
1406 version ".tar.xz"))
1407 (sha256
1408 (base32
418c62ff 1409 "1ggwfnqf17mp5dkfr82q1qrimkb6wv3304vl8mjv1nq0zisckhjv"))))
c195b5ba
EF
1410 (arguments
1411 (substitute-keyword-arguments (package-arguments qtsvg)
1412 ((#:tests? _ #f) #f))) ; TODO: Enable the tests
a69945a7
EF
1413 (inputs
1414 `(("qtbase" ,qtbase)
96412f34
EF
1415 ("qtdeclarative" ,qtdeclarative)))
1416 (synopsis "Qt Data Visualization module")
1417 (description "The Qt Data Visualization module provides a way to visualize
1418data in 3D as bar, scatter, and surface graphs. It is especially useful for
1419visualizing depth maps and large quantities of rapidly changing data, such as
1420data received from multiple sensors. The look and feel of graphs can be
9c2c524d
EF
1421customized by using themes or by adding custom items and labels to them.")
1422 (license license:gpl3)))
f47d2793
EF
1423
1424(define-public qtnetworkauth
1425 (package (inherit qtsvg)
1426 (name "qtnetworkauth")
418c62ff 1427 (version "5.9.4")
f47d2793
EF
1428 (source (origin
1429 (method url-fetch)
1430 (uri (string-append "https://download.qt.io/official_releases/qt/"
1431 (version-major+minor version) "/" version
1432 "/submodules/" name "-opensource-src-"
1433 version ".tar.xz"))
1434 (sha256
1435 (base32
418c62ff 1436 "0mqcqkp9h5bgzb3wfy239wh1c9s9zxd7mww11c0jyp56wk5balcx"))))
f18c9470
EF
1437 (arguments
1438 (substitute-keyword-arguments (package-arguments qtsvg)
1439 ((#:phases phases)
1440 `(modify-phases ,phases
1441 (add-after 'unpack 'remove-failing-test
1442 (lambda _
1443 ;; These tests can't find their test data.
1444 (substitute* "tests/auto/auto.pro"
1445 (("oauth1 ") "# oauth1 "))
1446 #t))))))
f47d2793 1447 (inputs
96412f34
EF
1448 `(("qtbase" ,qtbase)))
1449 (synopsis "Qt Network Authorization module")
1450 (description "The Qt Network Authorization module provides an
1451implementation of OAuth and OAuth2 authenticathon methods for Qt.")))
213238d9
EF
1452
1453(define-public qtremoteobjects
1454 (package (inherit qtsvg)
1455 (name "qtremoteobjects")
418c62ff 1456 (version "5.9.4")
213238d9
EF
1457 (source (origin
1458 (method url-fetch)
1459 (uri (string-append "https://download.qt.io/official_releases/qt/"
1460 (version-major+minor version) "/" version
1461 "/submodules/" name "-opensource-src-"
1462 version ".tar.xz"))
1463 (sha256
1464 (base32
418c62ff 1465 "1wb50dapv0l45c0rfmpiaddvwv9na50lmd5zmm052q9d1xb15f6b"))))
213238d9
EF
1466 (inputs
1467 `(("qtbase" ,qtbase)
96412f34
EF
1468 ("qtdeclarative" ,qtdeclarative)))
1469 (synopsis "Qt Remote Objects module")
1470 (description "The Qt Remote Objects module is an @dfn{inter-process
1471communication} (IPC) module developed for Qt. The idea is to extend existing
1472Qt's functionalities to enable an easy exchange of information between
1473processes or computers.")))
b84cc89a
EF
1474
1475(define-public qtspeech
1476 (package (inherit qtsvg)
1477 (name "qtspeech")
418c62ff 1478 (version "5.9.4")
b84cc89a
EF
1479 (source (origin
1480 (method url-fetch)
1481 (uri (string-append "https://download.qt.io/official_releases/qt/"
1482 (version-major+minor version) "/" version
1483 "/submodules/" name "-opensource-src-"
1484 version ".tar.xz"))
1485 (sha256
1486 (base32
418c62ff 1487 "17h8hrixxcsn7pd5iipbj2hxpp5m2dhfq3w04wkamambb49qs80x"))))
b84cc89a
EF
1488 (inputs
1489 `(("qtbase" ,qtbase)))
1490 (native-inputs
1491 `(("perl" ,perl)
1492 ("qtdeclarative" ,qtdeclarative)
1493 ("qtmultimedia" ,qtmultimedia)
96412f34
EF
1494 ("qtxmlpatterns" ,qtxmlpatterns)))
1495 (synopsis "Qt Speech module")
1496 (description "The Qt Speech module enables a Qt application to support
1497accessibility features such as text-to-speech, which is useful for end-users
1498who are visually challenged or cannot access the application for whatever
1499reason. The most common use case where text-to-speech comes in handy is when
1500the end-user is driving and cannot attend the incoming messages on the phone.
1501In such a scenario, the messaging application can read out the incoming
1502message.")))
a69945a7 1503
84ef83dd
AE
1504(define-public python-sip
1505 (package
1506 (name "python-sip")
079e6792 1507 (version "4.19.3")
84ef83dd
AE
1508 (source
1509 (origin
1510 (method url-fetch)
1511 (uri
1512 (string-append "mirror://sourceforge/pyqt/sip/"
8fa7f8d9 1513 "sip-" version "/sip-" version ".tar.gz"))
84ef83dd
AE
1514 (sha256
1515 (base32
079e6792 1516 "0x2bghbprwl3az1ni3p87i0bq8r99694la93kg65vi0cz12gh3bl"))))
84ef83dd
AE
1517 (build-system gnu-build-system)
1518 (native-inputs
1519 `(("python" ,python-wrapper)))
1520 (arguments
1521 `(#:tests? #f ; no check target
e8bdd73a
AE
1522 #:modules ((srfi srfi-1)
1523 ,@%gnu-build-system-modules)
84ef83dd 1524 #:phases
39766868
EF
1525 (modify-phases %standard-phases
1526 (replace 'configure
1527 (lambda* (#:key inputs outputs #:allow-other-keys)
1528 (let* ((out (assoc-ref outputs "out"))
1529 (bin (string-append out "/bin"))
1530 (include (string-append out "/include"))
1531 (python (assoc-ref inputs "python"))
1532 (python-version
1533 (last (string-split python #\-)))
1534 (python-major+minor
1535 (string-join
1536 (take (string-split python-version #\.) 2)
1537 "."))
1538 (lib (string-append out "/lib/python"
1539 python-major+minor
1540 "/site-packages")))
1541 (zero?
1542 (system* "python" "configure.py"
1543 "--bindir" bin
1544 "--destdir" lib
1545 "--incdir" include))))))))
1546 (home-page "https://www.riverbankcomputing.com/software/sip/intro")
84ef83dd
AE
1547 (synopsis "Python binding creator for C and C++ libraries")
1548 (description
1549 "SIP is a tool to create Python bindings for C and C++ libraries. It
1550was originally developed to create PyQt, the Python bindings for the Qt
1551toolkit, but can be used to create bindings for any C or C++ library.
1552
1553SIP comprises a code generator and a Python module. The code generator
1554processes a set of specification files and generates C or C++ code, which
1555is then compiled to create the bindings extension module. The SIP Python
1556module provides support functions to the automatically generated code.")
1557 ;; There is a choice between a python like license, gpl2 and gpl3.
1558 ;; For compatibility with pyqt, we need gpl3.
225941b0 1559 (license license:gpl3)))
84ef83dd
AE
1560
1561(define-public python2-sip
1562 (package (inherit python-sip)
1563 (name "python2-sip")
1564 (native-inputs
1565 `(("python" ,python-2)))))
014e7dd8
AE
1566
1567(define-public python-pyqt
1568 (package
1569 (name "python-pyqt")
28d0b521 1570 (version "5.9")
014e7dd8
AE
1571 (source
1572 (origin
1573 (method url-fetch)
1574 (uri
1575 (string-append "mirror://sourceforge/pyqt/PyQt5/"
2be06813 1576 "PyQt-" version "/PyQt5_gpl-"
014e7dd8
AE
1577 version ".tar.gz"))
1578 (sha256
1579 (base32
28d0b521 1580 "15hh4z5vd45dcswjla58q6rrfr6ic7jfz2n7c8lwfb10rycpj3mb"))
fc1adab1 1581 (patches (search-patches "pyqt-configure.patch"))))
014e7dd8
AE
1582 (build-system gnu-build-system)
1583 (native-inputs
499991cf
EB
1584 `(("qtbase" ,qtbase))) ; for qmake
1585 (propagated-inputs
1586 `(("python-sip" ,python-sip)))
014e7dd8 1587 (inputs
e9adcd81
EF
1588 `(("python" ,python-wrapper)
1589 ("qtbase" ,qtbase)
1590 ("qtconnectivity" ,qtconnectivity)
1591 ("qtdeclarative" ,qtdeclarative)
1592 ("qtlocation" ,qtlocation)
1593 ("qtmultimedia" ,qtmultimedia)
1594 ("qtsensors" ,qtsensors)
1595 ("qtserialport" ,qtserialport)
1596 ("qtsvg" ,qtsvg)
1597 ("qttools" ,qttools)
1598 ("qtwebchannel" ,qtwebchannel)
1599 ("qtwebkit" ,qtwebkit)
1600 ("qtwebsockets" ,qtwebsockets)
1601 ("qtx11extras" ,qtx11extras)
1602 ("qtxmlpatterns" ,qtxmlpatterns)))
014e7dd8 1603 (arguments
e8bdd73a
AE
1604 `(#:modules ((srfi srfi-1)
1605 ,@%gnu-build-system-modules)
1606 #:phases
eef988c8
EF
1607 (modify-phases %standard-phases
1608 (replace 'configure
1609 (lambda* (#:key inputs outputs #:allow-other-keys)
1610 (let* ((out (assoc-ref outputs "out"))
1611 (bin (string-append out "/bin"))
1612 (sip (string-append out "/share/sip"))
1613 (plugins (string-append out "/plugins"))
1614 (designer (string-append plugins "/designer"))
1615 (qml (string-append plugins "/PyQt5"))
1616 (python (assoc-ref inputs "python"))
1617 (python-version
1618 (last (string-split python #\-)))
1619 (python-major+minor
1620 (string-join
1621 (take (string-split python-version #\.) 2)
1622 "."))
1623 (lib (string-append out "/lib/python"
1624 python-major+minor
43e8824d
HG
1625 "/site-packages"))
1626 (stubs (string-append lib "/PyQt5")))
eef988c8
EF
1627 (zero? (system* "python" "configure.py"
1628 "--confirm-license"
1629 "--bindir" bin
1630 "--destdir" lib
1631 "--designer-plugindir" designer
1632 "--qml-plugindir" qml
43e8824d
HG
1633 ; Where to install the PEP 484 Type Hints stub
1634 ; files. Without this the stubs are tried to be
1635 ; installed into the python package's
1636 ; site-package directory, which is read-only.
1637 "--stubsdir" stubs
eef988c8
EF
1638 "--sipdir" sip))))))))
1639 (home-page "https://www.riverbankcomputing.com/software/pyqt/intro")
014e7dd8
AE
1640 (synopsis "Python bindings for Qt")
1641 (description
1642 "PyQt is a set of Python v2 and v3 bindings for the Qt application
1643framework. The bindings are implemented as a set of Python modules and
1644contain over 620 classes.")
225941b0 1645 (license license:gpl3)))
014e7dd8
AE
1646
1647(define-public python2-pyqt
1648 (package (inherit python-pyqt)
1649 (name "python2-pyqt")
1650 (native-inputs
1651 `(("python-sip" ,python2-sip)
2be06813 1652 ("qtbase" ,qtbase)))
014e7dd8 1653 (inputs
e9adcd81
EF
1654 `(("python" ,python-2)
1655 ,@(alist-delete "python" (package-inputs python-pyqt))))))
3e291958
AE
1656
1657(define-public python-pyqt-4
1658 (package (inherit python-pyqt)
1659 (name "python-pyqt")
41fa164a 1660 (version "4.12")
3e291958
AE
1661 (source
1662 (origin
1663 (method url-fetch)
1664 (uri
1665 (string-append "mirror://sourceforge/pyqt/PyQt4/"
41fa164a 1666 "PyQt-" version "/PyQt4_gpl_x11-"
3e291958
AE
1667 version ".tar.gz"))
1668 (sha256
1669 (base32
41fa164a 1670 "1nw8r88a5g2d550yvklawlvns8gd5slw53yy688kxnsa65aln79w"))))
3e291958
AE
1671 (native-inputs
1672 `(("python-sip" ,python-sip)
1673 ("qt" ,qt-4)))
e9adcd81 1674 (inputs `(("python" ,python-wrapper)))
3e291958
AE
1675 (arguments
1676 `(#:tests? #f ; no check target
e8bdd73a
AE
1677 #:modules ((srfi srfi-1)
1678 ,@%gnu-build-system-modules)
3e291958 1679 #:phases
f9513086
EF
1680 (modify-phases %standard-phases
1681 (replace 'configure
1682 (lambda* (#:key inputs outputs #:allow-other-keys)
1683 (let* ((out (assoc-ref outputs "out"))
1684 (bin (string-append out "/bin"))
1685 (sip (string-append out "/share/sip"))
1686 (python (assoc-ref inputs "python"))
1687 (python-version
1688 (last (string-split python #\-)))
1689 (python-major+minor
1690 (string-join
1691 (take (string-split python-version #\.) 2)
1692 "."))
1693 (lib (string-append out "/lib/python"
1694 python-major+minor
1695 "/site-packages")))
1696 (zero? (system* "python" "configure.py"
1697 "--confirm-license"
1698 "--bindir" bin
1699 "--destdir" lib
1700 "--sipdir" sip))))))))
225941b0 1701 (license (list license:gpl2 license:gpl3)))) ; choice of either license
3e291958 1702
6d8e14d0 1703(define-public python2-pyqt-4
1704 (package (inherit python-pyqt-4)
9fde8778 1705 (name "python2-pyqt")
6d8e14d0 1706 (native-inputs
1707 `(("python-sip" ,python2-sip)
1708 ("qt" ,qt-4)))
1709 (inputs
1710 `(("python" ,python-2)))))
1711
3befd0a9
RW
1712(define-public qscintilla
1713 (package
1714 (name "qscintilla")
0af6ffdd 1715 (version "2.10.2")
3befd0a9
RW
1716 (source (origin
1717 (method url-fetch)
1718 (uri (string-append "mirror://sourceforge/pyqt/QScintilla2/"
1719 "QScintilla-" version "/QScintilla_gpl-"
1720 version ".tar.gz"))
1721 (sha256
1722 (base32
0af6ffdd 1723 "1l2ylsv6s3wfhyx7qr5cxgkwwwhvbrpd2k7akgm9bvbyf4h1vcql"))))
3befd0a9
RW
1724 (build-system gnu-build-system)
1725 (arguments
1726 `(#:phases
1727 (modify-phases %standard-phases
1728 (replace 'configure
1729 (lambda* (#:key outputs #:allow-other-keys)
1730 (let ((out (assoc-ref outputs "out")))
1731 (chdir "Qt4Qt5")
1732 (substitute* "qscintilla.pro"
1733 (("\\$\\$\\[QT_INSTALL_LIBS\\]")
1734 (string-append out "/lib"))
1735 (("\\$\\$\\[QT_INSTALL_HEADERS\\]")
1736 (string-append out "/include"))
1737 (("\\$\\$\\[QT_INSTALL_TRANSLATIONS\\]")
1738 (string-append out "/translations"))
5430732b
HG
1739 (("\\$\\$\\[QT_INSTALL_DATA\\]")
1740 (string-append out "/lib/qt$${QT_MAJOR_VERSION}"))
1741 (("\\$\\$\\[QT_HOST_DATA\\]")
1742 (string-append out "/lib/qt$${QT_MAJOR_VERSION}")))
0af6ffdd 1743 (invoke "qmake")))))))
3befd0a9 1744 (native-inputs `(("qtbase" ,qtbase)))
d338321d 1745 (home-page "https://www.riverbankcomputing.co.uk/software/qscintilla/intro")
3befd0a9
RW
1746 (synopsis "Qt port of the Scintilla C++ editor control")
1747 (description "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++
1748editor control. QScintilla includes features especially useful when editing
1749and debugging source code. These include support for syntax styling, error
1750indicators, code completion and call tips.")
1751 (license license:gpl3+)))
1752
06d04dbc
RW
1753(define-public python-qscintilla
1754 (package (inherit qscintilla)
1755 (name "python-qscintilla")
1756 (arguments
1757 `(#:configure-flags
1758 (list "--pyqt=PyQt5"
1759 (string-append "--pyqt-sipdir="
1760 (assoc-ref %build-inputs "python-pyqt")
1761 "/share/sip")
1762 (string-append "--qsci-incdir="
1763 (assoc-ref %build-inputs "qscintilla")
1764 "/include")
1765 (string-append "--qsci-libdir="
1766 (assoc-ref %build-inputs "qscintilla")
1767 "/lib"))
1768 #:phases
1769 (modify-phases %standard-phases
1770 (replace 'configure
1771 (lambda* (#:key outputs configure-flags #:allow-other-keys)
1772 (chdir "Python")
76c7fc43
MW
1773 (apply invoke "python3" "configure.py"
1774 configure-flags)
1775 ;; Install to the right directory
1776 (substitute* '("Makefile"
1777 "Qsci/Makefile")
1778 (("\\$\\(INSTALL_ROOT\\)/gnu/store/[^/]+")
1779 (assoc-ref outputs "out")))
1780 #t)))))
06d04dbc
RW
1781 (inputs
1782 `(("qscintilla" ,qscintilla)
1783 ("python" ,python)
1784 ("python-pyqt" ,python-pyqt)))
1785 (description "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++
1786editor control. QScintilla includes features especially useful when editing
1787and debugging source code. These include support for syntax styling, error
1788indicators, code completion and call tips.
1789
1790This package provides the Python bindings.")))
1791
2456153a
RW
1792;; PyQt only looks for modules in its own directory. It ignores environment
1793;; variables such as PYTHONPATH, so we need to build a union package to make
1794;; it work.
1795(define-public python-pyqt+qscintilla
1796 (package (inherit python-pyqt)
1797 (name "python-pyqt+qscintilla")
1798 (source #f)
1799 (build-system trivial-build-system)
1800 (arguments
1801 '(#:modules ((guix build union))
1802 #:builder (begin
1803 (use-modules (ice-9 match)
1804 (guix build union))
1805 (match %build-inputs
1806 (((names . directories) ...)
1807 (union-build (assoc-ref %outputs "out")
1808 directories))))))
1809 (inputs
1810 `(("python-pyqt" ,python-pyqt)
1811 ("python-qscintilla" ,python-qscintilla)))
1812 (synopsis "Union of PyQt and the Qscintilla extension")
1813 (description
1814 "This package contains the union of PyQt and the Qscintilla extension.")))
1815
9e81af9e
EF
1816(define-public qtkeychain
1817 (package
1818 (name "qtkeychain")
4ad70ad8 1819 (version "0.8.0")
9e81af9e
EF
1820 (source
1821 (origin
1822 (method url-fetch)
1823 (uri (string-append "https://github.com/frankosterfeld/qtkeychain/"
1824 "archive/v" version ".tar.gz"))
1825 (file-name (string-append name "-" version ".tar.gz"))
1826 (sha256
4ad70ad8 1827 (base32 "0bxi5pfhxdvwk8yxa06lk2d7lcibmfqhahbin82bqf3m341zd4ml"))))
9e81af9e 1828 (build-system cmake-build-system)
18174d8a 1829 (native-inputs
f8127d26
HG
1830 `(("pkg-config" ,pkg-config)
1831 ("qttools" ,qttools)))
9e81af9e 1832 (inputs
18174d8a 1833 `(("qtbase" ,qtbase)))
9e81af9e
EF
1834 (arguments
1835 `(#:tests? #f ; No tests included
1836 #:phases
1837 (modify-phases %standard-phases
1838 (add-before
1839 'configure 'set-qt-trans-dir
1840 (lambda _
1841 (substitute* "CMakeLists.txt"
1842 (("\\$\\{qt_translations_dir\\}")
4ad70ad8
EF
1843 "${CMAKE_INSTALL_PREFIX}/share/qt/translations"))
1844 #t)))))
9e81af9e
EF
1845 (home-page "https://github.com/frankosterfeld/qtkeychain")
1846 (synopsis "Qt API to store passwords")
1847 (description
1848 "QtKeychain is a Qt library to store passwords and other secret data
1849securely. It will not store any data unencrypted unless explicitly requested.")
225941b0 1850 (license license:bsd-3)))
fc381a33
TD
1851
1852(define-public qwt
1853 (package
1854 (name "qwt")
1855 (version "6.1.3")
1856 (source
1857 (origin
1858 (method url-fetch)
1859 (uri
1860 (string-append "mirror://sourceforge/qwt/qwt/"
1861 version "/qwt-" version ".tar.bz2"))
1862 (sha256
1863 (base32 "0cwp63s03dw351xavb3pzbjlqvx7kj88wv7v4a2b18m9f97d7v7k"))))
1864 (build-system gnu-build-system)
1865 (inputs
1866 `(("qtbase" ,qtbase)
1867 ("qtsvg" ,qtsvg)
1868 ("qttools" ,qttools)))
1869 (arguments
1870 `(#:phases
1871 (modify-phases %standard-phases
1872 (replace 'configure
1873 (lambda* (#:key outputs #:allow-other-keys)
163651cb
SB
1874 (let* ((out (assoc-ref outputs "out"))
1875 (docdir (string-append out "/share/doc/qwt"))
1876 (incdir (string-append out "/include/qwt"))
1877 (pluginsdir (string-append out "/lib/qt5/plugins/designer"))
1878 (featuresdir (string-append out "/lib/qt5/mkspecs/features")))
fc381a33 1879 (substitute* '("qwtconfig.pri")
163651cb
SB
1880 (("^(\\s*QWT_INSTALL_PREFIX)\\s*=.*" _ x)
1881 (format #f "~a = ~a\n" x out))
1882 (("^(QWT_INSTALL_DOCS)\\s*=.*" _ x)
1883 (format #f "~a = ~a\n" x docdir))
1884 (("^(QWT_INSTALL_HEADERS)\\s*=.*" _ x)
1885 (format #f "~a = ~a\n" x incdir))
1886 (("^(QWT_INSTALL_PLUGINS)\\s*=.*" _ x)
1887 (format #f "~a = ~a\n" x pluginsdir))
1888 (("^(QWT_INSTALL_FEATURES)\\s*=.*" _ x)
1889 (format #f "~a = ~a\n" x featuresdir)))
1890 (substitute* '("doc/doc.pro")
1891 ;; We'll install them in the 'install-man-pages' phase.
1892 (("^unix:doc\\.files.*") ""))
fc381a33 1893 (zero? (system* "qmake")))))
163651cb 1894 (add-after 'install 'install-man-pages
fc381a33
TD
1895 (lambda* (#:key outputs #:allow-other-keys)
1896 (let* ((out (assoc-ref outputs "out"))
1897 (man (string-append out "/share/man")))
1898 ;; Remove some incomplete manual pages.
1899 (for-each delete-file (find-files "doc/man/man3" "^_tmp.*"))
1900 (mkdir-p man)
1901 (copy-recursively "doc/man" man)
1902 #t))))))
1903 (home-page "http://qwt.sourceforge.net")
1904 (synopsis "Qt widgets for plots, scales, dials and other technical software
1905GUI components")
1906 (description
1907 "The Qwt library contains widgets and components which are primarily useful
1908for technical and scientific purposes. It includes a 2-D plotting widget,
1909different kinds of sliders, and much more.")
1910 (license
1911 (list
1912 ;; The Qwt license is LGPL2.1 with some exceptions.
1913 (license:non-copyleft "http://qwt.sourceforge.net/qwtlicense.html")
1914 ;; textengines/mathml/qwt_mml_document.{cpp,h} is dual LGPL2.1/GPL3 (either).
1915 license:lgpl2.1 license:gpl3))))
47e1d280
TD
1916
1917(define-public qtwebkit
1918 (package
1919 (name "qtwebkit")
fdaf6cd3 1920 (version "5.9.1")
47e1d280
TD
1921 (source
1922 (origin
1923 (method url-fetch)
fdaf6cd3
EF
1924 (uri (string-append "https://download.qt.io/official_releases/qt/"
1925 (version-major+minor version) "/" version
1926 "/submodules/" name "-opensource-src-"
a20e00dd 1927 version ".tar.xz"))
47e1d280
TD
1928 (sha256
1929 (base32
fdaf6cd3 1930 "1ksjn1vjbfhdm4y4rg08ag4krk87ahp7qcdcpwll42l0rnz61998"))))
47e1d280
TD
1931 (build-system gnu-build-system)
1932 (native-inputs
1933 `(("perl" ,perl)
1934 ("python" ,python-2.7)
1935 ("ruby" ,ruby)
1936 ("bison" ,bison)
1937 ("flex" ,flex)
1938 ("gperf" ,gperf)
1939 ("pkg-config" ,pkg-config)))
1940 (inputs
1941 `(("icu" ,icu4c)
1942 ("libjpeg" ,libjpeg)
1943 ("libpng" ,libpng)
1944 ("libwebp" ,libwebp)
1945 ("sqlite" ,sqlite)
1946 ("fontconfig" ,fontconfig)
1947 ("libxrender", libxrender)
1948 ("qtbase" ,qtbase)
1949 ("qtdeclarative" ,qtdeclarative)
1950 ("qtmultimedia" ,qtmultimedia)
1951 ("libxml2" ,libxml2)
1952 ("libxslt" ,libxslt)
1953 ("libx11" ,libx11)
1954 ("libxcomposite" ,libxcomposite)))
1955 (arguments
1956 `(#:phases
1957 (modify-phases %standard-phases
4eb972b9
HG
1958 (add-before 'configure 'fix-qmlwebkit-plugins-rpath
1959 (lambda _
1960 (substitute* "Source/WebKit/qt/declarative/experimental/experimental.pri"
1961 (("RPATHDIR_RELATIVE_TO_DESTDIR = \\.\\./\\.\\./lib")
1962 "RPATHDIR_RELATIVE_TO_DESTDIR = ../../../../../lib"))
1963 (substitute* "Source/WebKit/qt/declarative/public.pri"
1964 (("RPATHDIR_RELATIVE_TO_DESTDIR = \\.\\./\\.\\./lib")
1965 "RPATHDIR_RELATIVE_TO_DESTDIR = ../../../../lib"))
1966 #t))
47e1d280
TD
1967 (replace 'configure
1968 (lambda* (#:key outputs #:allow-other-keys)
1969 (let ((out (assoc-ref outputs "out")))
1970 (setenv "QMAKEPATH"
1971 (string-append (getcwd) "/Tools/qmake:"
1972 (getenv "QMAKEPATH")))
1973 (system* "qmake"))))
1974 ;; prevent webkit from trying to install into the qtbase store directory,
1975 ;; and replace references to the build directory in linker options:
1976 (add-before 'build 'patch-installpaths
1977 (lambda* (#:key outputs inputs #:allow-other-keys)
1978 (let* ((out (assoc-ref outputs "out"))
1979 (qtbase (assoc-ref inputs "qtbase"))
1980 (builddir (getcwd))
1981 (linkbuild (string-append "-L" builddir))
1982 (linkout (string-append "-L" out))
1983 (makefiles
1984 (map-in-order
1985 (lambda (i)
1986 (let* ((in (car i))
1987 (mf (string-append (dirname in) "/"
1988 (cdr i))))
1989 ;; by default, these Makefiles are
1990 ;; generated during install, but we need
1991 ;; to generate them now
1992 (system* "qmake" in "-o" mf)
1993 mf))
1994 '(("Source/api.pri" . "Makefile.api")
1995 ("Source/widgetsapi.pri"
1996 . "Makefile.widgetsapi")
1997 ("Source/WebKit2/WebProcess.pro"
1998 . "Makefile.WebProcess")
1999 ("Source/WebKit2/PluginProcess.pro"
2000 . "Makefile.PluginProcess")
2001 ("Source/WebKit/qt/declarative/public.pri"
2002 . "Makefile.declarative.public")
2003 ("Source/WebKit/qt/declarative/experimental/experimental.pri"
2004 . "Makefile.declarative.experimental")
2005 ("Source/WebKit/qt/examples/platformplugin/platformplugin.pro"
2006 . "Makefile")))))
2007 ;; Order of qmake calls and substitutions matters here.
2008 (system* "qmake" "-prl" "Source/widgetsapi.pri"
2009 "-o" "Source/Makefile")
2010 (substitute* (find-files "lib" "libQt5.*\\.prl")
2011 ((linkbuild) linkout))
2012 (substitute* (find-files "lib"
2013 "libQt5WebKit.*\\.la")
2014 (("libdir='.*'")
2015 (string-append "libdir='" out "/lib'"))
2016 ((linkbuild) linkout))
2017 (substitute* (find-files "lib/pkgconfig"
2018 "Qt5WebKit.*\\.pc")
2019 (((string-append "prefix=" qtbase))
2020 (string-append "prefix=" out))
2021 ((linkbuild) linkout))
2022 ;; Makefiles must be modified after .prl/.la/.pc
2023 ;; files, lest they get rebuilt:
2024 (substitute* makefiles
2025 (((string-append "\\$\\(INSTALL_ROOT\\)" qtbase))
2026 out )
2027 (((string-append "-Wl,-rpath," builddir))
2028 (string-append "-Wl,-rpath," out)))))))))
2029 (home-page "https://www.webkit.org")
2030 (synopsis "Web browser engine and classes to render and interact with web
2031content")
2032 (description "QtWebKit provides a Web browser engine that makes it easy to
2033embed content from the World Wide Web into your Qt application. At the same
2034time Web content can be enhanced with native controls.")
2035
2036 (license license:lgpl2.1+)))
f048f12b 2037
2038(define-public dotherside
2039 (package
2040 (name "dotherside")
8895a968 2041 (version "0.6.3")
f048f12b 2042 (source
2043 (origin
2044 (method url-fetch)
2045 (uri (string-append "https://github.com/filcuc/DOtherSide/"
2046 "archive/v" version ".tar.gz"))
2047 (file-name (string-append name "-" version ".tar.gz"))
2048 (sha256
2049 (base32
8895a968 2050 "0azq7qlsrfdwbd6qsi7d3c1knn42qw0r47g43xf7clwbinapswpz"))))
f048f12b 2051 (build-system cmake-build-system)
2052 (native-inputs
2053 `(("qttools" ,qttools)))
2054 (inputs
2055 `(("qtbase" ,qtbase)
2056 ("qtdeclarative" ,qtdeclarative)))
2057 (home-page "https://github.com/frankosterfeld/qtkeychain")
2058 (synopsis "C language library for creating bindings for the Qt QML language")
2059 (description
2060 "DOtherSide is a C language library for creating bindings for the
2061QT QML language. The following features are implementable from
2062a binding language:
2063@itemize
2064@item Creating custom QObject
2065@item Creating custom QAbstractListModels
2066@item Creating custom properties, signals and slots
2067@item Creating from QML QObject defined in the binded language
2068@item Creating from Singleton QML QObject defined in the binded language
2069@end itemize\n")
2070 (license license:lgpl3))) ;version 3 only (+ exception)