void-packages/srcpkgs/libnfs/patches/sysmacros_makedev.patch
Jürgen Buchmüller 8f3b5b9384 libnfs: fix build
Since kernel-libc-headers was updated to 4.9.8 the macros `makedev`, `major`
and `minor` are defined in the include file `sys/sysmacros.h`. The definitions
in `sys/types.h` are obsoleted and will be removed soon.

This fix moves the `#include <sys/sysmacros.h>` after the `#include <sys/types.h>`.

Closes #5704
2017-02-09 22:13:05 +01:00

25 lines
520 B
Diff

--- lib/libnfs.c 2016-10-09 20:23:11.000000000 +0200
+++ lib/libnfs.c 2017-02-09 22:11:03.882598292 +0100
@@ -64,14 +64,6 @@
#include <strings.h>
#endif
-#ifdef MAJOR_IN_MKDEV
-#include <sys/mkdev.h>
-#endif
-
-#ifdef MAJOR_IN_SYSMACROS
-#include <sys/sysmacros.h>
-#endif
-
#include <stdio.h>
#include <stdarg.h>
#include <stdlib.h>
@@ -82,6 +74,7 @@
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
+#include <sys/sysmacros.h>
#include "libnfs-zdr.h"
#include "slist.h"
#include "libnfs.h"