summaryrefslogtreecommitdiff
path: root/guix/build
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2020-02-03 15:45:44 +0100
committerMarius Bakke <mbakke@fastmail.com>2020-02-03 15:45:44 +0100
commit52665d2b6bd709ba46c1e364a6d6164f5f4824ff (patch)
tree55fd79b3939c08f6f6e9fe383f0df5e4caa82b57 /guix/build
parent584d08c5c98cb1893e4f44bd1c4191f405b13f01 (diff)
parent0a83339bb1429332ee889e9a976aa214ae2ac0db (diff)
downloadguix-patches-52665d2b6bd709ba46c1e364a6d6164f5f4824ff.tar
guix-patches-52665d2b6bd709ba46c1e364a6d6164f5f4824ff.tar.gz
Merge branch 'staging' into core-updates
Diffstat (limited to 'guix/build')
-rw-r--r--guix/build/cargo-build-system.scm6
-rw-r--r--guix/build/compile.scm6
-rw-r--r--guix/build/qt-build-system.scm14
3 files changed, 19 insertions, 7 deletions
diff --git a/guix/build/cargo-build-system.scm b/guix/build/cargo-build-system.scm
index 8a8d74ee1b..0721989589 100644
--- a/guix/build/cargo-build-system.scm
+++ b/guix/build/cargo-build-system.scm
@@ -2,7 +2,7 @@
;;; Copyright © 2016 David Craven <david@craven.ch>
;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
;;; Copyright © 2019 Ivan Petkov <ivanppetkov@gmail.com>
-;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il>
+;;; Copyright © 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -58,7 +58,7 @@
(define (crate-src? path)
"Check if PATH refers to a crate source, namely a gzipped tarball with a
Cargo.toml file present at its root."
- (and (gzip-file? path)
+ (and (not (directory-exists? path)) ; not a tarball
;; First we print out all file names within the tarball to see if it
;; looks like the source of a crate. However, the tarball will include
;; an extra path component which we would like to ignore (since we're
@@ -119,6 +119,8 @@ directory = '" port)
;; upgrading the compiler for example.
(setenv "RUSTFLAGS" "--cap-lints allow")
(setenv "CC" (string-append (assoc-ref inputs "gcc") "/bin/gcc"))
+ (setenv "LIBGIT2_SYS_USE_PKG_CONFIG" "1")
+ (setenv "LIBSSH2_SYS_USE_PKG_CONFIG" "1")
;; We don't use the Cargo.lock file to determine the package versions we use
;; during building, and in any case if one is not present it is created
diff --git a/guix/build/compile.scm b/guix/build/compile.scm
index 3781e148ce..4b6472784c 100644
--- a/guix/build/compile.scm
+++ b/guix/build/compile.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2013, 2014, 2016, 2017, 2018, 2019 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2013, 2014, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
;;;
;;; This file is part of GNU Guix.
@@ -29,9 +29,7 @@
#:use-module (guix build utils)
#:use-module (language tree-il optimize)
#:use-module (language cps optimize)
- #:export (%default-optimizations
- %lightweight-optimizations
- compile-files))
+ #:export (compile-files))
;;; Commentary:
;;;
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)