diff options
author | Stephan Hartmann <stha09@googlemail.com> | 2020-02-18 16:31:45 +0100 |
---|---|---|
committer | Sergei Trofimovich <slyfox@gentoo.org> | 2020-03-10 19:35:44 +0000 |
commit | 18402f2ef1d009c5141c7dd628ab1cc7edea2d91 (patch) | |
tree | 0cbce1ce6c4122a52b673cabf4317469178ec915 /sys-apps/heirloom-tools | |
parent | dev-python/funcy: bumped to 1.14, added python 3.8 (diff) | |
download | gentoo-18402f2ef1d009c5141c7dd628ab1cc7edea2d91.tar.gz gentoo-18402f2ef1d009c5141c7dd628ab1cc7edea2d91.tar.bz2 gentoo-18402f2ef1d009c5141c7dd628ab1cc7edea2d91.zip |
sys-apps/heirloom-tools: fix building with glibc 2.30
While at it, fix patching with fuzz.
Closes: https://bugs.gentoo.org/692770
Package-Manager: Portage-2.3.84, Repoman-2.3.20
Signed-off-by: Stephan Hartmann <stha09@googlemail.com>
Closes: https://github.com/gentoo/gentoo/pull/14693
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
Diffstat (limited to 'sys-apps/heirloom-tools')
3 files changed, 82 insertions, 9 deletions
diff --git a/sys-apps/heirloom-tools/files/heirloom-tools-070715-glibc-2.30.patch b/sys-apps/heirloom-tools/files/heirloom-tools-070715-glibc-2.30.patch new file mode 100644 index 000000000000..19b90cea6d2a --- /dev/null +++ b/sys-apps/heirloom-tools/files/heirloom-tools-070715-glibc-2.30.patch @@ -0,0 +1,13 @@ +diff --git a/shl/shl.c b/shl/shl.c +index 6f5c2df..30d296c 100644 +--- a/shl/shl.c ++++ b/shl/shl.c +@@ -86,7 +86,7 @@ extern int sysv3; + #include <libgen.h> + #include <limits.h> + #include <stdarg.h> +-#if !defined (__dietlibc__) && !defined (__UCLIBC__) ++#if !defined (__dietlibc__) && !defined (__UCLIBC__) && !defined(__linux__) + #include <stropts.h> + #endif + #include <poll.h> diff --git a/sys-apps/heirloom-tools/files/heirloom-tools-070715-major.patch b/sys-apps/heirloom-tools/files/heirloom-tools-070715-major.patch index 82d32315d819..81e6755e7e32 100644 --- a/sys-apps/heirloom-tools/files/heirloom-tools-070715-major.patch +++ b/sys-apps/heirloom-tools/files/heirloom-tools-070715-major.patch @@ -1,6 +1,8 @@ +diff --git a/cpio/cpio.c b/cpio/cpio.c +index 89c5cbc..210287b 100644 --- a/cpio/cpio.c +++ b/cpio/cpio.c -@@ -91,9 +91,9 @@ +@@ -91,11 +91,12 @@ #include <sfile.h> #include <atoll.h> @@ -10,11 +12,45 @@ -#endif /* _AIX */ +#endif /* _AIX || __GLIBC__ */ - #ifndef major +-#ifndef major ++#include <sys/sysmacros.h> ++#if 0 #include <sys/mkdev.h> + #endif /* !major */ + +diff --git a/file/file.c b/file/file.c +index 6609734..d90af86 100644 +--- a/file/file.c ++++ b/file/file.c +@@ -66,7 +66,8 @@ static const char sccsid[] USED = "@(#)file.sl 1.33 (gritter) 4/14/06"; + #include <fcntl.h> + #include <libgen.h> + #include <inttypes.h> +-#ifndef major ++#include <sys/sysmacros.h> ++#if 0 + #include <sys/mkdev.h> + #endif + #include "iblok.h" +diff --git a/find/find.c b/find/find.c +index fac70f0..28e1b7f 100644 +--- a/find/find.c ++++ b/find/find.c +@@ -83,7 +83,8 @@ static const char sccsid[] USED = "@(#)find.sl 1.45 (gritter) 5/8/06"; + #ifdef _AIX + #include <sys/sysmacros.h> + #endif +-#ifndef major ++#include <sys/sysmacros.h> ++#if 0 + #include <sys/mkdev.h> + #endif + #if __NetBSD_Version__>= 300000000 +diff --git a/ls/ls.c b/ls/ls.c +index e4480d0..17186ba 100644 --- a/ls/ls.c +++ b/ls/ls.c -@@ -119,7 +119,7 @@ +@@ -119,7 +119,7 @@ static char ifmt_c[] = "-pc-d-b--nl-SD--"; #include <termcap.h> #endif /* USE_TERMCAP */ @@ -23,3 +59,31 @@ #include <sys/sysmacros.h> #endif +diff --git a/mknod/mknod.c b/mknod/mknod.c +index b772b88..f465883 100644 +--- a/mknod/mknod.c ++++ b/mknod/mknod.c +@@ -45,7 +45,8 @@ static const char sccsid[] USED = "@(#)mknod.sl 1.8 (gritter) 5/29/05"; + #include <string.h> + #include <limits.h> + #include <unistd.h> +-#ifndef major ++#include <sys/sysmacros.h> ++#if 0 + #include <sys/mkdev.h> + #endif /* !major */ + +diff --git a/tar/tar.c b/tar/tar.c +index 2d3dada..a8f1ccb 100644 +--- a/tar/tar.c ++++ b/tar/tar.c +@@ -98,7 +98,8 @@ static const char sccsid[] USED = "@(#)tar.sl 1.177 (gritter) 4/14/07"; + #include <sys/sysmacros.h> + #endif + +-#ifndef major ++#include <sys/sysmacros.h> ++#if 0 + #include <sys/mkdev.h> + #endif /* !major */ + diff --git a/sys-apps/heirloom-tools/heirloom-tools-070715-r1.ebuild b/sys-apps/heirloom-tools/heirloom-tools-070715-r1.ebuild index 9d55edab0b49..80d2232221aa 100644 --- a/sys-apps/heirloom-tools/heirloom-tools-070715-r1.ebuild +++ b/sys-apps/heirloom-tools/heirloom-tools-070715-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2018 Gentoo Foundation +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -23,16 +23,12 @@ DEPEND=" S="${WORKDIR}/heirloom-${PV}" PATCHES=( "${FILESDIR}"/${P}-major.patch + "${FILESDIR}"/${P}-glibc-2.30.patch ) # slightly broken RESTRICT="test" -src_prepare() { - find . -name '*.c' -exec sed -i -e 's|#ifndef[[:space:]]*major|#include <sys/sysmacros.h>\n#if 0|g' {} + || die - - default -} src_compile() { append-cppflags -D_GNU_SOURCE emake -j1 \ |