| 1 | ;;; GNU Guix --- Functional package management for GNU |
| 2 | ;;; Copyright © 2013, 2014, 2015, 2023, 2026 Andreas Enge <[email protected]> |
| 3 | ;;; Copyright © 2015, 2025 宋文武 <[email protected]> |
| 4 | ;;; Copyright © 2015, 2018-2021, 2023, 2025 Ludovic Courtès <[email protected]> |
| 5 | ;;; Copyright © 2015-2019, 2024, 2025 Efraim Flashner <[email protected]> |
| 6 | ;;; Copyright © 2016, 2017 Nikita <[email protected]> |
| 7 | ;;; Copyright © 2016 Thomas Danckaert <[email protected]> |
| 8 | ;;; Copyright © 2017, 2018, 2019, 2023 Ricardo Wurmus <[email protected]> |
| 9 | ;;; Copyright © 2017 Quiliro <[email protected]> |
| 10 | ;;; Copyright © 2017, 2018, 2020, 2021 Tobias Geerinckx-Rice <[email protected]> |
| 11 | ;;; Copyright © 2018, 2020, 2022 Nicolas Goaziou <[email protected]> |
| 12 | ;;; Copyright © 2018 Hartmut Goebel <[email protected]> |
| 13 | ;;; Copyright © 2018 Eric Bavier <[email protected]> |
| 14 | ;;; Copyright © 2019, 2020, 2022 Marius Bakke <[email protected]> |
| 15 | ;;; Copyright © 2018 John Soo <[email protected]> |
| 16 | ;;; Copyright © 2020 Mike Rosset <[email protected]> |
| 17 | ;;; Copyright © 2020 Jakub Kądziołka <[email protected]> |
| 18 | ;;; Copyright © 2020 Kei Kebreau <[email protected]> |
| 19 | ;;; Copyright © 2020 TomZ <[email protected]> |
| 20 | ;;; Copyright © 2020 Jonathan Brielmaier <[email protected]> |
| 21 | ;;; Copyright © 2020 Michael Rohleder <[email protected]> |
| 22 | ;;; Copyright © 2020-2026 Maxim Cournoyer <[email protected]> |
| 23 | ;;; Copyright © 2021, 2022, 2025 Brendan Tildesley <[email protected]> |
| 24 | ;;; Copyright © 2021, 2022, 2023 Guillaume Le Vaillant <[email protected]> |
| 25 | ;;; Copyright © 2021 Nicolò Balzarotti <[email protected]> |
| 26 | ;;; Copyright © 2022 Foo Chuan Wei <[email protected]> |
| 27 | ;;; Copyright © 2022 Zhu Zihao <[email protected]> |
| 28 | ;;; Copyright © 2022 Petr Hodina <[email protected]> |
| 29 | ;;; Copyright © 2022 Yash Tiwari <[email protected]> |
| 30 | ;;; Copyright © 2023 Sharlatan Hellseher <[email protected]> |
| 31 | ;;; Copyright © 2022, 2024, 2025 Zheng Junjie <[email protected]> |
| 32 | ;;; Copyright © 2023 Herman Rimm <[email protected]> |
| 33 | ;;; Copyright © 2023 Simon South <[email protected]> |
| 34 | ;;; Copyright © 2024 Foundation Devices, Inc. <[email protected]> |
| 35 | ;;; Copyright © 2024 Josep Bigorra <[email protected]> |
| 36 | ;;; Copyright © 2025 John Kehayias <[email protected]> |
| 37 | ;;; Copyright © 2024, 2026 Sughosha <[email protected]> |
| 38 | ;;; Copyright © 2025 Brice Waegeneire <[email protected]> |
| 39 | ;;; Copyright © 2025 Laura Kirsch <[email protected]> |
| 40 | ;;; Copyright © 2026 bdunahu <[email protected]> |
| 41 | ;;; |
| 42 | ;;; This file is part of GNU Guix. |
| 43 | ;;; |
| 44 | ;;; GNU Guix is free software; you can redistribute it and/or modify it |
| 45 | ;;; under the terms of the GNU General Public License as published by |
| 46 | ;;; the Free Software Foundation; either version 3 of the License, or (at |
| 47 | ;;; your option) any later version. |
| 48 | ;;; |
| 49 | ;;; GNU Guix is distributed in the hope that it will be useful, but |
| 50 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of |
| 51 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 52 | ;;; GNU General Public License for more details. |
| 53 | ;;; |
| 54 | ;;; You should have received a copy of the GNU General Public License |
| 55 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. |
| 56 | |
| 57 | (define-module (gnu packages qt) |
| 58 | #:use-module ((guix licenses) #:prefix license:) |
| 59 | #:use-module (guix packages) |
| 60 | #:use-module (guix download) |
| 61 | #:use-module (guix git-download) |
| 62 | #:use-module (guix build-system cmake) |
| 63 | #:use-module (guix build-system gnu) |
| 64 | #:use-module (guix build-system meson) |
| 65 | #:use-module (guix build-system trivial) |
| 66 | #:use-module (guix build-system pyproject) |
| 67 | #:use-module (guix build-system qt) |
| 68 | #:use-module (guix gexp) |
| 69 | #:use-module (guix packages) |
| 70 | #:use-module (guix deprecation) |
| 71 | #:use-module (guix search-paths) |
| 72 | #:use-module (guix utils) |
| 73 | #:use-module (gnu packages) |
| 74 | #:use-module (gnu packages backup) |
| 75 | #:use-module (gnu packages bash) |
| 76 | #:use-module (gnu packages base) |
| 77 | #:use-module (gnu packages bison) |
| 78 | #:use-module (gnu packages build-tools) |
| 79 | #:use-module (gnu packages crypto) |
| 80 | #:use-module (gnu packages check) |
| 81 | #:use-module (gnu packages cmake) |
| 82 | #:use-module (gnu packages compression) |
| 83 | #:use-module (gnu packages cpp) |
| 84 | #:use-module (gnu packages cups) |
| 85 | #:use-module (gnu packages curl) |
| 86 | #:use-module (gnu packages databases) |
| 87 | #:use-module (gnu packages dlang) |
| 88 | #:use-module (gnu packages documentation) |
| 89 | #:use-module (gnu packages elf) |
| 90 | #:use-module (gnu packages enchant) |
| 91 | #:use-module (gnu packages fontutils) |
| 92 | #:use-module (gnu packages compiler-tools) |
| 93 | #:use-module (gnu packages freedesktop) |
| 94 | #:use-module (gnu packages gcc) |
| 95 | #:use-module (gnu packages gdb) |
| 96 | #:use-module (gnu packages ghostscript) |
| 97 | #:use-module (gnu packages gl) |
| 98 | #:use-module (gnu packages glib) |
| 99 | #:use-module (gnu packages gnome) |
| 100 | #:use-module (gnu packages gnupg) |
| 101 | #:use-module (gnu packages gperf) |
| 102 | #:use-module (gnu packages graphics) |
| 103 | #:use-module (gnu packages gstreamer) |
| 104 | #:use-module (gnu packages gtk) |
| 105 | #:use-module (gnu packages icu4c) |
| 106 | #:use-module (gnu packages image) |
| 107 | #:use-module (gnu packages image-processing) |
| 108 | #:use-module (gnu packages kde-frameworks) |
| 109 | #:use-module (gnu packages kde-sdk) |
| 110 | #:use-module (gnu packages libevent) |
| 111 | #:use-module (gnu packages linux) |
| 112 | #:use-module (gnu packages llvm) |
| 113 | #:use-module (gnu packages logging) |
| 114 | #:use-module (gnu packages maths) |
| 115 | #:use-module (gnu packages markup) |
| 116 | #:use-module (gnu packages networking) |
| 117 | #:use-module (gnu packages node) |
| 118 | #:use-module (gnu packages nss) |
| 119 | #:use-module (gnu packages pciutils) |
| 120 | #:use-module (gnu packages pcre) |
| 121 | #:use-module (gnu packages perl) |
| 122 | #:use-module (gnu packages pkg-config) |
| 123 | #:use-module (gnu packages pulseaudio) |
| 124 | #:use-module (gnu packages pretty-print) |
| 125 | #:use-module (gnu packages protobuf) |
| 126 | #:use-module (gnu packages python) |
| 127 | #:use-module (gnu packages python-build) |
| 128 | #:use-module (gnu packages python-check) |
| 129 | #:use-module (gnu packages python-web) |
| 130 | #:use-module (gnu packages python-xyz) |
| 131 | #:use-module (gnu packages regex) |
| 132 | #:use-module (gnu packages ruby) |
| 133 | #:use-module (gnu packages rust-sources) |
| 134 | #:use-module (gnu packages sdl) |
| 135 | #:use-module (gnu packages serialization) |
| 136 | #:use-module (gnu packages sqlite) |
| 137 | #:use-module (gnu packages telephony) |
| 138 | #:use-module (gnu packages tls) |
| 139 | #:use-module (gnu packages toolkits) |
| 140 | #:use-module (gnu packages valgrind) |
| 141 | #:use-module (gnu packages video) |
| 142 | #:use-module (gnu packages vulkan) |
| 143 | #:use-module (gnu packages web) |
| 144 | #:use-module (gnu packages xdisorg) |
| 145 | #:use-module (gnu packages xiph) |
| 146 | #:use-module (gnu packages xorg) |
| 147 | #:use-module (gnu packages xml) |
| 148 | #:use-module (ice-9 format) |
| 149 | #:use-module (ice-9 match) |
| 150 | #:use-module (srfi srfi-1)) |
| 151 | |
| 152 | (define-public qtappinstancemanager |
| 153 | (package |
| 154 | (name "qtappinstancemanager") |
| 155 | (version "1.3.2") |
| 156 | (source |
| 157 | (origin |
| 158 | (method git-fetch) |
| 159 | (uri (git-reference |
| 160 | (url "https://github.com/oclero/qtappinstancemanager") |
| 161 | (commit (string-append "v" version)))) |
| 162 | (file-name (git-file-name name version)) |
| 163 | (sha256 |
| 164 | (base32 "12vfhjvxlnnm3wszv5qs7c1925gywgm00583ppnx0ab3k8iswqwd")))) |
| 165 | (build-system cmake-build-system) |
| 166 | (arguments |
| 167 | (list |
| 168 | #:tests? #f)) ;no tests |
| 169 | (inputs (list qtbase)) |
| 170 | (synopsis "Single application instance manager for Qt6") |
| 171 | (description |
| 172 | "QtAppInstanceManager is a tool to control how many instances of your Qt |
| 173 | application are running at the same time, and to send messages between |
| 174 | instances. It uses a local socket under the hood. You may then build upon this |
| 175 | foundation any messaging system or protocol, such as JSON-RPC for |
| 176 | instance (NB: not provided because out of the scope of this library). |
| 177 | |
| 178 | It is intended to be a replacement for QtSingleApplication, the deprecated Qt4 |
| 179 | official project.") |
| 180 | (home-page "https://github.com/oclero/qtappinstancemanager") |
| 181 | (license license:expat))) |
| 182 | |
| 183 | (define-public qcoro-qt6 |
| 184 | (package |
| 185 | (name "qcoro-qt6") |
| 186 | (version "0.11.0") |
| 187 | (source |
| 188 | (origin |
| 189 | (method git-fetch) |
| 190 | (uri (git-reference |
| 191 | (url "https://github.com/danvratil/qcoro") |
| 192 | (commit (string-append "v" version)))) |
| 193 | (file-name (git-file-name name version)) |
| 194 | (sha256 |
| 195 | (base32 "0g9laaw1mkp5ynpp3c7aingndcmgncbacslq3p6bzwjisdd6xr5m")))) |
| 196 | (build-system qt-build-system) |
| 197 | (arguments |
| 198 | (list #:qtbase qtbase |
| 199 | #:configure-flags |
| 200 | #~(list "-DCMAKE_CXX_FLAGS=-fPIC" |
| 201 | "-DUSE_QT_VERSION=6"))) |
| 202 | (native-inputs (list dbus)) ;for tests |
| 203 | (inputs (list qtdeclarative qtwebsockets libxkbcommon)) |
| 204 | (home-page "https://qcoro.dvratil.cz/") |
| 205 | (synopsis "C++ Coroutine Library for Qt6") |
| 206 | (description "QCoro is a C++ library that provide set of tools to make use |
| 207 | of C++20 coroutines in connection with certain asynchronous Qt actions.") |
| 208 | (license license:expat))) |
| 209 | |
| 210 | (define-public qlementine |
| 211 | (package |
| 212 | (name "qlementine") |
| 213 | (version "1.4.2") |
| 214 | (source |
| 215 | (origin |
| 216 | (method git-fetch) |
| 217 | (uri (git-reference |
| 218 | (url "https://github.com/oclero/qlementine") |
| 219 | (commit (string-append "v" version)))) |
| 220 | (file-name (git-file-name name version)) |
| 221 | (sha256 |
| 222 | (base32 "1cjch1jhlb67hcfgzf2vv5f9zlawr8ngl0gc43scplxdfpv3wda0")))) |
| 223 | (build-system cmake-build-system) |
| 224 | (arguments |
| 225 | (list |
| 226 | #:tests? #f)) ;no tests |
| 227 | (inputs (list qtbase qtsvg)) |
| 228 | (synopsis "Modern QStyle for desktop Qt6 applications") |
| 229 | (description "Qlementine is a modern QStyle for desktop Qt6 applications.") |
| 230 | (home-page "https://github.com/oclero/qlementine") |
| 231 | (license license:expat))) |
| 232 | |
| 233 | (define-public qlementine-icons |
| 234 | (package |
| 235 | (name "qlementine-icons") |
| 236 | (version "1.14.0") |
| 237 | (source |
| 238 | (origin |
| 239 | (method git-fetch) |
| 240 | (uri (git-reference |
| 241 | (url "https://github.com/oclero/qlementine-icons") |
| 242 | (commit (string-append "v" version)))) |
| 243 | (file-name (git-file-name name version)) |
| 244 | (sha256 |
| 245 | (base32 "187h8yvykah7xangbds9a0860p9p2fyf8v54y0ga2a3ygc7y5mfv")))) |
| 246 | (build-system cmake-build-system) |
| 247 | (arguments |
| 248 | (list |
| 249 | #:tests? #f)) ;no tests |
| 250 | (inputs (list qtbase qtsvg)) |
| 251 | (synopsis "Modern icon set for desktop Qt applications") |
| 252 | (description |
| 253 | "Qlementine Icons is a modern, vector, elegant, free, and open-source icon |
| 254 | library designed for use with a C++ library that enhances the appearance of |
| 255 | your QtWidgets application.") |
| 256 | (home-page "https://oclero.github.io/qlementine-icons/") |
| 257 | (license license:expat))) |
| 258 | |
| 259 | (define-public qmdnsengine |
| 260 | ;; Used as submodule in https://github.com/moonlight-stream/moonlight-qt |
| 261 | (let ((commit "b7a5a9f225d5e14b39f9fd1f905c4f505cf2ee99") |
| 262 | (revision "1")) |
| 263 | (package |
| 264 | (name "qmdnsengine") |
| 265 | (version (git-version "0.0.1" revision commit)) |
| 266 | (source (origin |
| 267 | (method git-fetch) |
| 268 | (uri (git-reference |
| 269 | (url "https://github.com/cgutman/qmdnsengine") |
| 270 | (commit commit))) |
| 271 | (file-name (git-file-name name version)) |
| 272 | (sha256 |
| 273 | (base32 |
| 274 | "1f5v5n9w4aszcdjxmw81cwmd26ssywvfiyr8x0vbyamp4kqd8mww")))) |
| 275 | (build-system cmake-build-system) |
| 276 | (arguments |
| 277 | '(#:configure-flags (list "-DBUILD_TESTS=ON"))) |
| 278 | (inputs (list qtbase-5)) |
| 279 | (synopsis "Multicast DNS library for Qt application") |
| 280 | (description "This package provides multicast DNS library for Qt |
| 281 | applications.") |
| 282 | (home-page "https://github.com/moonlight-stream/moonlight-common-c") |
| 283 | (license license:expat)))) |
| 284 | |
| 285 | (define-public qpropgen |
| 286 | (package |
| 287 | (name "qpropgen") |
| 288 | (version "0.1.2") |
| 289 | (source |
| 290 | (origin |
| 291 | (method git-fetch) |
| 292 | (uri (git-reference |
| 293 | (url "https://github.com/agateau/qpropgen") |
| 294 | (commit version))) |
| 295 | (file-name (git-file-name name version)) |
| 296 | (sha256 |
| 297 | (base32 |
| 298 | "0rrd7dbmhycqcxs2pkzcadjh2khhzqc69xzha003161hjdf3vh9f")))) |
| 299 | (build-system pyproject-build-system) |
| 300 | (arguments |
| 301 | (list |
| 302 | ;; XXX: 0.1.2 does not have tests/, examples are manual and require C++. |
| 303 | #:tests? #f |
| 304 | #:phases |
| 305 | #~(modify-phases %standard-phases |
| 306 | (add-after 'install 'install-cmake |
| 307 | (lambda _ |
| 308 | (install-file "cmake/qpropgen.cmake" |
| 309 | (string-append #$output "/share/" |
| 310 | #$name "/cmake"))))))) |
| 311 | (propagated-inputs (list python-jinja2 python-pyyaml python-strictyaml)) |
| 312 | (native-inputs (list python-pytest python-setuptools)) |
| 313 | (home-page "https://github.com/agateau/qpropgen") |
| 314 | (synopsis "Generates QObject properties from a YAML file") |
| 315 | (description "This package provides a tool to generate QML-friendly |
| 316 | QObject-based C++ classes from class definition files.") |
| 317 | (license license:asl2.0))) |
| 318 | |
| 319 | (define-public qite |
| 320 | (let ((commit "e9d33c84a0b346185b27efb44189f18acaa53906") |
| 321 | (revision "75")) |
| 322 | (package |
| 323 | (name "qite") |
| 324 | (version (git-version "0" revision commit)) |
| 325 | (source |
| 326 | (origin |
| 327 | (method git-fetch) |
| 328 | (uri |
| 329 | (git-reference |
| 330 | (url "https://github.com/Ri0n/qite") |
| 331 | (commit commit))) |
| 332 | (file-name (git-file-name name version)) |
| 333 | (sha256 |
| 334 | (base32 "13rwlb77hw44qksfh82mpklhkjr6z4pv1n4dj906hdw6213448vj")) |
| 335 | (modules '((guix build utils))) |
| 336 | (snippet |
| 337 | #~(begin |
| 338 | (substitute* "libqite/CMakeLists.txt" |
| 339 | (("CXX_STANDARD 14") "CXX_STANDARD 20")))))) |
| 340 | (build-system qt-build-system) |
| 341 | (arguments |
| 342 | `(#:tests? #f ; no target |
| 343 | #:phases |
| 344 | (modify-phases %standard-phases |
| 345 | (add-after 'unpack 'chdir |
| 346 | (lambda _ |
| 347 | (chdir "libqite")))))) |
| 348 | (inputs |
| 349 | (list qtbase-5 qtmultimedia-5)) |
| 350 | (home-page "https://github.com/Ri0n/qite/") |
| 351 | (synopsis "Qt Interactive Text Elements") |
| 352 | (description "Qite manages interactive elements on QTextEdit.") |
| 353 | (license license:asl2.0)))) |
| 354 | |
| 355 | (define-public qt5ct |
| 356 | (package |
| 357 | (name "qt5ct") |
| 358 | (version "1.9") |
| 359 | (source |
| 360 | (origin |
| 361 | (method url-fetch) |
| 362 | (uri |
| 363 | (string-append "mirror://sourceforge/qt5ct/qt5ct-" version ".tar.bz2")) |
| 364 | (sha256 |
| 365 | (base32 "1zwbb2jgwplbdizcra92q1hnynq13axzwryfh5cr4fs2kn9yc46w")))) |
| 366 | (build-system qt-build-system) |
| 367 | (arguments |
| 368 | (list |
| 369 | #:tests? #f ; No target |
| 370 | #:phases |
| 371 | #~(modify-phases %standard-phases |
| 372 | (add-after 'unpack 'patch |
| 373 | (lambda _ |
| 374 | (substitute* '("src/qt5ct-qtplugin/CMakeLists.txt" |
| 375 | "src/qt5ct-style/CMakeLists.txt") |
| 376 | (("\\$\\{PLUGINDIR\\}") |
| 377 | (string-append #$output "/lib/qt5/plugins")))))))) |
| 378 | (native-inputs |
| 379 | (list qttools-5)) |
| 380 | (inputs |
| 381 | (list qtsvg-5)) |
| 382 | (synopsis "Qt5 Configuration Tool") |
| 383 | (description "Qt5CT is a program that allows users to configure Qt5 |
| 384 | settings (such as icons, themes, and fonts) in desktop environments or |
| 385 | window managers, that don't provide Qt integration by themselves.") |
| 386 | (home-page "https://qt5ct.sourceforge.io/") |
| 387 | (license license:bsd-2))) |
| 388 | |
| 389 | (define-public qt6ct |
| 390 | (package |
| 391 | (name "qt6ct") |
| 392 | (version "0.11") |
| 393 | (source |
| 394 | (origin |
| 395 | (method git-fetch) |
| 396 | (uri (git-reference |
| 397 | (url "https://www.opencode.net/trialuser/qt6ct") |
| 398 | (commit version))) |
| 399 | (file-name (git-file-name name version)) |
| 400 | (sha256 |
| 401 | (base32 "17hfx90wnc40a1sq0qcdp2hml5mkjhlj5rwm95pc40p03nicpn67")))) |
| 402 | (build-system qt-build-system) |
| 403 | (arguments |
| 404 | (list |
| 405 | #:qtbase qtbase |
| 406 | #:tests? #f ; No target |
| 407 | #:phases |
| 408 | #~(modify-phases %standard-phases |
| 409 | (add-after 'unpack 'patch |
| 410 | (lambda _ |
| 411 | (substitute* '("src/qt6ct-qtplugin/CMakeLists.txt" |
| 412 | "src/qt6ct-style/CMakeLists.txt") |
| 413 | (("\\$\\{PLUGINDIR\\}") |
| 414 | (string-append #$output "/lib/qt6/plugins")))))))) |
| 415 | (native-inputs |
| 416 | (list qttools)) |
| 417 | (inputs |
| 418 | (list qtsvg |
| 419 | libxkbcommon)) |
| 420 | (synopsis "Qt6 Configuration Tool") |
| 421 | (description "Qt6CT is a program that allows users to configure Qt6 |
| 422 | settings (such as icons, themes, and fonts) in desktop environments or |
| 423 | window managers, that don't provide Qt integration by themselves.") |
| 424 | (home-page "https://www.opencode.net/trialuser/qt6ct") |
| 425 | (license license:bsd-2))) |
| 426 | |
| 427 | (define-public kddockwidgets |
| 428 | (package |
| 429 | (name "kddockwidgets") |
| 430 | (version "2.4.0") |
| 431 | (source (origin |
| 432 | (method git-fetch) |
| 433 | (uri (git-reference |
| 434 | (url "https://github.com/KDAB/KDDockWidgets") |
| 435 | (commit (string-append "v" version)))) |
| 436 | (file-name (git-file-name name version)) |
| 437 | (sha256 |
| 438 | (base32 |
| 439 | "0yrx6q74xb5ribah0naxln1sx4md9cakwn4jp0wbzapiyigh4apy")))) |
| 440 | (build-system cmake-build-system) |
| 441 | (arguments (list #:tests? #f |
| 442 | #:configure-flags #~(list |
| 443 | "-DKDDockWidgets_QT6=ON" |
| 444 | "-DKDDockWidgets_TESTS=ON"))) |
| 445 | (inputs |
| 446 | (list fmt-12 |
| 447 | nlohmann-json |
| 448 | qtbase |
| 449 | qtdeclarative |
| 450 | spdlog |
| 451 | libxkbcommon)) |
| 452 | (home-page "https://github.com/KDAB/KDDockWidgets") |
| 453 | (synopsis "KDAB's Dock Widget Framework for Qt") |
| 454 | (description "KDDockWidgets is a Qt dock widget library suitable for |
| 455 | replacing QDockWidget and implementing advanced functionalities missing in |
| 456 | Qt. Some of its features include: |
| 457 | @itemize |
| 458 | @item Advanced docking that QDockWidget doesn't support |
| 459 | @item Layout engine honouring size constraints and some size policies |
| 460 | @item Lazy separator resize |
| 461 | @item Reordering tabs with mouse |
| 462 | @item Partial layout save/restore, affecting only a chosen subset |
| 463 | @item Double-click on title bar to maximize |
| 464 | @item Double-click on separator to distribute equally |
| 465 | @item Show close button on tabs |
| 466 | @item Allows making a dock widget non-closable and/or non-dockable |
| 467 | @item Optional minimize and maximize button on the title bar |
| 468 | @item FloatingWindows can be utility windows or full native ones. |
| 469 | @end itemize") |
| 470 | (license (list license:gpl2 license:gpl3)))) ;dual-licensed |
| 471 | |
| 472 | (define-public kvantum |
| 473 | (package |
| 474 | (name "kvantum") |
| 475 | (version "1.1.5") |
| 476 | (source (origin |
| 477 | (method git-fetch) |
| 478 | (uri (git-reference |
| 479 | (url "https://github.com/tsujan/Kvantum") |
| 480 | (commit (string-append "V" version)))) |
| 481 | (file-name (git-file-name name version)) |
| 482 | (sha256 |
| 483 | (base32 |
| 484 | "17fjhnc8dpxb27dmv1c8mkcy2jwdny06zzqgd9zpamlqi97alp0v")) |
| 485 | (patches |
| 486 | (search-patches "kvantum-1.1.5-xdg-dirs-support.patch")))) |
| 487 | (build-system qt-build-system) |
| 488 | (arguments |
| 489 | (list |
| 490 | #:tests? #f ;no tests |
| 491 | #:qtbase qtbase |
| 492 | #:phases |
| 493 | #~(modify-phases %standard-phases |
| 494 | (add-after 'unpack 'chdir |
| 495 | (lambda _ |
| 496 | (chdir "Kvantum"))) |
| 497 | (add-after 'chdir 'patch-style-dir |
| 498 | (lambda _ |
| 499 | (substitute* "style/CMakeLists.txt" |
| 500 | (("\\$\\{KVANTUM_STYLE_DIR\\}") |
| 501 | (string-append #$output |
| 502 | "/lib/qt6/plugins/styles")))))))) |
| 503 | (native-inputs (list qttools)) |
| 504 | (inputs (list |
| 505 | kwindowsystem |
| 506 | qtsvg |
| 507 | qtwayland)) |
| 508 | (synopsis "SVG-based theme engine for Qt") |
| 509 | (description |
| 510 | "Kvantum is an SVG-based theme engine for Qt, |
| 511 | tuned to KDE and LXQt, with an emphasis on elegance, usability and |
| 512 | practicality.") |
| 513 | (home-page "https://github.com/tsujan/Kvantum") |
| 514 | (license license:gpl3+))) |
| 515 | |
| 516 | (define-public materialdecoration |
| 517 | (let ((commit "6a5de23f2e5162fbee39d16f938473ff970a2ec0") |
| 518 | (revision "9")) |
| 519 | (package |
| 520 | (name "materialdecoration") |
| 521 | (version |
| 522 | (git-version "1.1.0" revision commit)) |
| 523 | (source |
| 524 | (origin |
| 525 | (method git-fetch) |
| 526 | (uri |
| 527 | (git-reference |
| 528 | (url "https://github.com/lirios/materialdecoration.git") |
| 529 | (commit commit))) |
| 530 | (file-name |
| 531 | (git-file-name name version)) |
| 532 | (sha256 |
| 533 | (base32 "1zdrcb39fhhmn76w8anv1dnspz26pdl6izmj1mlm02aza4y8ffp4")) |
| 534 | (modules '((guix build utils) |
| 535 | (ice-9 ftw) |
| 536 | (srfi srfi-1))) |
| 537 | (snippet |
| 538 | `(begin |
| 539 | (delete-file-recursively "cmake/3rdparty"))))) |
| 540 | (build-system qt-build-system) |
| 541 | (arguments |
| 542 | `(#:tests? #f ; No target |
| 543 | #:configure-flags |
| 544 | ,#~(list |
| 545 | (string-append "-DCMAKE_CXX_FLAGS=-I" |
| 546 | #$(this-package-input "qtbase") |
| 547 | "/include/qt5/QtXkbCommonSupport/" |
| 548 | #$(package-version qtbase-5))))) |
| 549 | (native-inputs |
| 550 | (list cmake-shared extra-cmake-modules pkg-config)) |
| 551 | (inputs |
| 552 | (list qtbase-5 |
| 553 | qtwayland-5 |
| 554 | wayland |
| 555 | libxkbcommon)) |
| 556 | (synopsis "Material Decoration for Qt") |
| 557 | (description "MaterialDecoration is a client-side decoration for Qt |
| 558 | applications on Wayland.") |
| 559 | (home-page "https://github.com/lirios/materialdecoration") |
| 560 | (license license:lgpl3+)))) |
| 561 | |
| 562 | (define-public grantlee |
| 563 | (package |
| 564 | (name "grantlee") |
| 565 | (version "5.3.1") |
| 566 | (source |
| 567 | (origin |
| 568 | (method git-fetch) |
| 569 | (uri (git-reference |
| 570 | (url "https://github.com/steveire/grantlee") |
| 571 | (commit (string-append "v" version)))) |
| 572 | (file-name (git-file-name name version)) |
| 573 | (sha256 |
| 574 | (base32 "1ipnkdi8wgv519mvwa5zxlz20wipbypyfixjv2qdfd9vl1pznwvs")) |
| 575 | (patches (search-patches "grantlee-fix-i586-precision.patch" |
| 576 | "grantlee-register-metaenumvariable.patch")))) |
| 577 | (native-inputs |
| 578 | ;; Optional: lcov and cccc, both are for code coverage |
| 579 | (list doxygen)) |
| 580 | (inputs |
| 581 | (list qtdeclarative)) |
| 582 | (build-system qt-build-system) |
| 583 | (arguments |
| 584 | (list #:qtbase qtbase |
| 585 | #:configure-flags #~(list "-DGRANTLEE_BUILD_WITH_QT6=ON") |
| 586 | #:phases #~(modify-phases %standard-phases |
| 587 | (add-before 'check 'check-setup |
| 588 | (lambda _ |
| 589 | ;; make Qt render "offscreen", required for tests |
| 590 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 591 | (home-page "https://github.com/steveire/grantlee") |
| 592 | (synopsis "Libraries for text templating with Qt") |
| 593 | (description "Grantlee Templates can be used for theming and generation of |
| 594 | other text such as code. The syntax uses the syntax of the Django template |
| 595 | system, and the core design of Django is reused in Grantlee.") |
| 596 | (license license:lgpl2.1+))) |
| 597 | |
| 598 | (define (qt-url component version) |
| 599 | "Return a mirror URL for the Qt5 COMPONENT at VERSION." |
| 600 | ;; We can't use a mirror:// scheme because these URLs are not exact copies: |
| 601 | ;; the layout differs between them. |
| 602 | (let ((x (match (version-major version) |
| 603 | ("5" "-everywhere-opensource-src-") |
| 604 | ;; Version 6 and later dropped 'opensource' from the archive |
| 605 | ;; names. |
| 606 | (_ "-everywhere-src-")))) |
| 607 | (string-append "mirror://qt/qt/" |
| 608 | (version-major+minor version) "/" version |
| 609 | "/submodules/" component x version ".tar.xz"))) |
| 610 | |
| 611 | (define-public qtbase-5 |
| 612 | (package |
| 613 | (name "qtbase") |
| 614 | (version "5.15.17") |
| 615 | (source (origin |
| 616 | (method url-fetch) |
| 617 | (uri (qt-url name version)) |
| 618 | (sha256 |
| 619 | (base32 |
| 620 | "1zsnww4hp5n46jyg43w039lgxxrnjj1w0ngp54ibv9glng5i65fv")) |
| 621 | ;; Use TZDIR to avoid depending on package "tzdata". |
| 622 | (patches (search-patches "qtbase-5-use-TZDIR.patch" |
| 623 | "qtbase-moc-ignore-gcc-macro.patch" |
| 624 | "qtbase-absolute-runpath.patch")) |
| 625 | (modules '((guix build utils))) |
| 626 | (snippet |
| 627 | ;; corelib uses bundled harfbuzz, md4, md5, sha3 |
| 628 | '(begin |
| 629 | (with-directory-excursion "src/3rdparty" |
| 630 | (for-each delete-file-recursively |
| 631 | (list "double-conversion" "freetype" "harfbuzz-ng" |
| 632 | "libpng" "libjpeg" "pcre2" "sqlite" "xcb" |
| 633 | "zlib"))))))) |
| 634 | (build-system gnu-build-system) |
| 635 | (outputs '("out" "debug")) |
| 636 | (propagated-inputs |
| 637 | (list mesa |
| 638 | ;; Use which the package, not the function |
| 639 | (@ (gnu packages base) which))) |
| 640 | (inputs |
| 641 | (list alsa-lib |
| 642 | cups |
| 643 | dbus |
| 644 | double-conversion |
| 645 | eudev |
| 646 | expat |
| 647 | fontconfig |
| 648 | freetype |
| 649 | glib |
| 650 | gtk+ ;for GTK theme support |
| 651 | harfbuzz |
| 652 | icu4c |
| 653 | libinput-minimal |
| 654 | libjpeg-turbo |
| 655 | libmng |
| 656 | libpng |
| 657 | libx11 |
| 658 | libxcomposite |
| 659 | libxcursor |
| 660 | libxfixes |
| 661 | libxi |
| 662 | libxinerama |
| 663 | libxkbcommon |
| 664 | libxml2 |
| 665 | libxrandr |
| 666 | libxrender |
| 667 | libxslt |
| 668 | libxtst |
| 669 | mtdev |
| 670 | `(,mariadb "dev") |
| 671 | nss |
| 672 | openssl |
| 673 | pcre2 |
| 674 | postgresql |
| 675 | pulseaudio |
| 676 | sqlite |
| 677 | unixodbc |
| 678 | xcb-util |
| 679 | xcb-util-image |
| 680 | xcb-util-keysyms |
| 681 | xcb-util-renderutil |
| 682 | xcb-util-wm |
| 683 | xdg-utils |
| 684 | zlib)) |
| 685 | (native-inputs |
| 686 | (list bison |
| 687 | flex |
| 688 | gperf |
| 689 | perl |
| 690 | pkg-config |
| 691 | python |
| 692 | vulkan-headers |
| 693 | ruby-3.4)) |
| 694 | (arguments |
| 695 | `(#:disallowed-references ,(list (this-package-native-input "python")) |
| 696 | #:configure-flags |
| 697 | (let ((out (assoc-ref %outputs "out"))) |
| 698 | (list "-verbose" |
| 699 | "-prefix" out |
| 700 | "-docdir" (string-append out "/share/doc/qt5") |
| 701 | "-headerdir" (string-append out "/include/qt5") |
| 702 | "-archdatadir" (string-append out "/lib/qt5") |
| 703 | "-datadir" (string-append out "/share/qt5") |
| 704 | "-examplesdir" (string-append |
| 705 | out "/share/doc/qt5/examples") |
| 706 | "-opensource" |
| 707 | "-confirm-license" |
| 708 | |
| 709 | ;; Later stripped into the :debug output. |
| 710 | "-force-debug-info" |
| 711 | |
| 712 | ;; These features require higher versions of Linux than the |
| 713 | ;; minimum version of the glibc. See |
| 714 | ;; src/corelib/global/minimum-linux_p.h. By disabling these |
| 715 | ;; features Qt5 applications can be used on the oldest |
| 716 | ;; kernels that the glibc supports, including the RHEL6 |
| 717 | ;; (2.6.32) and RHEL7 (3.10) kernels. |
| 718 | "-no-feature-getentropy" ; requires Linux 3.17 |
| 719 | "-no-feature-renameat2" ; requires Linux 3.16 |
| 720 | |
| 721 | ;; Do not build examples; if desired, these could go |
| 722 | ;; into a separate output, but for the time being, we |
| 723 | ;; prefer to save the space and build time. |
| 724 | "-no-compile-examples" |
| 725 | ;; Most "-system-..." are automatic, but some use |
| 726 | ;; the bundled copy by default. |
| 727 | "-system-sqlite" |
| 728 | "-system-harfbuzz" |
| 729 | "-system-pcre" |
| 730 | ;; explicitly link with openssl instead of dlopening it |
| 731 | "-openssl-linked" |
| 732 | ;; explicitly link with dbus instead of dlopening it |
| 733 | "-dbus-linked" |
| 734 | ;; don't use the precompiled headers |
| 735 | "-no-pch" |
| 736 | ;; drop special machine instructions that do not have |
| 737 | ;; runtime detection |
| 738 | ,@(if (string-prefix? "x86_64" |
| 739 | (or (%current-target-system) |
| 740 | (%current-system))) |
| 741 | '() |
| 742 | '("-no-sse2")) |
| 743 | "-no-mips_dsp" |
| 744 | "-no-mips_dspr2")) |
| 745 | #:phases |
| 746 | (modify-phases %standard-phases |
| 747 | (add-after 'configure 'patch-bin-sh |
| 748 | (lambda _ |
| 749 | (substitute* '("config.status" |
| 750 | "configure" |
| 751 | "mkspecs/features/qt_functions.prf" |
| 752 | "qmake/library/qmakebuiltins.cpp") |
| 753 | (("/bin/sh") (which "sh"))))) |
| 754 | (add-after 'configure 'patch-xdg-open |
| 755 | (lambda _ |
| 756 | (substitute* '("src/platformsupport/services/genericunix/qgenericunixservices.cpp") |
| 757 | (("^.*const char \\*browsers.*$" all) |
| 758 | (string-append "*browser = QStringLiteral(\"" |
| 759 | (which "xdg-open") |
| 760 | "\"); return true; \n" all))))) |
| 761 | (replace 'configure |
| 762 | ;; Overridden to not pass "--enable-fast-install", which makes the |
| 763 | ;; configure process fail. |
| 764 | (lambda* (#:key outputs configure-flags #:allow-other-keys) |
| 765 | (let ((out (assoc-ref outputs "out"))) |
| 766 | (substitute* "configure" |
| 767 | (("/bin/pwd") (which "pwd"))) |
| 768 | (substitute* "src/corelib/global/global.pri" |
| 769 | (("/bin/ls") (which "ls"))) |
| 770 | ;; The configuration files for other Qt5 packages are searched |
| 771 | ;; through a call to "find_package" in Qt5Config.cmake, which |
| 772 | ;; disables the use of CMAKE_PREFIX_PATH via the parameter |
| 773 | ;; "NO_DEFAULT_PATH". Re-enable it so that the different |
| 774 | ;; components can be installed in different places. |
| 775 | (substitute* (find-files "." ".*\\.cmake") |
| 776 | (("NO_DEFAULT_PATH") "")) |
| 777 | (format #t "build directory: ~s~%" (getcwd)) |
| 778 | (format #t "configure flags: ~s~%" configure-flags) |
| 779 | (apply invoke "./configure" configure-flags)))) |
| 780 | (add-after 'install 'patch-mkspecs |
| 781 | (lambda* (#:key outputs #:allow-other-keys) |
| 782 | (let* ((out (assoc-ref outputs "out")) |
| 783 | (archdata (string-append out "/lib/qt5")) |
| 784 | (mkspecs (string-append archdata "/mkspecs")) |
| 785 | (qt_config.prf (string-append |
| 786 | mkspecs "/features/qt_config.prf"))) |
| 787 | ;; For each Qt module, let `qmake' uses search paths in the |
| 788 | ;; module directory instead of all in QT_INSTALL_PREFIX. |
| 789 | (substitute* qt_config.prf |
| 790 | (("\\$\\$\\[QT_INSTALL_HEADERS\\]") |
| 791 | "$$clean_path($$replace(dir, mkspecs/modules, ../../include/qt5))") |
| 792 | (("\\$\\$\\[QT_INSTALL_LIBS\\]") |
| 793 | "$$clean_path($$replace(dir, mkspecs/modules, ../../lib))") |
| 794 | (("\\$\\$\\[QT_HOST_LIBS\\]") |
| 795 | "$$clean_path($$replace(dir, mkspecs/modules, ../../lib))") |
| 796 | (("\\$\\$\\[QT_INSTALL_BINS\\]") |
| 797 | "$$clean_path($$replace(dir, mkspecs/modules, ../../bin))")) |
| 798 | |
| 799 | ;; Searches Qt tools in the current PATH instead of QT_HOST_BINS. |
| 800 | (substitute* (string-append mkspecs "/features/qt_functions.prf") |
| 801 | (("cmd = \\$\\$\\[QT_HOST_BINS\\]/\\$\\$2") |
| 802 | "cmd = $$system(which $${2}.pl 2>/dev/null || which $${2})")) |
| 803 | |
| 804 | ;; Resolve qmake spec files within qtbase by absolute paths. |
| 805 | (substitute* |
| 806 | (map (lambda (file) |
| 807 | (string-append mkspecs "/features/" file)) |
| 808 | '("device_config.prf" "moc.prf" "qt_build_config.prf" |
| 809 | "qt_config.prf" "winrt/package_manifest.prf")) |
| 810 | (("\\$\\$\\[QT_HOST_DATA/get\\]") archdata) |
| 811 | (("\\$\\$\\[QT_HOST_DATA/src\\]") archdata))))) |
| 812 | (add-after 'patch-mkspecs 'patch-prl-files |
| 813 | (lambda* (#:key outputs #:allow-other-keys) |
| 814 | (let ((out (assoc-ref outputs "out"))) |
| 815 | ;; Insert absolute references to the qtbase libraries because |
| 816 | ;; QT_INSTALL_LIBS does not always resolve correctly, depending |
| 817 | ;; on context. See <https://bugs.gnu.org/38405> |
| 818 | (substitute* (find-files (string-append out "/lib") "\\.prl$") |
| 819 | (("\\$\\$\\[QT_INSTALL_LIBS\\]") |
| 820 | (string-append out "/lib")))))) |
| 821 | (add-after 'unpack 'patch-paths |
| 822 | ;; Use the absolute paths for dynamically loaded libs, otherwise |
| 823 | ;; the lib will be searched in LD_LIBRARY_PATH which typically is |
| 824 | ;; not set in guix. |
| 825 | (lambda* (#:key inputs #:allow-other-keys) |
| 826 | ;; libresolve |
| 827 | (let ((glibc (assoc-ref inputs ,(if (%current-target-system) |
| 828 | "cross-libc" "libc")))) |
| 829 | (substitute* '("src/network/kernel/qdnslookup_unix.cpp" |
| 830 | "src/network/kernel/qhostinfo_unix.cpp") |
| 831 | (("^\\s*(lib.setFileName\\(QLatin1String\\(\")(resolv\"\\)\\);)" _ a b) |
| 832 | (string-append a glibc "/lib/lib" b)))) |
| 833 | ;; libGL |
| 834 | (substitute* "src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp" |
| 835 | (("^\\s*(QLibrary lib\\(QLatin1String\\(\")(GL\"\\)\\);)" _ a b) |
| 836 | (string-append a (assoc-ref inputs "mesa") "/lib/lib" b))) |
| 837 | ;; libXcursor |
| 838 | (substitute* "src/plugins/platforms/xcb/qxcbcursor.cpp" |
| 839 | (("^\\s*(QLibrary xcursorLib\\(QLatin1String\\(\")(Xcursor\"\\), 1\\);)" _ a b) |
| 840 | (string-append a (assoc-ref inputs "libxcursor") "/lib/lib" b)) |
| 841 | (("^\\s*(xcursorLib.setFileName\\(QLatin1String\\(\")(Xcursor\"\\)\\);)" _ a b) |
| 842 | (string-append a (assoc-ref inputs "libxcursor") "/lib/lib" b))))) |
| 843 | (add-after 'install 'do-not-capture-python |
| 844 | (lambda* (#:key outputs #:allow-other-keys) |
| 845 | ;; For some reason, patching the file after the |
| 846 | ;; patch-source-shebangs phase doesn't work for Qt 5. |
| 847 | (substitute* |
| 848 | (search-input-file |
| 849 | outputs "lib/qt5/mkspecs/features/uikit/devices.py") |
| 850 | (((which "python3")) |
| 851 | "/usr/bin/env python3"))))))) |
| 852 | (native-search-paths |
| 853 | (list (search-path-specification |
| 854 | (variable "QMAKEPATH") |
| 855 | (files '("lib/qt5"))) |
| 856 | (search-path-specification |
| 857 | (variable "QML2_IMPORT_PATH") |
| 858 | (files '("lib/qt5/qml"))) |
| 859 | (search-path-specification |
| 860 | (variable "QT_PLUGIN_PATH") |
| 861 | (files '("lib/qt5/plugins"))) |
| 862 | (search-path-specification |
| 863 | (variable "XDG_DATA_DIRS") |
| 864 | (files '("share"))) |
| 865 | (search-path-specification |
| 866 | (variable "XDG_CONFIG_DIRS") |
| 867 | (files '("etc/xdg"))))) |
| 868 | (home-page "https://www.qt.io/") |
| 869 | (synopsis "Cross-platform GUI library") |
| 870 | (description "Qt is a cross-platform application and UI framework for |
| 871 | developers using C++ or QML, a CSS & JavaScript like language.") |
| 872 | (license (list license:lgpl2.1 license:lgpl3)))) |
| 873 | |
| 874 | (define-public qtbase |
| 875 | (package |
| 876 | (inherit qtbase-5) |
| 877 | (name "qtbase") |
| 878 | (version "6.9.2") |
| 879 | (source (origin |
| 880 | (inherit (package-source qtbase-5)) |
| 881 | (uri (qt-url name version)) |
| 882 | (sha256 |
| 883 | (base32 |
| 884 | "0h149x8l2ywfr5m034n20z6cjxnldary39x0vv22jhg0ryg9rgj4")) |
| 885 | (modules '((guix build utils))) |
| 886 | (snippet |
| 887 | ;; corelib uses bundled harfbuzz, md4, md5, sha3 |
| 888 | '(with-directory-excursion "src/3rdparty" |
| 889 | (for-each delete-file-recursively |
| 890 | (list "double-conversion" "freetype" "harfbuzz-ng" |
| 891 | "pcre2" "md4c" "libpng" "libjpeg" |
| 892 | "sqlite" "xcb" "zlib")))) |
| 893 | (patches |
| 894 | (search-patches |
| 895 | "qtbase-moc-ignore-gcc-macro.patch" |
| 896 | "qtbase-absolute-runpath.patch" |
| 897 | "qtbase-qmake-use-libname.patch" |
| 898 | "qtbase-qmlimportscanner-qml-import-path.patch" |
| 899 | "qtbase-qmake-fix-includedir.patch" |
| 900 | "qtbase-patch-libvulkan.patch")))) |
| 901 | (build-system cmake-build-system) |
| 902 | (arguments |
| 903 | (substitute-keyword-arguments arguments |
| 904 | ((#:configure-flags _ ''()) |
| 905 | `(let ((out (assoc-ref %outputs "out"))) |
| 906 | (list "-GNinja" ;officially supported |
| 907 | "-DQT_BUILD_TESTS=ON" |
| 908 | (string-append "-DINSTALL_ARCHDATADIR=" out "/lib/qt6") |
| 909 | (string-append "-DINSTALL_DATADIR=" out "/share/qt6") |
| 910 | (string-append "-DINSTALL_DOCDIR=" out "/share/doc/qt6") |
| 911 | (string-append "-DINSTALL_MKSPECSDIR=" out "/lib/qt6/mkspecs") |
| 912 | (string-append "-DINSTALL_EXAMPLESDIR=" out |
| 913 | "/share/doc/qt6/examples") |
| 914 | (string-append "-DINSTALL_INCLUDEDIR=" out "/include/qt6") |
| 915 | |
| 916 | ;; Do not embed an absolute reference to compilers, to reduce |
| 917 | ;; the closure size. |
| 918 | "-DQT_EMBED_TOOLCHAIN_COMPILER=OFF" |
| 919 | |
| 920 | ;; Link with DBus and OpenSSL so they don't get dlopen'ed. |
| 921 | "-DINPUT_dbus=linked" |
| 922 | "-DINPUT_openssl=linked" |
| 923 | ;; These features require higher versions of Linux than the |
| 924 | ;; minimum version of the glibc. See |
| 925 | ;; src/corelib/global/minimum-linux_p.h. By disabling these |
| 926 | ;; features Qt applications can be used on the oldest kernels |
| 927 | ;; that the glibc supports, including the RHEL6 (2.6.32) and |
| 928 | ;; RHEL7 (3.10) kernels. |
| 929 | "-DFEATURE_getentropy=OFF" ; requires Linux 3.17 |
| 930 | "-DFEATURE_renameat2=OFF" ; requires Linux 3.16 |
| 931 | ;; Most system libraries are used by default, except in some |
| 932 | ;; cases such as for those below. |
| 933 | "-DFEATURE_system_pcre2=ON" |
| 934 | "-DFEATURE_system_sqlite=ON" |
| 935 | "-DFEATURE_system_xcb_xinput=ON" |
| 936 | ;; Don't use the precompiled headers. |
| 937 | "-DBUILD_WITH_PCH=OFF"))) |
| 938 | ((#:phases phases) |
| 939 | #~(modify-phases #$phases |
| 940 | (replace 'build |
| 941 | (lambda* (#:key parallel-build? #:allow-other-keys) |
| 942 | (apply invoke "cmake" "--build" "." |
| 943 | (if parallel-build? |
| 944 | `("--parallel" ,(number->string |
| 945 | (parallel-job-count))) |
| 946 | '())))) |
| 947 | (replace 'install |
| 948 | (lambda _ |
| 949 | (invoke "cmake" "--install" "."))) |
| 950 | (add-after 'unpack 'honor-CMAKE_PREFIX_PATH |
| 951 | (lambda _ |
| 952 | ;; The configuration files for other Qt packages are searched |
| 953 | ;; through a call to "find_package" in Qt5Config.cmake, which |
| 954 | ;; disables the use of CMAKE_PREFIX_PATH via the parameter |
| 955 | ;; "NO_DEFAULT_PATH". Re-enable it so that the different |
| 956 | ;; components can be installed in different places. |
| 957 | (substitute* (find-files "." "\\.cmake(\\.in)?$") |
| 958 | (("\\bNO_DEFAULT_PATH\\b") "")) |
| 959 | ;; Because Qt goes against the grain of CMake and set |
| 960 | ;; NO_DEFAULT_PATH, it needs to invent yet another variable |
| 961 | ;; to do what CMAKE_PREFIX_PATH could have done: |
| 962 | ;; QT_ADDITIONAL_PACKAGES_PREFIX_PATH. Since we patch out |
| 963 | ;; the NO_DEFAULT_PATH, we can set the default value of |
| 964 | ;; QT_ADDITIONAL_PACKAGES_PREFIX_PATH to that of |
| 965 | ;; CMAKE_PREFIX_PATH to ensure tools such as |
| 966 | ;; 'qmlimportscanner' from qtdeclarative work out of the |
| 967 | ;; box. |
| 968 | (substitute* "cmake/QtConfig.cmake.in" |
| 969 | (("set\\(QT_ADDITIONAL_HOST_PACKAGES_PREFIX_PATH" below) |
| 970 | (string-append " |
| 971 | if(QT_ADDITIONAL_PACKAGES_PREFIX_PATH STREQUAL \"\") |
| 972 | cmake_path(CONVERT $ENV{CMAKE_PREFIX_PATH} TO_CMAKE_PATH_LIST |
| 973 | QT_ADDITIONAL_PACKAGES_PREFIX_PATH) |
| 974 | endif()\n" below))))) |
| 975 | (delete 'patch-bin-sh) |
| 976 | (delete 'patch-xdg-open) |
| 977 | ;; Some tests fail to build on i686-linux |
| 978 | #$@(if (target-x86-32?) |
| 979 | #~((add-after 'unpack 'skip-some-tests |
| 980 | ;; This might be a FLOAT16 problem. |
| 981 | (lambda _ |
| 982 | (substitute* "tests/auto/corelib/global/CMakeLists.txt" |
| 983 | ((".*qcomparehelpers.*") ""))))) |
| 984 | #~()) |
| 985 | (add-after 'patch-paths 'patch-more-paths |
| 986 | (lambda* (#:key inputs #:allow-other-keys) |
| 987 | (substitute* (find-files "bin" "\\.in$") |
| 988 | (("/bin/pwd") |
| 989 | (search-input-file inputs "bin/pwd")) |
| 990 | ;; Do not keep a reference to cmake-minimal; it is looked |
| 991 | ;; from PATH anyway. |
| 992 | (("original_cmake_path=\"@CMAKE_COMMAND@\"") |
| 993 | "original_cmake_path=\"\"")) |
| 994 | (substitute* "src/gui/platform/unix/qdesktopunixservices.cpp" |
| 995 | (("\"xdg-open\"") |
| 996 | (format #f "~s" (search-input-file inputs "bin/xdg-open")))) |
| 997 | (substitute* '("mkspecs/features/qt_functions.prf" |
| 998 | "qmake/library/qmakebuiltins.cpp") |
| 999 | (("/bin/sh") |
| 1000 | (search-input-file inputs "bin/bash"))) |
| 1001 | |
| 1002 | (substitute* "tests/auto/tools/qt_cmake_create/\ |
| 1003 | tst_qt_cmake_create.cpp" |
| 1004 | (("/bin/sh") |
| 1005 | (which "sh"))) |
| 1006 | |
| 1007 | (substitute* "src/corelib/CMakeLists.txt" |
| 1008 | (("/bin/ls") |
| 1009 | (search-input-file inputs "bin/ls"))) |
| 1010 | |
| 1011 | ;; Patch the added reference for libvulkan.so |
| 1012 | (substitute* "src/gui/vulkan/qbasicvulkanplatforminstance.cpp" |
| 1013 | (("libvulkan\\.so\\.1") |
| 1014 | (search-input-file inputs "lib/libvulkan.so.1"))) |
| 1015 | |
| 1016 | ;; Use shared-mime-info as the default MIME type database. |
| 1017 | (substitute* "src/corelib/mimetypes/qmimedatabase.cpp" |
| 1018 | (("return dirs;" all) |
| 1019 | (string-append |
| 1020 | "dirs.append(\"" |
| 1021 | #$(this-package-input "shared-mime-info") "/share/mime" |
| 1022 | "\");\n" all))))) |
| 1023 | (delete 'do-not-capture-python) ;move after patch-source-shebangs |
| 1024 | (add-after 'patch-source-shebangs 'do-not-capture-python |
| 1025 | (lambda _ |
| 1026 | (substitute* '("libexec/qt-android-runner.py" |
| 1027 | "mkspecs/features/uikit/devices.py" |
| 1028 | "util/testrunner/qt-testrunner.py" |
| 1029 | "util/testrunner/sanitizer-testrunner.py") |
| 1030 | (((which "python3")) |
| 1031 | "/usr/bin/env python3")))) |
| 1032 | (replace 'configure |
| 1033 | (assoc-ref %standard-phases 'configure)) |
| 1034 | (delete 'check) ;move after patch-prl-files |
| 1035 | (add-after 'patch-prl-files 'check |
| 1036 | (lambda* (#:key tests? parallel-tests? |
| 1037 | native-inputs inputs #:allow-other-keys) |
| 1038 | (when tests? |
| 1039 | ;; The tests expect to find the modules provided by this |
| 1040 | ;; package; extend the environment variables needed to do so. |
| 1041 | (setenv "CMAKE_PREFIX_PATH" |
| 1042 | (string-append #$output |
| 1043 | ":" (getenv "CMAKE_PREFIX_PATH"))) |
| 1044 | (setenv "QMAKEPATH" (string-append #$output "/lib/qt6")) |
| 1045 | ;; It is necessary to augment LIBRARY_PATH with that of the |
| 1046 | ;; freshly installed qtbase because of the |
| 1047 | ;; 'qtbase-qmake-use-libname.patch' patch. |
| 1048 | (setenv "LIBRARY_PATH" (string-append #$output "/lib:" |
| 1049 | (getenv "LIBRARY_PATH"))) |
| 1050 | (setenv "QML_IMPORT_PATH" |
| 1051 | (string-append #$output "/lib/qt6/qml")) |
| 1052 | (setenv "QT_PLUGIN_PATH" |
| 1053 | (string-append #$output "/lib/qt6/plugins")) |
| 1054 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 1055 | ;; Skip tests known to fail on GNU/Linux, in a CI context or |
| 1056 | ;; due to bitness (see: https://code.qt.io/cgit/qt/qtbase.git |
| 1057 | ;; /tree/src/testlib/qtestblacklist.cpp). |
| 1058 | (setenv "QTEST_ENVIRONMENT" "linux ci 32bit") |
| 1059 | (setenv "HOME" "/tmp") ;some tests require a writable HOME |
| 1060 | |
| 1061 | ;; Note: the search path specified for TZDIR is only |
| 1062 | ;; effective for users of the package, not while it's being |
| 1063 | ;; built. |
| 1064 | (setenv "TZDIR" (search-input-directory |
| 1065 | (or native-inputs inputs) "share/zoneinfo")) |
| 1066 | |
| 1067 | ;; This is to avoid QTimeZone::systemTimeZone() returning |
| 1068 | ;; invalid QDate objects due to missing /etc/timezone or |
| 1069 | ;; /etc/localtime. |
| 1070 | (setenv "TZ" "Etc/UTC") |
| 1071 | |
| 1072 | (invoke |
| 1073 | "xvfb-run" "ctest" "--output-on-failure" |
| 1074 | "-j" (if parallel-tests? |
| 1075 | (number->string (parallel-job-count)) |
| 1076 | "1") |
| 1077 | "-E" ;disable problematic tests |
| 1078 | (string-append |
| 1079 | "(" |
| 1080 | (string-join |
| 1081 | (append |
| 1082 | (list |
| 1083 | ;; The 'tst_qdialogbuttonbox' may fail non-deterministically |
| 1084 | ;; (see: https://bugreports.qt.io/browse/QTBUG-123939). |
| 1085 | "tst_qdialogbuttonbox" |
| 1086 | |
| 1087 | ;; This test may fail non-deterministically (timeout) |
| 1088 | ;; after running for more than 300s (see: |
| 1089 | ;; https://bugreports.qt.io/browse/QTBUG-135603). |
| 1090 | "tst_qguitimer" |
| 1091 | |
| 1092 | ;; TODO: Enable this when update qtbase. |
| 1093 | ;; tst_QDate::startOfDay_endOfDay fails for BajaMexico |
| 1094 | ;; due to IANA timezone update (see: |
| 1095 | ;; https://bugreports.qt.io/browse/QTQAINFRA-6757). |
| 1096 | "tst_qdate" |
| 1097 | |
| 1098 | ;; The 'test_standalone_test' fails with a |
| 1099 | ;; "get_property could not find TARGET Qt6::Core" error |
| 1100 | ;; (see: https://bugreports.qt.io/browse/QTBUG-123940). |
| 1101 | "test_standalone_test" |
| 1102 | |
| 1103 | ;; The 'test_collecting_plugins' fails with a "Unknown |
| 1104 | ;; platform linux-g++" error (see: |
| 1105 | ;; https://bugreports.qt.io/browse/QTBUG-123941). |
| 1106 | "test_collecting_plugins" |
| 1107 | |
| 1108 | ;; The 'tst_selftests' fails with the following error: |
| 1109 | ;; with expansion: |
| 1110 | ;; false |
| 1111 | ;; with messages: |
| 1112 | ;; test := "keyboard" |
| 1113 | ;; arguments := QList("-o", "-,tap") |
| 1114 | ;; Detected locale "C" with character encoding "ANSI_X3.4-1968", which is not UTF-8. |
| 1115 | ;; Qt depends on a UTF-8 locale, but has failed to switch to one. |
| 1116 | ;; If this causes problems, reconfigure your locale. See the locale(1) manual |
| 1117 | ;; for more information. |
| 1118 | |
| 1119 | ;; See https://bugreports.qt.io/browse/QTBUG-113371 |
| 1120 | ;; Adding glibc-utf8-locales to native-inpus is no help. |
| 1121 | "tst_selftests" |
| 1122 | |
| 1123 | ;; The qsqldatabase test is flaky (see: |
| 1124 | ;; <https://qt-project.atlassian.net/browse/QTBUG-145385>). |
| 1125 | "tst_qsqldatabase" |
| 1126 | |
| 1127 | ;; The 'tst_qtimer' test has a propensity to hang and |
| 1128 | ;; fail (see: |
| 1129 | ;; <https://qt-project.atlassian.net/browse/QTBUG-145261>). |
| 1130 | "tst_qtimer" |
| 1131 | "tst_qtimer_no_glib" |
| 1132 | |
| 1133 | ;; The 'tst_qthread' test is also flaky, despite the |
| 1134 | ;; patch applied that promised to fix it. |
| 1135 | "tst_qthread" |
| 1136 | |
| 1137 | ;; The 'tst_qsystemsemaphore' test sometimes fails. |
| 1138 | "tst_qsystemsemaphore" |
| 1139 | ;; The 'tst_moc' test fails with "'fi.exists()' returned FALSE". |
| 1140 | "tst_moc" |
| 1141 | |
| 1142 | ;; The qgraphicsview and qopenglwidget tests fail with a |
| 1143 | ;; segfault for unknown reasons (see: |
| 1144 | ;; https://bugreports.qt.io/browse/QTBUG-116018). |
| 1145 | "tst_qgraphicsview" |
| 1146 | "tst_qopenglwidget" |
| 1147 | |
| 1148 | ;; The 'test_rcc' test fails on a comparison: |
| 1149 | ;; <<<<<< actual |
| 1150 | ;; 0x0,0x0,0x0,0x0,0x0,0x0,0x3,0xe8, |
| 1151 | ;; ====== |
| 1152 | ;; 0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0, |
| 1153 | ;; >>>>>> expected |
| 1154 | "tst_rcc" |
| 1155 | ;; The 'tst_qtemporarydir' and 'tst_qtemporaryfile' |
| 1156 | ;; tests depend on '/home' not being writable. |
| 1157 | "tst_qtemporarydir" |
| 1158 | "tst_qtemporaryfile" |
| 1159 | ;; The 'tst_qdir' compares two directories which are |
| 1160 | ;; unexpectedly different when inside the build |
| 1161 | ;; container. |
| 1162 | "tst_qdir" |
| 1163 | ;; This checks the last modified time of '/', and fails |
| 1164 | ;; because Epoch 0 is considered to be invalid. |
| 1165 | "tst_qresourceengine" |
| 1166 | ;; The 'tst_qfilesystemwatcher' installs a watcher on |
| 1167 | ;; '/home', which doesn't exist in the build container. |
| 1168 | "tst_qfilesystemwatcher" |
| 1169 | ;; Not all of the tested formats are supported by our |
| 1170 | ;; build of openssl; 871 passed, 122 failed. |
| 1171 | "tst_qsslkey" |
| 1172 | ;; The 'mockplugins' test fail following error: "Unknown |
| 1173 | ;; platform linux-g++", and the other plugin tests |
| 1174 | ;; depend on it. |
| 1175 | "mockplugins" |
| 1176 | "test_plugin_flavor.*" |
| 1177 | ;; The 'test_import_plugins' fails with "Could NOT find |
| 1178 | ;; Qt6MockPlugins1". |
| 1179 | "test_import_plugins" |
| 1180 | ;; The tst_QObjectRace::destroyRace is flaky (see: |
| 1181 | ;; https://bugreports.qt.io/browse/QTBUG-103489). |
| 1182 | "tst_qobjectrace" |
| 1183 | ;; The 'tst_QSettings::fromFile' assumes the data |
| 1184 | ;; location to be relative to the root directory and |
| 1185 | ;; fails. |
| 1186 | "tst_qsettings" |
| 1187 | ;; The 'tst_qaddpreroutine', |
| 1188 | ;; 'test_generating_cpp_exports' and |
| 1189 | ;; 'test_static_resources' tests fail with: "Unknown |
| 1190 | ;; platform linux-g++. |
| 1191 | "tst_qaddpreroutine" |
| 1192 | "test_generating_cpp_exports" |
| 1193 | "test_static_resources" |
| 1194 | ;; The 'tst_qfile' fails since there is no /home in the |
| 1195 | ;; build container. |
| 1196 | "tst_qfile" |
| 1197 | ;; The 'tst_QGlyphRun::mixedScripts' test fails with: |
| 1198 | ;; Actual (glyphRuns.size()): 1 |
| 1199 | ;; Expected (2) : 2 |
| 1200 | "tst_qglyphrun" |
| 1201 | ;; The 'tst_qx11info' test fails with "Internal error: |
| 1202 | ;; QPA plugin doesn't implement generatePeekerId", |
| 1203 | ;; likely requires a real display. |
| 1204 | "tst_qx11info" |
| 1205 | |
| 1206 | ;; The 'tst_qgraphicswidget' test fails because "This |
| 1207 | ;; plugin does not support propagateSizeHints". |
| 1208 | "tst_qgraphicswidget" |
| 1209 | ;; The 'tst_qdnslookup' test requires networking. |
| 1210 | "tst_qdnslookup" |
| 1211 | ;; The 'tst_qcompleter' and 'tst_QFiledialog::completer' |
| 1212 | ;; attempt to complete paths they assume exist, such as |
| 1213 | ;; "/home", "/etc" or "/root" and fail. |
| 1214 | "tst_qcompleter" |
| 1215 | "tst_qfiledialog" |
| 1216 | ;; The following tests fail with: "Generation of UI |
| 1217 | ;; files were triggered in the second build", but could |
| 1218 | ;; pass in `guix shell --container`. |
| 1219 | "test_qt_add_ui_1" |
| 1220 | "test_qt_add_ui_2" |
| 1221 | "test_qt_add_ui_6" |
| 1222 | "test_qt_add_ui_8" |
| 1223 | "test_qt_add_ui_9" |
| 1224 | ;; This test is susceptible to the 600 ms timeout used: |
| 1225 | "tst_qpauseanimation" |
| 1226 | |
| 1227 | ;; This test may fail non-deterministically as reported |
| 1228 | ;; in Guix bug#73233 and upstream at |
| 1229 | ;; https://bugreports.qt.io/browse/QTBUG-119321. |
| 1230 | "tst_qsharedmemory" |
| 1231 | |
| 1232 | ;; One of the finicky tests, see |
| 1233 | ;; https://codeberg.org/guix/guix/issues/7545 |
| 1234 | "tst_qlatin1stringmatcher" |
| 1235 | |
| 1236 | ;; This test fails deterministically on a non-privileged |
| 1237 | ;; daemon. |
| 1238 | "tst_qstandardpaths") |
| 1239 | #$@(cond |
| 1240 | ((target-ppc64le?) |
| 1241 | #~((list |
| 1242 | ;; The 'tst_QPainter::fpe_radialGradients' |
| 1243 | ;; test fails with a 'Floating point |
| 1244 | ;; exception' error on powerpc64le (see: |
| 1245 | ;; https://bugreports.qt.io/browse/QTBUG-117113). |
| 1246 | "tst_qpainter" |
| 1247 | |
| 1248 | ;; The 'startStopStartStopBuffers' test fails |
| 1249 | ;; on the powerpc64le architecture (see: |
| 1250 | ;; https://bugreports.qt.io/browse/QTBUG-80953). |
| 1251 | "tst_qprocess" |
| 1252 | |
| 1253 | ;; The 'tst_QSqlThread::readWriteThreading' |
| 1254 | ;; test may fail with an sqlite related error, |
| 1255 | ;; "'Unable to fetch row' || 'database is |
| 1256 | ;; locked'" (see: |
| 1257 | ;; https://bugreports.qt.io/browse/QTBUG-117114). |
| 1258 | "tst_qsqlthread" |
| 1259 | |
| 1260 | ;; The 'tst_qxmlstream' can time out (see: |
| 1261 | ;; https://bugreports.qt.io/projects/QTBUG/issues/QTBUG-123778). |
| 1262 | "tst_qxmlstream"))) |
| 1263 | ((target-x86-32?) |
| 1264 | #~((list |
| 1265 | ;; QCOMPARE(qRound(actual), expected) returned TRUE |
| 1266 | ;; unexpectedly. |
| 1267 | "tst_qglobal" |
| 1268 | |
| 1269 | ;; Actual (llMinDbl == llMin) : 0 |
| 1270 | ;; Expected (-9223372036854775807.0 == |
| 1271 | ;; Q_INT64_C(-9223372036854775807)) : 1 |
| 1272 | "tst_json" |
| 1273 | |
| 1274 | ;; 'QVector3D::normal(QVector3D(), v1, v2) == |
| 1275 | ;; v3.normalized()' returned FALSE. () |
| 1276 | "tst_qvectornd" |
| 1277 | |
| 1278 | ;; Actual (dv.validate(value, dummy)): Invalid |
| 1279 | ;; Expected (standard_state) : Intermediate |
| 1280 | "tst_qdoublevalidator"))) |
| 1281 | (else #~()))) "|") ")"))))) |
| 1282 | (replace 'patch-mkspecs |
| 1283 | (lambda* (#:key outputs #:allow-other-keys) |
| 1284 | (let* ((archdata (search-input-directory outputs "lib/qt6")) |
| 1285 | (mkspecs (search-input-directory outputs |
| 1286 | "lib/qt6/mkspecs")) |
| 1287 | (qt_config.prf |
| 1288 | (search-input-file |
| 1289 | outputs "lib/qt6/mkspecs/features/qt_config.prf")) |
| 1290 | (qt_functions.prf |
| 1291 | (search-input-file |
| 1292 | outputs "lib/qt6/mkspecs/features/qt_functions.prf"))) |
| 1293 | ;; For each Qt module, let `qmake' uses search paths in the |
| 1294 | ;; module directory instead of all in QT_INSTALL_PREFIX. |
| 1295 | (substitute* qt_config.prf |
| 1296 | (("\\$\\$\\[QT_INSTALL_HEADERS\\]") |
| 1297 | "$$clean_path($$replace(dir, mkspecs/modules, ../../include/qt6))") |
| 1298 | (("\\$\\$\\[QT_INSTALL_LIBS\\]") |
| 1299 | "$$clean_path($$replace(dir, mkspecs/modules, ../../lib))") |
| 1300 | (("\\$\\$\\[QT_HOST_LIBS\\]") |
| 1301 | "$$clean_path($$replace(dir, mkspecs/modules, ../../lib))") |
| 1302 | (("\\$\\$\\[QT_INSTALL_BINS\\]") |
| 1303 | "$$clean_path($$replace(dir, mkspecs/modules, ../../bin))")) |
| 1304 | |
| 1305 | ;; Searches Qt tools in the current PATH instead of QT_HOST_BINS. |
| 1306 | (substitute* qt_functions.prf |
| 1307 | (("cmd = \\$\\$\\[QT_HOST_BINS\\]/\\$\\$2") |
| 1308 | "cmd = $$system(which $${2}.pl 2>/dev/null || which $${2})")) |
| 1309 | |
| 1310 | ;; Resolve qmake spec files within qtbase by absolute paths. |
| 1311 | (substitute* |
| 1312 | (map (lambda (file) |
| 1313 | (search-input-file |
| 1314 | outputs |
| 1315 | (string-append "lib/qt6/mkspecs/features/" file))) |
| 1316 | '("device_config.prf" "moc.prf" "qt_config.prf")) |
| 1317 | (("\\$\\$\\[QT_HOST_DATA/get\\]") archdata) |
| 1318 | (("\\$\\$\\[QT_HOST_DATA/src\\]") archdata))))) |
| 1319 | (add-before 'install 'dont-install-tests |
| 1320 | (lambda _ |
| 1321 | (substitute* "cmake_install.cmake" |
| 1322 | (("include.*tests/cmake_install") "#")))))))) |
| 1323 | (native-inputs |
| 1324 | (modify-inputs native-inputs |
| 1325 | (prepend ninja ;CMake Generator, also used for tests |
| 1326 | tzdata-for-tests |
| 1327 | wayland-protocols |
| 1328 | xvfb-run-for-tests))) |
| 1329 | (propagated-inputs |
| 1330 | (modify-inputs propagated-inputs |
| 1331 | ;; Required by Qt6GuiDependencies.cmake. |
| 1332 | (prepend libxkbcommon vulkan-headers))) |
| 1333 | (inputs |
| 1334 | (modify-inputs inputs |
| 1335 | (delete "libxkbcommon") |
| 1336 | (prepend at-spi2-core |
| 1337 | bash-minimal |
| 1338 | coreutils-minimal |
| 1339 | `(,mariadb "lib") |
| 1340 | md4c |
| 1341 | libb2 |
| 1342 | libice |
| 1343 | libsm |
| 1344 | libxcb |
| 1345 | libxext |
| 1346 | shared-mime-info |
| 1347 | vulkan-loader |
| 1348 | xcb-util-cursor |
| 1349 | `(,zstd "lib")))) |
| 1350 | (native-search-paths |
| 1351 | (list (search-path-specification |
| 1352 | (variable "QMAKEPATH") |
| 1353 | (files '("lib/qt6"))) |
| 1354 | (search-path-specification |
| 1355 | (variable "QML_IMPORT_PATH") |
| 1356 | (files '("lib/qt6/qml"))) |
| 1357 | (search-path-specification |
| 1358 | (variable "QT_PLUGIN_PATH") |
| 1359 | (files '("lib/qt6/plugins"))) |
| 1360 | $TZDIR |
| 1361 | (search-path-specification |
| 1362 | (variable "XDG_DATA_DIRS") |
| 1363 | (files '("share"))) |
| 1364 | (search-path-specification |
| 1365 | (variable "XDG_CONFIG_DIRS") |
| 1366 | (files '("etc/xdg"))))))) |
| 1367 | |
| 1368 | (define-public qt3d-5 |
| 1369 | (package |
| 1370 | (inherit qtbase-5) |
| 1371 | (name "qt3d") |
| 1372 | (version "5.15.17") |
| 1373 | (source (origin |
| 1374 | (method url-fetch) |
| 1375 | (uri (qt-url name version)) |
| 1376 | (sha256 |
| 1377 | (base32 |
| 1378 | "13kha7x0zlgkm19lvvs1jmp1s75j70p9cy7iayfrgrygnlh1ckj3")))) |
| 1379 | (propagated-inputs `()) |
| 1380 | (native-inputs (list perl)) |
| 1381 | (inputs (list mesa qtbase-5 vulkan-headers zlib)) |
| 1382 | (arguments |
| 1383 | (list #:phases #~(modify-phases %standard-phases |
| 1384 | (add-before 'configure 'configure-qmake |
| 1385 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 1386 | (let* ((tmpdir (string-append (getenv "TMPDIR"))) |
| 1387 | (qmake (string-append tmpdir "/qmake")) |
| 1388 | (qt.conf (string-append tmpdir "/qt.conf"))) |
| 1389 | (symlink (which "qmake") qmake) |
| 1390 | (setenv "PATH" |
| 1391 | (string-append tmpdir ":" |
| 1392 | (getenv "PATH"))) |
| 1393 | (with-output-to-file qt.conf |
| 1394 | (lambda () |
| 1395 | (format #t "[Paths] |
| 1396 | Prefix=~a |
| 1397 | ArchData=lib/qt5 |
| 1398 | Data=share/qt5 |
| 1399 | Documentation=share/doc/qt5 |
| 1400 | Headers=include/qt5 |
| 1401 | Libraries=lib |
| 1402 | LibraryExecutables=lib/qt5/libexec |
| 1403 | Binaries=bin |
| 1404 | Tests=tests |
| 1405 | Plugins=lib/qt5/plugins |
| 1406 | Imports=lib/qt5/imports |
| 1407 | Qml2Imports=lib/qt5/qml |
| 1408 | Translations=share/qt5/translations |
| 1409 | Settings=etc/xdg |
| 1410 | Examples=share/doc/qt5/examples |
| 1411 | HostPrefix=~a |
| 1412 | HostData=lib/qt5 |
| 1413 | HostBinaries=bin |
| 1414 | HostLibraries=lib |
| 1415 | |
| 1416 | [EffectiveSourcePaths] |
| 1417 | HostPrefix=~a |
| 1418 | HostData=lib/qt5" |
| 1419 | #$output #$output #$(this-package-input |
| 1420 | "qtbase"))))))) |
| 1421 | (replace 'configure |
| 1422 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 1423 | (invoke "qmake" |
| 1424 | "QT_BUILD_PARTS = libs tools tests"))) |
| 1425 | (add-before 'check 'set-display |
| 1426 | (lambda _ |
| 1427 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 1428 | (synopsis "Qt module for 3D") |
| 1429 | (description "The Qt3d module provides classes for displaying 3D."))) |
| 1430 | |
| 1431 | (define-public qt3d |
| 1432 | (package |
| 1433 | (name "qt3d") |
| 1434 | (version "6.9.2") |
| 1435 | (source (origin |
| 1436 | (method url-fetch) |
| 1437 | (uri (qt-url name version)) |
| 1438 | (sha256 |
| 1439 | (base32 |
| 1440 | "0ndn5fbsfj2vbcq3siq1gnk2rgblicd6ri2jrh9g41anicxh4vma")))) |
| 1441 | (propagated-inputs (list)) |
| 1442 | (native-inputs (list perl)) |
| 1443 | (inputs (list libxkbcommon |
| 1444 | mesa |
| 1445 | qtbase |
| 1446 | qtdeclarative |
| 1447 | vulkan-headers |
| 1448 | zlib)) |
| 1449 | (build-system cmake-build-system) |
| 1450 | (arguments |
| 1451 | (list |
| 1452 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 1453 | #:phases |
| 1454 | #~(modify-phases %standard-phases |
| 1455 | (add-before 'check 'set-display |
| 1456 | (lambda _ |
| 1457 | ;; Make Qt render "offscreen", required for tests. |
| 1458 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 1459 | (synopsis "Qt module for 3D") |
| 1460 | (description "The Qt3d module provides classes for displaying 3D.") |
| 1461 | (home-page (package-home-page qtbase)) |
| 1462 | (license (package-license qtbase)))) |
| 1463 | |
| 1464 | (define-public qt5compat |
| 1465 | (package |
| 1466 | (name "qt5compat") |
| 1467 | (version "6.9.2") |
| 1468 | (source (origin |
| 1469 | (method url-fetch) |
| 1470 | (uri (qt-url name version)) |
| 1471 | (sha256 |
| 1472 | (base32 |
| 1473 | "0q2vly836wgs462czw7lg0ysf2h48iwbdy43wwf2gz49qq2rja6b")))) |
| 1474 | (build-system cmake-build-system) |
| 1475 | (arguments |
| 1476 | (list |
| 1477 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 1478 | #:phases #~(modify-phases %standard-phases |
| 1479 | (add-after 'install 'delete-installed-tests |
| 1480 | (lambda _ |
| 1481 | (delete-file-recursively |
| 1482 | (string-append #$output "/tests"))))))) |
| 1483 | (native-inputs (list perl)) |
| 1484 | (inputs (list icu4c libxkbcommon qtbase qtdeclarative qtshadertools)) |
| 1485 | (home-page (package-home-page qtbase)) |
| 1486 | (synopsis "Legacy Qt 5 APIs ported to Qt 6") |
| 1487 | (description "The @code{qt5compat} package includes application |
| 1488 | programming interfaces (APIs) from Qt 5 that were ported to Qt 6, to ease |
| 1489 | migration. It provides for example the @code{GraphicalEffects} module that |
| 1490 | came with the @code{qtgraphicaleffects} Qt 5 package.") |
| 1491 | (license (list license:gpl2+ license:lgpl3+)))) ;dual licensed |
| 1492 | |
| 1493 | (define-public qtsvg-5 |
| 1494 | (package |
| 1495 | (inherit qtbase-5) |
| 1496 | (name "qtsvg") |
| 1497 | (version "5.15.17") |
| 1498 | (source (origin |
| 1499 | (method url-fetch) |
| 1500 | (uri (qt-url name version)) |
| 1501 | (sha256 |
| 1502 | (base32 |
| 1503 | "0v0yldb5kwsq309p2rqiy4mcn7r1azm1i6zvrp93kry0f36x82km")))) |
| 1504 | (propagated-inputs `()) |
| 1505 | (native-inputs (list perl)) |
| 1506 | (inputs |
| 1507 | (list mesa qtbase-5 zlib)) |
| 1508 | (arguments |
| 1509 | `(#:phases |
| 1510 | (modify-phases %standard-phases |
| 1511 | (add-before 'configure 'configure-qmake |
| 1512 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 1513 | (let* ((out (assoc-ref outputs "out")) |
| 1514 | (qtbase (assoc-ref inputs "qtbase")) |
| 1515 | (tmpdir (string-append (getenv "TMPDIR"))) |
| 1516 | (qmake (string-append tmpdir "/qmake")) |
| 1517 | (qt.conf (string-append tmpdir "/qt.conf"))) |
| 1518 | ;; Use qmake with a customized qt.conf to override install |
| 1519 | ;; paths to $out. |
| 1520 | (symlink (which "qmake") qmake) |
| 1521 | (setenv "PATH" (string-append tmpdir ":" (getenv "PATH"))) |
| 1522 | (with-output-to-file qt.conf |
| 1523 | (lambda () |
| 1524 | (format #t "[Paths] |
| 1525 | Prefix=~a |
| 1526 | ArchData=lib/qt5 |
| 1527 | Data=share/qt5 |
| 1528 | Documentation=share/doc/qt5 |
| 1529 | Headers=include/qt5 |
| 1530 | Libraries=lib |
| 1531 | LibraryExecutables=lib/qt5/libexec |
| 1532 | Binaries=bin |
| 1533 | Tests=tests |
| 1534 | Plugins=lib/qt5/plugins |
| 1535 | Imports=lib/qt5/imports |
| 1536 | Qml2Imports=lib/qt5/qml |
| 1537 | Translations=share/qt5/translations |
| 1538 | Settings=etc/xdg |
| 1539 | Examples=share/doc/qt5/examples |
| 1540 | HostPrefix=~a |
| 1541 | HostData=lib/qt5 |
| 1542 | HostBinaries=bin |
| 1543 | HostLibraries=lib |
| 1544 | |
| 1545 | [EffectiveSourcePaths] |
| 1546 | HostPrefix=~a |
| 1547 | HostData=lib/qt5 |
| 1548 | " out out qtbase)))))) |
| 1549 | (replace 'configure |
| 1550 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 1551 | ;; Valid QT_BUILD_PARTS variables are: |
| 1552 | ;; libs tools tests examples demos docs translations |
| 1553 | (invoke "qmake" "QT_BUILD_PARTS = libs tools tests"))) |
| 1554 | (add-before 'check 'set-display |
| 1555 | (lambda _ |
| 1556 | ;; make Qt render "offscreen", required for tests |
| 1557 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 1558 | (synopsis "Qt module for displaying SVGs") |
| 1559 | (description "The QtSvg module provides classes for displaying the |
| 1560 | contents of SVG files."))) |
| 1561 | |
| 1562 | (define-public qtsvg |
| 1563 | (package |
| 1564 | (name "qtsvg") |
| 1565 | (version "6.9.2") |
| 1566 | (source (origin |
| 1567 | (method url-fetch) |
| 1568 | (uri (qt-url name version)) |
| 1569 | (sha256 |
| 1570 | (base32 |
| 1571 | "1985asvnkd2ar30nh2zyi490qz0vkz6z1f752lfald33yawcm16r")))) |
| 1572 | (build-system cmake-build-system) |
| 1573 | (arguments |
| 1574 | (list |
| 1575 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 1576 | #:phases |
| 1577 | #~(modify-phases %standard-phases |
| 1578 | (add-before 'check 'set-display |
| 1579 | (lambda _ |
| 1580 | ;; Make Qt render "offscreen", required for tests. |
| 1581 | (setenv "QT_QPA_PLATFORM" "offscreen"))) |
| 1582 | (add-after 'install 'delete-installed-tests |
| 1583 | (lambda _ |
| 1584 | (delete-file-recursively (string-append #$output "/tests"))))))) |
| 1585 | (native-inputs (list perl)) |
| 1586 | (inputs (list libxkbcommon mesa qtbase zlib)) |
| 1587 | (synopsis "Qt module for displaying SVGs") |
| 1588 | (description "The QtSvg module provides classes for displaying the |
| 1589 | contents of SVG files.") |
| 1590 | (home-page (package-home-page qtbase)) |
| 1591 | (license (package-license qtbase)))) |
| 1592 | |
| 1593 | (define-public qtimageformats-5 |
| 1594 | (package |
| 1595 | (inherit qtsvg-5) |
| 1596 | (name "qtimageformats") |
| 1597 | (version "5.15.17") |
| 1598 | (source (origin |
| 1599 | (method url-fetch) |
| 1600 | (uri (qt-url name version)) |
| 1601 | (sha256 |
| 1602 | (base32 |
| 1603 | "1lff6s212bl44ryfzq8hkp80vl37la7hmpvgz5fp553qi14y4623")) |
| 1604 | (modules '((guix build utils))) |
| 1605 | (snippet |
| 1606 | '(begin |
| 1607 | (delete-file-recursively "src/3rdparty"))))) |
| 1608 | (native-inputs `()) |
| 1609 | (inputs |
| 1610 | (list jasper |
| 1611 | libmng |
| 1612 | libtiff |
| 1613 | libwebp |
| 1614 | mesa |
| 1615 | qtbase-5 |
| 1616 | zlib)) |
| 1617 | (synopsis "Additional Image Format plugins for Qt") |
| 1618 | (description "The QtImageFormats module contains plugins for adding |
| 1619 | support for MNG, TGA, TIFF and WBMP image formats."))) |
| 1620 | |
| 1621 | (define-public qtimageformats |
| 1622 | (package |
| 1623 | (name "qtimageformats") |
| 1624 | (version "6.9.2") |
| 1625 | (source (origin |
| 1626 | (inherit (package-source qtimageformats-5)) |
| 1627 | (method url-fetch) |
| 1628 | (uri (qt-url name version)) |
| 1629 | (sha256 |
| 1630 | (base32 |
| 1631 | "0fciahs4i0nn5z0j624gkfncqg6byxswj45bw81drpjp5xz3y0la")))) |
| 1632 | (build-system cmake-build-system) |
| 1633 | (arguments |
| 1634 | (list |
| 1635 | #:phases |
| 1636 | #~(modify-phases %standard-phases |
| 1637 | (add-before 'check 'set-display |
| 1638 | (lambda _ |
| 1639 | ;; Make Qt render "offscreen", required for tests. |
| 1640 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 1641 | (inputs |
| 1642 | (list jasper |
| 1643 | libmng |
| 1644 | libtiff |
| 1645 | libwebp |
| 1646 | mesa |
| 1647 | qtbase |
| 1648 | zlib)) |
| 1649 | (synopsis "Additional Image Format plugins for Qt") |
| 1650 | (description "The QtImageFormats module contains plugins for adding |
| 1651 | support for MNG, TGA, TIFF and WBMP image formats.") |
| 1652 | (home-page (package-home-page qtbase)) |
| 1653 | (license (package-license qtbase)))) |
| 1654 | |
| 1655 | (define-public qtx11extras |
| 1656 | (package (inherit qtsvg-5) |
| 1657 | (name "qtx11extras") |
| 1658 | (version "5.15.17") |
| 1659 | (source (origin |
| 1660 | (method url-fetch) |
| 1661 | (uri (qt-url name version)) |
| 1662 | (sha256 |
| 1663 | (base32 |
| 1664 | "145hbdaj4r3lljgiasx404c12dl5sk4nghc1pc7w5xy1m8gppcgf")))) |
| 1665 | (arguments |
| 1666 | (substitute-keyword-arguments arguments |
| 1667 | ((#:tests? _ #f) #f))) ; TODO: Enable the tests |
| 1668 | (native-inputs (list perl)) |
| 1669 | (inputs |
| 1670 | (list mesa qtbase-5)) |
| 1671 | (synopsis "Qt Extras for X11") |
| 1672 | (description "The QtX11Extras module includes the library to access X11 |
| 1673 | from within Qt 5."))) |
| 1674 | |
| 1675 | (define-public qxlsx |
| 1676 | (package |
| 1677 | (name "qxlsx") |
| 1678 | (version "1.4.6") |
| 1679 | (source |
| 1680 | (origin |
| 1681 | (method git-fetch) |
| 1682 | (uri (git-reference |
| 1683 | (url "https://github.com/QtExcel/QXlsx") |
| 1684 | (commit (string-append "v" version)))) |
| 1685 | (file-name (git-file-name name version)) |
| 1686 | (sha256 |
| 1687 | (base32 "0xbpajvwkv09h2fang200nsanv5gl1alsdd725gh9cgq4szng6gj")) |
| 1688 | (patches (search-patches "qxlsx-fix-include-directory.patch")))) |
| 1689 | (build-system cmake-build-system) |
| 1690 | (arguments |
| 1691 | (list |
| 1692 | #:configure-flags |
| 1693 | #~(list "../source/QXlsx" |
| 1694 | "-DCMAKE_BUILD_TYPE=Release" |
| 1695 | (string-append "-DCMAKE_INSTALL_PREFIX=" #$output)) |
| 1696 | #:phases |
| 1697 | #~(modify-phases %standard-phases |
| 1698 | (replace 'check |
| 1699 | (lambda* (#:key tests? #:allow-other-keys) |
| 1700 | (when tests? |
| 1701 | (with-directory-excursion "../source/TestExcel" |
| 1702 | (invoke "qmake") |
| 1703 | (invoke "make" "-j" (number->string (parallel-job-count))) |
| 1704 | (invoke "./TestExcel")))))))) |
| 1705 | (inputs |
| 1706 | (list libxkbcommon qtbase vulkan-headers)) |
| 1707 | (home-page "https://qtexcel.github.io/QXlsx/") |
| 1708 | (synopsis "C++ library to read/write Excel XLSX files using Qt") |
| 1709 | (description |
| 1710 | "QXlsx is a successor of QtXlsx and providies a functionality to work with Excel |
| 1711 | XLSX document format.") |
| 1712 | (license license:expat))) |
| 1713 | |
| 1714 | (define-public qtxmlpatterns-5 |
| 1715 | (package (inherit qtsvg-5) |
| 1716 | (name "qtxmlpatterns") |
| 1717 | (version "5.15.17") |
| 1718 | (source (origin |
| 1719 | (method url-fetch) |
| 1720 | (uri (qt-url name version)) |
| 1721 | (sha256 |
| 1722 | (base32 |
| 1723 | "19pq6bmr7zs2n7m8hqsyxyml7kggdkvz0sdhxsg5gvk9fa264b4i")))) |
| 1724 | (arguments |
| 1725 | (substitute-keyword-arguments arguments |
| 1726 | ((#:phases phases) |
| 1727 | `(modify-phases ,phases |
| 1728 | (add-after 'unpack 'disable-network-tests |
| 1729 | (lambda _ (substitute* "tests/auto/auto.pro" |
| 1730 | (("qxmlquery") "# qxmlquery") |
| 1731 | (("xmlpatterns ") "# xmlpatterns")))) |
| 1732 | (add-after 'unpack 'skip-qquickxmllistmodel-test |
| 1733 | (lambda _ (substitute* "tests/auto/auto.pro" |
| 1734 | ((".*qquickxmllistmodel.*") "")))))))) |
| 1735 | (native-inputs (list perl qtdeclarative-5)) |
| 1736 | (inputs (list qtbase-5)) |
| 1737 | (synopsis "Qt XML patterns module") |
| 1738 | (description "The QtXmlPatterns module is a XQuery and XPath engine for |
| 1739 | XML and custom data models. It contains programs such as xmlpatterns and |
| 1740 | xmlpatternsvalidator."))) |
| 1741 | |
| 1742 | (define-public qtdeclarative-5 |
| 1743 | (package |
| 1744 | (inherit qtsvg-5) |
| 1745 | (name "qtdeclarative") |
| 1746 | (version "5.15.17") |
| 1747 | (source (origin |
| 1748 | (method url-fetch) |
| 1749 | (uri (qt-url name version)) |
| 1750 | (sha256 |
| 1751 | (base32 |
| 1752 | "1nnmch6a3k8ja9q8vzhl6kcl52xyy90rpbnaaqqvirwdgrfjvkg1")) |
| 1753 | (patches (search-patches "qtdeclarative-5-disable-qmlcache.patch")))) |
| 1754 | (arguments |
| 1755 | (substitute-keyword-arguments arguments |
| 1756 | ((#:tests? _ #f) #f) ;TODO: Enable the tests |
| 1757 | ((#:phases phases) |
| 1758 | #~(modify-phases #$phases |
| 1759 | (add-after 'build 'fix-qt5core-install-prefix |
| 1760 | (lambda _ |
| 1761 | ;; The Qt5Core install prefix is set to qtbase, but qmlcachegen |
| 1762 | ;; is provided by qtdeclarative-5. |
| 1763 | (substitute* |
| 1764 | "lib/cmake/Qt5QuickCompiler/Qt5QuickCompilerConfig.cmake" |
| 1765 | (("\\$\\{_qt5Core_install_prefix\\}") #$output)))) |
| 1766 | (add-after 'unpack 'fix-linking-riscv64 |
| 1767 | (lambda _ |
| 1768 | (substitute* "src/qml/qml.pro" |
| 1769 | (("DEFINES \\+= QT_NO_FOREACH") |
| 1770 | (string-append |
| 1771 | "isEqual(QT_ARCH, \"riscv64\"): QMAKE_LIBS += -latomic\n\n" |
| 1772 | "DEFINES += QT_NO_FOREACH"))))))))) |
| 1773 | (native-inputs |
| 1774 | (list perl |
| 1775 | pkg-config |
| 1776 | python |
| 1777 | python-wrapper |
| 1778 | qtsvg-5 |
| 1779 | vulkan-headers)) |
| 1780 | (inputs |
| 1781 | (list mesa qtbase-5)) |
| 1782 | (synopsis "Qt QML module (Quick 2)") |
| 1783 | (description "The Qt QML module provides a framework for developing |
| 1784 | applications and libraries with the QML language. It defines and implements the |
| 1785 | language and engine infrastructure, and provides an API to enable application |
| 1786 | developers to extend the QML language with custom types and integrate QML code |
| 1787 | with JavaScript and C++."))) |
| 1788 | |
| 1789 | (define-public qtdeclarative |
| 1790 | (package |
| 1791 | (name "qtdeclarative") |
| 1792 | (version "6.9.2") |
| 1793 | ;; TODO: Package 'masm' and unbundle from sources. |
| 1794 | (source (origin |
| 1795 | (method url-fetch) |
| 1796 | (uri (qt-url name version)) |
| 1797 | (sha256 |
| 1798 | (base32 |
| 1799 | "0r16qima008y2999r1djvwry01l295nmwwhqg081d2fr1cn2szs7")) |
| 1800 | (patches (search-patches "qtdeclarative-disable-qmlcache.patch")))) |
| 1801 | (outputs '("out" "debug")) |
| 1802 | (build-system cmake-build-system) |
| 1803 | (arguments |
| 1804 | (list |
| 1805 | ;; The build takes 12 minutes on a Ryzen 3900X when building with Ninja, |
| 1806 | ;; compared to 24 minutes with Make. |
| 1807 | #:configure-flags #~(list "-GNinja" |
| 1808 | "-DQT_BUILD_TESTS=ON") |
| 1809 | #:phases |
| 1810 | #~(modify-phases %standard-phases |
| 1811 | (add-after 'unpack 'honor-cmake-install-rpath |
| 1812 | ;; The build system goes out of its way to compute a runpath it |
| 1813 | ;; thinks makes more sense, and fails. Revert to the default |
| 1814 | ;; behavior, which is to honor CMAKE_INSTALL_RPATH. |
| 1815 | (lambda _ |
| 1816 | (substitute* "src/qml/Qt6QmlMacros.cmake" |
| 1817 | (("set_target_properties.*PROPERTIES.*INSTALL_RPATH.*" all) |
| 1818 | (string-append "# " all))))) |
| 1819 | (add-after 'unpack 'patch-qlibraryinfo-paths |
| 1820 | (lambda _ |
| 1821 | ;; The QLibraryInfo paths are hard-coded to point to the qtbase |
| 1822 | ;; installation, but all the tools used in the test suite come |
| 1823 | ;; from this package. |
| 1824 | (substitute* (find-files "tests" "\\.cpp$") |
| 1825 | (("QLibraryInfo::path\\(QLibraryInfo::BinariesPath)") |
| 1826 | (string-append "QStringLiteral(\"" #$output "/bin\")")) |
| 1827 | (("QLibraryInfo::path\\(QLibraryInfo::LibraryExecutablesPath)") |
| 1828 | (string-append "QStringLiteral(\"" #$output |
| 1829 | "/lib/qt6/libexec\")")) |
| 1830 | (("QLibraryInfo::path\\(QLibraryInfo::QmlImportsPath)") |
| 1831 | (string-append "QStringLiteral(\"" #$output |
| 1832 | "/lib/qt6/qml\")"))))) |
| 1833 | (replace 'build |
| 1834 | (lambda* (#:key parallel-build? #:allow-other-keys) |
| 1835 | (apply invoke "cmake" "--build" "." |
| 1836 | (if parallel-build? |
| 1837 | `("--parallel" ,(number->string (parallel-job-count))) |
| 1838 | '())))) |
| 1839 | (delete 'check) ;move after the install phase |
| 1840 | (replace 'install |
| 1841 | (lambda _ |
| 1842 | (invoke "cmake" "--install" "."))) |
| 1843 | (add-after 'install 'check |
| 1844 | (lambda* (#:key tests? parallel-tests? |
| 1845 | native-inputs inputs #:allow-other-keys) |
| 1846 | (when tests? |
| 1847 | (setenv "TZDIR" (search-input-directory |
| 1848 | (or native-inputs inputs) "share/zoneinfo")) |
| 1849 | (setenv "TZ" "Etc/UTC") |
| 1850 | (setenv "CMAKE_PREFIX_PATH" |
| 1851 | (string-append #$output |
| 1852 | ":" (getenv "CMAKE_PREFIX_PATH"))) |
| 1853 | (setenv "CPLUS_INCLUDE_PATH" |
| 1854 | (string-append #$output "/include/qt6/:" |
| 1855 | (getenv "CPLUS_INCLUDE_PATH"))) |
| 1856 | ;; The tests expect to find the modules provided by this |
| 1857 | ;; package; extend the environment variables needed to do so. |
| 1858 | (setenv "QML_IMPORT_PATH" |
| 1859 | (string-append #$output "/lib/qt6/qml")) |
| 1860 | (setenv "QT_PLUGIN_PATH" |
| 1861 | (string-append #$output "/lib/qt6/plugins:" |
| 1862 | (getenv "QT_PLUGIN_PATH"))) |
| 1863 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 1864 | ;; Skip tests known to fail on GNU/Linux, in a CI context or |
| 1865 | ;; due to bitness (see: https://code.qt.io/cgit/qt/qtbase.git |
| 1866 | ;; /tree/src/testlib/qtestblacklist.cpp). |
| 1867 | (setenv "QTEST_ENVIRONMENT" "linux ci 32bit") |
| 1868 | (setenv "HOME" "/tmp") ;a few tests require a writable HOME |
| 1869 | (invoke |
| 1870 | "ctest" "--output-on-failure" |
| 1871 | "-j" (if parallel-tests? |
| 1872 | (number->string (parallel-job-count)) |
| 1873 | "1") |
| 1874 | "-E" ;exclude some tests by regex |
| 1875 | (string-append |
| 1876 | "(" |
| 1877 | (string-join |
| 1878 | (list |
| 1879 | ;; The 'tst_qmltyperegistrar' test may fail |
| 1880 | ;; non-deterministically (see: |
| 1881 | ;; https://bugreports.qt.io/browse/QTBUG-123634). |
| 1882 | "tst_qmltyperegistrar" |
| 1883 | ;; The 'tst_qqmlqt' test may fail non-deterministically |
| 1884 | ;; (see: <https://qt-project.atlassian.net/browse/QTBUG-148723>). |
| 1885 | "tst_qqmlqt" |
| 1886 | ;; This test is marked as flaky upstream (see: |
| 1887 | ;; https://bugreports.qt.io/browse/QTBUG-101488). |
| 1888 | "tst_qquickfiledialogimpl" |
| 1889 | ;; These tests all fail because 'test_overlappingHandles' |
| 1890 | ;; (see: https://bugreports.qt.io/browse/QTBUG-95750). |
| 1891 | "tst_basic" |
| 1892 | "tst_fusion" |
| 1893 | "tst_imagine" |
| 1894 | "tst_material" |
| 1895 | "tst_universal" |
| 1896 | ;; Fails due to using the wrong lib/qt6/qml prefix: |
| 1897 | ;; "Warning: Failed to find the following builtins: |
| 1898 | ;; builtins.qmltypes, jsroot.qmltypes (so will use |
| 1899 | ;; qrc). Import paths used: |
| 1900 | ;; /gnu/store/...-qtbase-6.3.1/lib/qt6/qml" |
| 1901 | "tst_qmltc_qprocess" |
| 1902 | ;; This one also causes non-determinstic failures (see: |
| 1903 | ;; https://bugreports.qt.io/browse/QTBUG-101488). |
| 1904 | "tst_qquickfolderdialogimpl" |
| 1905 | ;; These test fail when running qmlimportscanner; perhaps |
| 1906 | ;; an extra CMAKE_PREFIX_PATH location is missing to |
| 1907 | ;; correctly locate the imports. |
| 1908 | "empty_qmldir" |
| 1909 | "qtquickcompiler" |
| 1910 | "cmake_tooling_imports" |
| 1911 | ;; This test seems to hangs for a long time, possibly |
| 1912 | ;; waiting for a killed process, which becomes a zombie in |
| 1913 | ;; the build container (perhaps solved after |
| 1914 | ;; fixing/applying #30948). |
| 1915 | "tst_qqmlpreview" |
| 1916 | |
| 1917 | ;; These tests fail starting with 6.5.2 (see: |
| 1918 | ;; https://bugreports.qt.io/browse/QTBUG-116019). They |
| 1919 | ;; appear to fail because of attempting to load QML from |
| 1920 | ;; elsewhere than from QML_IMPORT_PATH. |
| 1921 | "cmake_test_common_import_path" |
| 1922 | "tst_qqmlcomponent" |
| 1923 | "tst_qmllint" |
| 1924 | "tst_qmldomitem" |
| 1925 | "tst_dom_all" |
| 1926 | "tst_qmlls" |
| 1927 | "tst_qmllscompletions" |
| 1928 | ;; This test fails with comparing 'importPaths' between: |
| 1929 | ;; /tmp/guix-build-.../lib/qt6/qml |
| 1930 | ;; /gnu/store/......../lib/qt6/qml |
| 1931 | "test_generate_qmlls_ini" |
| 1932 | ;; This test fails starting with 6.6.3 (see: |
| 1933 | ;; https://bugreports.qt.io/browse/QTBUG-123748), for |
| 1934 | ;; unknown reasons. |
| 1935 | "tst_qquickiconimage" |
| 1936 | |
| 1937 | ;; These tests are slow (> 2 minutes) skip them (see: |
| 1938 | ;; <https://qt-project.atlassian.net/browse/QTBUG-148724>). |
| 1939 | "tst_qquickpopup" |
| 1940 | "tst_qquickmenu" |
| 1941 | "tst_qquickdrawer" |
| 1942 | "tst_fluentwinui3") |
| 1943 | "|") |
| 1944 | ")"))))) |
| 1945 | (add-after 'install 'delete-installed-tests |
| 1946 | (lambda _ |
| 1947 | (delete-file-recursively (string-append #$output "/tests"))))))) |
| 1948 | (native-inputs |
| 1949 | (list ninja |
| 1950 | perl |
| 1951 | pkg-config |
| 1952 | python |
| 1953 | qtshadertools |
| 1954 | vulkan-headers |
| 1955 | tzdata-for-tests)) |
| 1956 | (inputs |
| 1957 | (list at-spi2-core |
| 1958 | libxkbcommon |
| 1959 | mesa |
| 1960 | qtbase |
| 1961 | qtimageformats |
| 1962 | qtlanguageserver |
| 1963 | qtsvg)) |
| 1964 | (home-page (package-home-page qtbase)) |
| 1965 | (synopsis "Qt QML module (Quick 2)") |
| 1966 | (description "The Qt QML module provides a framework for developing |
| 1967 | applications and libraries with the QML language. It defines and implements |
| 1968 | the language and engine infrastructure, and provides an API to enable |
| 1969 | application developers to extend the QML language with custom types and |
| 1970 | integrate QML code with JavaScript and C++.") |
| 1971 | (license (package-license qtbase)))) |
| 1972 | |
| 1973 | (define-public qtconnectivity-5 |
| 1974 | (package |
| 1975 | (inherit qtsvg-5) |
| 1976 | (name "qtconnectivity") |
| 1977 | (version "5.15.17") |
| 1978 | (source (origin |
| 1979 | (method url-fetch) |
| 1980 | (uri (qt-url name version)) |
| 1981 | (sha256 |
| 1982 | (base32 |
| 1983 | "0ashlprn6fak67dpkcwjv8fipf3r3cb3v5bshnncscn8kkfgrxc7")))) |
| 1984 | (native-inputs |
| 1985 | (list perl pkg-config qtdeclarative-5)) |
| 1986 | (inputs |
| 1987 | (list bluez qtbase-5)) |
| 1988 | (synopsis "Qt Connectivity module") |
| 1989 | (description "The Qt Connectivity modules provides modules for interacting |
| 1990 | with Bluetooth and NFC."))) |
| 1991 | |
| 1992 | (define-public qtconnectivity |
| 1993 | (package |
| 1994 | (name "qtconnectivity") |
| 1995 | (version "6.9.2") |
| 1996 | (source (origin |
| 1997 | (method url-fetch) |
| 1998 | (uri (qt-url name version)) |
| 1999 | (sha256 |
| 2000 | (base32 |
| 2001 | "0qq4d8hn6s8bb9r2gglb6gzq6isbb13knqh7n2s2wsnx8rqwdzwa")))) |
| 2002 | (build-system cmake-build-system) |
| 2003 | (native-inputs |
| 2004 | (list perl pkg-config qtdeclarative)) |
| 2005 | (inputs |
| 2006 | (list bluez qtbase)) |
| 2007 | (arguments |
| 2008 | (list |
| 2009 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 2010 | #:phases |
| 2011 | #~(modify-phases %standard-phases |
| 2012 | (add-before 'check 'set-display |
| 2013 | (lambda _ |
| 2014 | ;; Make Qt render "offscreen", required for tests. |
| 2015 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 2016 | (synopsis "Qt Connectivity module") |
| 2017 | (description "The Qt Connectivity modules provides modules for interacting |
| 2018 | with Bluetooth and NFC.") |
| 2019 | (home-page (package-home-page qtbase)) |
| 2020 | (license (package-license qtbase)))) |
| 2021 | |
| 2022 | (define-public qtwebsockets-5 |
| 2023 | (package (inherit qtsvg-5) |
| 2024 | (name "qtwebsockets") |
| 2025 | (version "5.15.17") |
| 2026 | (source (origin |
| 2027 | (method url-fetch) |
| 2028 | (uri (qt-url name version)) |
| 2029 | (sha256 |
| 2030 | (base32 |
| 2031 | "11fb6bvabkdhjlwyd3q0nmzhaildv9dnda78j9sphfdd5c0x1i6c")))) |
| 2032 | (arguments |
| 2033 | (substitute-keyword-arguments arguments |
| 2034 | ((#:tests? _ #f) #f))) ; TODO: Enable the tests |
| 2035 | (native-inputs |
| 2036 | (list perl qtdeclarative-5)) |
| 2037 | (inputs (list qtbase-5)) |
| 2038 | (synopsis "Qt Web Sockets module") |
| 2039 | (description "WebSocket is a web-based protocol designed to enable two-way |
| 2040 | communication between a client application and a remote host. The Qt |
| 2041 | WebSockets module provides C++ and QML interfaces that enable Qt applications |
| 2042 | to act as a server that can process WebSocket requests, or a client that can |
| 2043 | consume data received from the server, or both."))) |
| 2044 | |
| 2045 | (define-public qtwebsockets |
| 2046 | (package |
| 2047 | (name "qtwebsockets") |
| 2048 | (version "6.9.2") |
| 2049 | (source (origin |
| 2050 | (method url-fetch) |
| 2051 | (uri (qt-url name version)) |
| 2052 | (sha256 |
| 2053 | (base32 |
| 2054 | "1vh82w96436pqrp4daf324mqs2zjvn51z78b3ksc5mnqgrk3z0xy")) |
| 2055 | (patches |
| 2056 | (search-patches |
| 2057 | "qtwebsockets-6.9-fix-tst_QWebSocket.patch")))) |
| 2058 | (build-system cmake-build-system) |
| 2059 | (arguments |
| 2060 | (list |
| 2061 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 2062 | #:phases #~(modify-phases %standard-phases |
| 2063 | (delete 'check) ;move after install |
| 2064 | (add-after 'install 'prepare-for-tests |
| 2065 | (lambda _ |
| 2066 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 2067 | (setenv "QML_IMPORT_PATH" |
| 2068 | (string-append #$output "/lib/qt6/qml:" |
| 2069 | (getenv "QML_IMPORT_PATH"))))) |
| 2070 | (add-after 'prepare-for-tests 'check |
| 2071 | (assoc-ref %standard-phases 'check)) |
| 2072 | (add-after 'check 'delete-installed-tests |
| 2073 | (lambda _ |
| 2074 | (delete-file-recursively |
| 2075 | (string-append #$output "/tests"))))))) |
| 2076 | (native-inputs (list perl)) |
| 2077 | (inputs (list qtbase qtdeclarative)) |
| 2078 | (synopsis "Qt Web Sockets module") |
| 2079 | (description "WebSocket is a web-based protocol designed to enable two-way |
| 2080 | communication between a client application and a remote host. The Qt |
| 2081 | WebSockets module provides C++ and QML interfaces that enable Qt applications |
| 2082 | to act as a server that can process WebSocket requests, or a client that can |
| 2083 | consume data received from the server, or both.") |
| 2084 | (home-page (package-home-page qtbase)) |
| 2085 | (license (package-license qtbase)))) |
| 2086 | |
| 2087 | (define-public qtsensors |
| 2088 | (package |
| 2089 | (inherit qtsvg) |
| 2090 | (name "qtsensors") |
| 2091 | (version "6.9.2") |
| 2092 | (source (origin |
| 2093 | (method url-fetch) |
| 2094 | (uri (qt-url name version)) |
| 2095 | (sha256 |
| 2096 | (base32 |
| 2097 | "0qj4674vim2p34mq3kp99spjyf82qvs75w625namzqp274pshk4n")))) |
| 2098 | (native-inputs (list qtdeclarative)) |
| 2099 | (inputs (list qtbase)) |
| 2100 | (synopsis "Qt Sensors module") |
| 2101 | (description "The Qt Sensors API provides access to sensor hardware via QML |
| 2102 | and C++ interfaces. The Qt Sensors API also provides a motion gesture |
| 2103 | recognition API for devices."))) |
| 2104 | |
| 2105 | (define-public qtsensors-5 |
| 2106 | (package |
| 2107 | (inherit qtsvg-5) |
| 2108 | (name "qtsensors") |
| 2109 | (version "5.15.17") |
| 2110 | (source (origin |
| 2111 | (method url-fetch) |
| 2112 | (uri (qt-url name version)) |
| 2113 | (sha256 |
| 2114 | (base32 |
| 2115 | "00h0qm6g0qjy56q3b7vp1m93p1jyaidlsl1cqmvv38ws5r79pb4h")))) |
| 2116 | (arguments |
| 2117 | (substitute-keyword-arguments arguments |
| 2118 | ((#:parallel-tests? _ #f) #f) ; can lead to race condition |
| 2119 | ((#:phases phases) |
| 2120 | `(modify-phases ,phases |
| 2121 | (add-after 'unpack 'fix-tests |
| 2122 | (lambda _ |
| 2123 | (substitute* "tests/auto/qsensorgestures_gestures\ |
| 2124 | /tst_sensorgestures_gestures.cpp" |
| 2125 | (("2000") "5000") ;lengthen test timeout |
| 2126 | ;; This test fails. |
| 2127 | (("QTest::newRow(\"twist\") << \"twist\"") "")))))))) |
| 2128 | (native-inputs |
| 2129 | (list perl qtdeclarative-5)) |
| 2130 | (inputs (list qtbase-5)) |
| 2131 | (synopsis "Qt Sensors module") |
| 2132 | (description "The Qt Sensors API provides access to sensor hardware via QML |
| 2133 | and C++ interfaces. The Qt Sensors API also provides a motion gesture |
| 2134 | recognition API for devices."))) |
| 2135 | |
| 2136 | (define-public qtmultimedia-5 |
| 2137 | (package |
| 2138 | (inherit qtsvg-5) |
| 2139 | (name "qtmultimedia") |
| 2140 | (version "5.15.17") |
| 2141 | (source (origin |
| 2142 | (method url-fetch) |
| 2143 | (uri (qt-url name version)) |
| 2144 | (sha256 |
| 2145 | (base32 |
| 2146 | "14rx3dgq1jzp4pii5ywxdpkrpwasbn5z0c518z09gwaafv7wcp56")) |
| 2147 | (modules '((guix build utils))) |
| 2148 | (snippet |
| 2149 | '(begin |
| 2150 | (delete-file-recursively |
| 2151 | "examples/multimedia/spectrum/3rdparty") |
| 2152 | ;; We also prevent the spectrum example from being built. |
| 2153 | (substitute* "examples/multimedia/multimedia.pro" |
| 2154 | (("spectrum") "#")))))) |
| 2155 | (arguments |
| 2156 | (substitute-keyword-arguments arguments |
| 2157 | ((#:phases phases) |
| 2158 | `(modify-phases ,phases |
| 2159 | (replace 'configure |
| 2160 | (lambda* (#:key outputs #:allow-other-keys) |
| 2161 | (let ((out (assoc-ref outputs "out"))) |
| 2162 | (invoke "qmake" "QT_BUILD_PARTS = libs tools tests" |
| 2163 | (string-append "QMAKE_LFLAGS_RPATH=-Wl,-rpath," |
| 2164 | out "/lib -Wl,-rpath,") |
| 2165 | (string-append "PREFIX=" out))))))) |
| 2166 | ((#:tests? _ #f) #f))) ; TODO: Enable the tests |
| 2167 | (native-inputs |
| 2168 | (list perl pkg-config python qtdeclarative-5)) |
| 2169 | (inputs |
| 2170 | (list alsa-lib |
| 2171 | mesa |
| 2172 | pulseaudio |
| 2173 | qtbase-5 |
| 2174 | ;; Gstreamer is needed for the mediaplayer plugin |
| 2175 | gstreamer |
| 2176 | gst-plugins-base)) |
| 2177 | (synopsis "Qt Multimedia module") |
| 2178 | (description "The Qt Multimedia module provides set of APIs to play and |
| 2179 | record media, and manage a collection of media content. It also contains a |
| 2180 | set of plugins for interacting with pulseaudio and GStreamer."))) |
| 2181 | |
| 2182 | (define-public qtshadertools |
| 2183 | (package |
| 2184 | (name "qtshadertools") |
| 2185 | (version "6.9.2") |
| 2186 | (source (origin |
| 2187 | (method url-fetch) |
| 2188 | (uri (qt-url name version)) |
| 2189 | ;; Note: the source bundles *patched* glslang and SPIRV-Cross |
| 2190 | ;; sources. |
| 2191 | (sha256 |
| 2192 | (base32 |
| 2193 | "158lpzb1nqspwm0n48d3nfr81q85zka1igrjp6xj8cjlv7wqlrqp")))) |
| 2194 | (build-system cmake-build-system) |
| 2195 | (arguments |
| 2196 | (list |
| 2197 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 2198 | #:phases #~(modify-phases %standard-phases |
| 2199 | (add-before 'check 'prepare-for-tests |
| 2200 | (lambda _ |
| 2201 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 2202 | (native-inputs (list perl)) |
| 2203 | (inputs (list glslang libxkbcommon qtbase)) |
| 2204 | (home-page (package-home-page qtbase)) |
| 2205 | (synopsis "Shader pipeline API and and tools for Qt") |
| 2206 | (description "The @code{qtshadertools} module provides APIs and tools |
| 2207 | supporting shader pipeline functionality as offered in Qt Quick to operate on |
| 2208 | Vulkan, OpenGL and other main graphic APIs.") |
| 2209 | (license (package-license qtbase)))) |
| 2210 | |
| 2211 | (define-public qtmultimedia |
| 2212 | (package |
| 2213 | (name "qtmultimedia") |
| 2214 | (version "6.9.2") |
| 2215 | (source (origin |
| 2216 | (method url-fetch) |
| 2217 | (uri (qt-url name version)) |
| 2218 | (sha256 |
| 2219 | (base32 |
| 2220 | "04mbwl1mg4rjgai027chldslpjnqrx52c3jxn20j2hx7ayda3y3v")))) |
| 2221 | (build-system cmake-build-system) |
| 2222 | (arguments |
| 2223 | (list |
| 2224 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON" |
| 2225 | "-DQT_FEATURE_pulseaudio=ON") |
| 2226 | #:phases |
| 2227 | #~(modify-phases %standard-phases |
| 2228 | (add-after 'unpack 'disable-integration-tests |
| 2229 | (lambda _ |
| 2230 | ;; XXX: The tst_qaudiodecoderbackend, tst_qaudiodevice, |
| 2231 | ;; tst_qaudiosource, tst_qmediaplayerbackend and |
| 2232 | ;; tst_qcamerabackend tests fail, presumably because they |
| 2233 | ;; require a functional pulseaudio daemon (which requires a dbus |
| 2234 | ;; session bus, which requires an X11 server, and then is still |
| 2235 | ;; unhappy). |
| 2236 | (substitute* "tests/auto/CMakeLists.txt" |
| 2237 | (("add_subdirectory\\(integration)") "")) |
| 2238 | ;; The "qvideoframecolormanagement" tests fail (image |
| 2239 | ;; comparisons). A warning right before the failures read "No |
| 2240 | ;; RHI backend. Using CPU conversion." (see: |
| 2241 | ;; https://bugreports.qt.io/browse/QTBUG-123749). |
| 2242 | (substitute* "tests/auto/unit/multimedia/CMakeLists.txt" |
| 2243 | (("add_subdirectory\\(qvideoframecolormanagement\\)") "")))) |
| 2244 | (add-before 'check 'prepare-for-tests |
| 2245 | (lambda _ |
| 2246 | (setenv "HOME" (getcwd)) |
| 2247 | (setenv "QT_QPA_PLATFORM" "offscreen"))) |
| 2248 | (add-after 'install 'delete-installed-tests |
| 2249 | (lambda _ |
| 2250 | (delete-file-recursively (string-append #$output "/tests"))))))) |
| 2251 | (native-inputs |
| 2252 | (list perl |
| 2253 | pkg-config |
| 2254 | qtshadertools |
| 2255 | vulkan-headers)) |
| 2256 | (inputs |
| 2257 | (list alsa-lib |
| 2258 | ffmpeg-6 |
| 2259 | glib |
| 2260 | libxkbcommon |
| 2261 | libxrandr |
| 2262 | mesa |
| 2263 | qtbase |
| 2264 | qtdeclarative |
| 2265 | pulseaudio)) |
| 2266 | (home-page (package-home-page qtbase)) |
| 2267 | (synopsis "Qt Multimedia module") |
| 2268 | (description "The Qt Multimedia module provides set of APIs to play and |
| 2269 | record media, and manage a collection of media content.") |
| 2270 | (license (package-license qtbase)))) |
| 2271 | |
| 2272 | (define-public qtwayland-5 |
| 2273 | (package |
| 2274 | (inherit qtsvg-5) |
| 2275 | (name "qtwayland") |
| 2276 | (version "5.15.18") |
| 2277 | (source (origin |
| 2278 | (method url-fetch) |
| 2279 | (uri (qt-url name version)) |
| 2280 | (patches (search-patches |
| 2281 | "qtwayland-update-wayland-xml.patch" |
| 2282 | ;; KDE Qt5 Patch Collection (kde/5.15 branch, on top |
| 2283 | ;; of v5.15.18-lts-lgpl). Includes fix for |
| 2284 | ;; QTBUG-103391: Wayland protocol error when |
| 2285 | ;; maximumWidth < minimumWidth (patch 0043). |
| 2286 | "qtwayland-5.15.18-0001-client-announce-an-output-after-receiving-more-compl.patch" |
| 2287 | "qtwayland-5.15.18-0002-fix-issue-with-repeated-window-size-changes.patch" |
| 2288 | "qtwayland-5.15.18-0003-client-connect-drags-being-accepted-to-updating-the-.patch" |
| 2289 | "qtwayland-5.15.18-0004-client-disconnect-registry-listener-on-destruction.patch" |
| 2290 | "qtwayland-5.15.18-0005-client-set-xdgshell-size-hints-before-the-first-comm.patch" |
| 2291 | "qtwayland-5.15.18-0006-fix-build.patch" |
| 2292 | "qtwayland-5.15.18-0007-fix-remove-listener.patch" |
| 2293 | "qtwayland-5.15.18-0008-hook-up-querykeyboardmodifers.patch" |
| 2294 | "qtwayland-5.15.18-0009-correctly-detect-if-image-format-is-supported-by-qim.patch" |
| 2295 | "qtwayland-5.15.18-0010-client-don-t-always-recreate-frame-callbacks.patch" |
| 2296 | "qtwayland-5.15.18-0011-client-always-destroy-frame-callback-in-the-actual-c.patch" |
| 2297 | "qtwayland-5.15.18-0012-wayland-client-use-wl_keyboard-to-determine-active-s.patch" |
| 2298 | "qtwayland-5.15.18-0013-client-do-not-empty-clipboard-when-a-new-popup-windo.patch" |
| 2299 | "qtwayland-5.15.18-0014-client-implement-datadevicev3.patch" |
| 2300 | "qtwayland-5.15.18-0015-client-delay-deletion-of-qdrag-object-until-after-we.patch" |
| 2301 | "qtwayland-5.15.18-0016-client-avoid-processing-of-events-when-showing-windo.patch" |
| 2302 | "qtwayland-5.15.18-0017-handle-registry_global-out-of-constructor.patch" |
| 2303 | "qtwayland-5.15.18-0018-connect-flushrequest-after-forceroundtrip.patch" |
| 2304 | "qtwayland-5.15.18-0019-move-the-wayland-socket-polling-to-a-separate-event-.patch" |
| 2305 | "qtwayland-5.15.18-0020-client-remove-mwaitingforupdatedelivery.patch" |
| 2306 | "qtwayland-5.15.18-0021-client-simplify-round-trip-behavior.patch" |
| 2307 | "qtwayland-5.15.18-0022-client-fix-opaque-region-setter.patch" |
| 2308 | "qtwayland-5.15.18-0023-use-proper-dependencies-in-compile-tests.patch" |
| 2309 | "qtwayland-5.15.18-0024-revert-client-remove-mwaitingforupdatedelivery.patch" |
| 2310 | "qtwayland-5.15.18-0025-fix-race-condition-on-mwaitingforupdatedelivery.patch" |
| 2311 | "qtwayland-5.15.18-0026-use-poll-2-when-reading-from-clipboard.patch" |
| 2312 | "qtwayland-5.15.18-0027-reduce-memory-leakage.patch" |
| 2313 | "qtwayland-5.15.18-0028-only-close-popup-in-the-the-hierchary.patch" |
| 2314 | "qtwayland-5.15.18-0029-check-pointer-for-null-before-use-in-assert.patch" |
| 2315 | "qtwayland-5.15.18-0030-use-wl_surface.damage_buffer-on-the-client-side.patch" |
| 2316 | "qtwayland-5.15.18-0031-client-clear-focus-on-touch-cancel.patch" |
| 2317 | "qtwayland-5.15.18-0032-guard-mresizedirty-by-the-correctmutex.patch" |
| 2318 | "qtwayland-5.15.18-0033-fix-compile-tests.patch" |
| 2319 | "qtwayland-5.15.18-0034-call-finishdrag-in-qwaylanddatadevice-dragsourcecanc.patch" |
| 2320 | "qtwayland-5.15.18-0035-hold-surface-read-lock-throughout-qwaylandeglwindow-.patch" |
| 2321 | "qtwayland-5.15.18-0036-keep-toplevel-windows-in-the-top-left-corner-of-the-.patch" |
| 2322 | "qtwayland-5.15.18-0037-client-add-f_seal_shrink-seal-to-shm-backing-file.patch" |
| 2323 | "qtwayland-5.15.18-0038-client-call-wl_output_release-upon-qwaylandscreen-de.patch" |
| 2324 | "qtwayland-5.15.18-0039-client-bump-wl_output-version.patch" |
| 2325 | "qtwayland-5.15.18-0040-fix-frame-sync-related-to-unprotected-multithread-ac.patch" |
| 2326 | "qtwayland-5.15.18-0041-client-handle-zwp_primary_selection_device_manager_v.patch" |
| 2327 | "qtwayland-5.15.18-0042-fixes-the-build-on-centos.patch" |
| 2328 | "qtwayland-5.15.18-0043-client-avoid-protocol-error-with-invalid-min-max-siz.patch" |
| 2329 | "qtwayland-5.15.18-0044-client-fix-handling-of-qt-blankcursor.patch" |
| 2330 | "qtwayland-5.15.18-0045-client-force-a-roundtrip-when-an-xdgoutput-is-not-re.patch" |
| 2331 | "qtwayland-5.15.18-0046-destroy-frame-queue-before-display.patch" |
| 2332 | "qtwayland-5.15.18-0047-client-fix-crash-on-dnd-updates-after-client-facing-.patch" |
| 2333 | "qtwayland-5.15.18-0048-convert-cursor-bitmap-to-supported-format.patch" |
| 2334 | "qtwayland-5.15.18-0049-replace-scale-with-devicepixelratio-for-non-integer-.patch" |
| 2335 | "qtwayland-5.15.18-0050-client-fix-buffer-damage.patch" |
| 2336 | "qtwayland-5.15.18-0051-client-commit-the-initial-surface-state-explicitly.patch" |
| 2337 | "qtwayland-5.15.18-0052-tests-fix-tst_xdgshell-minmaxsize.patch" |
| 2338 | "qtwayland-5.15.18-0053-client-remove-some-surface-commits.patch" |
| 2339 | "qtwayland-5.15.18-0054-client-avoid-locking-resizing-in-qwaylandshmbackings.patch" |
| 2340 | "qtwayland-5.15.18-0055-bradient-use-qwaylandwindow-actual-window-title.patch" |
| 2341 | "qtwayland-5.15.18-0056-redraw-hidpi.patch")) |
| 2342 | (sha256 |
| 2343 | (base32 |
| 2344 | "07gqgd6ixqnsvc9r1c9y92vaxwj11ijrqvnxib8sv6xwhcmhvw43")))) |
| 2345 | (arguments |
| 2346 | (substitute-keyword-arguments arguments |
| 2347 | ((#:phases phases) |
| 2348 | #~(modify-phases #$phases |
| 2349 | (add-after 'unpack 'disable-failing-tests |
| 2350 | (lambda _ |
| 2351 | ;; FIXME: tst_seatv4::animatedCursor() fails for no good |
| 2352 | ;; reason and breaks these two tests. |
| 2353 | (substitute* "tests/auto/client/seatv4/tst_seatv4.cpp" |
| 2354 | (((string-append "QVERIFY\\(!cursorSurface\\(\\)->" |
| 2355 | "m_waitingFrameCallbacks\\.empty\\(\\)\\);")) |
| 2356 | "") |
| 2357 | (("QTRY_COMPARE\\(bufferSpy\\.count\\(\\), 1\\);") |
| 2358 | "")) |
| 2359 | ;; KDE patch 0053 removed the wl_surface.commit call |
| 2360 | ;; from propagateSizeHints() because committing the |
| 2361 | ;; surface every time a size hint changed could send |
| 2362 | ;; incomplete state to the compositor (e.g. the window |
| 2363 | ;; geometry might not be set yet). As a result, |
| 2364 | ;; setMaximumSize() updates the xdg_toplevel min/max |
| 2365 | ;; size but no longer commits the surface, so the |
| 2366 | ;; compositor does not see the new values until the |
| 2367 | ;; next frame. This test calls setMaximumSize() and |
| 2368 | ;; immediately checks the committed value, which is |
| 2369 | ;; still the old one. |
| 2370 | (substitute* "tests/auto/client/xdgshell/tst_xdgshell.cpp" |
| 2371 | (("QCOMPOSITOR_TRY_COMPARE\\(xdgToplevel\\(\\)->m_committed\\.maxSize, QSize\\(500, 400\\)\\)") |
| 2372 | "QSKIP(\"setMaximumSize no longer triggers a surface commit (patch 0053)\")")) |
| 2373 | ;; Same issue: patch 0053 removed the wl_surface.commit |
| 2374 | ;; from setMask(), so moving a subsurface no longer |
| 2375 | ;; triggers an immediate parent surface commit. The |
| 2376 | ;; test expects the parent to commit right after |
| 2377 | ;; setGeometry on the child, but the commit count |
| 2378 | ;; stays at 0. |
| 2379 | (substitute* "tests/auto/client/surface/tst_surface.cpp" |
| 2380 | (("window\\.setObjectName\\(\"main\"\\)") |
| 2381 | "QSKIP(\"subsurface move no longer triggers parent commit (patch 0053)\"); window.setObjectName(\"main\")")) |
| 2382 | #$@(if (target-aarch64?) |
| 2383 | ;; The tst_surface::createSubsurface test fails on |
| 2384 | ;; aarch64 (see: |
| 2385 | ;; https://bugreports.qt.io/browse/QTBUG-117112). |
| 2386 | #~((substitute* "tests/auto/client/client.pro" |
| 2387 | ((".*surface.*") ""))) |
| 2388 | #~()))) |
| 2389 | (add-before 'check 'set-test-environment |
| 2390 | (lambda _ |
| 2391 | ;; Do not fail just because /etc/machine-id is missing. |
| 2392 | (setenv "DBUS_FATAL_WARNINGS" "0"))))))) |
| 2393 | (native-inputs (list glib perl pkg-config qtdeclarative-5)) |
| 2394 | (inputs |
| 2395 | (list fontconfig |
| 2396 | freetype |
| 2397 | libx11 |
| 2398 | libxcomposite |
| 2399 | libxext |
| 2400 | libxkbcommon |
| 2401 | libxrender |
| 2402 | mesa |
| 2403 | mtdev |
| 2404 | qtbase-5 |
| 2405 | vulkan-headers |
| 2406 | wayland)) |
| 2407 | (synopsis "Qt Wayland module") |
| 2408 | (description "The Qt Wayland module provides the QtWayland client and |
| 2409 | compositor libraries."))) |
| 2410 | |
| 2411 | (define-public qtwayland |
| 2412 | (package |
| 2413 | (name "qtwayland") |
| 2414 | (version "6.9.2") |
| 2415 | (source |
| 2416 | (origin |
| 2417 | (method url-fetch) |
| 2418 | (uri (qt-url name version)) |
| 2419 | (sha256 |
| 2420 | (base32 "10bpxwpam56gvymz9vjxkppbqsj1369ddzl3k4pz2s2maq39imya")))) |
| 2421 | (build-system cmake-build-system) |
| 2422 | (arguments |
| 2423 | (list #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 2424 | #:phases |
| 2425 | #~(modify-phases %standard-phases |
| 2426 | (add-after 'unpack 'update-wayland.xml |
| 2427 | ;; Upstream commit: c2f61bc47baacf2e6a44c6c3c4e4cbf0abfa4095 |
| 2428 | (lambda* (#:key inputs #:allow-other-keys) |
| 2429 | (copy-file (search-input-file |
| 2430 | inputs "/share/wayland/wayland.xml") |
| 2431 | "src/3rdparty/protocol/wayland/wayland.xml"))) |
| 2432 | (add-after 'unpack 'disable-failing-tests |
| 2433 | (lambda _ |
| 2434 | ;; FIXME: tst_seatv4::animatedCursor() fails here. |
| 2435 | ;; See also: <https://bugreports.qt.io/browse/QTBUG-78317> |
| 2436 | (substitute* "tests/auto/client/seatv4/tst_seatv4.cpp" |
| 2437 | (((string-append |
| 2438 | "QVERIFY\\(!cursorSurface\\(\\)->" |
| 2439 | "m_waitingFrameCallbacks\\.empty\\(\\)\\);")) "") |
| 2440 | (("QTRY_COMPARE\\(bufferSpy\\.size\\(\\), 1\\);") "")) |
| 2441 | ;; known failing with wayland-1.23.0, so skip this. |
| 2442 | ;; See also: <https://bugreports.qt.io/browse/QTBUG-126379> |
| 2443 | (substitute* "tests/auto/client/CMakeLists.txt" |
| 2444 | (("add_subdirectory\\(scaling\\)") "")))) |
| 2445 | (add-before 'check 'set-test-environment |
| 2446 | (lambda _ |
| 2447 | (setenv "XDG_RUNTIME_DIR" (getcwd)) |
| 2448 | ;; Do not fail just because /etc/machine-id is missing. |
| 2449 | (setenv "DBUS_FATAL_WARNINGS" "0") |
| 2450 | ;; Make Qt render "offscreen", required for tests. |
| 2451 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 2452 | (native-inputs (list glib perl pkg-config qtdeclarative)) |
| 2453 | (inputs |
| 2454 | (list fontconfig |
| 2455 | freetype |
| 2456 | libx11 |
| 2457 | libxcomposite |
| 2458 | libxext |
| 2459 | libxkbcommon |
| 2460 | libxrender |
| 2461 | mesa |
| 2462 | mtdev |
| 2463 | qtbase |
| 2464 | vulkan-headers |
| 2465 | wayland)) |
| 2466 | (native-search-paths |
| 2467 | (list (search-path-specification |
| 2468 | (variable "QT_PLUGIN_PATH") |
| 2469 | (files '("lib/qt6/plugins"))))) |
| 2470 | (synopsis "Qt Wayland module") |
| 2471 | (description "The Qt Wayland module provides the QtWayland client and |
| 2472 | compositor libraries.") |
| 2473 | (home-page (package-home-page qtbase)) |
| 2474 | (license (package-license qtbase)))) |
| 2475 | |
| 2476 | (define-public qtserialport-5 |
| 2477 | (package |
| 2478 | (inherit qtsvg-5) |
| 2479 | (name "qtserialport") |
| 2480 | (version "5.15.17") |
| 2481 | (source (origin |
| 2482 | (method url-fetch) |
| 2483 | (uri (qt-url name version)) |
| 2484 | (sha256 |
| 2485 | (base32 |
| 2486 | "1r5avi20fyxcnh27lcd78fmm9mqm67yydmq87p624qmqii8bdi12")))) |
| 2487 | (native-inputs (list perl)) |
| 2488 | (inputs (list qtbase-5 eudev)) |
| 2489 | (arguments |
| 2490 | (substitute-keyword-arguments arguments |
| 2491 | ((#:phases phases) |
| 2492 | #~(modify-phases #$phases |
| 2493 | (add-after 'unpack 'patch-dlopen-paths |
| 2494 | (lambda* (#:key inputs #:allow-other-keys) |
| 2495 | (substitute* "src/serialport/qtudev_p.h" |
| 2496 | ;; Use the absolute paths for dynamically loaded libs, |
| 2497 | ;; otherwise the lib will be searched in LD_LIBRARY_PATH which |
| 2498 | ;; typically is not set in guix. |
| 2499 | (("setFileNameAndVersion\\(QStringLiteral\\(\"udev\")") |
| 2500 | (format #f "setFileNameAndVersion(QStringLiteral(~s))" |
| 2501 | (string-append #$(this-package-input "eudev") |
| 2502 | "/lib/libudev")))))))))) |
| 2503 | (synopsis "Qt Serial Port module") |
| 2504 | (description "The Qt Serial Port module provides the library for |
| 2505 | interacting with serial ports from within Qt."))) |
| 2506 | |
| 2507 | (define-public qtserialport |
| 2508 | (package |
| 2509 | (name "qtserialport") |
| 2510 | (version "6.9.2") |
| 2511 | (source |
| 2512 | (origin |
| 2513 | (method url-fetch) |
| 2514 | (uri (qt-url name version)) |
| 2515 | (sha256 |
| 2516 | (base32 "0sz2dkas4qjdd6lkfb9g89vi94q18aiq9xdchlqb2yn0qbqb544b")))) |
| 2517 | (build-system cmake-build-system) |
| 2518 | (arguments |
| 2519 | (list #:phases |
| 2520 | #~(modify-phases %standard-phases |
| 2521 | (add-after 'unpack 'patch-dlopen-paths |
| 2522 | (lambda* (#:key inputs #:allow-other-keys) |
| 2523 | (substitute* "src/serialport/qtudev_p.h" |
| 2524 | ;; Use the absolute paths for dynamically loaded libs, |
| 2525 | ;; otherwise the lib will be searched in LD_LIBRARY_PATH |
| 2526 | ;; which typically is not set in guix. |
| 2527 | (("setFileNameAndVersion\\(QStringLiteral\\(\"udev\")") |
| 2528 | (format #f "setFileNameAndVersion(QStringLiteral(~s))" |
| 2529 | (string-append #$(this-package-input "eudev") |
| 2530 | "/lib/libudev"))))))))) |
| 2531 | (native-inputs (list pkg-config)) |
| 2532 | (inputs (list qtbase eudev)) |
| 2533 | (home-page (package-home-page qtbase)) |
| 2534 | (synopsis "Qt Serial Port module") |
| 2535 | (description "The Qt Serial Port module provides the library for |
| 2536 | interacting with serial ports from within Qt.") |
| 2537 | (license (package-license qtbase)))) |
| 2538 | |
| 2539 | (define-public qtwebchannel-5 |
| 2540 | (package (inherit qtsvg-5) |
| 2541 | (name "qtwebchannel") |
| 2542 | (version "5.15.17") |
| 2543 | (source (origin |
| 2544 | (method url-fetch) |
| 2545 | (uri (qt-url name version)) |
| 2546 | (sha256 |
| 2547 | (base32 |
| 2548 | "157nabb3g7i8damk10i1axmbbzxzh4hd45j0z3kzjj0cywf3rzgc")))) |
| 2549 | (native-inputs (list perl qtdeclarative-5 qtwebsockets-5)) |
| 2550 | (inputs (list qtbase-5)) |
| 2551 | (synopsis "Web communication library for Qt") |
| 2552 | (description "The Qt WebChannel module enables peer-to-peer communication |
| 2553 | between the host (QML/C++ application) and the client (HTML/JavaScript |
| 2554 | application). The transport mechanism is supported out of the box by the two |
| 2555 | popular web engines, Qt WebKit 2 and Qt WebEngine."))) |
| 2556 | |
| 2557 | (define-public qtwebchannel |
| 2558 | (package |
| 2559 | (name "qtwebchannel") |
| 2560 | (version "6.9.2") |
| 2561 | (source (origin |
| 2562 | (method url-fetch) |
| 2563 | (uri (qt-url name version)) |
| 2564 | (sha256 |
| 2565 | (base32 |
| 2566 | "0rcf7i1wamdf1qynq3yi88r77ch5dg1jinxywlfjlb2dmlvn72l7")))) |
| 2567 | (build-system cmake-build-system) |
| 2568 | (arguments |
| 2569 | (list |
| 2570 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 2571 | #:phases #~(modify-phases %standard-phases |
| 2572 | (delete 'check) ;move after install |
| 2573 | (add-after 'install 'prepare-for-tests |
| 2574 | (lambda _ |
| 2575 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 2576 | (setenv "QML_IMPORT_PATH" |
| 2577 | (string-append #$output "/lib/qt6/qml:" |
| 2578 | (getenv "QML_IMPORT_PATH"))))) |
| 2579 | (add-after 'prepare-for-tests 'check |
| 2580 | (assoc-ref %standard-phases 'check)) |
| 2581 | (add-after 'check 'delete-installed-tests |
| 2582 | (lambda _ |
| 2583 | (delete-file-recursively |
| 2584 | (string-append #$output "/tests"))))))) |
| 2585 | (native-inputs (list perl)) |
| 2586 | (inputs (list qtbase qtdeclarative qtwebsockets)) |
| 2587 | (home-page (package-home-page qtbase)) |
| 2588 | (synopsis "Web communication library for Qt") |
| 2589 | (description "The Qt WebChannel module enables peer-to-peer communication |
| 2590 | between the host (QML/C++ application) and the client (HTML/JavaScript |
| 2591 | application).") |
| 2592 | (license (package-license qtbase)))) |
| 2593 | |
| 2594 | (define-public qtwebview |
| 2595 | (package |
| 2596 | (name "qtwebview") |
| 2597 | (version "6.9.2") |
| 2598 | (source (origin |
| 2599 | (method url-fetch) |
| 2600 | (uri (qt-url name version)) |
| 2601 | (sha256 |
| 2602 | (base32 |
| 2603 | "1w8z3d7w7z2xjfb5l15gb37v9w6pa7d71jalkrqda8l2wr5d3ksc")))) |
| 2604 | (build-system cmake-build-system) |
| 2605 | (arguments |
| 2606 | (list #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 2607 | #:phases |
| 2608 | #~(modify-phases %standard-phases |
| 2609 | (add-before 'check 'set-display |
| 2610 | (lambda _ |
| 2611 | ;; Make Qt render "offscreen", required for tests. |
| 2612 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 2613 | ;; Set writable HOME for teststing cache directory. |
| 2614 | (setenv "HOME" "/tmp")))))) |
| 2615 | (native-inputs (list perl)) |
| 2616 | (inputs (list qtbase qtdeclarative qtwebengine)) |
| 2617 | (synopsis "Display web content in a QML application") |
| 2618 | (description "Qt WebView provides a way to display web content in a QML |
| 2619 | application without necessarily including a full web browser stack by using |
| 2620 | native APIs where it makes sense.") |
| 2621 | (home-page (package-home-page qtbase)) |
| 2622 | (license (package-license qtbase)))) |
| 2623 | |
| 2624 | (define-public qtlanguageserver |
| 2625 | (package |
| 2626 | (name "qtlanguageserver") |
| 2627 | (version "6.9.2") |
| 2628 | (source (origin |
| 2629 | (method url-fetch) |
| 2630 | (uri (qt-url name version)) |
| 2631 | (sha256 |
| 2632 | (base32 |
| 2633 | "1vlb0qn53y1b4zf7zkpxdvdh5ikr1cidq5gv8blvf6pyw6pnw6vq")))) |
| 2634 | (build-system cmake-build-system) |
| 2635 | (arguments |
| 2636 | (list #:phases #~(modify-phases %standard-phases |
| 2637 | (add-after 'install 'delete-installed-tests |
| 2638 | (lambda _ |
| 2639 | (delete-file-recursively |
| 2640 | (string-append #$output "/tests"))))))) |
| 2641 | (inputs (list qtbase)) |
| 2642 | (home-page (package-home-page qtbase)) |
| 2643 | (synopsis "Implementation of the Language Server Protocol for Qt") |
| 2644 | (description "This package provides an implementation of the Language |
| 2645 | Server Protocol (LSP) for Qt.") |
| 2646 | (license (package-license qtbase)))) |
| 2647 | |
| 2648 | (define-public qtlocation-5 |
| 2649 | (package |
| 2650 | (inherit qtsvg-5) |
| 2651 | (name "qtlocation") |
| 2652 | (version "5.15.17") |
| 2653 | (source (origin |
| 2654 | (method url-fetch) |
| 2655 | (uri (qt-url name version)) |
| 2656 | (sha256 |
| 2657 | (base32 |
| 2658 | "1kqljk3ax2dfib4g0nh9zwdabiv8lyr7hxbj9qh05lrhcyshkrpk")) |
| 2659 | (patches |
| 2660 | (search-patches "qtlocation-5.15.8-mapboxgl-gcc13.patch")) |
| 2661 | (modules '((guix build utils))) |
| 2662 | (snippet |
| 2663 | #~(begin |
| 2664 | ;; TODO: Unvendor more deps. |
| 2665 | (with-directory-excursion "src/3rdparty/mapbox-gl-native" |
| 2666 | (for-each delete-file-recursively |
| 2667 | (list "deps/rapidjson" |
| 2668 | "deps/protozero")) |
| 2669 | |
| 2670 | (substitute* "mapbox-gl-native.pro" |
| 2671 | ((" deps/protozero/1\\.5\\.2 \\\\ |
| 2672 | deps/protozero/1\\.5\\.2/include \\\\ |
| 2673 | deps/rapidjson/1\\.1\\.0 \\\\ |
| 2674 | deps/rapidjson/1\\.1\\.0/include \\\\") |
| 2675 | ""))))))) |
| 2676 | (arguments |
| 2677 | (substitute-keyword-arguments arguments |
| 2678 | ((#:tests? _ #f) #f) ; TODO: Enable the tests |
| 2679 | ((#:phases phases) |
| 2680 | #~(modify-phases #$phases |
| 2681 | (add-before 'check 'pre-check |
| 2682 | (lambda _ |
| 2683 | (setenv "HOME" "/tmp"))))))) |
| 2684 | (native-inputs (list perl qtdeclarative-5 qtquickcontrols-5 qtserialport-5)) |
| 2685 | (inputs (list icu4c openssl qtbase-5 zlib rapidjson protozero)) |
| 2686 | (synopsis "Qt Location and Positioning modules") |
| 2687 | (description "The Qt Location module provides an interface for location, |
| 2688 | positioning and geolocation plugins."))) |
| 2689 | |
| 2690 | (define-public qtlocation |
| 2691 | (package |
| 2692 | (inherit qtsvg) |
| 2693 | (name "qtlocation") |
| 2694 | (version "6.9.2") |
| 2695 | (source (origin |
| 2696 | (method url-fetch) |
| 2697 | (uri (qt-url name version)) |
| 2698 | (sha256 |
| 2699 | (base32 |
| 2700 | "1ybk3ig69p6zyrxabcfkb4pcyc251gy1m2brkf4q52cmcwcysias")))) |
| 2701 | (arguments |
| 2702 | (substitute-keyword-arguments arguments |
| 2703 | ((#:tests? _ #f) #f) ; TODO: Enable the tests |
| 2704 | ((#:phases phases) |
| 2705 | #~(modify-phases #$phases |
| 2706 | (add-before 'check 'pre-check |
| 2707 | (lambda _ |
| 2708 | (setenv "HOME" "/tmp"))))))) |
| 2709 | (native-inputs (list perl)) |
| 2710 | (inputs (list icu4c openssl qtbase zlib qtdeclarative qtpositioning |
| 2711 | libxkbcommon)) |
| 2712 | (synopsis "Qt Location and Positioning modules") |
| 2713 | (description "The Qt Location module provides an interface for location, |
| 2714 | positioning and geolocation plugins."))) |
| 2715 | |
| 2716 | (define-public qtlottie |
| 2717 | (package |
| 2718 | (name "qtlottie") |
| 2719 | (version "6.9.2") |
| 2720 | (source (origin |
| 2721 | (method url-fetch) |
| 2722 | (uri (qt-url name version)) |
| 2723 | (sha256 |
| 2724 | (base32 |
| 2725 | "1iiigsb4p1zwkxm1x9c4pbx5rgwz35krdqi3vkql4nawvp997px4")))) |
| 2726 | (build-system cmake-build-system) |
| 2727 | (arguments |
| 2728 | (list |
| 2729 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 2730 | #:phases |
| 2731 | #~(modify-phases %standard-phases |
| 2732 | (delete 'check) ;move after install |
| 2733 | (add-after 'install 'prepare-for-tests |
| 2734 | (lambda _ |
| 2735 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 2736 | (setenv "QML_IMPORT_PATH" |
| 2737 | (string-append #$output "/lib/qt6/qml:" |
| 2738 | (getenv "QML_IMPORT_PATH")))))))) |
| 2739 | (native-inputs (list perl)) |
| 2740 | (inputs (list libxkbcommon qtbase qtdeclarative)) |
| 2741 | (home-page (package-home-page qtbase)) |
| 2742 | (synopsis "QML API for rendering Bodymovin graphics and animations") |
| 2743 | (description "Qt Lottie Animation provides a QML API for rendering |
| 2744 | graphics and animations that are exported in JSON format by the Bodymovin |
| 2745 | plugin for Adobe After Effects.") |
| 2746 | (license (package-license qtbase)))) |
| 2747 | |
| 2748 | (define-public qttools-5 |
| 2749 | (package |
| 2750 | (inherit qtsvg-5) |
| 2751 | (name "qttools") |
| 2752 | (version "5.15.17") |
| 2753 | (source (origin |
| 2754 | (method url-fetch) |
| 2755 | (uri (qt-url name version)) |
| 2756 | (sha256 |
| 2757 | (base32 |
| 2758 | "1imzr7gxbbl1m05g6a4ji0pxvabp0j4x3q33dxa7zfrjczmhcc23")))) |
| 2759 | (arguments |
| 2760 | (substitute-keyword-arguments arguments |
| 2761 | ((#:tests? _ #f) #f) ; TODO: Enable the tests |
| 2762 | ((#:phases phases '%standard-phases) |
| 2763 | #~(modify-phases #$phases |
| 2764 | (add-after 'unpack 'patch-qmake |
| 2765 | (lambda* (#:key inputs #:allow-other-keys) |
| 2766 | ;; Adjust the default location of the 'qmake' command known to |
| 2767 | ;; the 'lprodump' command, which would otherwise look for it |
| 2768 | ;; in its own bindir. |
| 2769 | (substitute* "src/linguist/lprodump/main.cpp" |
| 2770 | (("app.applicationDirPath\\() \\+ QLatin1String\\(\"/qmake\")") |
| 2771 | (format #f "QLatin1String(~s)" |
| 2772 | (search-input-file inputs "bin/qmake")))))))))) |
| 2773 | (native-inputs (list perl qtdeclarative-5 vulkan-headers)) |
| 2774 | (inputs (list mesa qtbase-5)) |
| 2775 | (synopsis "Qt Tools and Designer modules") |
| 2776 | (description "The Qt Tools module provides a set of applications to browse |
| 2777 | the documentation, translate applications, generate help files and other stuff |
| 2778 | that helps in Qt development."))) |
| 2779 | |
| 2780 | (define-public qttools |
| 2781 | (package |
| 2782 | (name "qttools") |
| 2783 | (version "6.9.2") |
| 2784 | (source (origin |
| 2785 | (method url-fetch) |
| 2786 | (uri (qt-url name version)) |
| 2787 | (sha256 |
| 2788 | (base32 |
| 2789 | "12d4czfwvh9rfjwnkpsiwzrpx4ga69c6vz85aabhpk3hx7lggdyq")))) |
| 2790 | (build-system cmake-build-system) |
| 2791 | (arguments |
| 2792 | (list |
| 2793 | #:tests? #f |
| 2794 | ;; The build system attempts to fetch online resources and fails when |
| 2795 | ;; building the test suite. |
| 2796 | #:configure-flags #~(list "-DQT_BUILD_TESTS=OFF") |
| 2797 | #:phases #~(modify-phases %standard-phases |
| 2798 | (add-after 'install 'sanity-check |
| 2799 | (lambda* (#:key outputs #:allow-other-keys) |
| 2800 | ;; This validation exists to validate that the dynamic |
| 2801 | ;; library for Clang works as intended; there was |
| 2802 | ;; originally problems due to left-overs patching the |
| 2803 | ;; value of BUILD_SHARED_LIBS in CLANG-FROM-LLVM that |
| 2804 | ;; would cause the following error: "CommandLine Error: |
| 2805 | ;; Option 'filter' registered more than once!" |
| 2806 | (invoke/quiet (search-input-file outputs "bin/qdoc") |
| 2807 | "--help")))))) |
| 2808 | (native-inputs (list perl qtdeclarative vulkan-headers)) |
| 2809 | ;; Use clang-18, which is built using as a single shared library, which is |
| 2810 | ;; what the build system of qttools expects. |
| 2811 | (inputs (list clang-18 libxkbcommon mesa qtbase `(,zstd "lib"))) |
| 2812 | (home-page (package-home-page qtbase)) |
| 2813 | (synopsis "Qt Tools and Designer modules") |
| 2814 | (description "The Qt Tools module provides a set of applications to browse |
| 2815 | the documentation, translate applications, generate help files and other stuff |
| 2816 | that helps in Qt development.") |
| 2817 | ;; GPL 3 only with Qt GPL exception 1.0 (see: |
| 2818 | ;; LICENSES/Qt-GPL-exception-1.0.txt). |
| 2819 | (license (list license:gpl3)))) |
| 2820 | |
| 2821 | (define-public qttranslations |
| 2822 | (package |
| 2823 | (name "qttranslations") |
| 2824 | (version "6.9.2") |
| 2825 | (source (origin |
| 2826 | (method url-fetch) |
| 2827 | (uri (qt-url name version)) |
| 2828 | (sha256 |
| 2829 | (base32 |
| 2830 | "1mky3xj2yhcsrmpz8m28v7pky6ryn7hvdcglakww0rfk3qlbcfy7")))) |
| 2831 | (build-system cmake-build-system) |
| 2832 | (arguments (list #:tests? #f)) |
| 2833 | (native-inputs (list qtbase qttools)) |
| 2834 | (home-page (package-home-page qtbase)) |
| 2835 | (synopsis "Qt translation catalogs") |
| 2836 | (description "This package contains the translations for Qt contributed by |
| 2837 | the Qt community.") |
| 2838 | ;; GPL 3 only with Qt GPL exception 1.0 (see: |
| 2839 | ;; LICENSES/Qt-GPL-exception-1.0.txt). |
| 2840 | (license (list license:gpl3)))) |
| 2841 | |
| 2842 | (define-public qtscript-5 |
| 2843 | (package |
| 2844 | (inherit qtsvg-5) |
| 2845 | (name "qtscript") |
| 2846 | (version "5.15.17") |
| 2847 | (source (origin |
| 2848 | (method url-fetch) |
| 2849 | (uri (qt-url name version)) |
| 2850 | (sha256 |
| 2851 | (base32 |
| 2852 | "1qas9xx7zlika5x8x3n51dfc8ikm4r2p4p0j0w2rg3cigyjb2bb2")) |
| 2853 | (patches (search-patches "qtscript-disable-tests.patch")))) |
| 2854 | (native-inputs (list perl qttools-5)) |
| 2855 | (inputs (list qtbase-5)) |
| 2856 | (synopsis "Qt Script module") |
| 2857 | (description "Qt provides support for application scripting with ECMAScript. |
| 2858 | The following guides and references cover aspects of programming with |
| 2859 | ECMAScript and Qt."))) |
| 2860 | |
| 2861 | (define-public qtquick3d |
| 2862 | (package |
| 2863 | (name "qtquick3d") |
| 2864 | (version "6.9.2") |
| 2865 | (source (origin |
| 2866 | (method url-fetch) |
| 2867 | (uri (qt-url name version)) |
| 2868 | (sha256 |
| 2869 | (base32 |
| 2870 | "002888xfnkxmvn8413fllidl3mm2fcwc4gbzdnbvpjlysaq9f3ig")))) |
| 2871 | (build-system cmake-build-system) |
| 2872 | (arguments |
| 2873 | (list #:modules '((guix build cmake-build-system) |
| 2874 | (guix build qt-utils) |
| 2875 | (guix build utils)) |
| 2876 | #:imported-modules `(,@%cmake-build-system-modules |
| 2877 | (guix build qt-utils)) |
| 2878 | #:phases |
| 2879 | #~(modify-phases %standard-phases |
| 2880 | (delete 'check) ;moved after install phase |
| 2881 | (add-after 'install 'check |
| 2882 | (assoc-ref %standard-phases 'check)) |
| 2883 | (add-before 'check 'prepare-for-tests |
| 2884 | (lambda _ |
| 2885 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 2886 | (setenv "QT_PLUGIN_PATH" |
| 2887 | (string-append #$output "/lib/qt6/plugins:" |
| 2888 | (getenv "QT_PLUGIN_PATH"))) |
| 2889 | (setenv "QML_IMPORT_PATH" |
| 2890 | (string-append #$output "/lib/qt6/qml:" |
| 2891 | (getenv "QML_IMPORT_PATH"))))) |
| 2892 | (add-after 'check 'qt-wrap |
| 2893 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 2894 | (wrap-all-qt-programs #:inputs inputs |
| 2895 | #:outputs outputs |
| 2896 | #:qtbase #$qtbase)))))) |
| 2897 | (inputs (list qtbase qtdeclarative qtshadertools qtwayland)) |
| 2898 | (synopsis "Qt module and API for defining 3D content in Qt Quick") |
| 2899 | (description "Qt Quick 3D is a module within the Qt framework that |
| 2900 | provides a high-level interface for creating 3D content for user interfaces. Its key features include: |
| 2901 | @itemize |
| 2902 | @item Spatial (3D) scene graph |
| 2903 | @item Mixing 2D and 3D Qt Quick content |
| 2904 | @item Physically based rendering (PBR) materials |
| 2905 | @item Punctual and image based lighting |
| 2906 | @item Custom material and effect system |
| 2907 | @item GLTF (Graphics Library Transmission Format) 2.0 model import |
| 2908 | @item Animation support |
| 2909 | @item 3D input handling and picking |
| 2910 | @item 3D particle system |
| 2911 | @end itemize") |
| 2912 | (home-page (package-home-page qtbase)) |
| 2913 | (license (package-license qtbase)))) |
| 2914 | |
| 2915 | (define-public qtquick3dphysics |
| 2916 | (package |
| 2917 | (name "qtquick3dphysics") |
| 2918 | (version "6.9.2") |
| 2919 | (source (origin |
| 2920 | (method url-fetch) |
| 2921 | (uri (qt-url name version)) |
| 2922 | (sha256 |
| 2923 | (base32 |
| 2924 | "12yc0lswcmyaw19yyxzy73j95ncgqw8mlx8svhrwsllgcf2n9z47")))) |
| 2925 | (build-system cmake-build-system) |
| 2926 | (arguments |
| 2927 | (list #:phases #~(modify-phases %standard-phases |
| 2928 | (add-before 'check 'prepare-for-tests |
| 2929 | (lambda _ |
| 2930 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 2931 | (inputs (list qtbase qtdeclarative qtquick3d qtshadertools)) |
| 2932 | (synopsis "Physics engine integration for Qt Quick 3D") |
| 2933 | (description "Qt Quick 3D Physics provides a high-level API for physics |
| 2934 | simulation. It supports simulating interactive rigid bodies as well as static |
| 2935 | meshes and non-colliding bodies used for detecting overlaps. Every simulated |
| 2936 | body can have its own physical properties like mass, density and friction.") |
| 2937 | (home-page (package-home-page qtbase)) |
| 2938 | (license (package-license qtbase)))) |
| 2939 | |
| 2940 | (define-public qtquickcontrols-5 |
| 2941 | (package |
| 2942 | (inherit qtsvg-5) |
| 2943 | (name "qtquickcontrols") |
| 2944 | (version "5.15.17") |
| 2945 | (source (origin |
| 2946 | (method url-fetch) |
| 2947 | (uri (qt-url name version)) |
| 2948 | (sha256 |
| 2949 | (base32 |
| 2950 | "0d22z6a1l7iv1xmzgsf7inpgi857mg1ffv327wv7q2iapg2fsiw3")))) |
| 2951 | (arguments |
| 2952 | (substitute-keyword-arguments arguments |
| 2953 | ((#:tests? _ #f) #f))) ; TODO: Enable the tests |
| 2954 | (inputs (list qtbase-5 qtdeclarative-5)) |
| 2955 | (synopsis "Qt Quick Controls and other Quick modules") |
| 2956 | (description "The QtScript module provides classes for making Qt |
| 2957 | applications scriptable. This module provides a set of extra components that |
| 2958 | can be used to build complete interfaces in Qt Quick."))) |
| 2959 | |
| 2960 | (define-public qtquickcontrols2-5 |
| 2961 | (package |
| 2962 | (inherit qtsvg-5) |
| 2963 | (name "qtquickcontrols2") |
| 2964 | (version "5.15.17") |
| 2965 | (source (origin |
| 2966 | (method url-fetch) |
| 2967 | (uri (qt-url name version)) |
| 2968 | (sha256 |
| 2969 | (base32 |
| 2970 | "0v7mwzhc42cwf12z11g9qmysqhsqcvfk4pghh9n2p2kbrz6xdnd0")))) |
| 2971 | (arguments |
| 2972 | (substitute-keyword-arguments arguments |
| 2973 | ((#:tests? _ #f) #f))) ; TODO: Enable the tests |
| 2974 | (inputs (list qtbase-5 qtdeclarative-5)) |
| 2975 | (synopsis "Qt Quick Controls 2 and other Quick 2 modules") |
| 2976 | (description "The Qt Quick Controls 2 module contains the Qt Labs Platform |
| 2977 | module that provides platform integration: native dialogs, menus and menu bars, |
| 2978 | and tray icons. It falls back to Qt Widgets when a native implementation is |
| 2979 | not available."))) |
| 2980 | |
| 2981 | (define-public qtgraphicaleffects |
| 2982 | (package |
| 2983 | (inherit qtsvg-5) |
| 2984 | (name "qtgraphicaleffects") |
| 2985 | (version "5.15.17") |
| 2986 | (source (origin |
| 2987 | (method url-fetch) |
| 2988 | (uri (qt-url name version)) |
| 2989 | (sha256 |
| 2990 | (base32 |
| 2991 | "07m25w5qm6i13ygxg0pwaqfda4b8zyhs87n366cyn3wwm96x18ma")))) |
| 2992 | (arguments |
| 2993 | (substitute-keyword-arguments arguments |
| 2994 | ((#:tests? _ #f) #f))) ; TODO: Enable the tests |
| 2995 | (inputs (list qtbase-5 qtdeclarative-5)) |
| 2996 | (synopsis "Qt Graphical Effects module") |
| 2997 | (description "The Qt Graphical Effects module provides a set of QML types |
| 2998 | for adding visually impressive and configurable effects to user interfaces. |
| 2999 | Effects are visual items that can be added to Qt Quick user interface as UI |
| 3000 | components. The API consists of over 20 effects provided as separate QML |
| 3001 | types. The effects cover functional areas such as blending, masking, blurring, |
| 3002 | coloring, and many more."))) |
| 3003 | |
| 3004 | (define-public qtgamepad-5 |
| 3005 | (package |
| 3006 | (inherit qtsvg-5) |
| 3007 | (name "qtgamepad") |
| 3008 | (version "5.15.17") |
| 3009 | (source (origin |
| 3010 | (method url-fetch) |
| 3011 | (uri (qt-url name version)) |
| 3012 | (sha256 |
| 3013 | (base32 |
| 3014 | "1d05pl7391vp3s7h52aihka2aildzn3ifnmmvsrhn0g2689q6l95")))) |
| 3015 | (native-inputs (list perl pkg-config)) |
| 3016 | (inputs |
| 3017 | (list fontconfig |
| 3018 | freetype |
| 3019 | libxrender |
| 3020 | sdl2 |
| 3021 | qtbase-5 |
| 3022 | qtdeclarative-5)) |
| 3023 | (synopsis "Qt Gamepad module") |
| 3024 | (description "The Qt Gamepad module is an add-on library that enables Qt |
| 3025 | applications to support the use of gamepad hardware and in some cases remote |
| 3026 | control equipment. The module provides both QML and C++ interfaces. The |
| 3027 | primary target audience are embedded devices with fullscreen user interfaces, |
| 3028 | and mobile applications targeting TV-like form factors."))) |
| 3029 | |
| 3030 | (define-public qtscxml |
| 3031 | (package |
| 3032 | (name "qtscxml") |
| 3033 | (version "6.9.2") |
| 3034 | (source (origin |
| 3035 | (method url-fetch) |
| 3036 | (uri (qt-url name version)) |
| 3037 | (sha256 |
| 3038 | (base32 |
| 3039 | "1dpb687zbw4akx42kfpbb5cpdlq3hcqn8l3l0x7sd5i9061z2sp0")) |
| 3040 | (modules '((guix build utils))) |
| 3041 | (snippet |
| 3042 | '(delete-file-recursively "tests/3rdparty")))) |
| 3043 | (build-system cmake-build-system) |
| 3044 | (arguments |
| 3045 | (list |
| 3046 | ;; tst_scion fails with "Test data requested, but no testdata |
| 3047 | ;; available", while tst_qstatemachine has multiple unexplained failures |
| 3048 | ;; (see: https://bugreports.qt.io/browse/QTBUG-139847). |
| 3049 | #:test-exclude "(tst_scion|tst_qstatemachine)" |
| 3050 | #:phases |
| 3051 | #~(modify-phases %standard-phases |
| 3052 | (delete 'check) ;move after the install phase |
| 3053 | (add-after 'install 'check |
| 3054 | (assoc-ref %standard-phases 'check)) |
| 3055 | (add-before 'check 'check-setup |
| 3056 | (lambda _ |
| 3057 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 3058 | (setenv "QML_IMPORT_PATH" |
| 3059 | (string-append #$output "/lib/qt6/qml:" |
| 3060 | (getenv "QML_IMPORT_PATH")))))))) |
| 3061 | (inputs (list qtbase qtdeclarative libxkbcommon)) |
| 3062 | (synopsis "Qt SCXML module") |
| 3063 | (description "The Qt SCXML module provides functionality to create state |
| 3064 | machines from SCXML files. This includes both dynamically creating state |
| 3065 | machines (loading the SCXML file and instantiating states and transitions) and |
| 3066 | generating a C++ file that has a class implementing the state machine. It |
| 3067 | also contains functionality to support data models and executable content.") |
| 3068 | (home-page (package-home-page qtbase)) |
| 3069 | (license (package-license qtbase)))) |
| 3070 | |
| 3071 | (define-public qtpositioning |
| 3072 | (package |
| 3073 | (name "qtpositioning") |
| 3074 | (version "6.9.2") |
| 3075 | (source (origin |
| 3076 | (method url-fetch) |
| 3077 | (uri (qt-url name version)) |
| 3078 | (sha256 |
| 3079 | (base32 |
| 3080 | "06mwzlyprwz11ks6fsvzh03ilk5fxy3scr1gqqb4p85xzw0ri6j8")))) |
| 3081 | (build-system cmake-build-system) |
| 3082 | (arguments |
| 3083 | (list |
| 3084 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 3085 | #:phases #~(modify-phases %standard-phases |
| 3086 | (add-after 'install 'delete-installed-tests |
| 3087 | (lambda _ |
| 3088 | (delete-file-recursively |
| 3089 | (string-append #$output "/tests")))) |
| 3090 | (delete 'check) ;move after the install phase |
| 3091 | (add-after 'install 'check |
| 3092 | (assoc-ref %standard-phases 'check)) |
| 3093 | (add-before 'check 'check-setup |
| 3094 | (lambda _ |
| 3095 | (setenv "QML_IMPORT_PATH" |
| 3096 | (string-append #$output "/lib/qt6/qml:" |
| 3097 | (getenv "QML_IMPORT_PATH"))) |
| 3098 | ;; Make Qt render "offscreen", required for tests. |
| 3099 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 3100 | (inputs (list perl qtbase qtdeclarative qtserialport libxkbcommon)) |
| 3101 | (home-page (package-home-page qtbase)) |
| 3102 | (synopsis "QML and C++ positioning information API") |
| 3103 | (description "The Qt Positioning API provides positioning information via |
| 3104 | QML and C++ interfaces. The Qt Positioning API lets you to determine a |
| 3105 | position by using a variety of possible sources, including satellite, wifi, or |
| 3106 | text files. That information can then be used to, for example, determine a |
| 3107 | position on a map. In addition, you can use to the API to retrieve satellite |
| 3108 | information and perform area based monitoring.") |
| 3109 | (license (package-license qtbase)))) |
| 3110 | |
| 3111 | (define-public qtcharts-5 |
| 3112 | (package |
| 3113 | (inherit qtsvg-5) |
| 3114 | (name "qtcharts") |
| 3115 | (version "5.15.17") |
| 3116 | (source (origin |
| 3117 | (method url-fetch) |
| 3118 | (uri (qt-url name version)) |
| 3119 | (sha256 |
| 3120 | (base32 |
| 3121 | "0csimm84df9f70irp8di8r208jpiv6hhfbxdi4sxh9935ygpqgc4")))) |
| 3122 | (arguments |
| 3123 | (substitute-keyword-arguments arguments |
| 3124 | ((#:phases phases) |
| 3125 | #~(modify-phases #$phases |
| 3126 | (add-after 'unpack 'remove-failing-test |
| 3127 | (lambda _ |
| 3128 | (substitute* "tests/auto/auto.pro" |
| 3129 | (("qml") "# qml") |
| 3130 | (("qml-qtquicktest") "# qml-qtquicktest")))))))) |
| 3131 | (inputs (list qtbase-5 qtdeclarative-5)) |
| 3132 | (synopsis "Qt Charts module") |
| 3133 | (description "The Qt Charts module provides a set of easy to use chart |
| 3134 | components. It uses the Qt Graphics View Framework, therefore charts can be |
| 3135 | easily integrated to modern user interfaces. Qt Charts can be used as |
| 3136 | QWidgets, QGraphicsWidget, or QML types. Users can easily create impressive |
| 3137 | graphs by selecting one of the charts themes.") |
| 3138 | (license license:gpl3))) |
| 3139 | |
| 3140 | (define-public qtcharts |
| 3141 | (package |
| 3142 | (name "qtcharts") |
| 3143 | (version "6.9.2") |
| 3144 | (source (origin |
| 3145 | (method url-fetch) |
| 3146 | (uri (qt-url name version)) |
| 3147 | (sha256 |
| 3148 | (base32 |
| 3149 | "0jzzlh0jq5fidgs9r4aqpilyj0nan30r1d0pigp1hgz7cigz20cz")))) |
| 3150 | (build-system cmake-build-system) |
| 3151 | (arguments |
| 3152 | (list |
| 3153 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 3154 | #:phases |
| 3155 | #~(modify-phases %standard-phases |
| 3156 | (add-before 'check 'set-display |
| 3157 | (lambda _ |
| 3158 | ;; Make Qt render "offscreen", required for tests. |
| 3159 | (setenv "QT_QPA_PLATFORM" "offscreen"))) |
| 3160 | (add-after 'install 'delete-installed-tests |
| 3161 | (lambda _ |
| 3162 | (delete-file-recursively (string-append #$output "/tests")))) |
| 3163 | (delete 'check) ;; move after the install phase |
| 3164 | (add-after 'install 'check |
| 3165 | (assoc-ref %standard-phases 'check)) |
| 3166 | (add-before 'check 'set-QML_IMPORT_PATH |
| 3167 | (lambda _ |
| 3168 | (setenv |
| 3169 | "QML_IMPORT_PATH" |
| 3170 | (string-append #$output "/lib/qt6/qml:" |
| 3171 | (getenv "QML_IMPORT_PATH")))))))) |
| 3172 | (native-inputs |
| 3173 | (list perl pkg-config qtdeclarative)) |
| 3174 | (inputs (list qtbase qtdeclarative)) |
| 3175 | (synopsis "Qt Charts module") |
| 3176 | (description "The Qt Charts module provides a set of easy to use chart |
| 3177 | components. It uses the Qt Graphics View Framework, therefore charts can be |
| 3178 | easily integrated to modern user interfaces. Qt Charts can be used as |
| 3179 | QWidgets, QGraphicsWidget, or QML types. Users can easily create impressive |
| 3180 | graphs by selecting one of the charts themes.") |
| 3181 | (home-page (package-home-page qtbase)) |
| 3182 | (license (package-license qtbase)))) |
| 3183 | |
| 3184 | (define-public qtgraphs |
| 3185 | (package |
| 3186 | (name "qtgraphs") |
| 3187 | (version "6.9.2") |
| 3188 | (source (origin |
| 3189 | (method url-fetch) |
| 3190 | (uri (qt-url name version)) |
| 3191 | (sha256 |
| 3192 | (base32 |
| 3193 | "0wsa4iar52dhiilyl053j7lmsw3xdn47b0pjrylb5a0ij1izp057")))) |
| 3194 | (build-system cmake-build-system) |
| 3195 | (arguments |
| 3196 | (list #:configure-flags |
| 3197 | #~(list "-DQT_BUILD_TESTS=ON") |
| 3198 | #:phases |
| 3199 | #~(modify-phases %standard-phases |
| 3200 | (add-before 'check 'set-display |
| 3201 | (lambda _ |
| 3202 | ;; Make Qt render "offscreen", required for tests. |
| 3203 | (setenv "QT_QPA_PLATFORM" "offscreen"))) |
| 3204 | (add-after 'install 'delete-installed-tests |
| 3205 | (lambda _ |
| 3206 | (delete-file-recursively (string-append #$output |
| 3207 | "/tests")))) |
| 3208 | (delete 'check) ;; move after the install phase |
| 3209 | (add-after 'install 'check |
| 3210 | (assoc-ref %standard-phases 'check)) |
| 3211 | (add-before 'check 'set-QML_IMPORT_PATH |
| 3212 | (lambda _ |
| 3213 | (setenv |
| 3214 | "QML_IMPORT_PATH" |
| 3215 | (string-append #$output "/lib/qt6/qml:" |
| 3216 | (getenv "QML_IMPORT_PATH")))))))) |
| 3217 | (inputs (list qtbase qtdeclarative qtquick3d qtshadertools)) |
| 3218 | (synopsis "Qt Graphs module") |
| 3219 | (description "The Qt Graphs module enables you to visualize data in 2D and |
| 3220 | 3D graphs.") |
| 3221 | (home-page (package-home-page qtbase)) |
| 3222 | (license (package-license qtbase)))) |
| 3223 | |
| 3224 | (define-public qtnetworkauth |
| 3225 | (package |
| 3226 | (name "qtnetworkauth") |
| 3227 | (version "6.9.2") |
| 3228 | (source (origin |
| 3229 | (method url-fetch) |
| 3230 | (uri (qt-url name version)) |
| 3231 | (sha256 |
| 3232 | (base32 |
| 3233 | "114c65gyg56v70byyl3if1q7mzhp5kkv1g8sp4y9zaxqirbdjr91")))) |
| 3234 | (build-system cmake-build-system) |
| 3235 | (arguments |
| 3236 | (list #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 3237 | #:phases |
| 3238 | #~(modify-phases %standard-phases |
| 3239 | (add-before 'check 'check-setup |
| 3240 | (lambda _ |
| 3241 | (setenv "QT_QPA_PLATFORM" "offscreen")))))) |
| 3242 | (native-inputs (list perl)) |
| 3243 | (inputs (list qtbase)) |
| 3244 | (home-page (package-home-page qtbase)) |
| 3245 | (synopsis "Qt Network Authorization module") |
| 3246 | (description "The Qt Network Authorization module provides an |
| 3247 | implementation of OAuth and OAuth2 authenticathon methods for Qt.") |
| 3248 | (license (package-license qtbase)))) |
| 3249 | |
| 3250 | (define-public qtremoteobjects |
| 3251 | (package |
| 3252 | (name "qtremoteobjects") |
| 3253 | (version "6.9.2") |
| 3254 | (source (origin |
| 3255 | (method url-fetch) |
| 3256 | (uri (qt-url name version)) |
| 3257 | (sha256 |
| 3258 | (base32 |
| 3259 | "09lby6dqc2sfig1krcszg6fkypgxlz2r7hgjjfi95g7g9gqlwqnz")))) |
| 3260 | (build-system cmake-build-system) |
| 3261 | (arguments |
| 3262 | (list |
| 3263 | #:test-exclude (format |
| 3264 | #f "(~{~a~^|~})" |
| 3265 | ;; This test fails with "invalid index", but could |
| 3266 | ;; pass in `guix shell --container'. |
| 3267 | '("tst_modelview" |
| 3268 | ;; This test fails in Guix and is known to be flaky |
| 3269 | ;; (see: |
| 3270 | ;; https://bugreports.qt.io/browse/QTBUG-105895). |
| 3271 | "tst_external_IODevice")) |
| 3272 | #:phases |
| 3273 | #~(modify-phases %standard-phases |
| 3274 | (add-before 'check 'prepare-for-tests |
| 3275 | (lambda _ |
| 3276 | ;; Make Qt render "offscreen", required for tests. |
| 3277 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 3278 | (setenv "QML_IMPORT_PATH" |
| 3279 | (string-append #$output "/lib/qt6/qml:" |
| 3280 | (getenv "QML_IMPORT_PATH"))))) |
| 3281 | (delete 'check) ;move after the install phase |
| 3282 | (add-after 'install 'check |
| 3283 | (assoc-ref %standard-phases 'check))))) |
| 3284 | (native-inputs (list perl vulkan-headers)) |
| 3285 | (inputs (list libxkbcommon qtbase qtdeclarative)) |
| 3286 | (synopsis "Qt Remote Objects module") |
| 3287 | (description "The Qt Remote Objects module is an @dfn{inter-process |
| 3288 | communication} (IPC) module developed for Qt. The idea is to extend existing |
| 3289 | Qt's functionalities to enable an easy exchange of information between |
| 3290 | processes or computers.") |
| 3291 | (home-page (package-home-page qtbase)) |
| 3292 | (license (package-license qtbase)))) |
| 3293 | |
| 3294 | (define-public qtspeech-5 |
| 3295 | (package |
| 3296 | (inherit qtsvg-5) |
| 3297 | (name "qtspeech") |
| 3298 | (version "5.15.17") |
| 3299 | (source (origin |
| 3300 | (method url-fetch) |
| 3301 | (uri (qt-url name version)) |
| 3302 | (sha256 |
| 3303 | (base32 |
| 3304 | "11s5nhcj7ns7fwwmpmfv8i45b5h3xmjlq8rhm6qk11plvwi44dss")))) |
| 3305 | (arguments |
| 3306 | (substitute-keyword-arguments arguments |
| 3307 | ((#:tests? _ #f) #f))) ; TODO: Enable the tests |
| 3308 | (inputs (list qtbase-5)) |
| 3309 | (native-inputs (list perl qtdeclarative-5 qtmultimedia-5 qtxmlpatterns-5)) |
| 3310 | (synopsis "Qt Speech module") |
| 3311 | (description "The Qt Speech module enables a Qt application to support |
| 3312 | accessibility features such as text-to-speech, which is useful for end-users |
| 3313 | who are visually challenged or cannot access the application for whatever |
| 3314 | reason. The most common use case where text-to-speech comes in handy is when |
| 3315 | the end-user is driving and cannot attend the incoming messages on the phone. |
| 3316 | In such a scenario, the messaging application can read out the incoming |
| 3317 | message."))) |
| 3318 | |
| 3319 | (define-public qtspeech |
| 3320 | (package |
| 3321 | (name "qtspeech") |
| 3322 | (version "6.9.2") |
| 3323 | (source (origin |
| 3324 | (method url-fetch) |
| 3325 | (uri (qt-url name version)) |
| 3326 | (sha256 |
| 3327 | (base32 |
| 3328 | "1cc8l2h1frlraay0m40r5a91nsc7b53n6vksa52pwqqia4vngdmj")))) |
| 3329 | (build-system cmake-build-system) |
| 3330 | (arguments |
| 3331 | (list #:phases |
| 3332 | #~(modify-phases %standard-phases |
| 3333 | (delete 'check) ;move after the install phase |
| 3334 | (add-after 'install 'check |
| 3335 | (assoc-ref %standard-phases 'check)) |
| 3336 | (add-before 'check 'set-display |
| 3337 | (lambda _ |
| 3338 | ;; Make Qt render "offscreen", required for tests. |
| 3339 | (setenv "QT_QPA_PLATFORM" "offscreen"))) |
| 3340 | (add-before 'check 'prepare-for-tests |
| 3341 | (lambda* (#:key outputs #:allow-other-keys) |
| 3342 | (setenv "QML_IMPORT_PATH" |
| 3343 | (string-append (assoc-ref outputs "out") |
| 3344 | "/lib/qt6/qml:" |
| 3345 | (getenv "QML_IMPORT_PATH"))))) |
| 3346 | (add-after 'install 'delete-installed-tests |
| 3347 | (lambda _ |
| 3348 | (delete-file-recursively |
| 3349 | (string-append #$output "/tests"))))))) |
| 3350 | (propagated-inputs (list qtmultimedia)) |
| 3351 | (inputs (list qtbase qtdeclarative)) |
| 3352 | (synopsis "Qt Speech module") |
| 3353 | (description "The Qt Speech module enables a Qt application to support |
| 3354 | accessibility features such as text-to-speech, which is useful for end-users |
| 3355 | who are visually challenged or cannot access the application for whatever |
| 3356 | reason. The most common use case where text-to-speech comes in handy is when |
| 3357 | the end-user is driving and cannot attend the incoming messages on the phone. |
| 3358 | In such a scenario, the messaging application can read out the incoming |
| 3359 | message.") |
| 3360 | (home-page (package-home-page qtbase)) |
| 3361 | (license (package-license qtbase)))) |
| 3362 | |
| 3363 | (define-public qtvirtualkeyboard |
| 3364 | (package |
| 3365 | (name "qtvirtualkeyboard") |
| 3366 | (version "6.9.2") |
| 3367 | (source (origin |
| 3368 | (method url-fetch) |
| 3369 | (uri (qt-url name version)) |
| 3370 | (sha256 |
| 3371 | (base32 |
| 3372 | "1qqizh7kyqbqqnrm1mmlf2709rm1rnflbqdl1bi75yms07d00hbv")))) |
| 3373 | (build-system cmake-build-system) |
| 3374 | (arguments |
| 3375 | (list |
| 3376 | #:configure-flags #~(list "-DQT_BUILD_TESTS=ON") |
| 3377 | #:phases |
| 3378 | #~(modify-phases %standard-phases |
| 3379 | (add-before 'check 'check-setup |
| 3380 | (lambda _ |
| 3381 | (setenv "QML_IMPORT_PATH" |
| 3382 | (string-append #$output "/lib/qt6/qml:" |
| 3383 | (getenv "QML_IMPORT_PATH"))) |
| 3384 | (setenv "HOME" (getcwd)) |
| 3385 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 3386 | (setenv "DISPLAY" ":1") |
| 3387 | (system "Xvfb +extension GLX :1 &"))) |
| 3388 | (delete 'check) ;move after the install phase |
| 3389 | (add-after 'install 'check |
| 3390 | (assoc-ref %standard-phases 'check)) |
| 3391 | (add-after 'install 'delete-installed-tests |
| 3392 | (lambda _ |
| 3393 | (delete-file-recursively (string-append #$output "/tests"))))))) |
| 3394 | (native-inputs (list perl xorg-server-for-tests)) |
| 3395 | (inputs (list qtbase)) |
| 3396 | (propagated-inputs (list qtdeclarative qtmultimedia qtsvg)) |
| 3397 | (synopsis "QtQuick virtual keyboard") |
| 3398 | (description "The Qt Virtual Keyboard module provides a virtual keyboard |
| 3399 | framework that consists of a C++ backend supporting custom input methods as well |
| 3400 | as a UI frontend implemented in QML.") |
| 3401 | (home-page (package-home-page qtbase)) |
| 3402 | (license (package-license qtbase)))) |
| 3403 | |
| 3404 | (define-public qtspell |
| 3405 | (package |
| 3406 | (name "qtspell") |
| 3407 | (version "1.0.2") |
| 3408 | (source |
| 3409 | (origin |
| 3410 | (method git-fetch) |
| 3411 | (uri (git-reference |
| 3412 | (url "https://github.com/manisandro/qtspell") |
| 3413 | (commit version))) |
| 3414 | (file-name (git-file-name name version)) |
| 3415 | (sha256 |
| 3416 | (base32 "19ivs1pq9mmas731nx77lg63l0cn6c8g61s7a728s9hpxmihdq9s")))) |
| 3417 | (build-system cmake-build-system) |
| 3418 | (arguments |
| 3419 | `(#:configure-flags (list "-DQT_VER=6") |
| 3420 | #:tests? #f)) ;no test |
| 3421 | (native-inputs |
| 3422 | (list pkg-config qttools)) |
| 3423 | (inputs |
| 3424 | (list enchant qtbase)) |
| 3425 | (home-page "https://github.com/manisandro/qtspell") |
| 3426 | (synopsis "Spell checking for Qt text widgets") |
| 3427 | (description |
| 3428 | "QtSpell adds spell-checking functionality to Qt's text widgets, |
| 3429 | using the Enchant spell-checking library.") |
| 3430 | ;; COPYING file specify GPL3, but source code files all refer to GPL2+. |
| 3431 | (license license:gpl2+))) |
| 3432 | |
| 3433 | (define remove-third-party-files |
| 3434 | ;; Unlike a simpler option like `delete-all-but', this preserves the various |
| 3435 | ;; .gn, .gyp, etc. build files, which must be there even when the a bundled |
| 3436 | ;; library is not used. |
| 3437 | #~(begin |
| 3438 | (define preserved-club |
| 3439 | ;; Prefix exceptions with ./ for comparison with ftw. |
| 3440 | (map (cut string-append "./" <>) |
| 3441 | preserved-third-party-files)) |
| 3442 | (define protected (make-regexp "\\.(gn|gyp)i?$")) |
| 3443 | (define (empty? dir) |
| 3444 | (equal? (scandir dir) '("." ".."))) |
| 3445 | (define (third-party? file) |
| 3446 | (string-contains file "/third_party/")) |
| 3447 | (define (useless? file) |
| 3448 | (any (cute string-suffix? <> file) |
| 3449 | '(".zip" ".so" ".dll" ".exe" ".jar"))) |
| 3450 | (define (parents child) |
| 3451 | ;; Return all parent directories of CHILD up to and including |
| 3452 | ;; the closest "third_party". |
| 3453 | (let loop ((parent (dirname child)) |
| 3454 | (parents '())) |
| 3455 | (if (string=? "third_party" (basename parent)) |
| 3456 | (cons parent parents) |
| 3457 | (loop (dirname parent) |
| 3458 | (cons parent parents))))) |
| 3459 | (define (remove-loudly file) |
| 3460 | (format #t "deleting ~a...~%" file) |
| 3461 | (force-output) |
| 3462 | (delete-file file)) |
| 3463 | (define (delete-unwanted-files child stat flag base level) |
| 3464 | (match flag |
| 3465 | ((or 'regular 'symlink 'stale-symlink) |
| 3466 | (when (third-party? child) |
| 3467 | (unless (or (member child preserved-club) |
| 3468 | (any (cute member <> preserved-club) |
| 3469 | (parents child)) |
| 3470 | (regexp-exec protected child)) |
| 3471 | (remove-loudly child))) |
| 3472 | (when (and (useless? child) (file-exists? child)) |
| 3473 | (remove-loudly child)) |
| 3474 | #t) |
| 3475 | ('directory-processed |
| 3476 | (when (empty? child) |
| 3477 | (rmdir child)) |
| 3478 | #t) |
| 3479 | (_ #t))) |
| 3480 | |
| 3481 | (nftw "." delete-unwanted-files 'depth 'physical) |
| 3482 | |
| 3483 | ;; Assert that each preserved item is present to catch |
| 3484 | ;; removals. |
| 3485 | (for-each (lambda (third-party) |
| 3486 | (unless (file-exists? third-party) |
| 3487 | (error (format #f "~s does not exist!~%" |
| 3488 | third-party)))) |
| 3489 | preserved-club))) |
| 3490 | |
| 3491 | (define-public qtwebengine-5 |
| 3492 | (package |
| 3493 | (inherit qtsvg-5) |
| 3494 | (name "qtwebengine") |
| 3495 | (version "5.15.17") |
| 3496 | (source |
| 3497 | (origin |
| 3498 | (method url-fetch) |
| 3499 | (uri (qt-url name version)) |
| 3500 | (sha256 |
| 3501 | (base32 |
| 3502 | "11hir1dwsfy96jxmsmadcr46m034dpjlnpqw60nqk6wk0qscxvg8")) |
| 3503 | (patches (search-patches "qtwebengine5-python312-six-compat.patch")) |
| 3504 | (modules '((ice-9 ftw) |
| 3505 | (ice-9 match) |
| 3506 | (srfi srfi-1) |
| 3507 | (srfi srfi-26) |
| 3508 | (guix build utils))) |
| 3509 | (snippet |
| 3510 | #~(begin |
| 3511 | (let ((preserved-third-party-files |
| 3512 | '("base/third_party/double_conversion" |
| 3513 | "base/third_party/cityhash" |
| 3514 | "base/third_party/cityhash_v103" |
| 3515 | "base/third_party/dynamic_annotations" |
| 3516 | "base/third_party/icu" |
| 3517 | "base/third_party/libevent" |
| 3518 | "base/third_party/nspr" |
| 3519 | "base/third_party/superfasthash" |
| 3520 | "base/third_party/symbolize" |
| 3521 | "base/third_party/xdg_mime" |
| 3522 | "base/third_party/xdg_user_dirs" |
| 3523 | "net/third_party/mozilla_security_manager" |
| 3524 | "net/third_party/nss" |
| 3525 | "net/third_party/quiche" |
| 3526 | "net/third_party/uri_template" |
| 3527 | "third_party/abseil-cpp" |
| 3528 | "third_party/angle" |
| 3529 | "third_party/angle/src/common/third_party/base" |
| 3530 | "third_party/angle/src/common/third_party/smhasher" |
| 3531 | "third_party/angle/src/common/third_party/xxhash" |
| 3532 | "third_party/angle/src/third_party/compiler" |
| 3533 | "third_party/axe-core" |
| 3534 | "third_party/blink" |
| 3535 | "third_party/boringssl" |
| 3536 | "third_party/boringssl/src/third_party/fiat" |
| 3537 | "third_party/breakpad" |
| 3538 | "third_party/brotli" |
| 3539 | "third_party/catapult/common/py_vulcanize/py_vulcanize" |
| 3540 | "third_party/catapult/common/py_vulcanize/third_party" |
| 3541 | "third_party/catapult/third_party/beautifulsoup4" |
| 3542 | "third_party/catapult/third_party/html5lib-python" |
| 3543 | "third_party/catapult/third_party/polymer/components" |
| 3544 | "third_party/catapult/tracing" |
| 3545 | "third_party/catapult/tracing/third_party" |
| 3546 | "third_party/ced" |
| 3547 | "third_party/cld_3" |
| 3548 | "third_party/closure_compiler" |
| 3549 | "third_party/crashpad" |
| 3550 | "third_party/crashpad/crashpad/third_party/lss" |
| 3551 | "third_party/crashpad/crashpad/third_party/zlib" |
| 3552 | "third_party/crc32c" |
| 3553 | "third_party/dav1d" |
| 3554 | "third_party/dawn" |
| 3555 | "third_party/devtools-frontend" |
| 3556 | "third_party/devtools-frontend/src/front_end/third_party" |
| 3557 | "third_party/devtools-frontend/src/third_party/typescript" |
| 3558 | "third_party/emoji-segmenter" |
| 3559 | "third_party/ffmpeg" |
| 3560 | "third_party/googletest" |
| 3561 | "third_party/harfbuzz-ng/utils" |
| 3562 | "third_party/hunspell" |
| 3563 | "third_party/iccjpeg" |
| 3564 | "third_party/icu" |
| 3565 | "third_party/inspector_protocol" |
| 3566 | "third_party/jinja2" |
| 3567 | "third_party/jsoncpp" |
| 3568 | "third_party/jstemplate" |
| 3569 | "third_party/khronos" |
| 3570 | "third_party/leveldatabase" |
| 3571 | "third_party/libaddressinput" |
| 3572 | "third_party/libavif" |
| 3573 | "third_party/libgifcodec" |
| 3574 | "third_party/libjingle_xmpp" |
| 3575 | "third_party/libjpeg_turbo" |
| 3576 | "third_party/libpng" |
| 3577 | "third_party/libsrtp" |
| 3578 | "third_party/libsync" |
| 3579 | "third_party/libudev" |
| 3580 | "third_party/libvpx" |
| 3581 | "third_party/libwebm" |
| 3582 | "third_party/libwebp" |
| 3583 | "third_party/libxml" |
| 3584 | "third_party/libxslt" |
| 3585 | "third_party/libyuv" |
| 3586 | "third_party/lottie" |
| 3587 | "third_party/lss" |
| 3588 | "third_party/mako" |
| 3589 | "third_party/markupsafe" |
| 3590 | "third_party/mesa_headers" |
| 3591 | "third_party/metrics_proto" |
| 3592 | "third_party/modp_b64" |
| 3593 | "third_party/nasm" |
| 3594 | "third_party/node" |
| 3595 | "third_party/one_euro_filter" |
| 3596 | "third_party/openh264" |
| 3597 | "third_party/opus" |
| 3598 | "third_party/ots" |
| 3599 | "third_party/pdfium" |
| 3600 | "third_party/pdfium/third_party/agg23" |
| 3601 | "third_party/pdfium/third_party/base" |
| 3602 | "third_party/pdfium/third_party/freetype" |
| 3603 | "third_party/pdfium/third_party/lcms" |
| 3604 | "third_party/pdfium/third_party/libopenjpeg20" |
| 3605 | "third_party/pdfium/third_party/skia_shared" |
| 3606 | "third_party/perfetto" |
| 3607 | "third_party/pffft" |
| 3608 | "third_party/ply" |
| 3609 | "third_party/polymer" |
| 3610 | "third_party/protobuf" |
| 3611 | "third_party/protobuf/third_party/six" |
| 3612 | "third_party/pyjson5" |
| 3613 | "third_party/re2" |
| 3614 | "third_party/rnnoise" |
| 3615 | "third_party/skia" |
| 3616 | "third_party/skia/include/third_party/skcms/skcms.h" |
| 3617 | "third_party/skia/include/third_party/vulkan" |
| 3618 | "third_party/skia/third_party/skcms" |
| 3619 | "third_party/smhasher" |
| 3620 | "third_party/snappy" |
| 3621 | "third_party/sqlite" |
| 3622 | "third_party/usb_ids" |
| 3623 | "third_party/usrsctp" |
| 3624 | "third_party/vulkan_memory_allocator" |
| 3625 | "third_party/web-animations-js" |
| 3626 | "third_party/webrtc" |
| 3627 | "third_party/webrtc/common_audio/third_party/ooura/fft_size_128" |
| 3628 | "third_party/webrtc/common_audio/third_party/ooura/fft_size_256" |
| 3629 | "third_party/webrtc/common_audio/third_party/spl_sqrt_floor" |
| 3630 | "third_party/webrtc/modules/third_party/fft" |
| 3631 | "third_party/webrtc/modules/third_party/g711" |
| 3632 | "third_party/webrtc/modules/third_party/g722" |
| 3633 | "third_party/webrtc/rtc_base/third_party/base64" |
| 3634 | "third_party/webrtc/rtc_base/third_party/sigslot" |
| 3635 | "third_party/webrtc_overrides" |
| 3636 | "third_party/widevine/cdm/widevine_cdm_common.h" |
| 3637 | "third_party/widevine/cdm/widevine_cdm_version.h" |
| 3638 | "third_party/woff2" |
| 3639 | "third_party/xcbproto" |
| 3640 | "third_party/zlib" |
| 3641 | "url/third_party/mozilla" |
| 3642 | "v8/src/third_party/utf8-decoder" |
| 3643 | "v8/src/third_party/valgrind" |
| 3644 | "v8/src/third_party/siphash" |
| 3645 | "v8/third_party/v8/builtins" |
| 3646 | "v8/third_party/inspector_protocol"))) |
| 3647 | |
| 3648 | (with-directory-excursion "src/3rdparty" |
| 3649 | ;; TODO: Try removing "gn" too for future versions of qtwebengine-5. |
| 3650 | (delete-file-recursively "ninja") |
| 3651 | |
| 3652 | (with-directory-excursion "chromium" |
| 3653 | ;; Delete bundled software and binaries that were not explicitly |
| 3654 | ;; preserved above. |
| 3655 | #$remove-third-party-files |
| 3656 | |
| 3657 | ;; For compatibility with python-3.12 remove 'import imp'. |
| 3658 | ;; This can be removed with [email protected]. |
| 3659 | (substitute* '("mojo/public/tools/mojom/mojom/fileutil.py" |
| 3660 | "mojo/public/tools/mojom/mojom/parse/lexer.py") |
| 3661 | (("import imp\n") "")) |
| 3662 | |
| 3663 | ;; Use relative header locations instead of hard coded ones. |
| 3664 | (substitute* |
| 3665 | "base/third_party/dynamic_annotations/dynamic_annotations.c" |
| 3666 | (("base/third_party/valgrind") "valgrind")) |
| 3667 | (substitute* '("third_party/breakpad/breakpad/src/common\ |
| 3668 | /linux/http_upload.cc" |
| 3669 | "third_party/breakpad/breakpad/src/common/\ |
| 3670 | linux/libcurl_wrapper.h") |
| 3671 | (("third_party/curl") "curl")) |
| 3672 | (substitute* |
| 3673 | '("components/viz/common/gpu/vulkan_context_provider.h" |
| 3674 | "components/viz/common/resources/resource_format_utils.h" |
| 3675 | "gpu/config/gpu_info_collector_win.cc" |
| 3676 | "gpu/config/gpu_util.cc" |
| 3677 | "gpu/config/vulkan_info.h") |
| 3678 | (("third_party/vulkan_headers/include/") |
| 3679 | "")) |
| 3680 | |
| 3681 | ;; Replace Google Analytics bundle with an empty file and hope |
| 3682 | ;; no one notices. |
| 3683 | (mkdir-p "third_party/analytics") |
| 3684 | (call-with-output-file |
| 3685 | "third_party/analytics/google-analytics-bundle.js" |
| 3686 | (lambda (port) |
| 3687 | (const #t))))) |
| 3688 | ;; Do not enable support for loading the Widevine DRM plugin. |
| 3689 | (substitute* "src/buildtools/config/common.pri" |
| 3690 | (("enable_widevine=true") |
| 3691 | "enable_widevine=false"))))))) |
| 3692 | (build-system gnu-build-system) |
| 3693 | (native-inputs |
| 3694 | (list bison |
| 3695 | flex |
| 3696 | gperf |
| 3697 | ninja |
| 3698 | node-lts |
| 3699 | perl |
| 3700 | pkg-config |
| 3701 | python-beautifulsoup4 |
| 3702 | python-six |
| 3703 | python-wrapper |
| 3704 | ruby)) |
| 3705 | (inputs |
| 3706 | (list alsa-lib |
| 3707 | at-spi2-core |
| 3708 | cups-minimal |
| 3709 | curl |
| 3710 | dbus |
| 3711 | ffmpeg-4 |
| 3712 | fontconfig |
| 3713 | harfbuzz |
| 3714 | icu4c |
| 3715 | jsoncpp |
| 3716 | lcms |
| 3717 | libcap |
| 3718 | libevent |
| 3719 | libgcrypt |
| 3720 | libjpeg-turbo |
| 3721 | libvpx |
| 3722 | libwebp |
| 3723 | libx11 |
| 3724 | libxcb |
| 3725 | libxcomposite |
| 3726 | libxcursor |
| 3727 | libxkbfile |
| 3728 | libxi |
| 3729 | libxkbcommon |
| 3730 | ;; FIXME: libxml2 needs to built with icu support though it links to |
| 3731 | ;; libxml2 configure summary still states "Checking for compatible |
| 3732 | ;; system libxml2... no" |
| 3733 | libxml2 |
| 3734 | openh264 |
| 3735 | libxrandr |
| 3736 | libxrender |
| 3737 | libxslt |
| 3738 | libxtst |
| 3739 | mesa |
| 3740 | minizip |
| 3741 | nss |
| 3742 | opus |
| 3743 | pciutils |
| 3744 | protobuf |
| 3745 | pulseaudio |
| 3746 | qtmultimedia-5 |
| 3747 | re2 |
| 3748 | snappy |
| 3749 | eudev |
| 3750 | valgrind/pinned |
| 3751 | vulkan-headers |
| 3752 | xcb-util)) |
| 3753 | (propagated-inputs |
| 3754 | ;; Required by Qt5WebEngineCoreConfig.cmake. |
| 3755 | (list qtbase-5 qtdeclarative-5 qtwebchannel-5)) |
| 3756 | (arguments |
| 3757 | (substitute-keyword-arguments arguments |
| 3758 | ((#:modules modules '()) |
| 3759 | `((guix build gnu-build-system) |
| 3760 | (guix build utils) |
| 3761 | (ice-9 textual-ports))) |
| 3762 | ((#:phases phases) |
| 3763 | #~(modify-phases #$phases |
| 3764 | (add-before 'configure 'substitute-source |
| 3765 | (lambda* (#:key inputs #:allow-other-keys) |
| 3766 | (with-atomic-file-replacement |
| 3767 | "src/buildtools/config/linux.pri" |
| 3768 | (lambda (in out) |
| 3769 | (display (get-string-all in) out) |
| 3770 | (display "\ngn_args += use_system_openh264=true\n" out) |
| 3771 | (display "\ngn_args += link_pulseaudio = true\n" out))) |
| 3772 | ;; Qtwebengine is not installed into the same prefix as |
| 3773 | ;; qtbase. Some qtbase QTLibraryInfo constants will not |
| 3774 | ;; work. Replace with the full path to the qtwebengine-5 |
| 3775 | ;; translations and locales in the store. |
| 3776 | (substitute* "src/core/web_engine_library_info.cpp" |
| 3777 | (("QLibraryInfo::location\\(QLibraryInfo::TranslationsPath\\)") |
| 3778 | (string-append "QLatin1String(\"" #$output |
| 3779 | "/share/qt5/translations\")")) |
| 3780 | (("QLibraryInfo::location\\(QLibraryInfo::DataPath\\)") |
| 3781 | (string-append "QLatin1String(\"" #$output |
| 3782 | "/share/qt5\")")) |
| 3783 | (("QLibraryInfo::location\\(QLibraryInfo::LibraryExecutablesPath)") |
| 3784 | (string-append "QLatin1String(\"" #$output |
| 3785 | "/lib/qt5/libexec\")"))) |
| 3786 | ;; Substitute full dynamic library path for nss. |
| 3787 | (substitute* "src/3rdparty/chromium/crypto/nss_util.cc" |
| 3788 | (("libnssckbi.so") |
| 3789 | (search-input-file inputs "lib/nss/libnssckbi.so"))) |
| 3790 | ;; Substitute full dynamic library path for udev. |
| 3791 | (substitute* "src/3rdparty/chromium/device/udev_linux/udev1_loader.cc" |
| 3792 | (("libudev.so.1") |
| 3793 | (search-input-file inputs "lib/libudev.so.1"))))) |
| 3794 | (add-before 'configure 'set-env |
| 3795 | (lambda _ |
| 3796 | ;; Avoids potential race conditions. |
| 3797 | (setenv "PYTHONDONTWRITEBYTECODE" "1") |
| 3798 | (setenv "NINJAFLAGS" |
| 3799 | (string-append "-k1" ;less verbose build output |
| 3800 | ;; Respect the '--cores' option of 'guix build'. |
| 3801 | " -j" (number->string (parallel-job-count)))))) |
| 3802 | (replace 'configure |
| 3803 | (lambda _ |
| 3804 | ;; Valid QT_BUILD_PARTS variables are: |
| 3805 | ;; libs tools tests examples demos docs translations |
| 3806 | (invoke "qmake" |
| 3807 | #$@(if (target-x86-32?) |
| 3808 | ;; Don't exhaust memory while linking. |
| 3809 | #~("QMAKE_LFLAGS+=-Wl,--no-keep-memory -Wl,-z,now") |
| 3810 | #~()) |
| 3811 | "QT_BUILD_PARTS = libs tools" "--" |
| 3812 | "--webengine-printing-and-pdf=no" |
| 3813 | "--webengine-ffmpeg=system" |
| 3814 | ;; FIXME: Building qtwebengine-5 5.12.2 with |
| 3815 | ;; icu4c >= 68 fails. |
| 3816 | ;;"--webengine-icu=system" |
| 3817 | "--webengine-pepper-plugins=no" |
| 3818 | "-webengine-proprietary-codecs"))))) |
| 3819 | ;; Tests are disabled due to "Could not find QtWebEngineProcess error" |
| 3820 | ;; It's possible this can be fixed by setting QTWEBENGINEPROCESS_PATH |
| 3821 | ;; before running tests. |
| 3822 | ((#:tests? _ #f) #f))) |
| 3823 | (home-page "https://wiki.qt.io/QtWebEngine") |
| 3824 | (synopsis "Qt WebEngine module") |
| 3825 | (description "The Qt5WebEngine module provides support for web applications |
| 3826 | using the Chromium browser project. The Chromium source code has Google services |
| 3827 | and binaries removed, and adds modular support for using system libraries.") |
| 3828 | (license license:lgpl2.1+))) |
| 3829 | |
| 3830 | (define-public qtwebengine |
| 3831 | (package |
| 3832 | (name "qtwebengine") |
| 3833 | (version "6.9.3") |
| 3834 | (source |
| 3835 | (origin |
| 3836 | (method url-fetch) |
| 3837 | (uri (qt-url name version)) |
| 3838 | (sha256 |
| 3839 | (base32 |
| 3840 | "0rl9v936sq6spvb3sfkpmc51wwmljrn4ssy3ii0pdn0xsl8kn2ym")) |
| 3841 | (modules '((ice-9 ftw) |
| 3842 | (ice-9 match) |
| 3843 | (srfi srfi-1) |
| 3844 | (srfi srfi-26) |
| 3845 | (guix build utils))) |
| 3846 | ;; This is only needed until 6.10, where it arrived upstream. |
| 3847 | ;; https://codereview.qt-project.org/c/qt/qtwebengine/+/675112 |
| 3848 | (patches (search-patches "qtwebengine-revert-egl.patch")) |
| 3849 | (snippet |
| 3850 | #~(begin |
| 3851 | ;; Note: Anything under a 'third_party/' directory that needs to |
| 3852 | ;; be preserved must be explicitly added below, otherwise it gets |
| 3853 | ;; removed by the 'remove-third-party-files' code snippet included |
| 3854 | ;; below. It is useful to refer to the list used by |
| 3855 | ;; ungoogled-chromium when upgrading, but not all of the items |
| 3856 | ;; present in it will need to be reported here, as Qt already |
| 3857 | ;; removes components its build doesn't use. |
| 3858 | (let ((preserved-third-party-files |
| 3859 | '("base/third_party/double_conversion" |
| 3860 | "base/third_party/cityhash" |
| 3861 | "base/third_party/cityhash_v103" |
| 3862 | "base/third_party/icu" |
| 3863 | "base/third_party/nspr" |
| 3864 | "base/third_party/superfasthash" |
| 3865 | "base/third_party/symbolize" |
| 3866 | "base/third_party/xdg_user_dirs" |
| 3867 | "net/third_party/mozilla_security_manager" |
| 3868 | "net/third_party/nss" |
| 3869 | "net/third_party/quiche" |
| 3870 | "net/third_party/uri_template" |
| 3871 | "third_party/abseil-cpp" |
| 3872 | "third_party/angle" |
| 3873 | "third_party/angle/src/common/third_party/xxhash" |
| 3874 | "third_party/angle/src/third_party/libXNVCtrl" ;Expat |
| 3875 | "third_party/angle/src/third_party/volk" |
| 3876 | "third_party/angle/src/third_party/ceval" |
| 3877 | "third_party/axe-core" |
| 3878 | "third_party/blink" |
| 3879 | "third_party/bidimapper" |
| 3880 | "third_party/boringssl" |
| 3881 | "third_party/boringssl/src/third_party/fiat" |
| 3882 | "third_party/breakpad" |
| 3883 | "third_party/brotli" |
| 3884 | "third_party/catapult" |
| 3885 | "third_party/catapult/common/py_vulcanize/third_party/rcssmin" |
| 3886 | "third_party/catapult/common/py_vulcanize/third_party/rjsmin" |
| 3887 | "third_party/catapult/third_party/polymer" |
| 3888 | "third_party/catapult/tracing/third_party/d3/d3.min.js" |
| 3889 | "third_party/catapult/tracing/third_party/gl-matrix/dist/gl-matrix-min.js" |
| 3890 | "third_party/catapult/tracing/third_party/jpeg-js/jpeg-js-decoder.js" |
| 3891 | "third_party/catapult/tracing/third_party/jszip/jszip.min.js" |
| 3892 | "third_party/catapult/tracing/third_party/mannwhitneyu/mannwhitneyu.js" |
| 3893 | "third_party/catapult/tracing/third_party/oboe/dist" |
| 3894 | "third_party/catapult/tracing/third_party/pako/pako.min.js" |
| 3895 | "third_party/ced" |
| 3896 | "third_party/cld_3" |
| 3897 | "third_party/closure_compiler" |
| 3898 | "third_party/cpuinfo" ;BSD-2 |
| 3899 | "third_party/crabbyavif" ;ASL2.0 |
| 3900 | "third_party/crashpad" |
| 3901 | "third_party/crashpad/crashpad/third_party/lss" |
| 3902 | "third_party/crashpad/crashpad/third_party/zlib" |
| 3903 | "third_party/crc32c" |
| 3904 | "third_party/d3" |
| 3905 | "third_party/dav1d" |
| 3906 | "third_party/dawn" |
| 3907 | "third_party/dawn/third_party/gn/webgpu-cts" |
| 3908 | "third_party/dawn/third_party/khronos" |
| 3909 | "third_party/devtools-frontend" |
| 3910 | "third_party/devtools-frontend/src/front_end/third_party/i18n" |
| 3911 | "third_party/devtools-frontend/src/front_end/third_party/\ |
| 3912 | additional_readme_paths.json" |
| 3913 | "third_party/devtools-frontend/src/front_end/third_party/axe-core" |
| 3914 | "third_party/devtools-frontend/src/front_end/third_party/chromium" |
| 3915 | "third_party/devtools-frontend/src/front_end/third_party/codemirror" |
| 3916 | "third_party/devtools-frontend/src/front_end/third_party/codemirror.next" |
| 3917 | "third_party/devtools-frontend/src/front_end/third_party/csp_evaluator" |
| 3918 | "third_party/devtools-frontend/src/front_end/third_party/diff" |
| 3919 | "third_party/devtools-frontend/src/front_end/third_party/intl-messageformat" |
| 3920 | "third_party/devtools-frontend/src/front_end/third_party/lighthouse" |
| 3921 | "third_party/devtools-frontend/src/front_end/third_party/lit" |
| 3922 | "third_party/devtools-frontend/src/front_end/third_party/acorn" |
| 3923 | "third_party/devtools-frontend/src/front_end/third_party/marked" |
| 3924 | "third_party/devtools-frontend/src/front_end/third_party/puppeteer" |
| 3925 | "third_party/devtools-frontend/src/front_end/third_party/\ |
| 3926 | puppeteer/package/lib/esm/third_party/mitt" |
| 3927 | "third_party/devtools-frontend/src/front_end/third_party/\ |
| 3928 | puppeteer/package/lib/esm/third_party/parsel-js" ;Expat |
| 3929 | "third_party/devtools-frontend/src/front_end/third_party/\ |
| 3930 | puppeteer/package/lib/esm/third_party/rxjs" |
| 3931 | "third_party/devtools-frontend/src/front_end/third_party/\ |
| 3932 | vscode.web-custom-data" |
| 3933 | "third_party/devtools-frontend/src/front_end/third_party/puppeteer-replay" |
| 3934 | "third_party/devtools-frontend/src/third_party/pyjson5" |
| 3935 | "third_party/devtools-frontend/src/front_end/third_party/\ |
| 3936 | third-party-web" ;Expat |
| 3937 | "third_party/devtools-frontend/src/front_end/third_party/wasmparser" |
| 3938 | "third_party/devtools-frontend/src/front_end/third_party/\ |
| 3939 | web-vitals" ;ASL2.0 |
| 3940 | "third_party/devtools-frontend/src/scripts/build/typescript" |
| 3941 | "third_party/devtools-frontend/src/third_party/i18n" |
| 3942 | "third_party/distributed_point_functions" |
| 3943 | "third_party/dom_distiller_js" |
| 3944 | "third_party/emoji-segmenter" |
| 3945 | "third_party/fast_float" ;Expat (or ASL2.0 or Boost) |
| 3946 | "third_party/fdlibm" |
| 3947 | "third_party/ffmpeg/libavcodec/avcodec.h" |
| 3948 | "third_party/ffmpeg/libavcodec/packet.h" |
| 3949 | "third_party/ffmpeg/libavformat/avformat.h" |
| 3950 | "third_party/ffmpeg/libavformat/avio.h" |
| 3951 | "third_party/ffmpeg/libavutil/avutil.h" |
| 3952 | "third_party/ffmpeg/libavutil/imgutils.h" |
| 3953 | "third_party/ffmpeg/libavutil/log.h" |
| 3954 | "third_party/ffmpeg/libavutil/mathematics.h" |
| 3955 | "third_party/ffmpeg/libavutil/opt.h" |
| 3956 | "third_party/fft2d" |
| 3957 | "third_party/flatbuffers" |
| 3958 | "third_party/fp16" ;Expat |
| 3959 | "third_party/freetype" |
| 3960 | "third_party/gemmlowp" ;ASL2.0 |
| 3961 | "third_party/google_input_tools" ;ASL2.0 |
| 3962 | "third_party/googletest" |
| 3963 | "third_party/harfbuzz-ng" |
| 3964 | "third_party/highway" |
| 3965 | "third_party/hunspell" |
| 3966 | "third_party/iccjpeg" |
| 3967 | "third_party/icu" ;TODO: make pdfium use system version |
| 3968 | "third_party/inspector_protocol" |
| 3969 | "third_party/ipcz" ;BSD-3 |
| 3970 | "third_party/jinja2" |
| 3971 | "third_party/jsoncpp" |
| 3972 | "third_party/jstemplate" |
| 3973 | "third_party/khronos" |
| 3974 | "third_party/leveldatabase" |
| 3975 | "third_party/libaddressinput" |
| 3976 | "third_party/libaom" |
| 3977 | "third_party/libaom/source/libaom/third_party/fastfeat" |
| 3978 | "third_party/libaom/source/libaom/third_party/SVT-AV1" ;BSD-3 |
| 3979 | "third_party/libaom/source/libaom/third_party/vector" |
| 3980 | "third_party/libaom/source/libaom/third_party/x86inc" |
| 3981 | "third_party/libavif" |
| 3982 | "third_party/libavifinfo" |
| 3983 | "third_party/libevent" |
| 3984 | "third_party/libgav1" |
| 3985 | "third_party/libjingle_xmpp" |
| 3986 | "third_party/libjpeg_turbo" |
| 3987 | "third_party/libpng" ;TODO: make pdfium use system version |
| 3988 | "third_party/libsecret" ;LGPL2.1+ |
| 3989 | "third_party/libsrtp" |
| 3990 | "third_party/libsync" |
| 3991 | "third_party/liburlpattern" |
| 3992 | "third_party/libva_protected_content" ;Expat |
| 3993 | "third_party/libvpx" |
| 3994 | "third_party/libvpx/source/libvpx/third_party/x86inc" ;Expat |
| 3995 | "third_party/libwebm" |
| 3996 | "third_party/libwebp" |
| 3997 | "third_party/libx11" |
| 3998 | "third_party/libxcb-keysyms" |
| 3999 | "third_party/libxml" |
| 4000 | "third_party/libyuv" |
| 4001 | "third_party/libzip" ;BSD-3 |
| 4002 | "third_party/lit" |
| 4003 | "third_party/lottie" |
| 4004 | "third_party/lss" |
| 4005 | "third_party/mako" |
| 4006 | "third_party/markupsafe" |
| 4007 | "third_party/material_color_utilities" ;ASL2.0 |
| 4008 | "third_party/mesa_headers" |
| 4009 | "third_party/metrics_proto" |
| 4010 | "third_party/minigbm" ;BSD-3 |
| 4011 | "third_party/modp_b64" |
| 4012 | "third_party/nasm" |
| 4013 | "third_party/nearby" ;ASL2.0 |
| 4014 | "third_party/node" |
| 4015 | "third_party/omnibox_proto" ;BSD-3 |
| 4016 | "third_party/one_euro_filter" |
| 4017 | "third_party/openscreen" ;BSD-3 |
| 4018 | "third_party/openscreen/src/third_party/tinycbor" ;Expat |
| 4019 | "third_party/openh264" |
| 4020 | "third_party/opus/src/include/opus.h" |
| 4021 | "third_party/opus/src/include/opus_custom.h" |
| 4022 | "third_party/opus/src/include/opus_defines.h" |
| 4023 | "third_party/opus/src/include/opus_multistream.h" |
| 4024 | "third_party/opus/src/include/opus_types.h" |
| 4025 | "third_party/ots" |
| 4026 | "third_party/flac" |
| 4027 | "third_party/pdfium" |
| 4028 | "third_party/pdfium/third_party/agg23" |
| 4029 | "third_party/pdfium/third_party/bigint" |
| 4030 | "third_party/pdfium/third_party/freetype" |
| 4031 | "third_party/pdfium/third_party/lcms" |
| 4032 | "third_party/pdfium/third_party/libopenjpeg" |
| 4033 | "third_party/pdfium/third_party/libtiff" |
| 4034 | "third_party/pdfium/third_party/freetype/include/pstables.h" ;FreeType |
| 4035 | "third_party/perfetto" |
| 4036 | "third_party/perfetto/protos/third_party/chromium" |
| 4037 | "third_party/perfetto/protos/third_party/simpleperf" ;ASL2.0 |
| 4038 | "third_party/pffft" |
| 4039 | "third_party/ply" |
| 4040 | "third_party/polymer" |
| 4041 | "third_party/private_membership" ;ASL2.0 |
| 4042 | "third_party/private-join-and-compute" ;ASL2.0 |
| 4043 | "third_party/protobuf" |
| 4044 | "third_party/protobuf-javascript" ;BSD-3 |
| 4045 | "third_party/pthreadpool" ;BSD-2 |
| 4046 | "third_party/pyjson5" |
| 4047 | "third_party/qcms" ;Expat |
| 4048 | "third_party/rapidhash/rapidhash.h" ;BSD-2 |
| 4049 | "third_party/re2" |
| 4050 | "third_party/rnnoise" |
| 4051 | "third_party/ruy" ;ASL2.0 |
| 4052 | "third_party/selenium-atoms" |
| 4053 | "third_party/s2cellid" ;ASL2.0 |
| 4054 | "third_party/securemessage" ;ASL2.0 |
| 4055 | "third_party/shell-encryption" ;ASL2.0 |
| 4056 | "third_party/skia" |
| 4057 | "third_party/skia/include/third_party/vulkan" |
| 4058 | "third_party/skia/modules/skcms" |
| 4059 | "third_party/skia/third_party/vulkanmemoryallocator" |
| 4060 | "third_party/smhasher" |
| 4061 | "third_party/snappy" |
| 4062 | "third_party/speech-dispatcher" |
| 4063 | "third_party/sqlite" |
| 4064 | "third_party/swiftshader" ;ASL2.0 |
| 4065 | "third_party/swiftshader/third_party/llvm-10.0" ;ASL2.0, with LLVM exception |
| 4066 | "third_party/swiftshader/third_party/marl" ;ASL2.0 |
| 4067 | "third_party/swiftshader/third_party/SPIRV-Headers" ;X11-style |
| 4068 | "third_party/swiftshader/third_party/SPIRV-Tools" ;ASL2.0 |
| 4069 | "third_party/tensorflow-text" ;ASL2.0 |
| 4070 | "third_party/tflite" ;ASL2.0 |
| 4071 | "third_party/tflite_support" ;ASL2.0 |
| 4072 | "third_party/ukey2" ;ASL2.0 |
| 4073 | "third_party/usb_ids" |
| 4074 | "third_party/utf" ;Expat |
| 4075 | "third_party/glslang" |
| 4076 | "third_party/spirv-headers" |
| 4077 | "third_party/spirv-tools" |
| 4078 | "third_party/vulkan-headers" |
| 4079 | "third_party/vulkan-loader" |
| 4080 | "third_party/vulkan-tools" |
| 4081 | "third_party/vulkan-validation-layers" |
| 4082 | "third_party/vulkan_memory_allocator" |
| 4083 | "third_party/webgpu-cts" |
| 4084 | "third_party/webrtc" |
| 4085 | "third_party/webrtc/common_audio/third_party/ooura" |
| 4086 | "third_party/webrtc/common_audio/third_party/spl_sqrt_floor" |
| 4087 | "third_party/webrtc/modules/third_party/fft" |
| 4088 | "third_party/webrtc/modules/third_party/g711" |
| 4089 | "third_party/webrtc/modules/third_party/g722" |
| 4090 | "third_party/webrtc/rtc_base/third_party/base64" |
| 4091 | "third_party/webrtc/rtc_base/third_party/sigslot" |
| 4092 | "third_party/webrtc_overrides" |
| 4093 | "third_party/widevine/cdm/widevine_cdm_common.h" |
| 4094 | "third_party/widevine/cdm/widevine_cdm_version.h" |
| 4095 | "third_party/woff2" |
| 4096 | "third_party/wuffs" |
| 4097 | "third_party/x11proto" |
| 4098 | "third_party/xnnpack" ;BSD-3 |
| 4099 | "third_party/zstd" |
| 4100 | "third_party/zlib" ;TODO: make pdfium use system version |
| 4101 | "third_party/zxcvbn-cpp" ;Expat |
| 4102 | "url/third_party/mozilla" |
| 4103 | "v8/src/third_party/siphash" |
| 4104 | "v8/src/third_party/utf8-decoder" |
| 4105 | "v8/src/third_party/valgrind" |
| 4106 | "v8/third_party/inspector_protocol" |
| 4107 | "v8/third_party/glibc/src/sysdeps/ieee754/dbl-64" |
| 4108 | "v8/third_party/v8/builtins" |
| 4109 | "v8/third_party/v8/codegen/fp16-inl.h"))) ;Expat |
| 4110 | |
| 4111 | (with-directory-excursion "src/3rdparty" |
| 4112 | (with-directory-excursion "chromium" |
| 4113 | ;; Delete bundled software and binaries that were not |
| 4114 | ;; explicitly preserved above. |
| 4115 | #$remove-third-party-files |
| 4116 | |
| 4117 | ;; Use relative header locations instead of hard coded ones. |
| 4118 | (substitute* '("v8/BUILD.gn" |
| 4119 | "v8/src/codegen/ia32/cpu-ia32.cc" |
| 4120 | "v8/src/codegen/x64/cpu-x64.cc") |
| 4121 | ((".*\"src/third_party/valgrind/valgrind.h\",.*") |
| 4122 | "") |
| 4123 | (("#include \"src/third_party/valgrind/valgrind.h\"") |
| 4124 | "")) |
| 4125 | (substitute* "third_party/breakpad/breakpad/src/common/\ |
| 4126 | linux/libcurl_wrapper.h" |
| 4127 | (("third_party/curl") "curl")) |
| 4128 | (substitute* |
| 4129 | '("components/viz/common/gpu/vulkan_context_provider.h" |
| 4130 | "gpu/config/gpu_util.cc") |
| 4131 | (("third_party/vulkan/include/") |
| 4132 | "")) |
| 4133 | |
| 4134 | ;; Replace Google Analytics bundle with an empty file and |
| 4135 | ;; hope no one notices. |
| 4136 | (mkdir-p "third_party/analytics") |
| 4137 | (call-with-output-file |
| 4138 | "third_party/analytics/google-analytics-bundle.js" |
| 4139 | (lambda (port) |
| 4140 | (const #t))))) |
| 4141 | (substitute* "src/core/CMakeLists.txt" |
| 4142 | (("enable_widevine=true") |
| 4143 | (string-join |
| 4144 | '(;; Do not enable support for loading the Widevine DRM |
| 4145 | ;; plugin. |
| 4146 | "enable_widevine=false" |
| 4147 | ;; Link pulseaudio directly instead of using dlopen. |
| 4148 | "link_pulseaudio=true") |
| 4149 | "\n")))))))) |
| 4150 | (build-system cmake-build-system) |
| 4151 | (arguments |
| 4152 | (list |
| 4153 | ;; XXX: The test suite is not built by default; leave it off to save |
| 4154 | ;; some build time and resources. |
| 4155 | #:tests? #f |
| 4156 | #:configure-flags |
| 4157 | ;; Use the CMake ninja generator, otherwise the build fails. |
| 4158 | #~(list "-GNinja" |
| 4159 | ;; The PDF renderer plugin fails to build with errors such as |
| 4160 | ;; "src/3rdparty/chromium/components/pdf |
| 4161 | ;; /renderer/pdf_accessibility_tree.cc:1373:39: |
| 4162 | ;; error: use of undeclared identifier 'IDS_PDF_PAGE_INDEX'"; |
| 4163 | ;; disable it. |
| 4164 | "-DQT_FEATURE_webengine_printing_and_pdf=OFF" |
| 4165 | "-DQT_FEATURE_webengine_pepper_plugins=OFF" ;widevine |
| 4166 | |
| 4167 | ;; The webenginedriver feature is disabled, otherwise the RUNPATH |
| 4168 | ;; validation phase fails. |
| 4169 | "-DQT_FEATURE_webenginedriver=OFF" |
| 4170 | |
| 4171 | ;; Do not artificially limit codec support; video decoding is |
| 4172 | ;; done by ffmpeg. |
| 4173 | "-DQT_FEATURE_webengine_proprietary_codecs=ON" |
| 4174 | |
| 4175 | #$@(if (target-x86-64?) |
| 4176 | #~("-DQT_FEATURE_webengine_vaapi=ON") |
| 4177 | #~()) |
| 4178 | |
| 4179 | ;; Use system libraries where possible (see src/core/CMakeLists.txt). |
| 4180 | "-DQT_FEATURE_webengine_system_alsa=ON" |
| 4181 | "-DQT_FEATURE_webengine_system_ffmpeg=ON" |
| 4182 | "-DQT_FEATURE_webengine_system_freetype=ON" |
| 4183 | "-DQT_FEATURE_webengine_system_harfbuzz=ON" |
| 4184 | "-DQT_FEATURE_webengine_system_icu=ON" |
| 4185 | "-DQT_FEATURE_webengine_system_lcms2=ON" |
| 4186 | "-DQT_FEATURE_webengine_system_libevent=ON" |
| 4187 | "-DQT_FEATURE_webengine_system_libjpeg=ON" |
| 4188 | "-DQT_FEATURE_webengine_system_libpci=ON" |
| 4189 | "-DQT_FEATURE_webengine_system_libpng=ON" |
| 4190 | "-DQT_FEATURE_webengine_system_libtiff=ON" |
| 4191 | "-DQT_FEATURE_webengine_system_libwebp=ON" |
| 4192 | "-DQT_FEATURE_webengine_system_libxml=ON" |
| 4193 | "-DQT_FEATURE_webengine_system_minizip=ON" |
| 4194 | "-DQT_FEATURE_webengine_system_opus=ON" |
| 4195 | "-DQT_FEATURE_webengine_system_pulseaudio=ON" |
| 4196 | "-DQT_FEATURE_webengine_system_re2=ON" |
| 4197 | "-DQT_FEATURE_webengine_system_zlib=ON" |
| 4198 | "-DQT_FEATURE_webengine_system_glib=ON" |
| 4199 | "-DQT_FEATURE_webengine_system_snappy=ON") |
| 4200 | #:phases |
| 4201 | #~(modify-phases %standard-phases |
| 4202 | (add-after 'unpack 'patch-paths |
| 4203 | (lambda* (#:key inputs #:allow-other-keys) |
| 4204 | ;; Qtwebengine is not installed into the same prefix as qtbase. |
| 4205 | ;; Some qtbase QTLibraryInfo constants will not work. Replace |
| 4206 | ;; with the full path to the qtwebengine translations and |
| 4207 | ;; locales in the store. |
| 4208 | (substitute* "src/core/web_engine_library_info.cpp" |
| 4209 | (("QLibraryInfo::path\\(QLibraryInfo::TranslationsPath)") |
| 4210 | (string-append "QLatin1String(\"" #$output |
| 4211 | "/share/qt6/translations\")")) |
| 4212 | (("QLibraryInfo::path\\(QLibraryInfo::DataPath)") |
| 4213 | (string-append "QLatin1String(\"" #$output |
| 4214 | "/share/qt6\")")) |
| 4215 | (("QLibraryInfo::path\\(QLibraryInfo::LibraryExecutablesPath)") |
| 4216 | (string-append "QLatin1String(\"" #$output |
| 4217 | "/lib/qt6/libexec\")"))) |
| 4218 | ;; Substitute full dynamic library path for nss. |
| 4219 | (substitute* "src/3rdparty/chromium/crypto/nss_util.cc" |
| 4220 | (("libnssckbi.so") |
| 4221 | (search-input-file inputs "lib/nss/libnssckbi.so"))) |
| 4222 | ;; Substitute full dynamic library path for udev. |
| 4223 | (substitute* "src/3rdparty/chromium/device/udev_linux/udev1_loader.cc" |
| 4224 | (("libudev.so.1") |
| 4225 | (search-input-file inputs "lib/libudev.so.1"))) |
| 4226 | ;; Patch the location of the X11 keyboard layouts. |
| 4227 | (substitute* "src/3rdparty/chromium/ui/events/ozone/layout/xkb\ |
| 4228 | /xkb_keyboard_layout_engine.cc" |
| 4229 | (("/usr/share/X11/xkb") |
| 4230 | (search-input-directory inputs "share/X11/xkb"))))) |
| 4231 | (add-before 'configure 'prepare-build-environment |
| 4232 | (lambda _ |
| 4233 | ;; Avoids potential race conditions. |
| 4234 | (setenv "PYTHONDONTWRITEBYTECODE" "1") |
| 4235 | (setenv "NINJAFLAGS" |
| 4236 | (string-append |
| 4237 | "-k1" ;less verbose build output |
| 4238 | ;; Respect the '--cores' option of 'guix build'. |
| 4239 | " -j" (number->string (parallel-job-count)))) |
| 4240 | ;; Use Clang/LDD to help tame the memory requirements and hasten |
| 4241 | ;; the build. |
| 4242 | (setenv "AR" "llvm-ar") (setenv "NM" "llvm-nm") |
| 4243 | (setenv "CC" "clang") (setenv "CXX" "clang++"))) |
| 4244 | (replace 'build |
| 4245 | (lambda* (#:key parallel-build? #:allow-other-keys) |
| 4246 | (apply invoke "cmake" "--build" "." |
| 4247 | (if parallel-build? |
| 4248 | `("--parallel" ,(number->string (parallel-job-count))) |
| 4249 | '())))) |
| 4250 | (replace 'install |
| 4251 | (lambda _ |
| 4252 | (invoke "cmake" "--install" "."))) |
| 4253 | (add-after 'install 'delete-installed-tests |
| 4254 | (lambda _ |
| 4255 | (delete-file-recursively |
| 4256 | (string-append #$output "/tests"))))))) |
| 4257 | (native-inputs |
| 4258 | (list bison |
| 4259 | clang-20 |
| 4260 | flex |
| 4261 | gperf |
| 4262 | lld-as-ld-wrapper-18 |
| 4263 | ninja |
| 4264 | node-lts |
| 4265 | perl |
| 4266 | pkg-config |
| 4267 | python-beautifulsoup4 |
| 4268 | python-html5lib |
| 4269 | python-wrapper |
| 4270 | ruby)) |
| 4271 | (inputs |
| 4272 | (list alsa-lib |
| 4273 | at-spi2-core |
| 4274 | cups-minimal |
| 4275 | curl |
| 4276 | dbus |
| 4277 | eudev |
| 4278 | ffmpeg-6 |
| 4279 | fontconfig |
| 4280 | fxdiv |
| 4281 | harfbuzz |
| 4282 | icu4c |
| 4283 | jsoncpp |
| 4284 | lcms |
| 4285 | libcap |
| 4286 | libevent |
| 4287 | libgcrypt |
| 4288 | libjpeg-turbo |
| 4289 | libva |
| 4290 | libvpx |
| 4291 | libwebp |
| 4292 | libx11 |
| 4293 | libxcb |
| 4294 | libxcomposite |
| 4295 | libxcursor |
| 4296 | libxi |
| 4297 | libxkbcommon |
| 4298 | libxkbfile |
| 4299 | ;; FIXME: libxml2 needs to built with icu support though it links to |
| 4300 | ;; libxml2 configure summary still states "Checking for compatible |
| 4301 | ;; system libxml2... no" |
| 4302 | libxml2 |
| 4303 | libxrandr |
| 4304 | libxrender |
| 4305 | libxslt |
| 4306 | libxtst |
| 4307 | mesa |
| 4308 | minizip |
| 4309 | nss |
| 4310 | openh264 |
| 4311 | opus |
| 4312 | pciutils |
| 4313 | protobuf |
| 4314 | pulseaudio |
| 4315 | qtmultimedia |
| 4316 | re2-next |
| 4317 | snappy |
| 4318 | valgrind/pinned |
| 4319 | vulkan-headers |
| 4320 | xcb-util |
| 4321 | xkeyboard-config)) |
| 4322 | (propagated-inputs |
| 4323 | (list qtbase |
| 4324 | qtdeclarative |
| 4325 | qtwebchannel)) |
| 4326 | (home-page "https://wiki.qt.io/QtWebEngine") |
| 4327 | (synopsis "Qt WebEngine module") |
| 4328 | (description "The Qt WebEngine module provides support for web |
| 4329 | applications using the Chromium browser project. The Chromium source code has |
| 4330 | Google services and binaries removed, and adds modular support for using |
| 4331 | system libraries.") |
| 4332 | (license license:lgpl2.1+))) |
| 4333 | |
| 4334 | (define-public single-application |
| 4335 | (package |
| 4336 | (name "single-application") |
| 4337 | (version "3.5.4") |
| 4338 | (source |
| 4339 | (origin |
| 4340 | (method git-fetch) |
| 4341 | (uri |
| 4342 | (git-reference |
| 4343 | (url "https://github.com/itay-grudev/SingleApplication") |
| 4344 | (commit (string-append "v" version)))) |
| 4345 | (file-name (git-file-name name version)) |
| 4346 | (sha256 |
| 4347 | (base32 |
| 4348 | "0cj3rgsscpm5y5lp0hfsfkfdnm1h5msqw90baqj3zxmh9fh8h9nv")))) |
| 4349 | (build-system cmake-build-system) |
| 4350 | (arguments |
| 4351 | (list |
| 4352 | #:tests? #f ; no check target |
| 4353 | #:configure-flags |
| 4354 | #~(list "-DQT_DEFAULT_MAJOR_VERSION=6" |
| 4355 | ;; Projects can decide how to build this library. You might need |
| 4356 | ;; to override this flag (QApplication, QGuiApplication or |
| 4357 | ;; QCoreApplication). |
| 4358 | "-DQAPPLICATION_CLASS=QApplication") |
| 4359 | #:phases |
| 4360 | #~(modify-phases %standard-phases |
| 4361 | ;; No install target, install things manually |
| 4362 | (replace 'install |
| 4363 | (lambda* (#:key source #:allow-other-keys) |
| 4364 | (install-file |
| 4365 | "libSingleApplication.a" (string-append #$output "/lib")) |
| 4366 | (for-each |
| 4367 | (lambda (file) |
| 4368 | (install-file (string-append source "/" file) |
| 4369 | (string-append #$output "/include"))) |
| 4370 | '("SingleApplication" |
| 4371 | "singleapplication.h" |
| 4372 | "singleapplication_p.h"))))))) |
| 4373 | (inputs (list qtbase)) |
| 4374 | (home-page "https://github.com/itay-grudev/SingleApplication") |
| 4375 | (synopsis "Replacement of QtSingleApplication for Qt5 and Qt6") |
| 4376 | (description |
| 4377 | "SingleApplication is a replacement of the QtSingleApplication for Qt5 and |
| 4378 | Qt6. |
| 4379 | |
| 4380 | It keeps the Primary Instance of your Application and kills each subsequent |
| 4381 | instances. It can (if enabled) spawn secondary (non-related to the primary) |
| 4382 | instances and can send data to the primary instance from secondary instances.") |
| 4383 | (license (license:non-copyleft "file:///LICENSE")))) |
| 4384 | |
| 4385 | (define-public pyotherside |
| 4386 | (package |
| 4387 | (name "pyotherside") |
| 4388 | (version "1.6.2") |
| 4389 | (source (origin |
| 4390 | (method git-fetch) |
| 4391 | (uri (git-reference |
| 4392 | (url "https://github.com/thp/pyotherside") |
| 4393 | (commit version))) |
| 4394 | (file-name (git-file-name name version)) |
| 4395 | (sha256 |
| 4396 | (base32 |
| 4397 | "1nn0rmdwrxz6j95plzfy4r6s2jfq9ddqj7danbn4rx2nnd81brnq")))) |
| 4398 | (build-system qt-build-system) |
| 4399 | (arguments |
| 4400 | (list |
| 4401 | #:qtbase qtbase |
| 4402 | #:modules '((guix build qt-build-system) |
| 4403 | ((guix build gnu-build-system) #:prefix gnu:) |
| 4404 | (guix build utils)) |
| 4405 | #:phases |
| 4406 | #~(modify-phases %standard-phases |
| 4407 | (add-after 'unpack 'fix-installation-prefix |
| 4408 | (lambda _ |
| 4409 | ;; The QT_INSTALL_QML property points to the qtbase |
| 4410 | ;; installation prefix. |
| 4411 | (substitute* "src/src.pro" |
| 4412 | (("\\$\\$\\[QT_INSTALL_QML]") |
| 4413 | (string-append #$output "/lib/qt" |
| 4414 | #$(version-major (package-version qtbase)) |
| 4415 | "/qml"))))) |
| 4416 | (replace 'configure |
| 4417 | (lambda _ |
| 4418 | (invoke "qmake"))) |
| 4419 | (replace 'build (assoc-ref gnu:%standard-phases 'build)) |
| 4420 | (replace 'check |
| 4421 | (lambda* (#:key tests? #:allow-other-keys) |
| 4422 | (when tests? |
| 4423 | (invoke "./tests/tests")))) |
| 4424 | (replace 'install |
| 4425 | ;; Specify a specific install target, otherwise the build fails |
| 4426 | ;; attempting to install the qtquicktests target to the qtbase |
| 4427 | ;; installation prefix. |
| 4428 | (lambda _ |
| 4429 | (invoke "make" "sub-src-install_subtargets")))))) |
| 4430 | (inputs (list python qtdeclarative qtsvg)) |
| 4431 | (home-page "https://thp.io/2011/pyotherside/") |
| 4432 | (synopsis "Qt plugin providing access to a Python 3 interpreter from QML") |
| 4433 | (description "Pyotherside is a Qt plugin providing access to a Python 3 |
| 4434 | interpreter from QML for creating asynchronous mobile and desktop UIs with |
| 4435 | Python.") |
| 4436 | (license license:isc))) |
| 4437 | |
| 4438 | (define-public pyotherside-for-qt5 |
| 4439 | (package/inherit pyotherside |
| 4440 | (name "pyotherside-for-qt5") |
| 4441 | (arguments |
| 4442 | (substitute-keyword-arguments arguments |
| 4443 | ((#:qtbase _ #f) |
| 4444 | qtbase-5) |
| 4445 | ((#:phases phases '%standard-phases) |
| 4446 | #~(modify-phases #$phases |
| 4447 | (replace 'fix-installation-prefix |
| 4448 | (lambda _ |
| 4449 | ;; The QT_INSTALL_QML property points to the qtbase |
| 4450 | ;; installation prefix. |
| 4451 | (substitute* "src/src.pro" |
| 4452 | (("\\$\\$\\[QT_INSTALL_QML]") |
| 4453 | (string-append #$output "/lib/qt" |
| 4454 | #$(version-major (package-version qtbase-5)) |
| 4455 | "/qml"))))))))) |
| 4456 | (inputs (modify-inputs inputs |
| 4457 | (replace "qtdeclarative" qtdeclarative-5) |
| 4458 | (replace "qtquickcontrols2" qtquickcontrols-5) |
| 4459 | (replace "qtsvg" qtsvg-5))))) |
| 4460 | |
| 4461 | (define-public python-sip |
| 4462 | (package |
| 4463 | (name "python-sip") |
| 4464 | (version "6.12.0") |
| 4465 | (source |
| 4466 | (origin |
| 4467 | (method url-fetch) |
| 4468 | (uri (list (pypi-uri "sip" version) |
| 4469 | (string-append "https://www.riverbankcomputing.com/static/" |
| 4470 | "Downloads/sip/" version |
| 4471 | "/sip-" version ".tar.gz"))) |
| 4472 | (sha256 |
| 4473 | (base32 |
| 4474 | "1il938crjap0f05773mk70fjp91b1fbn76hi64r4j5akz2afsg08")) |
| 4475 | (modules '((guix build utils))) |
| 4476 | (snippet |
| 4477 | ;; Relax setuptools dependency |
| 4478 | #~(substitute* "pyproject.toml" |
| 4479 | (("\"setuptools>=.*\",") "\"setuptools\","))) |
| 4480 | (patches (search-patches "python-sip-include-dirs.patch")))) |
| 4481 | (build-system pyproject-build-system) |
| 4482 | (arguments |
| 4483 | (list #:tests? #f)) ; No test system found. |
| 4484 | (native-inputs |
| 4485 | (list python-setuptools python-setuptools-scm python-wheel)) |
| 4486 | (propagated-inputs |
| 4487 | (list python-packaging python-setuptools python-tomli)) |
| 4488 | (home-page "https://www.riverbankcomputing.com/software/sip/intro") |
| 4489 | (synopsis "Python binding creator for C and C++ libraries") |
| 4490 | (description |
| 4491 | "SIP is a tool to create Python bindings for C and C++ libraries. It |
| 4492 | was originally developed to create PyQt, the Python bindings for the Qt |
| 4493 | toolkit, but can be used to create bindings for any C or C++ library. |
| 4494 | |
| 4495 | SIP comprises a code generator and a Python module. The code generator |
| 4496 | processes a set of specification files and generates C or C++ code, which |
| 4497 | is then compiled to create the bindings extension module. The SIP Python |
| 4498 | module provides support functions to the automatically generated code.") |
| 4499 | ;; There is a choice between a python like license, gpl2 and gpl3. |
| 4500 | ;; For compatibility with pyqt, we need gpl3. |
| 4501 | (license license:gpl3))) |
| 4502 | |
| 4503 | (define-public python-sip-4 |
| 4504 | (package |
| 4505 | (inherit python-sip) |
| 4506 | (name "python-sip") |
| 4507 | (version "4.19.25") |
| 4508 | (source |
| 4509 | (origin |
| 4510 | (method url-fetch) |
| 4511 | (uri (list (pypi-uri "sip" version) |
| 4512 | (string-append "https://www.riverbankcomputing.com/static/" |
| 4513 | "Downloads/sip/" |
| 4514 | version |
| 4515 | "/sip-" |
| 4516 | version |
| 4517 | ".tar.gz"))) |
| 4518 | (sha256 |
| 4519 | (base32 "04a23cgsnx150xq86w1z44b6vr2zyazysy9mqax0fy346zlr77dk")))) |
| 4520 | (build-system gnu-build-system) |
| 4521 | (arguments |
| 4522 | (list |
| 4523 | #:tests? #f ;no check target |
| 4524 | #:imported-modules %pyproject-build-system-modules |
| 4525 | #:modules `((srfi srfi-1) |
| 4526 | ((guix build pyproject-build-system) #:prefix py:) |
| 4527 | ,@%default-gnu-modules) |
| 4528 | #:phases |
| 4529 | #~(modify-phases %standard-phases |
| 4530 | (add-after 'unpack 'substitute |
| 4531 | (lambda _ |
| 4532 | (substitute* "siplib/siplib.c" |
| 4533 | ;; Replaces the internal data-structure usage |
| 4534 | ;; that was removed in python 3.11 with the |
| 4535 | ;; new official API call so the code will compile |
| 4536 | ;; with python > 3.11 |
| 4537 | (("frame->f_back") |
| 4538 | "PyFrame_GetBack(frame)")))) |
| 4539 | (replace 'configure |
| 4540 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 4541 | (invoke "python" "configure.py" |
| 4542 | "--bindir" (string-append #$output "/bin") |
| 4543 | "--destdir" (py:site-packages inputs outputs) |
| 4544 | "--incdir" (string-append #$output "/include"))))))) |
| 4545 | (native-inputs (list python-setuptools python-wrapper)) |
| 4546 | (propagated-inputs (list)) |
| 4547 | (license license:gpl3))) |
| 4548 | |
| 4549 | (define-public python-pyqt |
| 4550 | (package |
| 4551 | (name "python-pyqt") |
| 4552 | (version "5.15.11") |
| 4553 | (source |
| 4554 | (origin |
| 4555 | (method url-fetch) |
| 4556 | ;; PyPI is the canonical distribution point of PyQt. Older |
| 4557 | ;; releases are available from the web site. |
| 4558 | (uri (list (pypi-uri "PyQt5" version) |
| 4559 | (string-append "https://www.riverbankcomputing.com/static/" |
| 4560 | "Downloads/PyQt5/" version "/PyQt5-" |
| 4561 | version ".tar.gz"))) |
| 4562 | (file-name (string-append "PyQt5-" version ".tar.gz")) |
| 4563 | (sha256 |
| 4564 | (base32 |
| 4565 | "0lkwap0va0kq9j9x540cc5fink2w8ppxiiji395pp8mlxd1mg97x")))) |
| 4566 | (build-system pyproject-build-system) |
| 4567 | (arguments |
| 4568 | (list |
| 4569 | #:tests? #f ; No tests. |
| 4570 | #:configure-flags |
| 4571 | #~`(("--verbose" . "") ; Print commands run. |
| 4572 | ("--confirm-license" . "") |
| 4573 | ("--jobs" . ,(number->string (parallel-job-count)))) |
| 4574 | #:phases |
| 4575 | #~(modify-phases %standard-phases |
| 4576 | ;; When building python-pyqtwebengine, <qprinter.h> can not be |
| 4577 | ;; included. Here we substitute the full path to the header in the |
| 4578 | ;; store. |
| 4579 | (add-after 'unpack 'substitute-source |
| 4580 | (lambda* (#:key inputs #:allow-other-keys) |
| 4581 | (let* ((version #$(package-version this-package)) |
| 4582 | (qt-version (string-take version 1)) |
| 4583 | (qtprinter.h (string-append "include/qt" |
| 4584 | qt-version |
| 4585 | "/QtPrintSupport" |
| 4586 | "/qprinter.h"))) |
| 4587 | (substitute* '("sip/QtPrintSupport/qprinter.sip" |
| 4588 | "sip/QtPrintSupport/qpyprintsupport_qlist.sip") |
| 4589 | (("<qprinter.h>") |
| 4590 | (format #f "~s" |
| 4591 | (search-input-file inputs qtprinter.h)))))))))) |
| 4592 | (native-inputs |
| 4593 | (list qtbase-5 ; for qmake |
| 4594 | python-pyqt-builder)) |
| 4595 | (propagated-inputs |
| 4596 | (list python-sip python-pyqt5-sip)) |
| 4597 | (inputs |
| 4598 | (list python-wrapper |
| 4599 | qtbase-5 |
| 4600 | qtconnectivity-5 |
| 4601 | qtdeclarative-5 |
| 4602 | qtlocation-5 |
| 4603 | qtmultimedia-5 |
| 4604 | qtsensors-5 |
| 4605 | qtserialport-5 |
| 4606 | qtsvg-5 |
| 4607 | qttools-5 |
| 4608 | qtwebchannel-5 |
| 4609 | qtwebsockets-5 |
| 4610 | qtx11extras |
| 4611 | qtxmlpatterns-5)) |
| 4612 | (home-page "https://www.riverbankcomputing.com/software/pyqt/intro") |
| 4613 | (synopsis "Python bindings for Qt") |
| 4614 | (description |
| 4615 | "PyQt is a set of Python v2 and v3 bindings for the Qt application |
| 4616 | framework. The bindings are implemented as a set of Python modules and |
| 4617 | contain over 620 classes.") |
| 4618 | (license license:gpl3))) |
| 4619 | |
| 4620 | (define-public python-pyqt-6 |
| 4621 | (package |
| 4622 | (inherit python-pyqt) |
| 4623 | (version "6.9.1") |
| 4624 | (source |
| 4625 | (origin |
| 4626 | (method url-fetch) |
| 4627 | (uri (pypi-uri "pyqt6" version)) |
| 4628 | (file-name (string-append "pyqt6-" version ".tar.gz")) |
| 4629 | (sha256 |
| 4630 | (base32 "19n3q6b8mbzswrkq5rqmkh1kx0br1xd1z6m024hiq3xl7zh2nr2h")))) |
| 4631 | (inputs ;Qt5 dependencies only in python-pyqt: |
| 4632 | ;; (qt)connectivity, location, sensors, serialport, x11extras, xmlpatterns. |
| 4633 | (list python-wrapper |
| 4634 | qtbase |
| 4635 | qtdeclarative |
| 4636 | qtmultimedia |
| 4637 | qtpositioning |
| 4638 | qtscxml |
| 4639 | qtspeech |
| 4640 | qtsvg |
| 4641 | qttools |
| 4642 | qtwebchannel |
| 4643 | qtwebsockets)) |
| 4644 | (propagated-inputs (list python-sip python-pyqt6-sip)) |
| 4645 | (native-inputs (list python-pyqt-builder qtbase)))) ;qtbase is required for qmake. |
| 4646 | |
| 4647 | (define-public python-pyqt5-sip |
| 4648 | (package |
| 4649 | (name "python-pyqt5-sip") |
| 4650 | (version "12.17.0") |
| 4651 | (source |
| 4652 | (origin |
| 4653 | (method url-fetch) |
| 4654 | (uri (pypi-uri "pyqt5_sip" version)) |
| 4655 | (sha256 |
| 4656 | (base32 |
| 4657 | "0kqbz61fcbv9indv927cic90x0kbfzi2h1hcvjgsyf92pp6ssbb8")))) |
| 4658 | (build-system pyproject-build-system) |
| 4659 | (arguments |
| 4660 | `(#:tests? #f)) ;; No test code. |
| 4661 | (native-inputs |
| 4662 | (list python-setuptools)) |
| 4663 | (home-page "https://www.riverbankcomputing.com/software/sip/") |
| 4664 | (synopsis "Sip module support for PyQt5") |
| 4665 | (description "Sip module support for PyQt5") |
| 4666 | (license license:lgpl2.1+))) |
| 4667 | |
| 4668 | (define-public python-pyqt6-sip |
| 4669 | (package |
| 4670 | (inherit python-pyqt5-sip) |
| 4671 | (name "python-pyqt6-sip") |
| 4672 | (version "13.10.2") |
| 4673 | (source |
| 4674 | (origin |
| 4675 | (method url-fetch) |
| 4676 | (uri (pypi-uri "pyqt6_sip" version)) |
| 4677 | (sha256 |
| 4678 | (base32 "1zpsarqn56jakdridn3lk4qgc2i8h9xaqp6hdg700rajpxbd2jj6")))) |
| 4679 | (synopsis "Sip module support for PyQt6") |
| 4680 | (description |
| 4681 | "SIP is used to write self contained extension modules, i.e. without a |
| 4682 | library to be wrapped. This SIP extension module provides support for the |
| 4683 | PyQt6 package."))) |
| 4684 | |
| 4685 | (define-public python-pyqtwebengine |
| 4686 | (package |
| 4687 | (name "python-pyqtwebengine") |
| 4688 | (version "5.15.9") |
| 4689 | (source |
| 4690 | (origin |
| 4691 | (method url-fetch) |
| 4692 | ;; The newest releases are only available on PyPI. Older ones |
| 4693 | ;; are mirrored at the upstream home page. |
| 4694 | (uri (list (pypi-uri "PyQtWebEngine" version) |
| 4695 | (string-append "https://www.riverbankcomputing.com/static" |
| 4696 | "/Downloads/PyQtWebEngine/" version |
| 4697 | "/PyQtWebEngine-" version ".tar.gz"))) |
| 4698 | (sha256 |
| 4699 | (base32 |
| 4700 | "0hdr0g0rzlhsnylhfk826pq1lw8p9dqcr8yma2wy9dgjrj6n0ixb")))) |
| 4701 | (build-system pyproject-build-system) |
| 4702 | (native-inputs |
| 4703 | (list python python-sip |
| 4704 | python-pyqt-builder |
| 4705 | ;; qtbase is required for qmake |
| 4706 | qtbase-5)) |
| 4707 | (inputs |
| 4708 | `(("python" ,python-wrapper) |
| 4709 | ("python-sip" ,python-sip) |
| 4710 | ("python-pyqt" ,python-pyqt) |
| 4711 | ("qtbase" ,qtbase-5) |
| 4712 | ("qtsvg-5" ,qtsvg-5) |
| 4713 | ("qtdeclarative-5" ,qtdeclarative-5) |
| 4714 | ("qtwebchannel-5" ,qtwebchannel-5) |
| 4715 | ("qtwebengine-5" ,qtwebengine-5))) |
| 4716 | (arguments |
| 4717 | (list |
| 4718 | #:tests? #f ; No tests. |
| 4719 | #:configure-flags |
| 4720 | #~`(("--verbose" . "") ; Print commands run. |
| 4721 | ("--jobs" . ,(number->string (parallel-job-count)))) |
| 4722 | #:phases |
| 4723 | #~(modify-phases %standard-phases |
| 4724 | (add-after 'unpack 'set-include-dirs |
| 4725 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 4726 | (let* ((python (assoc-ref inputs "python")) |
| 4727 | (python-pyqt (assoc-ref inputs "python-pyqt")) |
| 4728 | (sip-include-dirs (string-append |
| 4729 | python-pyqt "/lib/python" |
| 4730 | (python-version python) |
| 4731 | "/site-packages/PyQt5/bindings"))) |
| 4732 | (setenv "SIP_INCLUDE_DIRS" sip-include-dirs))))))) |
| 4733 | (home-page "https://www.riverbankcomputing.com/software/pyqtwebengine/intro") |
| 4734 | (synopsis "Python bindings for QtWebEngine") |
| 4735 | (description |
| 4736 | "PyQtWebEngine is a set of Python bindings for The Qt Company's Qt |
| 4737 | WebEngine libraries. The bindings sit on top of PyQt5 and are implemented as a |
| 4738 | set of three modules. Prior to v5.12 these bindings were part of PyQt |
| 4739 | itself.") |
| 4740 | (license license:gpl3))) |
| 4741 | |
| 4742 | (define-public python-pyqtwebengine-6 |
| 4743 | (package |
| 4744 | (name "python-pyqtwebengine") |
| 4745 | (version "6.9.0") |
| 4746 | (source |
| 4747 | (origin |
| 4748 | (method url-fetch) |
| 4749 | (uri (pypi-uri "pyqt6_webengine" version)) |
| 4750 | (sha256 |
| 4751 | (base32 "09dah4cv3jgw86ar4irwah03pg70jwi8br1mcphbh1nspgikgrba")) |
| 4752 | (modules '((guix build utils))) |
| 4753 | (snippet |
| 4754 | ;; Fix missing include for QVariant. |
| 4755 | '(substitute* "sip/QtWebEngineCore/qwebengineframe.sip" |
| 4756 | (("#include <qwebengineframe\\.h>" all) |
| 4757 | (string-append "#include <qvariant.h>\n" all)))))) |
| 4758 | (build-system pyproject-build-system) |
| 4759 | (native-inputs (list python python-sip python-pyqt-builder |
| 4760 | ;; qtbase is required for qmake |
| 4761 | qtbase)) |
| 4762 | (inputs (list python-pyqt-6 qtbase qtdeclarative qtwebchannel qtwebengine)) |
| 4763 | (arguments |
| 4764 | (list |
| 4765 | #:tests? #f ;No tests. |
| 4766 | #:configure-flags #~`(("--verbose" . "") ;Print commands run. |
| 4767 | ("--jobs" unquote |
| 4768 | (number->string (parallel-job-count)))) |
| 4769 | #:phases #~(modify-phases %standard-phases |
| 4770 | (add-after 'unpack 'set-include-dirs |
| 4771 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 4772 | (let* ((python (assoc-ref inputs "python")) |
| 4773 | (sip-include-dirs (search-input-directory inputs |
| 4774 | (string-append "/lib/python" |
| 4775 | (python-version python) |
| 4776 | "/site-packages/PyQt6/bindings")))) |
| 4777 | (setenv "SIP_INCLUDE_DIRS" sip-include-dirs))))))) |
| 4778 | (home-page "https://www.riverbankcomputing.com/software/pyqtwebengine/intro") |
| 4779 | (synopsis "Python bindings for QtWebEngine") |
| 4780 | (description |
| 4781 | "PyQtWebEngine is a set of Python bindings for The Qt Company's Qt |
| 4782 | WebEngine libraries. The bindings sit on top of PyQt6 and are implemented as a |
| 4783 | set of three modules.") |
| 4784 | (license license:gpl3))) |
| 4785 | |
| 4786 | (define-public python-pyqt-builder |
| 4787 | (package |
| 4788 | (name "python-pyqt-builder") |
| 4789 | (version "1.18.2") |
| 4790 | (source |
| 4791 | (origin |
| 4792 | (method url-fetch) |
| 4793 | (uri (pypi-uri "pyqt_builder" version)) |
| 4794 | (sha256 |
| 4795 | (base32 |
| 4796 | "1g40j5iyad8bw8113rsxxkbkdi7g1lcjj0lb1j7pma442i3fmpsn")))) |
| 4797 | (build-system pyproject-build-system) |
| 4798 | (native-inputs (list python-setuptools |
| 4799 | python-setuptools-scm |
| 4800 | python-wheel)) |
| 4801 | (inputs |
| 4802 | (list python-sip)) |
| 4803 | (arguments (list #:tests? #f)) ; no test suite |
| 4804 | (home-page "https://www.riverbankcomputing.com/static/Docs/PyQt-builder/") |
| 4805 | (synopsis "PEP 517 compliant PyQt build system") |
| 4806 | (description "PyQt-builder is a tool for generating Python bindings for C++ |
| 4807 | libraries that use the Qt application framework. The bindings are built on |
| 4808 | top of the PyQt bindings for Qt. PyQt-builder is used to build PyQt itself.") |
| 4809 | ;; Either version 2 or 3, but no other version. See the file |
| 4810 | ;; 'pyqtbuild/builder.py' in the source distribution for more information. |
| 4811 | (license (list license:gpl2 license:gpl3)))) |
| 4812 | |
| 4813 | (define-public python-qtpy |
| 4814 | (package |
| 4815 | (name "python-qtpy") |
| 4816 | (version "2.4.3") |
| 4817 | (source |
| 4818 | (origin |
| 4819 | (method url-fetch) |
| 4820 | (uri (pypi-uri "qtpy" version)) |
| 4821 | (sha256 |
| 4822 | (base32 "1fzmrpjgchiiqsxnyg8ci553nazflfycr9lbas8dmlz669w4yx6v")))) |
| 4823 | (build-system pyproject-build-system) |
| 4824 | (arguments |
| 4825 | (list |
| 4826 | #:test-flags |
| 4827 | ;; Fatal Python error: Aborted |
| 4828 | #~(list "--ignore=qtpy/tests/test_compat.py" |
| 4829 | "--ignore=qtpy/tests/test_qtcore.py" |
| 4830 | "--ignore=qtpy/tests/test_qtgui.py" |
| 4831 | "--ignore=qtpy/tests/test_qtprintsupport.py" |
| 4832 | "--ignore=qtpy/tests/test_qtwidgets.py" |
| 4833 | "--ignore=qtpy/tests/test_uic.py" |
| 4834 | ;; ModuleNotFoundError: No module named 'PyQt5.QtTextToSpeech' |
| 4835 | "-k" (string-append "not test_qttexttospeech" |
| 4836 | ;; Fatal Python error: Segmentation fault |
| 4837 | " and not test_qtsql_members_aliases")))) |
| 4838 | ;; XXX: Do not include, even supported: Qt5, PySide2 PySide6, only test |
| 4839 | ;; against Qt6 to reduce closure size.. |
| 4840 | (native-inputs |
| 4841 | (list python-pyqt-6 |
| 4842 | python-pytest |
| 4843 | python-setuptools)) |
| 4844 | (propagated-inputs |
| 4845 | (list python-packaging)) |
| 4846 | (home-page "https://github.com/spyder-ide/qtpy") |
| 4847 | (synopsis "Uniform layer to support PyQt5, PySide2, PyQt6, PySide6") |
| 4848 | (description |
| 4849 | "Provides an abstraction layer on top of the various Qt bindings (PyQt5, |
| 4850 | PySide2, PyQt6, PySide6) and additional custom QWidgets.") |
| 4851 | (license license:expat))) |
| 4852 | |
| 4853 | (define-public python-qt-py |
| 4854 | (package |
| 4855 | (name "python-qt-py") |
| 4856 | (version "2.0.3") |
| 4857 | (source |
| 4858 | (origin |
| 4859 | (method git-fetch) |
| 4860 | (uri (git-reference |
| 4861 | (url "https://github.com/mottosso/Qt.py") |
| 4862 | (commit version))) |
| 4863 | (file-name (git-file-name name version)) |
| 4864 | (sha256 |
| 4865 | (base32 "0p3aiskbhy5g9f87mkv1vc0mw155wl5x915lk9ankj6d1djjkfxw")))) |
| 4866 | (build-system pyproject-build-system) |
| 4867 | (arguments |
| 4868 | ;; See: <https://github.com/mottosso/Qt.py/issues/395>. |
| 4869 | (list #:tests? #f)) |
| 4870 | (native-inputs |
| 4871 | (list python-pyqt-6 |
| 4872 | python-setuptools)) |
| 4873 | (propagated-inputs |
| 4874 | (list python-types-pyside6)) |
| 4875 | (home-page "https://github.com/mottosso/Qt.py") |
| 4876 | (synopsis "Abstraction layer for Python Qt bindings") |
| 4877 | (description |
| 4878 | "This package provides an abstraction layer on top of the various Qt |
| 4879 | bindings (PySide, PySide2, PyQt4 and PyQt5).") |
| 4880 | (license license:expat))) |
| 4881 | |
| 4882 | ;; XXX: Deprecated on <2026-03-13>. |
| 4883 | (define-deprecated-package python-qt.py python-qt-py) |
| 4884 | |
| 4885 | (define-public python-superqt |
| 4886 | ;; XXX: Move to (gnu packages python-graphics) or closer to mantid to |
| 4887 | ;; prevent adding python-science module here. |
| 4888 | (package |
| 4889 | (name "python-superqt") |
| 4890 | (version "0.8.1") |
| 4891 | (source |
| 4892 | (origin |
| 4893 | (method git-fetch) |
| 4894 | (uri (git-reference |
| 4895 | (url "https://github.com/pyapp-kit/superqt") |
| 4896 | (commit (string-append "v" version)))) |
| 4897 | (file-name (git-file-name name version)) |
| 4898 | (sha256 |
| 4899 | (base32 "1sxvz1jm1kyd4nlaz6g9p64c0ifj1mmj0qcwpgd0p3b7l7yyvjqz")))) |
| 4900 | (build-system pyproject-build-system) |
| 4901 | (arguments |
| 4902 | (list #:tests? #f)) ;XXX: tets segfaulted |
| 4903 | (native-inputs |
| 4904 | (list python-pytest |
| 4905 | python-hatch-vcs |
| 4906 | python-hatchling |
| 4907 | python-numpy |
| 4908 | python-pytest-qt)) |
| 4909 | (propagated-inputs |
| 4910 | (list python-pygments |
| 4911 | python-qtpy |
| 4912 | python-typing-extensions |
| 4913 | ;; [optional] |
| 4914 | python-pyqt-6 |
| 4915 | python-pyconify)) |
| 4916 | (home-page "https://github.com/pyapp-kit/superqt") |
| 4917 | (synopsis "Extra widgets and components for PyQt/PySide") |
| 4918 | (description "This package provides some extra widgets for |
| 4919 | @code{PyQt/PySide}: |
| 4920 | @itemize |
| 4921 | @item Multi-handle slider for float values |
| 4922 | @item Spinbox with arbitrarily large integers |
| 4923 | @item Magnitude combined with unit dropdown |
| 4924 | @item Label that will elide text |
| 4925 | @item Searchable ComboBox populated from Enum |
| 4926 | @item Searchable List |
| 4927 | @item Searchable Tree |
| 4928 | @item Color ComboBox |
| 4929 | @item Colormap ComboBox |
| 4930 | @item Toggle switch |
| 4931 | @item Collapsible widget to hide and unhide child widgets |
| 4932 | @item Flow layout |
| 4933 | @end itemize") |
| 4934 | (license license:bsd-3))) |
| 4935 | |
| 4936 | (define-public qscintilla-qt6 |
| 4937 | (package |
| 4938 | (name "qscintilla-qt6") |
| 4939 | (version "2.14.1") |
| 4940 | (source (origin |
| 4941 | (method url-fetch) |
| 4942 | (uri (string-append "https://www.riverbankcomputing.com/static" |
| 4943 | "/Downloads/QScintilla/" version |
| 4944 | "/QScintilla_src-" version ".tar.gz")) |
| 4945 | (sha256 |
| 4946 | (base32 |
| 4947 | "0kfx9hxd9a9h7cs3qby0lrbkj8hswxhq1k3clz5xz1cxrim3rqfz")))) |
| 4948 | (build-system gnu-build-system) |
| 4949 | (arguments |
| 4950 | `(#:phases |
| 4951 | (modify-phases %standard-phases |
| 4952 | (replace 'configure |
| 4953 | (lambda* (#:key outputs #:allow-other-keys) |
| 4954 | (let ((out (assoc-ref outputs "out"))) |
| 4955 | (chdir "src") |
| 4956 | (substitute* "qscintilla.pro" |
| 4957 | (("\\$\\$\\[QT_INSTALL_LIBS\\]") |
| 4958 | (string-append out "/lib")) |
| 4959 | (("\\$\\$\\[QT_INSTALL_HEADERS\\]") |
| 4960 | (string-append out "/include")) |
| 4961 | (("\\$\\$\\[QT_INSTALL_TRANSLATIONS\\]") |
| 4962 | (string-append out "/translations")) |
| 4963 | (("\\$\\$\\[QT_INSTALL_DATA\\]") |
| 4964 | (string-append out "/lib/qt$${QT_MAJOR_VERSION}")) |
| 4965 | (("\\$\\$\\[QT_HOST_DATA\\]") |
| 4966 | (string-append out "/lib/qt$${QT_MAJOR_VERSION}"))) |
| 4967 | (invoke "qmake"))))))) |
| 4968 | (native-inputs (list qtbase)) |
| 4969 | (home-page "https://www.riverbankcomputing.co.uk/software/qscintilla/intro") |
| 4970 | (synopsis "Qt port of the Scintilla C++ editor control") |
| 4971 | (description "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ |
| 4972 | editor control. QScintilla includes features especially useful when editing |
| 4973 | and debugging source code. These include support for syntax styling, error |
| 4974 | indicators, code completion and call tips.") |
| 4975 | (license license:gpl3+))) |
| 4976 | |
| 4977 | (define-public qscintilla-qt5 |
| 4978 | (package |
| 4979 | (inherit qscintilla-qt6) |
| 4980 | (name "qscintilla-qt5") |
| 4981 | (native-inputs (list qtbase-5)))) |
| 4982 | |
| 4983 | ;; 2026-07-17 |
| 4984 | (define-deprecated-package qscintilla qscintilla-qt5) |
| 4985 | |
| 4986 | (define-public python-qscintilla |
| 4987 | (package/inherit qscintilla-qt5 |
| 4988 | (name "python-qscintilla") |
| 4989 | (build-system pyproject-build-system) |
| 4990 | (arguments |
| 4991 | (list #:tests? #f |
| 4992 | #:phases |
| 4993 | #~(modify-phases %standard-phases |
| 4994 | (add-before 'build 'set-configure-flags |
| 4995 | (lambda _ |
| 4996 | (setenv "CFLAGS" (string-append |
| 4997 | "--qsci-include-dir" |
| 4998 | #$(this-package-input "qscintilla-qt5") |
| 4999 | "/include" |
| 5000 | " --qsci-library-dir" |
| 5001 | #$(this-package-input "qscintilla-qt5") |
| 5002 | "/lib")))) |
| 5003 | (add-after 'unpack 'prepare-build |
| 5004 | (lambda _ |
| 5005 | (chdir "Python") |
| 5006 | (symlink "pyproject-qt5.toml" "pyproject.toml"))) |
| 5007 | (add-after 'unpack 'set-include-dirs |
| 5008 | (lambda _ |
| 5009 | (let* ((python-pyqt #$(this-package-input "python-pyqt")) |
| 5010 | (sip-include-dirs (string-append |
| 5011 | python-pyqt "/lib/python" |
| 5012 | #$(version-major+minor |
| 5013 | (package-version python)) |
| 5014 | "/site-packages/PyQt5/bindings"))) |
| 5015 | (setenv "SIP_INCLUDE_DIRS" sip-include-dirs))))))) |
| 5016 | (native-inputs |
| 5017 | (list python-pyqt-builder qtbase-5)) |
| 5018 | (inputs |
| 5019 | (list python-pyqt python-sip qscintilla-qt5)) |
| 5020 | (description "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ |
| 5021 | editor control. QScintilla includes features especially useful when editing |
| 5022 | and debugging source code. These include support for syntax styling, error |
| 5023 | indicators, code completion and call tips. |
| 5024 | |
| 5025 | This package provides the Python bindings."))) |
| 5026 | |
| 5027 | ;; PyQt only looks for modules in its own directory. It ignores environment |
| 5028 | ;; variables such as PYTHONPATH, so we need to build a union package to make |
| 5029 | ;; it work. |
| 5030 | (define-public python-pyqt+qscintilla |
| 5031 | (package/inherit python-pyqt |
| 5032 | (name "python-pyqt+qscintilla") |
| 5033 | (source #f) |
| 5034 | (build-system trivial-build-system) |
| 5035 | (arguments |
| 5036 | '(#:modules ((guix build union)) |
| 5037 | #:builder (begin |
| 5038 | (use-modules (ice-9 match) |
| 5039 | (guix build union)) |
| 5040 | (match %build-inputs |
| 5041 | (((names . directories) ...) |
| 5042 | (union-build (assoc-ref %outputs "out") |
| 5043 | directories)))))) |
| 5044 | (inputs |
| 5045 | `(("python-pyqt" ,python-pyqt) |
| 5046 | ("python-qscintilla" ,python-qscintilla))) |
| 5047 | (synopsis "Union of PyQt and the Qscintilla extension") |
| 5048 | (description |
| 5049 | "This package contains the union of PyQt and the Qscintilla extension."))) |
| 5050 | |
| 5051 | (define-public qtkeychain |
| 5052 | (package |
| 5053 | (name "qtkeychain") |
| 5054 | (version "0.15.0") |
| 5055 | (source |
| 5056 | (origin |
| 5057 | (method git-fetch) |
| 5058 | (uri (git-reference |
| 5059 | (url "https://github.com/frankosterfeld/qtkeychain/") |
| 5060 | (commit version))) |
| 5061 | (file-name (git-file-name name version)) |
| 5062 | (sha256 |
| 5063 | (base32 |
| 5064 | "0j1mn6vl0zc54b0pcffr20sqa5lbiwyi0l6vfa1ad3av0b66h1zy")))) |
| 5065 | (build-system cmake-build-system) |
| 5066 | (native-inputs |
| 5067 | (list pkg-config qttools-5)) |
| 5068 | (inputs |
| 5069 | (list libsecret qtbase-5)) |
| 5070 | (arguments |
| 5071 | `(#:tests? #f ; No tests included |
| 5072 | #:phases |
| 5073 | (modify-phases %standard-phases |
| 5074 | (add-before 'configure 'set-qt-trans-dir |
| 5075 | (lambda _ |
| 5076 | (substitute* "CMakeLists.txt" |
| 5077 | (("\\$\\{qt_translations_dir\\}") |
| 5078 | "${CMAKE_INSTALL_PREFIX}/share/qt5/translations"))))))) |
| 5079 | (home-page "https://github.com/frankosterfeld/qtkeychain") |
| 5080 | (synopsis "Qt API to store passwords") |
| 5081 | (description |
| 5082 | "QtKeychain is a Qt library to store passwords and other secret data |
| 5083 | securely. It will not store any data unencrypted unless explicitly requested.") |
| 5084 | (license license:bsd-3))) |
| 5085 | |
| 5086 | (define-public qtkeychain-qt6 |
| 5087 | (package |
| 5088 | (inherit qtkeychain) |
| 5089 | (name "qtkeychain-qt6") |
| 5090 | (native-inputs |
| 5091 | (modify-inputs native-inputs |
| 5092 | (replace "qttools" qttools))) |
| 5093 | (inputs |
| 5094 | (modify-inputs inputs |
| 5095 | (replace "qtbase" qtbase))) |
| 5096 | (arguments |
| 5097 | (substitute-keyword-arguments arguments |
| 5098 | ((#:configure-flags flags #~(list)) |
| 5099 | #~(cons "-DBUILD_WITH_QT6=ON" #$flags)) |
| 5100 | ((#:phases phases '%standard-phases) |
| 5101 | #~(modify-phases #$phases |
| 5102 | (replace 'set-qt-trans-dir |
| 5103 | (lambda _ |
| 5104 | (lambda _ |
| 5105 | (substitute* "CMakeLists.txt" |
| 5106 | (("\\$\\{qt_translations_dir\\}") |
| 5107 | "${CMAKE_INSTALL_PREFIX}/share/qt6/translations"))))))))))) |
| 5108 | |
| 5109 | (define-public qtsolutions |
| 5110 | (let ((commit "777e95ba69952f11eaec0adfb0cb987fabcdecb3") |
| 5111 | (revision "54")) |
| 5112 | (package |
| 5113 | (name "qtsolutions") |
| 5114 | (version (git-version "0" revision commit)) |
| 5115 | (source |
| 5116 | (origin |
| 5117 | (method git-fetch) |
| 5118 | (uri (git-reference |
| 5119 | (url "https://github.com/qtproject/qt-solutions") |
| 5120 | (commit commit))) |
| 5121 | (file-name (git-file-name name version)) |
| 5122 | (sha256 |
| 5123 | (base32 "044dzxxhjldzmxd1pqi7p1ppppjvqjdr42bm60gbl8902rda6qrk")) |
| 5124 | (modules '((guix build utils) |
| 5125 | (ice-9 ftw) |
| 5126 | (srfi srfi-1))) |
| 5127 | (snippet |
| 5128 | ;; Unvendor QtLockFile from QtSingleApplication. |
| 5129 | '(begin |
| 5130 | (with-directory-excursion "qtsingleapplication/src" |
| 5131 | (for-each delete-file |
| 5132 | (find-files "." "qtlockedfile.*\\.(h|cpp)")) |
| 5133 | (substitute* "qtsingleapplication.pri" |
| 5134 | ;; Add include path of LockedFile. |
| 5135 | (("INCLUDEPATH \\+=") |
| 5136 | "INCLUDEPATH += ../../qtlockedfile/src") |
| 5137 | ;; Link library of LockedFile. |
| 5138 | (("LIBS \\+=") |
| 5139 | "LIBS += -lQtSolutions_LockedFile")) |
| 5140 | (substitute* '("qtlocalpeer.h" "qtlocalpeer.cpp") |
| 5141 | (("#include \"qtlockedfile.*\\.cpp\"") "") |
| 5142 | ;; Unwrap namespace added in the vendoring process. |
| 5143 | (("QtLP_Private::QtLockedFile") |
| 5144 | "QtLockedFile"))))))) |
| 5145 | (build-system gnu-build-system) |
| 5146 | (arguments |
| 5147 | `(#:tests? #f ; No target |
| 5148 | #:imported-modules |
| 5149 | ((guix build copy-build-system) |
| 5150 | ,@%default-gnu-imported-modules) |
| 5151 | #:modules |
| 5152 | (((guix build copy-build-system) #:prefix copy:) |
| 5153 | (guix build gnu-build-system) |
| 5154 | (guix build utils)) |
| 5155 | #:phases |
| 5156 | (modify-phases %standard-phases |
| 5157 | (add-after 'unpack 'patch-source |
| 5158 | (lambda* (#:key outputs #:allow-other-keys) |
| 5159 | (substitute* (find-files "." "common.pri") |
| 5160 | ;; Remove unnecessary prefixes/suffixes in library names. |
| 5161 | (("qt5") "qt") |
| 5162 | (("-head") "")) |
| 5163 | ;; Disable building of examples. |
| 5164 | (substitute* (find-files "." "\\.pro$") |
| 5165 | (("SUBDIRS\\+=examples") "")) |
| 5166 | ;; Fix deprecated functions. |
| 5167 | (substitute* "qtsoap/src/qtsoap.cpp" |
| 5168 | (("toAscii") "toUtf8")))) |
| 5169 | (replace 'configure |
| 5170 | (lambda _ |
| 5171 | (for-each (lambda (solution) |
| 5172 | (with-directory-excursion solution |
| 5173 | (invoke "./configure" "-library") |
| 5174 | (invoke "qmake"))) |
| 5175 | '("qtlockedfile" "qtpropertybrowser" "qtservice" |
| 5176 | "qtsingleapplication" "qtsoap")))) |
| 5177 | (replace 'build |
| 5178 | (lambda _ |
| 5179 | (for-each (lambda (solution) |
| 5180 | (with-directory-excursion solution |
| 5181 | (invoke "make"))) |
| 5182 | '("qtlockedfile" "qtpropertybrowser" "qtservice" |
| 5183 | "qtsingleapplication" "qtsoap")))) |
| 5184 | (replace 'install |
| 5185 | (lambda args |
| 5186 | (for-each (lambda (solution) |
| 5187 | (with-directory-excursion solution |
| 5188 | (apply |
| 5189 | (assoc-ref copy:%standard-phases 'install) |
| 5190 | #:install-plan |
| 5191 | '(("src" "include" #:include-regexp ("\\.h$")) |
| 5192 | ("lib" "lib")) |
| 5193 | args))) |
| 5194 | '("qtlockedfile" "qtpropertybrowser" "qtservice" |
| 5195 | "qtsingleapplication" "qtsoap"))))))) |
| 5196 | (inputs |
| 5197 | (list qtbase-5)) |
| 5198 | (synopsis "Collection of Qt extensions") |
| 5199 | (description "QtSolutions is a set of components extending Qt. |
| 5200 | @itemize |
| 5201 | @item QtLockedFile: A class that extends QFile with advisory locking functions. |
| 5202 | @item QtPropertyBrowser: A framework that enables the user to edit a set of |
| 5203 | properties. |
| 5204 | @item QtService: A helper for writing services such as Unix daemons. |
| 5205 | @item QtSingleApplication: A component that provides support for applications |
| 5206 | that can be only started once per user. |
| 5207 | @item QtSoap: A component that provides basic web service support with version |
| 5208 | 1.1 of the SOAP protocol. |
| 5209 | @end itemize\n") |
| 5210 | (home-page "https://doc.qt.io/archives/qq/qq09-qt-solutions.html") |
| 5211 | (license (list license:bsd-3 |
| 5212 | ;; QScriptParser and QScriptGrammar specifically allow |
| 5213 | ;; redistribution under GPL3 or LGPL2.1 |
| 5214 | license:gpl3 license:lgpl2.1))))) |
| 5215 | |
| 5216 | (define-public qwindowkit |
| 5217 | (package |
| 5218 | (name "qwindowkit") |
| 5219 | (version "1.5.0") |
| 5220 | (source (origin |
| 5221 | (method git-fetch) |
| 5222 | (uri (git-reference |
| 5223 | (url "https://github.com/stdware/qwindowkit") |
| 5224 | (commit version))) |
| 5225 | (file-name (git-file-name name version)) |
| 5226 | (sha256 |
| 5227 | (base32 |
| 5228 | "1h9w6abdnf5yyyga54caxwn4vihim1400gw3rv8bgf2b7w53chpw")))) |
| 5229 | (build-system cmake-build-system) |
| 5230 | (arguments |
| 5231 | (list #:tests? #f ;no test suite |
| 5232 | #:configure-flags |
| 5233 | #~(list "-DQWINDOWKIT_BUILD_QUICK=ON"))) ;required by Jami |
| 5234 | (native-inputs (list qmsetup)) |
| 5235 | (inputs (list qtbase qtdeclarative)) |
| 5236 | (home-page "https://github.com/stdware/qwindowkit") |
| 5237 | (synopsis "Frameless window framework for Qt") |
| 5238 | (description "QWindowKit is a cross-platform window customization |
| 5239 | framework for Qt Widgets and Qt Quick.") |
| 5240 | (license license:asl2.0))) |
| 5241 | |
| 5242 | (define-public qwt |
| 5243 | (package |
| 5244 | (name "qwt") |
| 5245 | (version "6.1.5") |
| 5246 | (source |
| 5247 | (origin |
| 5248 | (method url-fetch) |
| 5249 | (uri |
| 5250 | (string-append "mirror://sourceforge/qwt/qwt/" |
| 5251 | version "/qwt-" version ".tar.bz2")) |
| 5252 | (sha256 |
| 5253 | (base32 "0hf0mpca248xlqn7xnzkfj8drf19gdyg5syzklvq8pibxiixwxj0")))) |
| 5254 | (build-system gnu-build-system) |
| 5255 | (inputs |
| 5256 | (list qtbase-5 qtsvg-5 qttools-5)) |
| 5257 | (arguments |
| 5258 | `(#:phases |
| 5259 | (modify-phases %standard-phases |
| 5260 | (replace 'configure |
| 5261 | (lambda* (#:key outputs #:allow-other-keys) |
| 5262 | (let* ((out (assoc-ref outputs "out")) |
| 5263 | (docdir (string-append out "/share/doc/qwt")) |
| 5264 | (incdir (string-append out "/include/qwt")) |
| 5265 | (pluginsdir (string-append out "/lib/qt5/plugins/designer")) |
| 5266 | (featuresdir (string-append out "/lib/qt5/mkspecs/features"))) |
| 5267 | (substitute* '("qwtconfig.pri") |
| 5268 | (("^(\\s*QWT_INSTALL_PREFIX)\\s*=.*" _ x) |
| 5269 | (format #f "~a = ~a\n" x out)) |
| 5270 | (("^(QWT_INSTALL_DOCS)\\s*=.*" _ x) |
| 5271 | (format #f "~a = ~a\n" x docdir)) |
| 5272 | (("^(QWT_INSTALL_HEADERS)\\s*=.*" _ x) |
| 5273 | (format #f "~a = ~a\n" x incdir)) |
| 5274 | (("^(QWT_INSTALL_PLUGINS)\\s*=.*" _ x) |
| 5275 | (format #f "~a = ~a\n" x pluginsdir)) |
| 5276 | (("^(QWT_INSTALL_FEATURES)\\s*=.*" _ x) |
| 5277 | (format #f "~a = ~a\n" x featuresdir))) |
| 5278 | (substitute* '("doc/doc.pro") |
| 5279 | ;; We'll install them in the 'install-man-pages' phase. |
| 5280 | (("^unix:doc\\.files.*") "")) |
| 5281 | (invoke "qmake")))) |
| 5282 | (add-after 'install 'install-man-pages |
| 5283 | (lambda* (#:key outputs #:allow-other-keys) |
| 5284 | (let* ((out (assoc-ref outputs "out")) |
| 5285 | (man (string-append out "/share/man"))) |
| 5286 | ;; Remove some incomplete manual pages. |
| 5287 | (for-each delete-file (find-files "doc/man/man3" "^_tmp.*")) |
| 5288 | (mkdir-p man) |
| 5289 | (copy-recursively "doc/man" man))))))) |
| 5290 | (home-page "https://qwt.sourceforge.net") |
| 5291 | (synopsis "Qt widgets for plots, scales, dials and other technical software |
| 5292 | GUI components") |
| 5293 | (description |
| 5294 | "The Qwt library contains widgets and components which are primarily useful |
| 5295 | for technical and scientific purposes. It includes a 2-D plotting widget, |
| 5296 | different kinds of sliders, and much more.") |
| 5297 | (license |
| 5298 | (list |
| 5299 | ;; The Qwt license is LGPL2.1 with some exceptions. |
| 5300 | (license:non-copyleft "http://qwt.sourceforge.net/qwtlicense.html") |
| 5301 | ;; textengines/mathml/qwt_mml_document.{cpp,h} is dual LGPL2.1/GPL3 (either). |
| 5302 | license:lgpl2.1 license:gpl3)))) |
| 5303 | |
| 5304 | (define-public jkqtplotter |
| 5305 | (let ((revision "0") |
| 5306 | ;; This is the tag v5.0.0-beta2. |
| 5307 | (commit "b8cc2909f2498f7bb3ee1830151b3dc71bcf6375")) |
| 5308 | (package |
| 5309 | (name "jkqtplotter") |
| 5310 | (version (git-version "4.0.3" revision commit)) |
| 5311 | (source |
| 5312 | (origin |
| 5313 | (method git-fetch) |
| 5314 | (uri (git-reference |
| 5315 | (url "https://github.com/jkriege2/JKQtPlotter") |
| 5316 | (commit commit))) |
| 5317 | (file-name (git-file-name name version)) |
| 5318 | (sha256 |
| 5319 | (base32 "0lv202l9jg80z9ddn3ylkvgh4v3kwg8g0f4r1ydvd0xnnl6rijpq")))) |
| 5320 | (build-system qt-build-system) |
| 5321 | (inputs (list opencv qtsvg)) |
| 5322 | (arguments |
| 5323 | (list |
| 5324 | #:qtbase qtbase |
| 5325 | #:tests? #f ;no tests |
| 5326 | #:phases |
| 5327 | #~(modify-phases %standard-phases |
| 5328 | (add-after 'install 'delete-broken-binaries |
| 5329 | (lambda _ |
| 5330 | (delete-file-recursively (string-append #$output "/bin"))))))) |
| 5331 | (home-page "https://jkriege2.github.io/JKQtPlotter/index.html") |
| 5332 | (synopsis "Qt Plotting Library") |
| 5333 | (description |
| 5334 | "JKQTPlotter is a library of function and data plotter classes for Qt. |
| 5335 | It includes a plotter widget and a LaTeX equation renderer and supports |
| 5336 | a variety of graphs and charts.") |
| 5337 | (license license:lgpl2.1+)))) |
| 5338 | |
| 5339 | (define-public dotherside |
| 5340 | (package |
| 5341 | (name "dotherside") |
| 5342 | (version "0.9.0") |
| 5343 | (source |
| 5344 | (origin |
| 5345 | (method git-fetch) |
| 5346 | (uri (git-reference |
| 5347 | (url "https://github.com/filcuc/DOtherSide") |
| 5348 | (commit (string-append "v" version)))) |
| 5349 | (file-name (git-file-name name version)) |
| 5350 | (sha256 |
| 5351 | (base32 |
| 5352 | "13n2qb8q9jz4ihwlbs7y15lw90w9113gb1bgnb1dggpxkj64r953")))) |
| 5353 | (build-system cmake-build-system) |
| 5354 | (arguments (list #:tests? #f)) |
| 5355 | (native-inputs |
| 5356 | (list qttools-5)) |
| 5357 | (inputs |
| 5358 | ;; TODO: Support Qt 6 (requires qtdeclarative of Qt6). |
| 5359 | (list qtbase-5 qtdeclarative-5)) |
| 5360 | (home-page "https://filcuc.github.io/DOtherSide/index.html") |
| 5361 | (synopsis "C language library for creating bindings for the Qt QML language") |
| 5362 | (description |
| 5363 | "DOtherSide is a C language library for creating bindings for the |
| 5364 | QT QML language. The following features are implementable from |
| 5365 | a binding language: |
| 5366 | @itemize |
| 5367 | @item Creating custom QObject |
| 5368 | @item Creating custom QAbstractListModels |
| 5369 | @item Creating custom properties, signals and slots |
| 5370 | @item Creating from QML QObject defined in the binded language |
| 5371 | @item Creating from Singleton QML QObject defined in the binded language |
| 5372 | @end itemize\n") |
| 5373 | (license license:lgpl3))) ;version 3 only (+ exception) |
| 5374 | |
| 5375 | (define-public qcodeeditor |
| 5376 | (let ((commit "dc644d41b68978ab9a5591ba891a223221570e74") ;no tags |
| 5377 | (revision "0")) |
| 5378 | (package |
| 5379 | (name "qcodeeditor") |
| 5380 | (version (git-version "0" revision commit)) |
| 5381 | (source (origin |
| 5382 | (method git-fetch) |
| 5383 | (uri (git-reference |
| 5384 | (url "https://github.com/Megaxela/QCodeEditor") |
| 5385 | (commit commit))) |
| 5386 | (file-name (git-file-name name version)) |
| 5387 | (sha256 |
| 5388 | (base32 |
| 5389 | "1bpvfwbgp275w79dzrd7d9k3md1ch7n88rh59mxdfj8s911n42j8")) |
| 5390 | (patches |
| 5391 | (search-patches |
| 5392 | "qcodeeditor-qt6.patch" |
| 5393 | "qcodeeditor-fix-build-with-c++17.patch")))) |
| 5394 | (build-system qt-build-system) |
| 5395 | (arguments |
| 5396 | (list #:qtbase qtbase |
| 5397 | #:tests? #f ;no tests |
| 5398 | #:configure-flags |
| 5399 | #~(list "-DBUILD_EXAMPLE=ON" |
| 5400 | (string-append "-DCMAKE_EXE_LINKER_FLAGS=-Wl,-rpath=" |
| 5401 | #$output "/lib")) |
| 5402 | #:phases |
| 5403 | #~(modify-phases %standard-phases |
| 5404 | (add-after 'unpack 'build-shared-library |
| 5405 | (lambda _ |
| 5406 | (substitute* "CMakeLists.txt" |
| 5407 | (("STATIC") "SHARED")))) |
| 5408 | ;; Install rule does not exist. |
| 5409 | (replace 'install |
| 5410 | (lambda _ |
| 5411 | (install-file "example/QCodeEditorExample" |
| 5412 | (string-append #$output "/bin")) |
| 5413 | (install-file "libQCodeEditor.so" |
| 5414 | (string-append #$output "/lib")) |
| 5415 | (for-each |
| 5416 | (lambda (file) |
| 5417 | (install-file file |
| 5418 | (string-append #$output |
| 5419 | "/include/QCodeEditor"))) |
| 5420 | (find-files "../source/include/internal" "\\.hpp"))))))) |
| 5421 | (inputs |
| 5422 | (list qtwayland)) |
| 5423 | (home-page "https://github.com/Megaxela/QCodeEditor") |
| 5424 | (synopsis "Qt code editor widget") |
| 5425 | (description |
| 5426 | "QCodeEditor is a Qt widget for editing/viewing code.") |
| 5427 | (license license:expat)))) |
| 5428 | |
| 5429 | (define-public qt-advanced-docking-system |
| 5430 | (package |
| 5431 | (name "qt-advanced-docking-system") |
| 5432 | (version "4.4.1") |
| 5433 | (source |
| 5434 | (origin |
| 5435 | (method git-fetch) |
| 5436 | (uri |
| 5437 | (git-reference |
| 5438 | (url "https://github.com/githubuser0xFFFF/Qt-Advanced-Docking-System") |
| 5439 | (commit version))) |
| 5440 | (file-name (git-file-name name version)) |
| 5441 | (sha256 |
| 5442 | (base32 "07qhvhz4cmkrpxpfmybva57ddshkwf993jiryxg3lkj24p1rlh7d")))) |
| 5443 | (build-system qt-build-system) |
| 5444 | (arguments |
| 5445 | (list #:qtbase qtbase |
| 5446 | #:tests? #f ;no tests |
| 5447 | #:configure-flags |
| 5448 | #~(list ;; Examples require qtdeclarative. |
| 5449 | "-DBUILD_EXAMPLES=OFF" |
| 5450 | (string-append "-DADS_VERSION=" #$version)))) |
| 5451 | (home-page "https://github.com/githubuser0xFFFF/Qt-Advanced-Docking-System") |
| 5452 | (synopsis "Advanced docking system for Qt") |
| 5453 | (description |
| 5454 | "Qt Advanced Docking System lets you create customizable layouts using a |
| 5455 | window docking system.") |
| 5456 | (license license:lgpl2.1+))) |
| 5457 | |
| 5458 | (define-public qtpromise |
| 5459 | (package |
| 5460 | (name "qtpromise") |
| 5461 | (version "0.7.0") |
| 5462 | (source (origin |
| 5463 | (method git-fetch) |
| 5464 | (uri (git-reference |
| 5465 | (url "https://github.com/simonbrunel/qtpromise") |
| 5466 | (commit (string-append "v" version)))) |
| 5467 | (file-name (git-file-name name version)) |
| 5468 | (sha256 |
| 5469 | (base32 |
| 5470 | "0nsh6v5k4kdrrhcd6adz947n0dka4rrbx8f8rvm1175545nbi67s")))) |
| 5471 | (build-system qt-build-system) |
| 5472 | (arguments |
| 5473 | (list #:phases |
| 5474 | #~(modify-phases %standard-phases |
| 5475 | (add-before 'install 'fix-include-path |
| 5476 | (lambda _ |
| 5477 | (chdir "../source") |
| 5478 | (substitute* "../source/include/QtPromise" |
| 5479 | (("../src/") "")))) |
| 5480 | (replace 'install |
| 5481 | (lambda _ |
| 5482 | (let ((include (string-append #$output "/include"))) |
| 5483 | (with-directory-excursion "../source" |
| 5484 | (install-file "include/QtPromise" |
| 5485 | (string-append include)) |
| 5486 | (copy-recursively "src/qtpromise" |
| 5487 | (string-append include |
| 5488 | "/qtpromise"))))))))) |
| 5489 | (home-page "https://qtpromise.netlify.app/") |
| 5490 | (synopsis "Promises/A+ implementation for Qt/C++") |
| 5491 | (description |
| 5492 | "This package provides a Qt/C++ implementation of |
| 5493 | @url{Promises/A+,https://promisesaplus.com/} standard for the ``promises'' |
| 5494 | programming paradigm.") |
| 5495 | (license license:expat))) |
| 5496 | |
| 5497 | (define-public qtwidgetanimationframework |
| 5498 | (let ((commit "b07ab59cee7a21eb29d29cb67c160681f13ac5ae") ;no tags |
| 5499 | (revision "0")) |
| 5500 | (package |
| 5501 | (name "qtwidgetanimationframework") |
| 5502 | (version (git-version "0" revision commit)) |
| 5503 | (source |
| 5504 | (origin |
| 5505 | (method git-fetch) |
| 5506 | (uri |
| 5507 | (git-reference |
| 5508 | (url "https://github.com/dimkanovikov/WidgetAnimationFramework") |
| 5509 | (commit commit))) |
| 5510 | (file-name (git-file-name name version)) |
| 5511 | (sha256 |
| 5512 | (base32 "1smbdrzk05vvbf6lpjdq82k4y2kc4yv1gk5388qbslbzlb6ihls6")))) |
| 5513 | (build-system qt-build-system) |
| 5514 | (arguments |
| 5515 | (list #:qtbase qtbase |
| 5516 | #:tests? #f ;no tests |
| 5517 | #:modules '((guix build qt-build-system) |
| 5518 | ((guix build gnu-build-system) #:prefix gnu:) |
| 5519 | (guix build utils)) |
| 5520 | #:phases |
| 5521 | #~(modify-phases %standard-phases |
| 5522 | ;; This project does not have any build rule but its demo has |
| 5523 | ;; one. |
| 5524 | (add-after 'unpack 'pre-configure |
| 5525 | (lambda _ |
| 5526 | (copy-file "demo/waf-demo.pro" "src/waf.pro") |
| 5527 | (substitute* "src/waf.pro" |
| 5528 | (("main.cpp ") "") |
| 5529 | (("app") "lib") |
| 5530 | (("waf-demo") "waf")) |
| 5531 | (chdir "src"))) |
| 5532 | ;; No configure script exists. |
| 5533 | (replace 'configure |
| 5534 | (lambda _ |
| 5535 | (invoke "qmake"))) |
| 5536 | (replace 'build (assoc-ref gnu:%standard-phases 'build)) |
| 5537 | ;; No install rule exists. |
| 5538 | (replace 'install |
| 5539 | (lambda _ |
| 5540 | ;; Install library files. |
| 5541 | (for-each |
| 5542 | (lambda (file) |
| 5543 | (install-file file |
| 5544 | (string-append #$output "/lib/" |
| 5545 | (dirname file)))) |
| 5546 | (find-files "." "\\.so")) |
| 5547 | ;; Install header files. |
| 5548 | (for-each |
| 5549 | (lambda (file) |
| 5550 | (install-file file |
| 5551 | (string-append #$output "/include/WAF/" |
| 5552 | (dirname file)))) |
| 5553 | (find-files "." "\\.h$"))))))) |
| 5554 | (home-page "https://github.com/dimkanovikov/WidgetAnimationFramework") |
| 5555 | (synopsis "Extension for animating Qt widgets") |
| 5556 | (description |
| 5557 | "@acronym{WAF,Widget Animation Framework} is an extension for animating |
| 5558 | Qt widgets.") |
| 5559 | (license license:lgpl3+)))) |
| 5560 | |
| 5561 | (define-public qtcolorwidgets |
| 5562 | (let ((commit "8491078434b24cba295b5e41cc0d2a94c7049a5b") |
| 5563 | (revision "1")) |
| 5564 | (package |
| 5565 | (name "qtcolorwidgets") |
| 5566 | (version (git-version "2.2.0" revision commit)) |
| 5567 | (source |
| 5568 | (origin |
| 5569 | (method git-fetch) |
| 5570 | (uri (git-reference |
| 5571 | (url "https://gitlab.com/mattbas/Qt-Color-Widgets") |
| 5572 | (commit commit))) |
| 5573 | (file-name (git-file-name name version)) |
| 5574 | (sha256 |
| 5575 | (base32 |
| 5576 | "1ixb2v5mjdszkxqq51knaj1pcivnihwlj9qlm9pxmvzl9qsvbcgg")))) |
| 5577 | (build-system cmake-build-system) |
| 5578 | (arguments |
| 5579 | (list #:tests? #f ;there are no tests |
| 5580 | #:configure-flags #~(list "-DQT_VERSION_MAJOR=6"))) |
| 5581 | (native-inputs (list qttools)) |
| 5582 | (inputs (list qtbase)) |
| 5583 | (home-page "https://gitlab.com/mattbas/Qt-Color-Widgets") |
| 5584 | (synopsis "Color management widgets") |
| 5585 | (description "QtColorWidgets provides a Qt color dialog that is more |
| 5586 | user-friendly than the default @code{QColorDialog} and several other |
| 5587 | color-related widgets.") |
| 5588 | ;; Includes a license exception for combining with GPL2 code. |
| 5589 | (license license:lgpl3+)))) |
| 5590 | |
| 5591 | (define-public qcustomplot |
| 5592 | (package |
| 5593 | (name "qcustomplot") |
| 5594 | (version "2.1.1") |
| 5595 | (source |
| 5596 | (origin |
| 5597 | (method url-fetch) |
| 5598 | (uri (string-append "https://www.qcustomplot.com/release/" |
| 5599 | version "/QCustomPlot.tar.gz")) |
| 5600 | (sha256 |
| 5601 | (base32 "0aiixk36v1534429yndn2phn7q7m2rvkh81hn7awin4b1vkidz4s")))) |
| 5602 | (native-inputs |
| 5603 | `(("qcustomplot-sharedlib" |
| 5604 | ,(origin |
| 5605 | (method url-fetch) |
| 5606 | (uri (string-append "https://www.qcustomplot.com/release/" |
| 5607 | version "/QCustomPlot-sharedlib.tar.gz")) |
| 5608 | (sha256 |
| 5609 | (base32 "1h5l29q82grz94z5ch95vq6hs5clcymbcb3yngqfsh47gsffmmim")))))) |
| 5610 | (inputs |
| 5611 | (list qtbase)) |
| 5612 | (build-system gnu-build-system) |
| 5613 | (arguments |
| 5614 | `(#:phases |
| 5615 | (modify-phases %standard-phases |
| 5616 | (add-after 'unpack 'unpack-extra-files |
| 5617 | (lambda* (#:key inputs #:allow-other-keys) |
| 5618 | (invoke "tar" "-xvf" (assoc-ref inputs "qcustomplot-sharedlib")))) |
| 5619 | (replace 'configure |
| 5620 | (lambda* (#:key outputs #:allow-other-keys) |
| 5621 | (chdir "qcustomplot-sharedlib/sharedlib-compilation") |
| 5622 | (substitute* "sharedlib-compilation.pro" |
| 5623 | ;; Don't build debug library. |
| 5624 | (("debug_and_release") |
| 5625 | "release")) |
| 5626 | (invoke "qmake" |
| 5627 | (string-append "DESTDIR=" |
| 5628 | (assoc-ref outputs "out") |
| 5629 | "/lib")))) |
| 5630 | (add-after 'install 'install-header |
| 5631 | (lambda* (#:key outputs #:allow-other-keys) |
| 5632 | (install-file "../../qcustomplot.h" |
| 5633 | (string-append (assoc-ref outputs "out") |
| 5634 | "/include"))))))) |
| 5635 | (home-page "https://www.qcustomplot.com/") |
| 5636 | (synopsis "Qt widget for plotting and data visualization") |
| 5637 | (description |
| 5638 | "QCustomPlot is a Qt C++ widget providing 2D plots, graphs and charts.") |
| 5639 | (license license:gpl3+))) |
| 5640 | |
| 5641 | (define-public qcustomplot-qt5 |
| 5642 | (package/inherit qcustomplot |
| 5643 | (name "qcustomplot-qt5") |
| 5644 | (inputs |
| 5645 | (modify-inputs inputs |
| 5646 | (replace "qtbase" qtbase-5))))) |
| 5647 | |
| 5648 | (define-public python-shiboken-6 |
| 5649 | (package |
| 5650 | (name "python-shiboken-6") |
| 5651 | (version "6.9.2") |
| 5652 | (source (origin |
| 5653 | (method url-fetch) |
| 5654 | (uri (string-append "mirror://qt/QtForPython/pyside6/PySide6-" |
| 5655 | version "-src/pyside-setup-everywhere-src-" |
| 5656 | version ".tar.xz")) |
| 5657 | (sha256 |
| 5658 | (base32 |
| 5659 | "0b92b4zi5rqg5acgbb6yan349idvzmc0x8wjwkdwkga2ad38gh4y")))) |
| 5660 | (build-system cmake-build-system) |
| 5661 | (inputs |
| 5662 | (list clang-18 |
| 5663 | libxml2 |
| 5664 | libxslt |
| 5665 | python-wrapper |
| 5666 | qtbase)) |
| 5667 | (properties `((upstream-name . "pyside-setup"))) |
| 5668 | (arguments |
| 5669 | (list |
| 5670 | #:tests? #f |
| 5671 | ;; FIXME: Building tests fails |
| 5672 | #:imported-modules (append %cmake-build-system-modules |
| 5673 | %pyproject-build-system-modules) |
| 5674 | #:modules '((guix build cmake-build-system) |
| 5675 | ((guix build pyproject-build-system) #:prefix py:) |
| 5676 | (guix build utils)) |
| 5677 | #:configure-flags #~(list |
| 5678 | ;; The RUNPATH of shibokenmodule contains the entry |
| 5679 | ;; in build directory instead of install directory. |
| 5680 | "-DCMAKE_SKIP_RPATH=TRUE" |
| 5681 | (string-append "-DCMAKE_MODULE_LINKER_FLAGS=-Wl,-rpath=" |
| 5682 | #$output "/lib") |
| 5683 | "-DBUILD_TESTS=off") |
| 5684 | #:phases |
| 5685 | #~(modify-phases %standard-phases |
| 5686 | (add-after 'unpack 'use-shiboken-dir-only |
| 5687 | (lambda _ (chdir "sources/shiboken6"))) |
| 5688 | ;; .dist-info in site-packages is necessary for sanity-check. |
| 5689 | (add-after 'install 'install-distinfo |
| 5690 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 5691 | (with-directory-excursion (py:site-packages inputs outputs) |
| 5692 | (for-each |
| 5693 | (lambda (name) |
| 5694 | (let ((dir (string-append name "-" #$version ".dist-info"))) |
| 5695 | (mkdir-p dir) |
| 5696 | (call-with-output-file (string-append dir "/METADATA") |
| 5697 | (lambda (port) |
| 5698 | (format port "\ |
| 5699 | Metadata-Version: 1.1 |
| 5700 | Name: ~a |
| 5701 | Version: ~a~%" name #$version))))) |
| 5702 | (list "shiboken6" "shiboken6_generator"))))) |
| 5703 | ;; The build scripts need to modify some files in |
| 5704 | ;; the read-only source directory. |
| 5705 | (add-before 'configure 'make-files-writable |
| 5706 | (lambda _ |
| 5707 | (for-each make-file-writable (find-files ".")))) |
| 5708 | ;; the Zip format does not support timestamps before 1980. |
| 5709 | (add-after 'make-files-writable 'ensure-no-mtimes-pre-1980 |
| 5710 | (assoc-ref py:%standard-phases 'ensure-no-mtimes-pre-1980)) |
| 5711 | (add-before 'configure 'set-build-env |
| 5712 | (lambda _ |
| 5713 | (let ((llvm #$(this-package-input "clang"))) |
| 5714 | (setenv "CLANG_INSTALL_DIR" llvm)) |
| 5715 | ;; Use Clang instead of GCC. |
| 5716 | (setenv "AR" "llvm-ar") |
| 5717 | (setenv "NM" "llvm-nm") |
| 5718 | (setenv "CC" "clang") |
| 5719 | (setenv "CXX" "clang++")))))) |
| 5720 | (home-page "https://wiki.qt.io/Qt_for_Python") |
| 5721 | (synopsis |
| 5722 | "Shiboken generates bindings for C++ libraries using CPython source code") |
| 5723 | (description |
| 5724 | "Shiboken generates bindings for C++ libraries using CPython source code") |
| 5725 | (license |
| 5726 | (list |
| 5727 | ;; The main code is GPL3 or LGPL3. |
| 5728 | ;; Examples are BSD-3. |
| 5729 | license:gpl3 |
| 5730 | license:lgpl3 |
| 5731 | license:bsd-3)))) |
| 5732 | |
| 5733 | (define-public python-pyside-6 |
| 5734 | (package |
| 5735 | (name "python-pyside-6") |
| 5736 | (version (package-version python-shiboken-6)) |
| 5737 | (source (package-source python-shiboken-6)) |
| 5738 | (build-system cmake-build-system) |
| 5739 | ;; TODO: Add more Qt components if available. |
| 5740 | (inputs |
| 5741 | (list qtbase |
| 5742 | qtdeclarative |
| 5743 | qtmultimedia |
| 5744 | qtnetworkauth |
| 5745 | qtpositioning |
| 5746 | qtsvg |
| 5747 | qttools |
| 5748 | qtwebchannel |
| 5749 | qtwebengine |
| 5750 | qtwebsockets)) |
| 5751 | (propagated-inputs |
| 5752 | (list python-shiboken-6)) |
| 5753 | (native-inputs |
| 5754 | (list python-wrapper)) |
| 5755 | (arguments |
| 5756 | (list |
| 5757 | #:tests? #f |
| 5758 | #:imported-modules (append %cmake-build-system-modules |
| 5759 | %pyproject-build-system-modules) |
| 5760 | #:modules '((guix build cmake-build-system) |
| 5761 | ((guix build pyproject-build-system) #:prefix py:) |
| 5762 | (guix build utils) |
| 5763 | (ice-9 match) |
| 5764 | (srfi srfi-1)) |
| 5765 | #:configure-flags |
| 5766 | #~(list "-DBUILD_TESTS=FALSE" |
| 5767 | (string-append "-DPYTHON_EXECUTABLE=" |
| 5768 | (search-input-file %build-inputs "/bin/python"))) |
| 5769 | #:phases |
| 5770 | #~(modify-phases %standard-phases |
| 5771 | (add-after 'unpack 'go-to-source-dir |
| 5772 | (lambda _ (chdir "sources/pyside6"))) |
| 5773 | ;; .dist-info in site-packages is necessary for sanity-check. |
| 5774 | (add-after 'install 'install-distinfo |
| 5775 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 5776 | (with-directory-excursion (py:site-packages inputs outputs) |
| 5777 | (let ((dir (string-append "PySide6-" #$version ".dist-info"))) |
| 5778 | (mkdir-p dir) |
| 5779 | (call-with-output-file (string-append dir "/METADATA") |
| 5780 | (lambda (port) |
| 5781 | (format port "\ |
| 5782 | Metadata-Version: 1.1 |
| 5783 | Name: PySide6 |
| 5784 | Version: ~a |
| 5785 | Requires-Dist: shiboken6==~a~%" #$version #$version))))))) |
| 5786 | (add-after 'go-to-source-dir 'set-rpath |
| 5787 | (lambda _ |
| 5788 | (substitute* "CMakeLists.txt" |
| 5789 | (("CMAKE_INSTALL_RPATH") |
| 5790 | (string-append "CMAKE_INSTALL_RPATH " #$output "/lib"))))) |
| 5791 | (add-after 'go-to-source-dir 'fix-qt-module-detection |
| 5792 | (lambda* (#:key inputs #:allow-other-keys) |
| 5793 | (substitute* "cmake/PySideHelpers.cmake" |
| 5794 | (("\\(\"\\$\\{found_basepath\\}\" GREATER \"0\"\\)") |
| 5795 | "true")) |
| 5796 | (define (search-input-directories dir) |
| 5797 | (filter-map |
| 5798 | (match-lambda |
| 5799 | ((name . directory) |
| 5800 | (and (directory-exists? directory) |
| 5801 | (string-append directory "/" dir)))) |
| 5802 | inputs)) |
| 5803 | (let ((dirs (search-input-directories "include/qt6"))) |
| 5804 | (substitute* "cmake/Macros/PySideModules.cmake" |
| 5805 | (("set\\(shiboken_include_dir_list " all) |
| 5806 | (string-append all (string-join dirs ";") " "))) |
| 5807 | (setenv "CXXFLAGS" |
| 5808 | (string-join |
| 5809 | (map (lambda (dir) |
| 5810 | (string-append "-I" dir)) |
| 5811 | dirs) |
| 5812 | " ")))))))) |
| 5813 | (home-page "https://wiki.qt.io/Qt_for_Python") |
| 5814 | (synopsis |
| 5815 | "The Qt for Python product enables the use of Qt6 APIs in Python applications") |
| 5816 | (description |
| 5817 | "The Qt for Python product enables the use of Qt6 APIs in Python |
| 5818 | applications. It lets Python developers utilize the full potential of Qt, |
| 5819 | using the PySide6 module. The PySide6 module provides access to the |
| 5820 | individual Qt modules such as QtCore, QtGui,and so on. Qt for Python also |
| 5821 | comes with the Shiboken6 CPython binding code generator, which can be used to |
| 5822 | generate Python bindings for your C or C++ code.") |
| 5823 | (license (list |
| 5824 | license:lgpl3 |
| 5825 | ;;They state that: |
| 5826 | ;; this file may be used under the terms of the GNU General |
| 5827 | ;; Public License version 2.0 or (at your option) the GNU |
| 5828 | ;; General Public license version 3 or any later version |
| 5829 | ;; approved by the KDE Free Qt Foundation. |
| 5830 | ;; Thus, it is currently v2 or v3, but no "+". |
| 5831 | license:gpl3 |
| 5832 | license:gpl2)))) |
| 5833 | |
| 5834 | (define-public libqglviewer |
| 5835 | (package |
| 5836 | (name "libqglviewer") |
| 5837 | (version "2.7.2") |
| 5838 | (source (origin |
| 5839 | (method url-fetch) |
| 5840 | (uri |
| 5841 | (string-append "http://libqglviewer.com/src/libQGLViewer-" |
| 5842 | version ".tar.gz")) |
| 5843 | (sha256 |
| 5844 | (base32 |
| 5845 | "023w7da1fyn2z69nbkp2rndiv886zahmc5cmira79zswxjfpklp2")))) |
| 5846 | (build-system gnu-build-system) |
| 5847 | (arguments |
| 5848 | '(#:tests? #f ; no check target |
| 5849 | #:make-flags |
| 5850 | (list (string-append "PREFIX=" |
| 5851 | (assoc-ref %outputs "out"))) |
| 5852 | #:phases |
| 5853 | (modify-phases %standard-phases |
| 5854 | (replace 'configure |
| 5855 | (lambda* (#:key make-flags #:allow-other-keys) |
| 5856 | (apply invoke (cons "qmake" make-flags))))))) |
| 5857 | (native-inputs |
| 5858 | (list qtbase-5 qttools-5)) |
| 5859 | (inputs |
| 5860 | (list glu)) |
| 5861 | (home-page "https://libqglviewer.com") |
| 5862 | (synopsis "Qt-based C++ library for the creation of OpenGL 3D viewers") |
| 5863 | (description |
| 5864 | "@code{libQGLViewer} is a C++ library based on Qt that eases the creation |
| 5865 | of OpenGL 3D viewers. |
| 5866 | |
| 5867 | It provides some of the typical 3D viewer functionalities, such as the |
| 5868 | possibility to move the camera using the mouse, which lacks in most of the |
| 5869 | other APIs. Other features include mouse manipulated frames, interpolated |
| 5870 | keyFrames, object selection, stereo display, screenshot saving and much more. |
| 5871 | It can be used by OpenGL beginners as well as to create complex applications, |
| 5872 | being fully customizable and easy to extend.") |
| 5873 | ;; According to LICENSE, either version 2 or version 3 of the GNU GPL may |
| 5874 | ;; be used. |
| 5875 | (license (list license:gpl2 license:gpl3)))) |
| 5876 | |
| 5877 | (define-public qhexedit |
| 5878 | (package |
| 5879 | (name "qhexedit") |
| 5880 | (version "0.8.9") |
| 5881 | (source |
| 5882 | (origin |
| 5883 | (method git-fetch) |
| 5884 | (uri (git-reference |
| 5885 | (url "https://github.com/Simsys/qhexedit2") |
| 5886 | (commit (string-append "v" version)))) |
| 5887 | (file-name (git-file-name name version)) |
| 5888 | (sha256 |
| 5889 | (base32 "1j333kiwhbidphdx86yilkaivgl632spfh6fqx93bc80gk4is3xa")))) |
| 5890 | (build-system gnu-build-system) |
| 5891 | (arguments |
| 5892 | `(#:phases |
| 5893 | (modify-phases %standard-phases |
| 5894 | (add-after 'unpack 'fix-path |
| 5895 | (lambda* (#:key outputs #:allow-other-keys) |
| 5896 | (substitute* "src/qhexedit.pro" |
| 5897 | (("^unix:DESTDIR = /usr/lib") |
| 5898 | (string-append "unix:DESTDIR = " |
| 5899 | (assoc-ref outputs "out") "/lib"))))) |
| 5900 | (replace 'configure |
| 5901 | (lambda _ |
| 5902 | (chdir "src") |
| 5903 | (invoke "qmake" "qhexedit.pro"))) |
| 5904 | (add-after 'install 'install-headers |
| 5905 | (lambda* (#:key outputs #:allow-other-keys) |
| 5906 | (let* ((out (assoc-ref outputs "out")) |
| 5907 | (include-dir (string-append out "/include"))) |
| 5908 | (mkdir-p include-dir) |
| 5909 | (for-each (lambda (file) |
| 5910 | (install-file file include-dir)) |
| 5911 | (find-files "." "\\.h$")))))))) |
| 5912 | (inputs (list qtbase-5)) |
| 5913 | (native-inputs (list qttools-5)) |
| 5914 | (home-page "https://simsys.github.io") |
| 5915 | (synopsis "Binary editor widget for Qt") |
| 5916 | (description |
| 5917 | "@code{QHexEdit} is a hex editor widget for the Qt framework. It is a |
| 5918 | simple editor for binary data, just like @code{QPlainTextEdit} is for text |
| 5919 | data.") |
| 5920 | (license license:lgpl2.1))) |
| 5921 | |
| 5922 | (define-public qhotkey |
| 5923 | (package |
| 5924 | (name "qhotkey") |
| 5925 | (version "1.5.0") |
| 5926 | (source |
| 5927 | (origin |
| 5928 | (method git-fetch) |
| 5929 | (uri (git-reference |
| 5930 | (url "https://github.com/Skycoder42/QHotkey") |
| 5931 | (commit version))) |
| 5932 | (file-name (git-file-name name version)) |
| 5933 | (sha256 |
| 5934 | (base32 "0glzh4l532xk4v9mphsdf96v1557pyvg5al3ha0vr3244bfh9hcf")))) |
| 5935 | (build-system cmake-build-system) |
| 5936 | (arguments |
| 5937 | (list #:tests? #f ;no tests |
| 5938 | #:configure-flags |
| 5939 | #~(list "-DQT_DEFAULT_MAJOR_VERSION=6" |
| 5940 | "-DBUILD_SHARED_LIBS=ON" |
| 5941 | "-DQHOTKEY_EXAMPLES=ON"))) |
| 5942 | (inputs (list libx11 qtbase)) |
| 5943 | (home-page "https://github.com/Skycoder42/QHotkey") |
| 5944 | (synopsis "Global shortcut key for Qt desktop applications") |
| 5945 | (description |
| 5946 | "This package provides @code{QHotKey} class that can be used to create |
| 5947 | hotkeys/global shortcuts, aka shortcuts that work everywhere, independent of |
| 5948 | the application state.") |
| 5949 | (license license:bsd-3))) |
| 5950 | |
| 5951 | (define-public qthttpserver |
| 5952 | (package |
| 5953 | (name "qthttpserver") |
| 5954 | (version "6.9.2") |
| 5955 | (source (origin |
| 5956 | (method url-fetch) |
| 5957 | (uri (qt-url name version)) |
| 5958 | (sha256 |
| 5959 | (base32 |
| 5960 | "06a0f7j1b309xffw3rwydz8lpzxnf5jg67savswskzbd3lfzlhqk")))) |
| 5961 | (build-system cmake-build-system) |
| 5962 | (inputs (list qtbase)) |
| 5963 | (propagated-inputs (list qtwebsockets)) ;dependency of cmake module |
| 5964 | (home-page (package-home-page qtbase)) |
| 5965 | (synopsis "HTTP server module for Qt") |
| 5966 | (description "Qt HTTP Server supports building HTTP server functionality |
| 5967 | into an application. Common use cases are exposing the application's |
| 5968 | functionality through REST APIs, or making devices in a trusted environment |
| 5969 | configurable also via HTTP.") |
| 5970 | (license license:gpl3+))) |
| 5971 | |
| 5972 | (define-public soqt |
| 5973 | (package |
| 5974 | (name "soqt") |
| 5975 | (version "1.6.2") |
| 5976 | (source |
| 5977 | (origin |
| 5978 | (method git-fetch) |
| 5979 | (uri (git-reference |
| 5980 | (url "https://github.com/coin3d/soqt") |
| 5981 | (commit (string-append "v" version)) |
| 5982 | (recursive? #t))) |
| 5983 | (file-name (git-file-name name version)) |
| 5984 | (sha256 |
| 5985 | (base32 "0rsfc4wmghl9fr4bwh9rpzjwzsmx00k4ki5gyvy85nb4kbmr9dwv")))) |
| 5986 | (build-system cmake-build-system) |
| 5987 | (arguments '(#:tests? #f)) ; There are no tests |
| 5988 | (native-inputs |
| 5989 | (list pkg-config cmake-minimal)) |
| 5990 | (inputs |
| 5991 | (list qtbase-5 coin3d)) |
| 5992 | (home-page "https://github.com/coin3d/soqt") |
| 5993 | (synopsis "Qt GUI component toolkit library for Coin") |
| 5994 | (description "SoQt is a Qt GUI component toolkit library for Coin. It is |
| 5995 | also compatible with SGI and TGS Open Inventor, and the API is based on the API |
| 5996 | of the InventorXt GUI component toolkit.") |
| 5997 | (license license:bsd-3))) |
| 5998 | |
| 5999 | (define-public hyprland-qtutils |
| 6000 | (package |
| 6001 | (name "hyprland-qtutils") |
| 6002 | (version "0.1.5") |
| 6003 | (source (origin |
| 6004 | (method git-fetch) |
| 6005 | (uri (git-reference |
| 6006 | (url "https://github.com/hyprwm/hyprland-qtutils") |
| 6007 | (commit (string-append "v" version)))) |
| 6008 | (file-name (git-file-name name version)) |
| 6009 | (sha256 |
| 6010 | (base32 |
| 6011 | "09q8nacsxfih2px78bnallxvgr7g2z4b2dhy090sbah5siv1wdkd")))) |
| 6012 | (build-system qt-build-system) |
| 6013 | (arguments |
| 6014 | (list #:tests? #f ;There are no tests. |
| 6015 | #:qtbase qtbase)) |
| 6016 | (native-inputs (list gcc-15 pkg-config)) |
| 6017 | (inputs |
| 6018 | (list bash-minimal |
| 6019 | hyprutils |
| 6020 | kirigami |
| 6021 | libxkbcommon |
| 6022 | qqc2-desktop-style |
| 6023 | qtbase |
| 6024 | qtdeclarative |
| 6025 | qtwayland |
| 6026 | wayland)) |
| 6027 | (home-page "https://github.com/hyprwm/hyprland-qtutils") |
| 6028 | (synopsis "Hyprland QT/QML utility apps") |
| 6029 | (description |
| 6030 | "This package provides some QT/QML utilities that might be used by |
| 6031 | various hypr* apps.") |
| 6032 | (license license:bsd-3))) |
| 6033 | |
| 6034 | (define-public hyprland-qt-support |
| 6035 | (package |
| 6036 | (name "hyprland-qt-support") |
| 6037 | (version "0.1.0") |
| 6038 | (source |
| 6039 | (origin |
| 6040 | (method git-fetch) |
| 6041 | (uri (git-reference |
| 6042 | (url "https://github.com/hyprwm/hyprland-qt-support") |
| 6043 | (commit (string-append "v" version)))) |
| 6044 | (file-name (git-file-name name version)) |
| 6045 | (sha256 |
| 6046 | (base32 "0rxdj8l985bvsg3gca79jb4rf0dy066x5cmxsyyavlcp7yz6irps")))) |
| 6047 | (build-system qt-build-system) |
| 6048 | (arguments |
| 6049 | (list |
| 6050 | #:tests? #f ;There are no tests. |
| 6051 | #:qtbase qtbase |
| 6052 | #:configure-flags |
| 6053 | #~(list "-DINSTALL_QML_PREFIX=lib/qt6/qml"))) |
| 6054 | (native-inputs (list pkg-config)) |
| 6055 | (inputs (list qtbase qtdeclarative hyprlang)) |
| 6056 | (home-page "https://github.com/hyprwm/hyprland-qt-support") |
| 6057 | (synopsis "QML style provider for Hyprland applications") |
| 6058 | (description |
| 6059 | "This package provides a QML style that can be used by setting the |
| 6060 | @code{QT_QUICK_CONTROLS_STYLE} variable to the string |
| 6061 | @code{org.hyprland.style} (or passing it to @code{QQuickStyle::setStyle}).") |
| 6062 | (license license:bsd-3))) |
| 6063 | |
| 6064 | (define-public libdbusmenu-qt |
| 6065 | (package |
| 6066 | (name "libdbusmenu-qt") |
| 6067 | (version "0.9.3+16.04.20160218-0ubuntu1") |
| 6068 | (source |
| 6069 | (origin |
| 6070 | (method git-fetch) |
| 6071 | ;; Download from github rather than launchpad because launchpad trunk |
| 6072 | ;; tarball hash is not deterministic. |
| 6073 | (uri (git-reference |
| 6074 | (url "https://github.com/unity8-team/libdbusmenu-qt") |
| 6075 | (commit version))) |
| 6076 | (file-name (git-file-name name version)) |
| 6077 | (sha256 |
| 6078 | (base32 "0b7ii1cvmpcyl79gqal9c3va9m55h055s4hx7fpxkhhqs9463ggg")))) |
| 6079 | (build-system cmake-build-system) |
| 6080 | (arguments |
| 6081 | ;; XXX: Tests require a dbus session and some icons. |
| 6082 | '(#:tests? #f)) |
| 6083 | (native-inputs |
| 6084 | (list doxygen)) |
| 6085 | (inputs |
| 6086 | (list qtbase-5)) |
| 6087 | (home-page "https://launchpad.net/libdbusmenu-qt") |
| 6088 | (synopsis "Qt implementation of the DBusMenu spec") |
| 6089 | (description "This library provides a Qt implementation of the DBusMenu |
| 6090 | protocol. The DBusMenu protocol makes it possible for applications to export |
| 6091 | and import their menus over DBus.") |
| 6092 | (license license:lgpl2.1+))) |
| 6093 | |
| 6094 | (define-public kdsingleapplication |
| 6095 | (package |
| 6096 | (name "kdsingleapplication") |
| 6097 | (version "1.1.0") |
| 6098 | (source |
| 6099 | (origin |
| 6100 | (method git-fetch) |
| 6101 | (uri (git-reference |
| 6102 | (url "https://github.com/KDAB/KDSingleApplication") |
| 6103 | (commit (string-append "v" version)))) |
| 6104 | (file-name (git-file-name name version)) |
| 6105 | (sha256 |
| 6106 | (base32 "1w7wg9w4mifrkpn7hhw1nnnwh1vhnf8i4wgfxvh44nacwslbwsb2")))) |
| 6107 | (build-system qt-build-system) |
| 6108 | (arguments |
| 6109 | (list |
| 6110 | #:qtbase qtbase |
| 6111 | #:configure-flags |
| 6112 | #~(list "-DKDSingleApplication_QT6=ON" "-DKDSingleApplication_TESTS=ON"))) |
| 6113 | (inputs (list libxkbcommon vulkan-headers)) |
| 6114 | (home-page "https://github.com/KDAB/KDSingleApplication") |
| 6115 | (synopsis "Qt helper class for single-instance policy applications") |
| 6116 | (description "KD SingleApplication is a helper class for single-instance |
| 6117 | policy applications.") |
| 6118 | (license |
| 6119 | (list license:bsd-3 ; cmake/* |
| 6120 | license:expat)))) ; everything else |
| 6121 | |
| 6122 | |
| 6123 | (define libkode |
| 6124 | (origin |
| 6125 | (method git-fetch) |
| 6126 | (uri (git-reference |
| 6127 | (url "https://github.com/cornelius/libkode") |
| 6128 | (commit "2891c9eec984e423bfb56e0284784c85a6e6bb14"))) |
| 6129 | (file-name "libkode") |
| 6130 | (sha256 |
| 6131 | (base32 "08wvxmk77zrixll8wfhwd7ixvpvj2wbisvq8lqw2b8ym77sbbyz4")))) |
| 6132 | |
| 6133 | (define-public kdsoap |
| 6134 | (let ((commit "b23dcc1b554d98a4b77fb56fff0d0f0714c8f0bf") |
| 6135 | (revision "0")) |
| 6136 | (package |
| 6137 | (name "kdsoap") |
| 6138 | (version (git-version "2.2.0" revision commit)) |
| 6139 | (source |
| 6140 | (origin |
| 6141 | (method git-fetch) |
| 6142 | (uri (git-reference |
| 6143 | (url "https://github.com/KDAB/KDSoap") |
| 6144 | (commit commit))) |
| 6145 | (file-name (git-file-name name version)) |
| 6146 | (sha256 |
| 6147 | (base32 "1invsvadfz3l6cf453j4ad4dkg3gas3h85nxvvlif6h7xfx73qhi")))) |
| 6148 | (build-system qt-build-system) |
| 6149 | (arguments |
| 6150 | (list #:qtbase qtbase |
| 6151 | #:configure-flags |
| 6152 | #~(list "-DKDSoap_TESTS=true") |
| 6153 | #:phases |
| 6154 | #~(modify-phases %standard-phases |
| 6155 | (add-after 'unpack 'add-libkode |
| 6156 | (lambda* (#:key native-inputs inputs #:allow-other-keys) |
| 6157 | (copy-recursively #$(this-package-native-input "libkode") |
| 6158 | "kdwsdl2cpp/libkode"))) |
| 6159 | (replace 'check |
| 6160 | (lambda* (#:key native-inputs inputs tests? #:allow-other-keys) |
| 6161 | (when tests? |
| 6162 | (setenv "TZDIR" (search-input-directory |
| 6163 | (or native-inputs inputs) "share/zoneinfo")) |
| 6164 | (setenv "TZ" "Etc/UTC") |
| 6165 | (invoke "ctest" "-E" ;; These tests try connect to the internet. |
| 6166 | "(kdsoap-test_webcalls|kdsoap-test_webcalls_wsdl|kdsoap-test_calc)"))))))) |
| 6167 | (native-inputs (list libkode tzdata-for-tests)) |
| 6168 | (home-page "https://www.kdab.com/development-resources/qt-tools/kd-soap/") |
| 6169 | (synopsis "Qt SOAP component") |
| 6170 | (description "KD SOAP is a tool for creating client applications for web |
| 6171 | services using the XML based SOAP protocol and without the need for a dedicated |
| 6172 | web server.") |
| 6173 | (license (list license:gpl2 license:gpl3))))) |
| 6174 | |
| 6175 | (define-public libaccounts-qt6 |
| 6176 | (package |
| 6177 | (name "libaccounts-qt6") |
| 6178 | (version "1.17") |
| 6179 | (source (origin |
| 6180 | (method git-fetch) |
| 6181 | (uri (git-reference |
| 6182 | (url "https://gitlab.com/accounts-sso/libaccounts-qt") |
| 6183 | (commit (string-append "VERSION_" version)))) |
| 6184 | (file-name (git-file-name name version)) |
| 6185 | (sha256 |
| 6186 | (base32 |
| 6187 | "0859nsksgfrj6ynj74awj1fr6slwcjavs989xc7mbgpvi87n1xlq")))) |
| 6188 | (build-system gnu-build-system) |
| 6189 | (arguments |
| 6190 | (list #:tests? #f ;TODO |
| 6191 | #:phases |
| 6192 | #~(modify-phases %standard-phases |
| 6193 | (replace 'configure |
| 6194 | (lambda _ |
| 6195 | (substitute* "tests/tst_libaccounts.pro" |
| 6196 | (("QMAKE_RPATHDIR = \\$\\$\\{QMAKE_LIBDIR\\}") |
| 6197 | (string-append "QMAKE_RPATHDIR =" |
| 6198 | #$output "/lib"))) |
| 6199 | (invoke "qmake" |
| 6200 | (string-append "PREFIX=" #$output) |
| 6201 | (string-append "LIBDIR=" #$output "/lib"))))))) |
| 6202 | ;; * SignOnQt5 (required version >= 8.55), D-Bus service which performs |
| 6203 | ;; user authentication on behalf of its clients, |
| 6204 | ;; <https://gitlab.com/accounts-sso/signond> |
| 6205 | (native-inputs (list doxygen pkg-config qtbase qttools)) |
| 6206 | (inputs (list glib signond-qt6 libaccounts-glib)) |
| 6207 | (home-page "https://accounts-sso.gitlab.io/") |
| 6208 | (synopsis "Qt6 bindings for libaccounts-glib") |
| 6209 | (description |
| 6210 | "Accounts SSO is a framework for application developers who |
| 6211 | wish to acquire, use and store web account details and credentials. It |
| 6212 | handles the authentication process of an account and securely stores the |
| 6213 | credentials and service-specific settings.") |
| 6214 | (license license:lgpl2.1+))) |
| 6215 | |
| 6216 | (define-public packagekit-qt6 |
| 6217 | (package |
| 6218 | (name "packagekit-qt6") |
| 6219 | (version "1.1.2") |
| 6220 | (source (origin |
| 6221 | (method git-fetch) |
| 6222 | (uri (git-reference |
| 6223 | (url "https://github.com/PackageKit/PackageKit-Qt") |
| 6224 | (commit (string-append "v" version)))) |
| 6225 | (file-name (git-file-name name version)) |
| 6226 | (sha256 |
| 6227 | (base32 |
| 6228 | "1nx8xfhz9v4pc0mz1ir0pq47skpc3w3yj8wqa4m5yky87ib5xcxc")))) |
| 6229 | (build-system cmake-build-system) |
| 6230 | (arguments |
| 6231 | (list |
| 6232 | #:tests? #f ;no test suite |
| 6233 | #:configure-flags #~(list "-DBUILD_WITH_QT6=ON"))) |
| 6234 | (inputs (list packagekit qtbase)) |
| 6235 | (home-page "https://www.freedesktop.org/software/PackageKit/pk-intro.html") |
| 6236 | (synopsis "Qt6 bindings for PackageKit") |
| 6237 | (description "Provides Qt6 bindings to PackageKit which is a DBUS |
| 6238 | abstraction layer that allows the session user to manage packages in |
| 6239 | a secure way.") |
| 6240 | (license license:lgpl2.1+))) |
| 6241 | |
| 6242 | ;; fork for support qt6 |
| 6243 | (define-public signond-qt6 |
| 6244 | (let ((commit "c8ad98249af541514ff7a81634d3295e712f1a39") |
| 6245 | (revision "0")) |
| 6246 | (package |
| 6247 | (name "signond-qt6") |
| 6248 | (version (git-version "8.61" revision commit)) |
| 6249 | (source (origin |
| 6250 | (method git-fetch) |
| 6251 | (uri (git-reference |
| 6252 | (url "https://gitlab.com/nicolasfella/signond") |
| 6253 | (commit commit))) |
| 6254 | (file-name (git-file-name name version)) |
| 6255 | (sha256 |
| 6256 | (base32 |
| 6257 | "13cgdf6hhi2z3c8sax79dwi7450n8h228kpyl2w5lx0xglb2savq")))) |
| 6258 | (build-system qt-build-system) |
| 6259 | (native-inputs (list doxygen pkg-config qttools)) |
| 6260 | (inputs (list dbus glib libaccounts-glib)) |
| 6261 | (arguments |
| 6262 | (list #:qtbase qtbase |
| 6263 | #:tests? #f ; Figure out how to run tests |
| 6264 | #:modules '((guix build qt-build-system) |
| 6265 | ((guix build gnu-build-system) #:prefix gnu:) |
| 6266 | (guix build utils)) |
| 6267 | #:phases |
| 6268 | #~(modify-phases %standard-phases |
| 6269 | (replace 'configure |
| 6270 | (lambda _ |
| 6271 | (substitute* "src/signond/signond.pro" |
| 6272 | (("/etc/") |
| 6273 | (string-append #$output "/etc/"))) |
| 6274 | (substitute* |
| 6275 | '("tests/extensions/extensions.pri" |
| 6276 | "tests/signond-tests/mock-ac-plugin/plugin.pro" |
| 6277 | "tests/signond-tests/identity-tool.pro" |
| 6278 | "tests/signond-tests/mock-ac-plugin/identity-ac-helper.pro" |
| 6279 | "tests/libsignon-qt-tests/libsignon-qt-tests.pro" |
| 6280 | "tests/signond-tests/signond-tests.pri") |
| 6281 | (("QMAKE_RPATHDIR = \\$\\$\\{QMAKE_LIBDIR\\}") |
| 6282 | (string-append "QMAKE_RPATHDIR = " |
| 6283 | #$output "/lib:" |
| 6284 | #$output "/lib/signon"))) |
| 6285 | (invoke "qmake" |
| 6286 | (string-append "PREFIX=" #$output) |
| 6287 | (string-append "LIBDIR=" #$output "/lib") |
| 6288 | (string-append "QMAKE_LFLAGS_RPATH=-Wl,-rpath," |
| 6289 | #$output "/lib -Wl,-rpath,")))) |
| 6290 | (replace 'build (assoc-ref gnu:%standard-phases 'build)) |
| 6291 | (replace 'install (assoc-ref gnu:%standard-phases 'install))))) |
| 6292 | (home-page "https://accounts-sso.gitlab.io/signond/index.html") |
| 6293 | (synopsis "Perform user authentication over D-Bus") |
| 6294 | (description "This package provides a D-Bus service which performs user |
| 6295 | authentication on behalf of its clients.") |
| 6296 | (license license:lgpl2.1+)))) |
| 6297 | |
| 6298 | (define-public clazy |
| 6299 | (package |
| 6300 | (name "clazy") |
| 6301 | (version "1.12") |
| 6302 | (source (origin |
| 6303 | (method git-fetch) |
| 6304 | (uri (git-reference |
| 6305 | (url "https://github.com/KDE/clazy") |
| 6306 | (commit (string-append "v" version)))) |
| 6307 | (file-name (git-file-name name version)) |
| 6308 | (sha256 |
| 6309 | (base32 |
| 6310 | "1y0g1j9ib1b0likjizw70hibky20gxxirqls6hf4crc214279v0m")))) |
| 6311 | (build-system cmake-build-system) |
| 6312 | (native-inputs (list python)) |
| 6313 | (inputs (list clang-13 llvm-13)) |
| 6314 | (home-page "https://github.com/KDE/clazy/") |
| 6315 | (synopsis "Qt-oriented static code analyzer") |
| 6316 | (description "clazy is a compiler plugin which allows @command{clang} to |
| 6317 | understand Qt semantics. It can emit more than fifty (50) Qt-related compiler |
| 6318 | warnings, ranging from unneeded memory allocations to misuses of the API, |
| 6319 | including @i{fix-its} for automatic refactoring.") |
| 6320 | (license license:lgpl2.0+))) |
| 6321 | |
| 6322 | (define-public qt-creator |
| 6323 | (package |
| 6324 | (name "qt-creator") |
| 6325 | (version "18.0.2") |
| 6326 | (source (origin |
| 6327 | (method url-fetch) |
| 6328 | (uri (string-append |
| 6329 | "mirror://qt/qtcreator/" |
| 6330 | (version-major+minor version) "/" version |
| 6331 | "/qt-creator-opensource-src-" version ".tar.gz")) |
| 6332 | (modules '((guix build utils))) |
| 6333 | (snippet '(begin |
| 6334 | (for-each |
| 6335 | delete-file-recursively |
| 6336 | ;; Remove bundled libraries, where supported. |
| 6337 | ;; TODO: package and unbundle litehtml |
| 6338 | '("src/libs/3rdparty/yaml-cpp")) |
| 6339 | ;; qt-creator installation attempts to install the |
| 6340 | ;; yaml-cpp LICENSE file, but we removed the bundled |
| 6341 | ;; yaml-cpp, so create an empty file to allow it to |
| 6342 | ;; install properly. |
| 6343 | (mkdir-p "src/libs/3rdparty/yaml-cpp") |
| 6344 | (call-with-output-file "src/libs/3rdparty/yaml-cpp/LICENSE" |
| 6345 | (lambda (port) |
| 6346 | (const #t))))) |
| 6347 | (sha256 |
| 6348 | (base32 |
| 6349 | "13v9ysaaiyccz6anjva7mlifgls013c3s0n5gm443w6v4ssrjdz7")))) |
| 6350 | (outputs '("out" "debug")) |
| 6351 | (build-system qt-build-system) |
| 6352 | (arguments |
| 6353 | (list |
| 6354 | #:qtbase qtbase |
| 6355 | #:configure-flags |
| 6356 | #~(list "-DWITH_DOCS=ON" |
| 6357 | "-DBUILD_DEVELOPER_DOCS=ON" |
| 6358 | "-DBUILD_EXECUTABLE_CMDBRIDGE=OFF" ;requires Go libraries |
| 6359 | "-DCMAKE_VERBOSE_MAKEFILE=ON" |
| 6360 | "-DCLANGTOOLING_LINK_CLANG_DYLIB=ON" |
| 6361 | "-DWITH_TESTS=ON" |
| 6362 | ;; Extend the RUNPATH with lib/qtcreator, which contains |
| 6363 | ;; multiple shared objects. |
| 6364 | (string-append "-DCMAKE_SHARED_LINKER_FLAGS=-Wl,-rpath=" |
| 6365 | #$output "/lib/qtcreator")) |
| 6366 | #:phases |
| 6367 | #~(modify-phases %standard-phases |
| 6368 | (add-after 'unpack 'fix-yaml-cpp-duplicate-alias-error |
| 6369 | (lambda _ |
| 6370 | ;; The CMake module attempts to create the 'yaml-cpp' alias, but |
| 6371 | ;; it already exists in the yaml-cpp native config file (see: |
| 6372 | ;; https://bugreports.qt.io/browse/QTCREATORBUG-33457). |
| 6373 | (substitute* "cmake/Findyaml-cpp.cmake" |
| 6374 | (("add_library\\(yaml-cpp ALIAS yaml-cpp::yaml-cpp)") |
| 6375 | "")))) |
| 6376 | (add-after 'unpack 'patch-perfparser |
| 6377 | ;; XXX: The 'patch-perfparser' phase is also used by the 'hotspot' |
| 6378 | ;; package; keep its copy in sync (paying attention to the |
| 6379 | ;; different demangler.cpp file name). |
| 6380 | (lambda* (#:key inputs #:allow-other-keys) |
| 6381 | ;; perfparser attempts to dynamically load the demangle |
| 6382 | ;; libraries; use their absolute file name to avoid having to |
| 6383 | ;; set LD_LIBRARY_PATH. |
| 6384 | (let ((librustc_demangle.so |
| 6385 | (with-exception-handler (lambda (ex) |
| 6386 | (if (search-error? ex) |
| 6387 | #f |
| 6388 | (raise-exception ex))) |
| 6389 | (lambda () |
| 6390 | (search-input-file inputs "lib/librustc_demangle.so")) |
| 6391 | #:unwind? #t))) |
| 6392 | (substitute* "src/tools/perfparser/app/demangler.cpp" |
| 6393 | (("loadDemangleLib\\(QStringLiteral\\(\"rustc_demangle\")" |
| 6394 | all) |
| 6395 | (if librustc_demangle.so |
| 6396 | (format #f "loadDemangleLib(QStringLiteral(~s)" |
| 6397 | librustc_demangle.so) |
| 6398 | all)) ;no rustc_demangle; leave unchanged |
| 6399 | (("loadDemangleLib\\(QStringLiteral\\(\"d_demangle\")") |
| 6400 | (format #f "loadDemangleLib(QStringLiteral(~s)" |
| 6401 | (search-input-file inputs |
| 6402 | "lib/libd_demangle.so"))))))) |
| 6403 | (add-after 'unpack 'patch-paths |
| 6404 | (lambda* (#:key inputs #:allow-other-keys) |
| 6405 | (substitute* '("src/libs/utils/commandline.cpp" |
| 6406 | "src/libs/utils/deviceshell.cpp") |
| 6407 | (("/bin/sh") |
| 6408 | (search-input-file inputs "bin/sh"))) |
| 6409 | (substitute* "src/libs/utils/qtcprocess.cpp" |
| 6410 | (("/usr/bin/env") |
| 6411 | (search-input-file inputs "bin/env"))) |
| 6412 | (substitute* '("tests/auto/utils/process/tst_process.cpp" |
| 6413 | "tests/auto/utils/commandline/tst_commandline.cpp") |
| 6414 | (("/bin/sh") |
| 6415 | (which "sh"))))) |
| 6416 | (add-before 'build 'build-doc |
| 6417 | (lambda _ |
| 6418 | (invoke "cmake" "--build" "." "--target=docs" "-v"))) |
| 6419 | (add-after 'build-doc 'install-doc |
| 6420 | (lambda _ |
| 6421 | (invoke "cmake" "--install" "." "--prefix" #$output |
| 6422 | "--component=qch_docs") |
| 6423 | (invoke "cmake" "--install" "." "--prefix" #$output |
| 6424 | "--component=html_docs"))) |
| 6425 | (replace 'check |
| 6426 | (lambda* (#:key tests? parallel-tests? #:allow-other-keys) |
| 6427 | (when tests? |
| 6428 | (invoke "xvfb-run" ;for the 'renderpass' tests |
| 6429 | "ctest" "-j" (if parallel-tests? |
| 6430 | (number->string (parallel-job-count)) |
| 6431 | "1") |
| 6432 | "--label-exclude" "exclude_from_precheck" |
| 6433 | "-E" |
| 6434 | (string-append |
| 6435 | "(" |
| 6436 | (string-join |
| 6437 | (list |
| 6438 | ;; The performance data tests require external |
| 6439 | ;; data. |
| 6440 | "tst_perfdata") "|") |
| 6441 | ")"))))) |
| 6442 | (add-after 'qt-wrap 'wrap-bin |
| 6443 | ;; Make a few well-integrated tools readily available. |
| 6444 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 6445 | (wrap-program (search-input-file outputs "bin/qtcreator") |
| 6446 | `("PATH" suffix ,(map (lambda (c) |
| 6447 | (dirname (search-input-file inputs c))) |
| 6448 | '("bin/clang-tidy" |
| 6449 | "bin/clazy-standalone" |
| 6450 | "bin/gdb" |
| 6451 | "bin/kcachegrind" |
| 6452 | "bin/perf" |
| 6453 | "bin/valgrind"))))))))) |
| 6454 | (native-inputs |
| 6455 | (list googletest |
| 6456 | pkg-config |
| 6457 | python |
| 6458 | qttools |
| 6459 | qttranslations |
| 6460 | vulkan-headers |
| 6461 | xvfb-run)) |
| 6462 | (inputs |
| 6463 | (append |
| 6464 | (list bash-minimal |
| 6465 | coreutils-minimal |
| 6466 | clang-20 |
| 6467 | clazy |
| 6468 | d-demangler |
| 6469 | elfutils |
| 6470 | gdb |
| 6471 | kcachegrind |
| 6472 | libarchive |
| 6473 | libsecret |
| 6474 | libxkbcommon |
| 6475 | llvm-20 |
| 6476 | perf |
| 6477 | qt5compat |
| 6478 | qtcharts |
| 6479 | qtdeclarative |
| 6480 | qtquick3d |
| 6481 | qtquick3dphysics |
| 6482 | qtserialport |
| 6483 | qtshadertools |
| 6484 | qtsvg |
| 6485 | yaml-cpp |
| 6486 | valgrind/pinned |
| 6487 | vulkan-loader |
| 6488 | `(,zstd "lib")) |
| 6489 | (if (supported-package? rust-rustc-demangle-capi-0.1) |
| 6490 | (list rust-rustc-demangle-capi-0.1) |
| 6491 | '()))) |
| 6492 | (home-page "https://www.qt.io/") |
| 6493 | (synopsis "Integrated development environment (IDE) for Qt") |
| 6494 | (description "Qt Creator is an IDE tailored to the needs of Qt developers. |
| 6495 | It includes features such as an advanced code editor, a visual debugger and a |
| 6496 | @acronym{GUI, Graphical User Interface} designer.") |
| 6497 | (license license:gpl3+))) ;with the Qt Company GPL Exception 1.0 |
| 6498 | |
| 6499 | ;;; |
| 6500 | ;;; Avoid adding new packages to the end of this file. To reduce the chances |
| 6501 | ;;; of a merge conflict, place them above by existing packages with similar |
| 6502 | ;;; functionality or similar names. |
| 6503 | ;;; |