gnu: openboard: Switch to Qt6.
* gnu/packages/education.scm (openboard)[arguments]<#:qtbase>: Add.
<#:modules>: Remove.
<#:phases>: Remove fix-hard-coded-env, fix-library-path. Remove custom
configure, build, install.
{set-initial-values}: Remove obsolete substitution.
[native-inputs]: Replace qttools-5 by qttools. Add pkg-config.
[inputs]: Replace ffmpeg-4 by ffmpeg, libressl by openssl, qtdeclarative-5
by qtdeclarative, qtmultimedia-5 by qtmultimedia, qtsvg-5 by qtsvg,
qtwebchannel-5 by qtwebchannel, qtwebengine-5 by qtwebengine, quazip-5
by quazip. Remove qtbase-5 and qtxmlpatterns-5.
Add cups-minimal and qt5compat.
Fixes: guix/guix#3075
Change-Id: I386837d4735313c6b20b3f662e83d268176b4f77
1 files changed, 16 insertions(+), 72 deletions(-) M gnu/packages/education.scm
M gnu/packages/education.scm => gnu/packages/education.scm +16 -72
@@ 13,6 13,7 @@ ;;; Copyright © 2022 Luis Felipe López Acevedo <luis.felipe.la@protonmail.com> ;;; Copyright © 2023 Maxim Cournoyer <maxim@guixotic.coop> ;;; Copyright © 2024 Luis Higino <luishenriquegh2701@gmail.com> ;;; Copyright © 2025 Andreas Enge <andreas@enge.fr> ;;; ;;; This file is part of GNU Guix. ;;; @@ 36,6 37,7 @@ #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages compression) #:use-module (gnu packages cups) #:use-module (gnu packages curl) #:use-module (gnu packages databases) #:use-module (gnu packages django) @@ 452,100 454,42 @@ specialized device.") (build-system qt-build-system) (arguments (list #:qtbase qtbase #:tests? #f ;no tests #:modules '((guix build qt-build-system) ((guix build gnu-build-system) #:prefix gnu:) (guix build utils)) #:phases #~(modify-phases %standard-phases (add-after 'unpack 'set-initial-values ;; Remove useless "Check for updates" action from menu. Also ;; prevent pop-up window about importing Open Sankore documents ;; since we don't package OpenBoard-Importer. ;; Remove useless "Check for updates" action from menu. (lambda _ (substitute* "src/core/UBSettings.cpp" (("(appHideCheckForSoftwareUpdate = .*?)false(\\);)" _ beg end) (string-append beg "true" end)) (("(appLookForOpenSankoreInstall = .*?)true(\\);)" _ beg end) (string-append beg "false" end))))) (add-after 'unpack 'fix-hard-coded-env (lambda* (#:key inputs #:allow-other-keys) (substitute* "src/frameworks/UBPlatformUtils_linux.cpp" (("/usr/bin/env") (search-input-file inputs "/bin/env"))))) (add-after 'unpack 'fix-library-path (lambda* (#:key inputs #:allow-other-keys) (substitute* "OpenBoard.pro" (("/usr/include/quazip5") (search-input-directory inputs "/include/QuaZip-Qt5-1.5/quazip")) (("-lquazip5") "-lquazip1-qt5") (("/usr/include/poppler") (search-input-directory inputs "/include/poppler"))))) (replace 'configure (lambda _ (invoke "qmake" "OpenBoard.pro"))) (replace 'build (assoc-ref gnu:%standard-phases 'build)) (replace 'install (lambda* (#:key inputs #:allow-other-keys) (let* ((share (string-append #$output "/share")) (openboard (string-append share "/openboard")) (i18n (string-append openboard "/i18n"))) ;; Install data. (with-directory-excursion "resources" (for-each (lambda (directory) (let ((target (string-append openboard "/" directory))) (mkdir-p target) (copy-recursively directory target))) '("customizations" "etc" "library")) (mkdir-p i18n) (for-each (lambda (f) (install-file f i18n)) (find-files "i18n" "\\.qm$"))) ;; Install desktop file an icon. (install-file "resources/images/OpenBoard.png" (string-append share "/icons/hicolor/64x64/apps/")) (make-desktop-entry-file (string-append share "/applications/" #$name ".desktop") #:name "OpenBoard" #:comment "Interactive whiteboard application" #:exec "openboard %f" #:icon "OpenBoard" #:mime-type "application/ubz" #:categories '("Education")) ;; Install executable. (install-file "build/linux/release/product/OpenBoard" openboard) (let ((bin (string-append #$output "/bin"))) (mkdir-p bin) (symlink (string-append openboard "/OpenBoard") (string-append bin "/openboard"))))))))) (string-append beg "true" end)))))))) (native-inputs (list qttools-5)) (list pkg-config qttools)) (inputs (list alsa-lib coreutils-minimal ;for patched 'env' shebang ffmpeg-4 cups-minimal ffmpeg freetype lame libass libfdk libressl libtheora libva libvorbis libvpx libx264 openssl opus poppler qtbase-5 qtdeclarative-5 qtmultimedia-5 qtsvg-5 qtwebchannel-5 qtwebengine-5 qtxmlpatterns-5 quazip-5 qt5compat qtdeclarative qtmultimedia qtsvg qtwebchannel qtwebengine quazip sdl zlib)) (home-page "https://openboard.ch/")