summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2018-02-17 08:15:54 +0100
committerFabian Groffen <grobian@gentoo.org>2018-02-17 08:15:54 +0100
commit592f652fd2387627411c99bdbb203bbe2339c587 (patch)
treee43893834078e838e92e6549b8fda737a56b8f3c /sys-apps/coreutils/coreutils-8.29.ebuild
parentscripts/bootstrap-prefix: add back initial support for ppc-darwin9 (diff)
downloadprefix-592f652fd2387627411c99bdbb203bbe2339c587.tar.gz
prefix-592f652fd2387627411c99bdbb203bbe2339c587.tar.bz2
prefix-592f652fd2387627411c99bdbb203bbe2339c587.zip
sys-apps/coreutils: add back libstdbuf fixes, bug #647708
Closes: https://bugs.gentoo.org/647708 Package-Manager: Portage-2.3.18-prefix, Repoman-2.3.6
Diffstat (limited to 'sys-apps/coreutils/coreutils-8.29.ebuild')
-rw-r--r--sys-apps/coreutils/coreutils-8.29.ebuild17
1 files changed, 17 insertions, 0 deletions
diff --git a/sys-apps/coreutils/coreutils-8.29.ebuild b/sys-apps/coreutils/coreutils-8.29.ebuild
index fc62029cf3..bbbb8867ae 100644
--- a/sys-apps/coreutils/coreutils-8.29.ebuild
+++ b/sys-apps/coreutils/coreutils-8.29.ebuild
@@ -67,6 +67,23 @@ src_prepare() {
eapply_user
epatch "${FILESDIR}"/${PN}-8.22-mint.patch
+ # fixup libstdbuf non-libtool stuff
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ sed -i \
+ -e "/src_libstdbuf_so_LDFLAGS = -shared/s:-shared:-dynamiclib -install_name ${EPREFIX}/usr/libexec/coreutils/libstdbuf.dylib:" \
+ Makefile.in \
+ || die
+ elif use elibc_Cygwin ; then
+ epatch "${FILESDIR}"/${P}-cygwin-8.26-3.patch
+ sed -i -e 's|\(libstdbuf\.so\)$(EXEEXT)|\1|g' Makefile.in || die
+ fi
+ sed -i \
+ -e "s/libstdbuf\\.so/libstdbuf$(get_libname)/" \
+ src/stdbuf.c \
+ Makefile.in \
+ configure \
+ || die
+
# Since we've patched many .c files, the make process will try to
# re-build the manpages by running `./bin --help`. When doing a
# cross-compile, we can't do that since 'bin' isn't a native bin.