From: soeren@soeren-tempel.net
To: 65486@debbugs.gnu.org
Cc: ludo@gnu.org
Subject: [bug#65486] [PATCH v3] syscalls: Consistently use existing linux? definition
Date: Sun, 17 Sep 2023 17:21:48 +0200 [thread overview]
Message-ID: <20230917152149.8587-1-soeren@soeren-tempel.net> (raw)
In-Reply-To: <87il89yugy.fsf@gnu.org>
From: Sören Tempel <soeren@soeren-tempel.net>
Instead of duplicating this existing logic across the source file. This
will make it easier to add additional linux targets (e.g. linux-musl) in
the future.
* guix/build/syscalls.scm (readdir*): Use linux? constant.
* guix/build/syscalls.scm (write-socket-address!): Use linux? constant.
* guix/build/syscalls.scm (read-socket-address): Use linux? constant.
Signed-off-by: Sören Tempel <soeren@soeren-tempel.net>
---
guix/build/syscalls.scm | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/guix/build/syscalls.scm b/guix/build/syscalls.scm
index d947b010d3..c9c0bf594d 100644
--- a/guix/build/syscalls.scm
+++ b/guix/build/syscalls.scm
@@ -1244,7 +1244,7 @@ (define (readdir-procedure name-field-offset sizeof-dirent-header
(define readdir*
;; Decide at run time which one must be used.
- (if (string-contains %host-type "linux-gnu")
+ (if linux?
(readdir-procedure (c-struct-field-offset %struct-dirent-header/linux
name)
sizeof-dirent-header/linux
@@ -1664,7 +1664,7 @@ (define (write-socket-address!/hurd sockaddr bv index)
(error "unsupported socket address" sockaddr)))))
(define write-socket-address!
- (if (string-contains %host-type "linux-gnu")
+ (if linux?
write-socket-address!/linux
write-socket-address!/hurd))
@@ -1696,7 +1696,7 @@ (define* (read-socket-address/hurd bv #:optional (index 0))
(vector family)))))
(define read-socket-address
- (if (string-contains %host-type "linux-gnu")
+ (if linux?
read-socket-address/linux
read-socket-address/hurd))
next prev parent reply other threads:[~2023-09-17 15:23 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-24 6:33 [bug#65486] [PATCH] syscalls: Add support for musl libc soeren
2023-09-09 13:04 ` [bug#65486] [PATCH v2] " soeren
2023-09-11 21:09 ` [bug#65486] [PATCH] " Ludovic Courtès
2023-09-13 10:23 ` Sören Tempel
2023-09-13 20:39 ` Ludovic Courtès
2023-09-15 10:57 ` Sören Tempel
2023-09-17 10:14 ` bug#65486: " Ludovic Courtès
2023-09-17 10:17 ` [bug#65486] " Ludovic Courtès
2023-09-17 11:38 ` Christopher Baines
2023-09-17 15:21 ` soeren [this message]
2023-09-17 15:21 ` [bug#65486] [PATCH v3] " soeren
2023-09-30 10:16 ` [bug#65486] [PATCH] " Sören Tempel
2023-10-10 17:15 ` Christopher Baines
2023-10-23 10:11 ` Ludovic Courtès
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=20230917152149.8587-1-soeren@soeren-tempel.net \
--to=soeren@soeren-tempel.net \
--cc=65486@debbugs.gnu.org \
--cc=ludo@gnu.org \
/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.