From 54376cfcdb7fb1fa6acffa93b69889034a6136a7 Mon Sep 17 00:00:00 2001 From: Nicolas Graves Date: Tue, 28 Apr 2026 09:48:57 +0200 Subject: gnu: glibc-headers-mesboot: Improve kernel headers fetch. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is a follow-up to eb504359c76de431c4f88c00a19a1a6c10a3d7f9 and can be merged with it. Signed-off-by: Ludovic Courtès --- gnu/packages/commencement.scm | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm index 8bedce40584..333f828dbaf 100644 --- a/gnu/packages/commencement.scm +++ b/gnu/packages/commencement.scm @@ -1604,13 +1604,16 @@ ac_cv_c_float_format='IEEE (little-endian)' (arguments (substitute-keyword-arguments arguments ((#:configure-flags configure-flags) - #~(let ((ioctl.h (search-input-file %build-inputs - "/include/asm/ioctl.h"))) + #~(let ((kernel-headers + (search-input-directory %build-inputs + #$(if (system-hurd?) + "include/mach" + "include/linux")))) (list (string-append "--prefix=" #$output) "--disable-obsolete-rpc" "--host=i686-unknown-linux-gnu" - (string-append "--with-headers=" (dirname (dirname ioctl.h))) + (string-append "--with-headers=" (dirname kernel-headers)) "--enable-static-nss" "--with-pthread" "--without-cvs" @@ -1652,10 +1655,13 @@ ac_cv_c_float_format='IEEE (little-endian)' (substitute* "configure" (("/bin/pwd") "pwd"))))) (replace 'install - (lambda* (#:key outputs make-flags #:allow-other-keys) - (let* ((ioctl.h (search-input-file %build-inputs - "/include/asm/ioctl.h")) - (kernel-headers (dirname (dirname (dirname ioctl.h))))) + (lambda* (#:key inputs outputs make-flags #:allow-other-keys) + (let* ((kernel-headers + (search-input-directory inputs + #$(if (system-hurd?) + "include/mach" + "include/linux"))) + (kernel-headers (dirname (dirname kernel-headers)))) (apply invoke "make" make-flags) (copy-recursively kernel-headers #$output)))) (add-before 'configure 'remove-bashism -- cgit v1.2.3