Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 1 | https://bugs.gentoo.org/579928 |
| 2 | |
| 3 | From d84db34dbe39d55b4d7e868764c056689aa0793b Mon Sep 17 00:00:00 2001 |
| 4 | From: Mike Frysinger <vapier@gentoo.org> |
| 5 | Date: Tue, 19 Apr 2016 01:56:41 -0400 |
| 6 | Subject: [PATCH] extlinux: pull in sys/sysmacros.h for major/minor/makedev |
| 7 | |
| 8 | These functions are defined in sys/sysmacros.h, so add the include to |
| 9 | main.c. This is already handled correctly in mountinfo.c. Otherwise |
| 10 | we get build failures like: |
| 11 | |
| 12 | main.o: In function 'find_device_sysfs': |
| 13 | extlinux/main.c:1131: undefined reference to 'minor' |
| 14 | |
| 15 | Upstream-Status: Pending |
| 16 | Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> |
| 17 | Signed-off-by: Mike Frysinger <vapier@gentoo.org> |
| 18 | |
| 19 | The first part wasn't enough in OE build, I had to add the same for syslinuxext.c. |
| 20 | --- |
| 21 | extlinux/main.c | 1 + |
| 22 | 1 file changed, 1 insertion(+) |
| 23 | |
| 24 | diff --git a/extlinux/main.c b/extlinux/main.c |
| 25 | index a7ebd49..ebff7ea 100644 |
| 26 | --- a/extlinux/main.c |
| 27 | +++ b/extlinux/main.c |
| 28 | @@ -38,6 +38,7 @@ |
| 29 | #include <sysexits.h> |
| 30 | #include <sys/ioctl.h> |
| 31 | #include <sys/stat.h> |
| 32 | +#include <sys/sysmacros.h> |
| 33 | #include <sys/types.h> |
| 34 | #include <sys/mount.h> |
| 35 | #include <sys/vfs.h> |
| 36 | --- a/libinstaller/syslinuxext.c 2017-02-22 20:17:05.336869181 +0100 |
| 37 | +++ b/libinstaller/syslinuxext.c 2017-02-22 20:16:47.500868751 +0100 |
| 38 | @@ -2,6 +2,7 @@ |
| 39 | |
| 40 | #include <sys/stat.h> |
| 41 | #include <sys/types.h> |
| 42 | +#include <sys/sysmacros.h> |
| 43 | #include <getopt.h> |
| 44 | #include <ext2fs/ext2fs.h> |
| 45 | |