summary refs log tree commit diff
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2018-10-15 10:31:24 +0200
committerLudovic Courtès <ludo@gnu.org>2018-10-15 10:31:24 +0200
commitf1a9c6e581e3b90713d11801dbab9a611f6fe63a (patch)
tree868ffafa8c3f02d94d11a29c3ff1cab6440650a9
parentc2397a869549b6786b801ab816acdba68555494a (diff)
downloadguix-f1a9c6e581e3b90713d11801dbab9a611f6fe63a.tar.gz
gnu: lsof: Fix builds on glibc 2.28.
* gnu/packages/lsof.scm (lsof)[arguments]: In 'disable-failing-tests',
add 'substitute*' use for "tests/LTlib.c".
-rw-r--r--gnu/packages/lsof.scm7
1 files changed, 7 insertions, 0 deletions
diff --git a/gnu/packages/lsof.scm b/gnu/packages/lsof.scm
index 8b3ebe2945..311e244608 100644
--- a/gnu/packages/lsof.scm
+++ b/gnu/packages/lsof.scm
@@ -2,6 +2,7 @@
 ;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
 ;;; Copyright © 2017 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
+;;; Copyright © 2018 Ludovic Courtès <ludo@gnu.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -77,6 +78,12 @@
             #t))
         (add-before 'check 'disable-failing-tests
           (lambda _
+            ;; In libc 2.28, the 'major' and 'minor' macros are provided by
+            ;; <sys/sysmacros.h> only so include it.
+            (substitute* "tests/LTlib.c"
+              (("#ifndef lint")
+               "#include <sys/sysmacros.h>\n\n#ifndef lint"))
+
             (substitute* "tests/Makefile"
               ;; Fails with ‘ERROR!!! client gethostbyaddr() failure’.
               (("(STDTST=.*) LTsock" _ prefix) prefix)