[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#50299: [PATCH v3 09/27] gnu: swi-prolog: Set PROG_SWIPL when cross-c
From: |
Maxime Devos |
Subject: |
bug#50299: [PATCH v3 09/27] gnu: swi-prolog: Set PROG_SWIPL when cross-compiling. |
Date: |
Thu, 30 Sep 2021 00:47:41 +0200 |
* gnu/packages/prolog.scm
(swi-prolog)[arguments]<#:configure-flags>: Set PROG_SWIPL and
SWIPL_NATIVE_FRIEND when cross-compiling.
(swi-prolog)[native-inputs]: Add 'this-package' when cross-compiling.
---
gnu/packages/prolog.scm | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/prolog.scm b/gnu/packages/prolog.scm
index 3eaec533d7..7a5ac04a0c 100644
--- a/gnu/packages/prolog.scm
+++ b/gnu/packages/prolog.scm
@@ -27,6 +27,7 @@
#:use-module (guix packages)
#:use-module (guix build-system cmake)
#:use-module (guix build-system gnu)
+ #:use-module (guix utils)
#:use-module (gnu packages backup)
#:use-module (gnu packages bash)
#:use-module (gnu packages compression)
@@ -107,6 +108,12 @@ manner. It also features an interactive interpreter.")
'("-DBSD_SIGNALS=1" "-DQSORT_R_GNU=1"
;; If absent, the non-existent 'cc' is used.
"-DCMAKE_HOST_CC=gcc"
+ ;; swi-prolog needs a native copy of itself for
+ ;; cross-compilation.
+ "-DSWIPL_NATIVE_FRIEND=/nowhere"
+ (string-append "-DPROG_SWIPL="
+ (assoc-ref %build-host-inputs "swi-prolog")
+ "/bin/swipl"))
'())
"-DINSTALL_DOCUMENTATION=ON"
"-DSWIPL_INSTALL_IN_LIB=OFF") ; FIXME: Breaks RUNPATH validation.
@@ -125,7 +132,15 @@ manner. It also features an interactive interpreter.")
'("save")))
#t)))))
(native-inputs
- `(("texinfo" ,texinfo)
+ `(,@(if (%current-target-system)
+ (begin
+ (unless (equal? (target-64bit?)
+ (target-64bit? (%current-system)))
+ (error "swi-prolog requires --system and --target to have \
+the same word size"))
+ `(("swi-prolog" ,this-package)))
+ '())
+ ("texinfo" ,texinfo)
("perl" ,perl)
("pkg-config" ,pkg-config)))
(inputs
--
2.33.0
- bug#50299: [PATCH v3 03/27] gnu: lean: Add bash-minimal., (continued)
- bug#50299: [PATCH v3 03/27] gnu: lean: Add bash-minimal., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 04/27] gnu: swi-prolog: Move native-inputs to inputs where appropriate., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 05/27] gnu: swi-prolog: Don't explicitely enable tests., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 08/27] gnu: swi-prolog: Use cross-compiled bash in shebangs., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 06/27] gnu: swi-prolog: Make configuration wok when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 17/27] gnu: libicns: Don't run tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 13/27] gnu: ruby-ffi-rzmq: Respect #:tests?., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 15/27] gnu: ecl: Don't pretend to enable tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 21/27] gnu: lablgtk: Don't run tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 20/27] gnu: ocaml4.07-fftw3: Don't run tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 09/27] gnu: swi-prolog: Set PROG_SWIPL when cross-compiling.,
Maxime Devos <=
- bug#50299: [PATCH v3 12/27] gnu: ruby-ffi-rzmq: Don't enable tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 23/27] gnu: pjproject: Don't run tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 24/27] gnu: tdlib: Don't run tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 25/27] gnu: extra-cmake-modules: Don't run tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 02/27] gnu: lean: Set #:tests? appropriately when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 07/27] gnu: swi-prolog: Don't use 'cc'., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 11/27] gnu: ruby-byebug-11: Don't enable tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 26/27] gnu: inkscape-1.1: Don't run tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 14/27] gnu: go-1.16: Don't enable tests when cross-compiling., Maxime Devos, 2021/09/29
- bug#50299: [PATCH v3 16/27] gnu: perl-unicode-utf8: Don't run tests when cross-compiling., Maxime Devos, 2021/09/29