0002-mdadm.h-include-sysmacros.h-unconditionally.patch 1.1 KB

1234567891011121314151617181920212223242526272829303132333435
  1. From 6c781ad75d92c6f65832810c44afcba1b2dffc41 Mon Sep 17 00:00:00 2001
  2. From: Baruch Siach <baruch@tkos.co.il>
  3. Date: Tue, 6 Aug 2019 16:01:15 +0300
  4. Subject: [PATCH] mdadm.h: include sysmacros.h unconditionally
  5. musl libc now also requires sys/sysmacros.h for the major/minor macros.
  6. All supported libc implementations carry sys/sysmacros.h, including
  7. diet-libc, klibc, and uclibc-ng.
  8. Cc: Hauke Mehrtens <hauke@hauke-m.de>
  9. Signed-off-by: Baruch Siach <baruch@tkos.co.il>
  10. ---
  11. Upstream status: https://marc.info/?l=linux-raid&m=156509677018508
  12. mdadm.h | 2 --
  13. 1 file changed, 2 deletions(-)
  14. diff --git a/mdadm.h b/mdadm.h
  15. index c36d7fdb10f6..d61a9ca82dc1 100644
  16. --- a/mdadm.h
  17. +++ b/mdadm.h
  18. @@ -45,10 +45,8 @@ extern __off64_t lseek64 __P ((int __fd, __off64_t __offset, int __whence));
  19. #include <errno.h>
  20. #include <string.h>
  21. #include <syslog.h>
  22. -#ifdef __GLIBC__
  23. /* Newer glibc requires sys/sysmacros.h directly for makedev() */
  24. #include <sys/sysmacros.h>
  25. -#endif
  26. #ifdef __dietlibc__
  27. #include <strings.h>
  28. /* dietlibc has deprecated random and srandom!! */
  29. --
  30. 2.20.1