From: Thiago Jung Bauermann via Guix-patches via <guix-patches@gnu.org>
To: 49672@debbugs.gnu.org
Cc: Thiago Jung Bauermann <bauermann@kolabnow.com>
Subject: [bug#49672] [PATCH 1/9] gnu: Fix check of ‘%current-system’ and ‘%current-target-system’
Date: Tue, 20 Jul 2021 22:00:35 -0300 [thread overview]
Message-ID: <20210721010043.632012-1-bauermann@kolabnow.com> (raw)
In-Reply-To: <20210721004615.631777-1-bauermann@kolabnow.com>
The order of the check is important because ‘%current-system’ is always
defined, while ‘%current-target-system’ is only defined when
cross-building.
Therefore, it’s important to check ‘%current-target-system’ first,
otherwise the cross-build target is never considered.
* gnu/packages/bdw-gc.scm (libgc)[arguments]<#:configure-flags>: Check
‘%current-target-system’ first.
* gnu/packages/crypto.scm (libb2)[arguments]<#:configure-flags>: Likewise.
* gnu/packages/golang.scm (go-1.4)[arguments]<#:system>: Likewise.
(go-1.14)[arguments]<#:system>: Likewise.
* gnu/packages/java.scm (jamvm-1-bootstrap)[arguments]<#:phases>: Likewise.
[native-inputs]: Likewise.
(ant-bootstrap)[arguments]<#:phases>: Likewise.
(classpath-jamvm-wrappers)[arguments]<#:builder>: Likewise.
* gnu/packages/lisp.scm (clisp)[arguments]<#:configure-flags>: Likewise.
* gnu/packages/photo.scm (lensfun)[arguments]<#:configure-flags>: Likewise.
* gnu/packages/php.scm (php)[arguments]<#:phases>: Likewise.
* gnu/packages/sdl.scm (sdl-gfx)[arguments]<#:configure-flags>: Likewise.
* gnu/packages/telephony.scm (pjproject)[arguments]<#:configure-flags>: Likewise.
---
gnu/packages/bdw-gc.scm | 4 ++--
gnu/packages/crypto.scm | 4 ++--
gnu/packages/golang.scm | 8 ++++----
gnu/packages/java.scm | 16 ++++++++--------
gnu/packages/lisp.scm | 4 ++--
gnu/packages/photo.scm | 4 ++--
gnu/packages/php.scm | 4 ++--
gnu/packages/sdl.scm | 4 ++--
gnu/packages/telephony.scm | 4 ++--
9 files changed, 26 insertions(+), 26 deletions(-)
diff --git a/gnu/packages/bdw-gc.scm b/gnu/packages/bdw-gc.scm
index ecac5b93687e..cd834ff11031 100644
--- a/gnu/packages/bdw-gc.scm
+++ b/gnu/packages/bdw-gc.scm
@@ -52,8 +52,8 @@
;; to configure script. See bug report and discussion:
;; <https://lists.opendylan.org/pipermail/bdwgc/2017-April/006275.html>
;; <https://lists.gnu.org/archive/html/bug-hurd/2017-01/msg00008.html>
- ,@(if (hurd-triplet? (or (%current-system)
- (%current-target-system)))
+ ,@(if (hurd-triplet? (or (%current-target-system)
+ (%current-system)))
'("--disable-gcj-support")
'()))))
(native-inputs `(("pkg-config" ,pkg-config)))
diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm
index fe2cec045d6c..dff9584e07b3 100644
--- a/gnu/packages/crypto.scm
+++ b/gnu/packages/crypto.scm
@@ -867,8 +867,8 @@ data on your platform, so the seed itself will be as random as possible.
(arguments
`(#:configure-flags
(list
- ,@(if (any (cute string-prefix? <> (or (%current-system)
- (%current-target-system)))
+ ,@(if (any (cute string-prefix? <> (or (%current-target-system)
+ (%current-system)))
'("x86_64" "i686"))
;; fat only checks for Intel optimisations
'("--enable-fat")
diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm
index a830afa022a6..58688687bba3 100644
--- a/gnu/packages/golang.scm
+++ b/gnu/packages/golang.scm
@@ -1046,8 +1046,8 @@ your Go binary to be later served from an http.FileSystem.")
(guix build utils)
(srfi srfi-1))
#:tests? #f ; Tests are run by the all.bash script.
- ,@(if (string-prefix? "aarch64-linux" (or (%current-system)
- (%current-target-system)))
+ ,@(if (string-prefix? "aarch64-linux" (or (%current-target-system)
+ (%current-system)))
'(#:system "armhf-linux")
'())
#:phases
@@ -1199,8 +1199,8 @@ in the style of communicating sequential processes (@dfn{CSP}).")
(arguments
(substitute-keyword-arguments (package-arguments go-1.4)
((#:system system)
- (if (string-prefix? "aarch64-linux" (or (%current-system)
- (%current-target-system)))
+ (if (string-prefix? "aarch64-linux" (or (%current-target-system)
+ (%current-system)))
"aarch64-linux"
system))
((#:phases phases)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 64df5a2e24a2..e69d62be0802 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -315,8 +315,8 @@ language.")
"--enable-runtime-reloc-checks"
"--enable-ffi")
#:phases
- ,(if (string-prefix? "aarch64" (or (%current-system)
- (%current-target-system)))
+ ,(if (string-prefix? "aarch64" (or (%current-target-system)
+ (%current-system)))
;; Makefiles and the configure script need to be regenerated to
;; incorporate support for AArch64.
'(modify-phases %standard-phases
@@ -330,8 +330,8 @@ language.")
("zip" ,zip)
("zlib" ,zlib)))
(native-inputs
- (if (string-prefix? "aarch64" (or (%current-system)
- (%current-target-system)))
+ (if (string-prefix? "aarch64" (or (%current-target-system)
+ (%current-system)))
;; Additional packages needed for autoreconf.
`(("autoconf" ,autoconf)
("automake" ,automake)
@@ -401,8 +401,8 @@ JNI.")
;; Without these JamVM options the build may freeze.
(substitute* "bootstrap.sh"
(("^\"\\$\\{JAVACMD\\}\" " m)
- ,@(if (string-prefix? "armhf" (or (%current-system)
- (%current-target-system)))
+ ,@(if (string-prefix? "armhf" (or (%current-target-system)
+ (%current-system)))
`((string-append m "-Xnocompact "))
`((string-append m "-Xnocompact -Xnoinlining ")))))
@@ -674,8 +674,8 @@ the standard javac executable.")))
(for-each (lambda (tool)
(with-output-to-file (string-append bin tool)
(lambda _
- ,@(if (string-prefix? "armhf" (or (%current-system)
- (%current-target-system)))
+ ,@(if (string-prefix? "armhf" (or (%current-target-system)
+ (%current-system)))
`((format #t "#!~a/bin/sh
~a/bin/jamvm -Xnocompact -classpath ~a/share/classpath/tools.zip \
gnu.classpath.tools.~a.~a $@"
diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scm
index d8d7a7394c44..ee43226ff091 100644
--- a/gnu/packages/lisp.scm
+++ b/gnu/packages/lisp.scm
@@ -347,8 +347,8 @@ supporting ASDF, Sockets, Gray streams, MOP, and other useful components.")
("libsigsegv" ,libsigsegv)))
(arguments
`(#:configure-flags '(,@(if (string-prefix? "armhf-linux"
- (or (%current-system)
- (%current-target-system)))
+ (or (%current-target-system)
+ (%current-system)))
'("CFLAGS=-falign-functions=4")
'())
"--with-dynamic-ffi"
diff --git a/gnu/packages/photo.scm b/gnu/packages/photo.scm
index 673989e06b09..1b646497c91e 100644
--- a/gnu/packages/photo.scm
+++ b/gnu/packages/photo.scm
@@ -440,8 +440,8 @@ scene to produce an image that looks much like a tone-mapped image.")
"0cfk8jjhs9nbfjfdy98plrj9ayi59aph0nx6ppslgjhlcvacm2xf"))))
(build-system cmake-build-system)
(arguments
- `(,@(if (any (cute string-prefix? <> (or (%current-system)
- (%current-target-system)))
+ `(,@(if (any (cute string-prefix? <> (or (%current-target-system)
+ (%current-system)))
'("x86_64" "i686"))
;; SSE and SSE2 are supported only on Intel processors.
'()
diff --git a/gnu/packages/php.scm b/gnu/packages/php.scm
index 4edff2cfd886..597494e8a94f 100644
--- a/gnu/packages/php.scm
+++ b/gnu/packages/php.scm
@@ -177,8 +177,8 @@
(substitute* "ext/standard/tests/streams/bug60602.phpt"
(("'ls'") (string-append "'" (which "ls") "'")))
- ,@(if (string-prefix? "arm" (or (%current-system)
- (%current-target-system)))
+ ,@(if (string-prefix? "arm" (or (%current-target-system)
+ (%current-system)))
;; Drop tests known to fail on armhf.
'((for-each delete-file
(list
diff --git a/gnu/packages/sdl.scm b/gnu/packages/sdl.scm
index 128bd95af881..bddc0bdbe990 100644
--- a/gnu/packages/sdl.scm
+++ b/gnu/packages/sdl.scm
@@ -200,8 +200,8 @@ system, such as sound redirection over the network.")
(build-system gnu-build-system)
(outputs '("out" "debug"))
(arguments
- `(,@(if (any (cute string-prefix? <> (or (%current-system)
- (%current-target-system)))
+ `(,@(if (any (cute string-prefix? <> (or (%current-target-system)
+ (%current-system)))
'("x86_64" "i686"))
;; mmx is supported only on Intel processors.
'()
diff --git a/gnu/packages/telephony.scm b/gnu/packages/telephony.scm
index f75a168948bb..4957ecca13a0 100644
--- a/gnu/packages/telephony.scm
+++ b/gnu/packages/telephony.scm
@@ -755,8 +755,8 @@ your calls and messages.")
"--with-external-srtp"
"--with-external-pa"
;; The following flag is Linux specific.
- ,@(if (string-contains (or (%current-system)
- (%current-target-system)) "linux")
+ ,@(if (string-contains (or (%current-target-system)
+ (%current-system)) "linux")
'("--enable-epoll")
'())
"--with-gnutls" ;disable OpenSSL checks
next prev parent reply other threads:[~2021-07-21 1:02 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-21 0:46 [bug#49672] [PATCH 0/9] Target check fixes and cleanups Thiago Jung Bauermann via Guix-patches via
2021-07-21 1:00 ` Thiago Jung Bauermann via Guix-patches via [this message]
2021-07-21 1:00 ` [bug#49672] [PATCH 2/9] utils: Add ‘current-target-nix-system’ helper Thiago Jung Bauermann via Guix-patches via
2021-07-21 1:00 ` [bug#49672] [PATCH 3/9] gnu: Query membership in ‘supported-systems’ list with Nix identifier Thiago Jung Bauermann via Guix-patches via
2021-07-21 1:00 ` [bug#49672] [PATCH 4/9] gnu: Use ‘current-target-nix-system’ in pattern matches Thiago Jung Bauermann via Guix-patches via
2021-07-21 1:00 ` [bug#49672] [PATCH 5/9] gnu: Use ‘current-target-nix-system’ in prefix checks Thiago Jung Bauermann via Guix-patches via
2021-07-21 1:00 ` [bug#49672] [PATCH 6/9] gnu: Fix GNU/Linux system detection Thiago Jung Bauermann via Guix-patches via
2021-07-21 1:00 ` [bug#49672] [PATCH 7/9] bootloader: grub: Fix mix of GNU triplet and Nix system identifier Thiago Jung Bauermann via Guix-patches via
2021-07-21 1:00 ` [bug#49672] [PATCH 8/9] gnu: ustr: Don’t pass default argument Thiago Jung Bauermann via Guix-patches via
2021-07-21 1:00 ` [bug#49672] [PATCH 9/9] gnu: Use existing target helpers from ‘(guix utils)’ Thiago Jung Bauermann via Guix-patches via
2021-11-07 11:23 ` [bug#49672] [PATCH 0/9] Target check fixes and cleanups Maxime Devos
2021-11-12 0:56 ` Thiago Jung Bauermann via Guix-patches via
2022-03-27 21:40 ` [bug#49672] [PATCH v2 0/6] Target check fixes for cross compilation Thiago Jung Bauermann via Guix-patches via
2022-03-27 21:40 ` [bug#49672] [PATCH v2 1/6] gnu: Fix GNU/Linux system detection Thiago Jung Bauermann via Guix-patches via
2022-03-27 21:40 ` [bug#49672] [PATCH v2 2/6] gnu: libgc: Use default argument in ‘target-hurd?’ call Thiago Jung Bauermann via Guix-patches via
2022-03-27 21:40 ` [bug#49672] [PATCH v2 3/6] utils: Introduce the ‘current-target-nix-system’ procedure Thiago Jung Bauermann via Guix-patches via
2022-03-27 21:40 ` [bug#49672] [PATCH v2 4/6] gnu: Use ‘current-target-nix-system’ for matches Thiago Jung Bauermann via Guix-patches via
2022-03-27 21:40 ` [bug#49672] [PATCH v2 5/6] gnu: Query membership in ‘supported-systems’ list with Nix identifier Thiago Jung Bauermann via Guix-patches via
2022-03-27 21:40 ` [bug#49672] [PATCH v2 6/6] gnu: Fix check of ‘%current-system’ and ‘%current-target-system’ Thiago Jung Bauermann via Guix-patches via
2022-03-28 12:10 ` [bug#49672] [PATCH v2 0/6] Target check fixes for cross compilation Maxime Devos
2022-03-29 0:12 ` Thiago Jung Bauermann via Guix-patches via
2022-04-29 4:17 ` Thiago Jung Bauermann via Guix-patches via
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210721010043.632012-1-bauermann@kolabnow.com \
--to=guix-patches@gnu.org \
--cc=49672@debbugs.gnu.org \
--cc=bauermann@kolabnow.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.