summaryrefslogtreecommitdiff
path: root/guix/utils.scm
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2018-06-12 19:51:23 +0200
committerMarius Bakke <mbakke@fastmail.com>2018-06-16 21:35:25 +0200
commit259341cf93de80533d212cb73e5e652aa4bc716c (patch)
treeea6fc37bb2759fabc88f54ce6feb98aa51c1575e /guix/utils.scm
parent406c83f78d4c7851743bb0f82a9de02c8afa63f3 (diff)
gnu: ldb: Fix build on 32-bit systems.
* guix/utils.scm (target-64bit?): New procedure. * gnu/packages/samba.scm (ldb)[inputs]: Only add LMDB on 64-bit systems. [arguments]: Make #:tests? conditional on LMDB availability.
Diffstat (limited to 'guix/utils.scm')
-rw-r--r--guix/utils.scm6
1 files changed, 6 insertions, 0 deletions
diff --git a/guix/utils.scm b/guix/utils.scm
index e9efea5866..a5de9605e7 100644
--- a/guix/utils.scm
+++ b/guix/utils.scm
@@ -7,6 +7,7 @@
;;; Copyright © 2015 David Thompson <davet@gnu.org>
;;; Copyright © 2017 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
+;;; Copyright © 2018 Marius Bakke <mbakke@fastmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -77,6 +78,7 @@
package-name->name+version
target-mingw?
target-arm32?
+ target-64bit?
version-compare
version>?
version>=?
@@ -474,6 +476,10 @@ a character other than '@'."
(define (target-arm32?)
(string-prefix? "arm" (or (%current-target-system) (%current-system))))
+(define (target-64bit?)
+ (let ((system (or (%current-target-system) (%current-system))))
+ (any (cut string-prefix? <> system) '("x86_64" "aarch64" "mips64" "ppc64"))))
+
(define version-compare
(let ((strverscmp
(let ((sym (or (dynamic-func "strverscmp" (dynamic-link))