diff options
Diffstat (limited to 'guix')
-rw-r--r-- | guix/build/qt-build-system.scm | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/guix/build/qt-build-system.scm b/guix/build/qt-build-system.scm index be2b808901..005157b0a4 100644 --- a/guix/build/qt-build-system.scm +++ b/guix/build/qt-build-system.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2014 Federico Beffa <beffa@fbengineering.ch> ;;; Copyright © 2014, 2015 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2018 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2019 Hartmut Goebel <h.goebel@crazy-compilers.com> +;;; Copyright © 2019, 2020 Hartmut Goebel <h.goebel@crazy-compilers.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -36,6 +36,17 @@ ;; ;; Code: +(define* (check-setup #:rest args) + ;; Make Qt render "offscreen". In many cases this allows to run tests + ;; without starting a X11 server. + (setenv "QT_QPA_PLATFORM" "offscreen") + ;; Qt/KDE tests often need dbus (`dbus-launch …`) which is not fully + ;; set-up the the build container. + (setenv "DBUS_FATAL_WARNINGS" "0") + ;; Set here to ease overwriting 'check (even if set there, too) + (setenv "CTEST_OUTPUT_ON_FAILURE" "1") + #t) + (define (variables-for-wrapping base-directories) (define (collect-sub-dirs base-directories subdirectory) @@ -101,6 +112,7 @@ add a dependency of that output on Qt." (define %standard-phases (modify-phases cmake:%standard-phases + (add-before 'check 'check-setup check-setup) (add-after 'install 'qt-wrap wrap-all-programs))) (define* (qt-build #:key inputs (phases %standard-phases) |