diff options
author | Mike Frysinger <vapier@gentoo.org> | 2016-04-19 03:10:47 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2016-04-19 03:10:47 -0400 |
commit | 3066e312d61ea915d131290aca54cea4d6496a20 (patch) | |
tree | de20a2b0280c2b8a196348d4841dc974bfd9372b /sys-fs/lsscsi | |
parent | sys-fs/lsscsi: drop old <0.28 versions (diff) | |
download | gentoo-3066e312d61ea915d131290aca54cea4d6496a20.tar.gz gentoo-3066e312d61ea915d131290aca54cea4d6496a20.tar.bz2 gentoo-3066e312d61ea915d131290aca54cea4d6496a20.zip |
sys-fs/lsscsi: fix build w/newer glibc #580494
Diffstat (limited to 'sys-fs/lsscsi')
-rw-r--r-- | sys-fs/lsscsi/files/lsscsi-0.28-sysmacros.patch | 37 | ||||
-rw-r--r-- | sys-fs/lsscsi/lsscsi-0.28.ebuild | 6 |
2 files changed, 43 insertions, 0 deletions
diff --git a/sys-fs/lsscsi/files/lsscsi-0.28-sysmacros.patch b/sys-fs/lsscsi/files/lsscsi-0.28-sysmacros.patch new file mode 100644 index 000000000000..099256fdcdca --- /dev/null +++ b/sys-fs/lsscsi/files/lsscsi-0.28-sysmacros.patch @@ -0,0 +1,37 @@ +https://bugs.gentoo.org/580494 + +From 5f1d6f46c8c1ac134841cfcce22dc7639598e032 Mon Sep 17 00:00:00 2001 +From: Mike Frysinger <vapier@gentoo.org> +Date: Tue, 19 Apr 2016 03:07:23 -0400 +Subject: [PATCH] include sys/sysmacros.h for major/minor + +These funcs are defined in sys/sysmacros.h, so include it to avoid: +lsscsi.c: In function 'collect_dev_nodes': +lsscsi.c:961:32: warning: implicit declaration of function 'major' [-Wimplicit-function-declaration] + cur_ent->maj = major(stats.st_rdev); + ^ +lsscsi.c:962:32: warning: implicit declaration of function 'minor' [-Wimplicit-function-declaration] + cur_ent->min = minor(stats.st_rdev); + ^ +lsscsi.o: In function 'get_dev_node': +lsscsi.c:(.text+0x10f0): undefined reference to 'major' +lsscsi.c:(.text+0x1117): undefined reference to 'minor' +--- + src/lsscsi.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/lsscsi.c b/src/lsscsi.c +index e494169..61cfebd 100644 +--- a/src/lsscsi.c ++++ b/src/lsscsi.c +@@ -23,6 +23,7 @@ + #include <unistd.h> + #include <getopt.h> + #include <fcntl.h> ++#include <sys/sysmacros.h> + #include <sys/types.h> + #include <sys/stat.h> + #include <dirent.h> +-- +2.7.4 + diff --git a/sys-fs/lsscsi/lsscsi-0.28.ebuild b/sys-fs/lsscsi/lsscsi-0.28.ebuild index e3700959f087..f11c94795ef7 100644 --- a/sys-fs/lsscsi/lsscsi-0.28.ebuild +++ b/sys-fs/lsscsi/lsscsi-0.28.ebuild @@ -4,6 +4,8 @@ EAPI=5 +inherit eutils + DESCRIPTION="SCSI sysfs query tool" HOMEPAGE="http://sg.danny.cz/scsi/lsscsi.html" SRC_URI="http://sg.danny.cz/scsi/${P}.tgz" @@ -11,3 +13,7 @@ SRC_URI="http://sg.danny.cz/scsi/${P}.tgz" LICENSE="GPL-2" SLOT="0" KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 sparc x86" + +src_prepare() { + epatch "${FILESDIR}"/${P}-sysmacros.patch #580494 +} |