check for argp header

  • Done
  • quality assurance status badge
Details
2 participants
  • Ludovic Courtès
  • Nikita Gillmann
Owner
unassigned
Submitted by
Nikita Gillmann
Severity
normal
N
N
Nikita Gillmann wrote on 15 May 2020 14:30
(address . guix-patches@gnu.org)
20200515123016.gmeicqvo67qrqpuh@hex
Hi,

as mentioned in IRC I have begun porting Guix to NetBSD (with the path
taken not yet decided upon, just plain building guix itself for now).

Glibc provides argp. Arguably we don't have to check for argp because
Guix targets glibc. But I am quiete certain that there will be people
who will attempt to do what I am doing and run into this.

I haven't tested this, but semantically it should check out. I don't
know how much changed in guix's bootstrap but configure.ac should still be
the right place for this patch.
From eb8214d2cd6b2170f6e05b89dbd8e47e1f0f4326 Mon Sep 17 00:00:00 2001
From: nikita <nikita@n0.is>
Date: Fri, 15 May 2020 14:23:48 +0200
Subject: [PATCH] configure: check for arpg header as required by nix.

This is provided by glibc, porting to a platform without glibc
revealed this lack of check.
---
configure.ac | 3 +++
1 file changed, 3 insertions(+)

Toggle diff (16 lines)
diff --git a/configure.ac b/configure.ac
index 0a20b476eb..174633785a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -266,6 +266,9 @@ else
fi
AC_SUBST([LIBLZ])
+# check for standard headers, required in Nix daemon
+AC_CHECK_HEADERS([argp.h])
+
dnl Check for Guile-SSH, for the (guix ssh) module.
GUIX_CHECK_GUILE_SSH
AM_CONDITIONAL([HAVE_GUILE_SSH],
--
2.25.2
L
L
Ludovic Courtès wrote on 16 May 2020 19:22
(name . Nikita Gillmann)(address . nikita@n0.is)(address . 41286@debbugs.gnu.org)
87ftbzrdzw.fsf@gnu.org
Hi Nikita,

Nikita Gillmann <nikita@n0.is> skribis:

Toggle quote (7 lines)
> as mentioned in IRC I have begun porting Guix to NetBSD (with the path
> taken not yet decided upon, just plain building guix itself for now).
>
> Glibc provides argp. Arguably we don't have to check for argp because
> Guix targets glibc. But I am quiete certain that there will be people
> who will attempt to do what I am doing and run into this.

Guix targets glibc-based systems, so as you write, it’s reasonable to
assume argp is present.

Also, using AC_CHECK_HEADERS doesn’t achieve anything: it only defines
‘HAVE_ARGP_H’ to zero or one.

Last, I don’t want to discourage anyone from porting, but I also want to
be clear about what it entails. I’m strongly in favor of supporting
only glibc because: (1) after all, it’s about GNU as a system, and (2)
my experience with Nixpkgs is that supporting multiple C libraries is
just too much work to maintain good support.

Thus I’m closing for now.

Thanks,
Ludo’.
L
L
Ludovic Courtès wrote on 16 May 2020 19:22
control message for bug #41286
(address . control@debbugs.gnu.org)
87eerjrdzk.fsf@gnu.org
tags 41286 wontfix
close 41286
quit
?
Your comment

This issue is archived.

To comment on this conversation send an email to 41286@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 41286
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch