diff options
author | Sebastian Pipping <sping@gentoo.org> | 2020-11-26 19:33:02 +0100 |
---|---|---|
committer | Sebastian Pipping <sping@gentoo.org> | 2020-11-26 19:36:37 +0100 |
commit | 129f4ab9f8571c651937c46ba7bd4c82d6d052a2 (patch) | |
tree | b0eb60041e2e3169350ad7792a7bbac33d024eed /dev-libs/libowfat | |
parent | dev-libs/pugixml: cleanup old (diff) | |
download | gentoo-129f4ab9f8571c651937c46ba7bd4c82d6d052a2.tar.gz gentoo-129f4ab9f8571c651937c46ba7bd4c82d6d052a2.tar.bz2 gentoo-129f4ab9f8571c651937c46ba7bd4c82d6d052a2.zip |
dev-libs/libowfat: Fix compile with GCC 10 for www-servers/gatling
Closes: https://bugs.gentoo.org/756847
Signed-off-by: Sebastian Pipping <sping@gentoo.org>
Package-Manager: Portage-3.0.0, Repoman-2.3.23
Diffstat (limited to 'dev-libs/libowfat')
-rw-r--r-- | dev-libs/libowfat/files/libowfat-0.32-gcc10.patch | 25 | ||||
-rw-r--r-- | dev-libs/libowfat/libowfat-0.32-r2.ebuild | 49 |
2 files changed, 74 insertions, 0 deletions
diff --git a/dev-libs/libowfat/files/libowfat-0.32-gcc10.patch b/dev-libs/libowfat/files/libowfat-0.32-gcc10.patch new file mode 100644 index 000000000000..3f2924304318 --- /dev/null +++ b/dev-libs/libowfat/files/libowfat-0.32-gcc10.patch @@ -0,0 +1,25 @@ +From 67729f54c2e7a24b2bebfa23b75afe607c09a67a Mon Sep 17 00:00:00 2001 +From: Sebastian Pipping <sebastian@pipping.org> +Date: Thu, 26 Nov 2020 19:28:03 +0100 +Subject: [PATCH] Fix build with -fno-common or GCC 10 + +--- + io_internal.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/io_internal.h b/io_internal.h +index 6d37c11..3e378d9 100644 +--- a/io_internal.h ++++ b/io_internal.h +@@ -83,7 +83,7 @@ my_extern array io_pollfds; + my_extern long first_readable; + my_extern long first_writeable; + +-my_extern long first_deferred; ++extern long first_deferred; + + my_extern enum __io_waitmode { + UNDECIDED, +-- +2.27.0 + diff --git a/dev-libs/libowfat/libowfat-0.32-r2.ebuild b/dev-libs/libowfat/libowfat-0.32-r2.ebuild new file mode 100644 index 000000000000..6e711f600ef4 --- /dev/null +++ b/dev-libs/libowfat/libowfat-0.32-r2.ebuild @@ -0,0 +1,49 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +inherit flag-o-matic toolchain-funcs + +DESCRIPTION="reimplement libdjb - excellent libraries from Dan Bernstein" +SRC_URI="https://www.fefe.de/${PN}/${P}.tar.xz" +HOMEPAGE="https://www.fefe.de/libowfat/" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~hppa ~sparc ~x86" +IUSE="diet" + +RDEPEND="diet? ( >=dev-libs/dietlibc-0.33_pre20090721 )" +DEPEND="${RDEPEND} + >=sys-apps/sed-4" + +PATCHES=( + "${FILESDIR}"/${P}-gcc10.patch +) + +pkg_setup() { + # Required for mult/umult64.c to be usable + append-flags -fomit-frame-pointer +} + +src_compile() { + emake \ + CC=$(tc-getCC) \ + CFLAGS="-I. ${CFLAGS}" \ + DIET="${EPREFIX}/usr/bin/diet -Os" \ + prefix="${EPREFIX}/usr" \ + INCLUDEDIR="${EPREFIX}/usr/include" \ + $( use diet || echo 'DIET=' ) +} + +src_install() { + emake \ + DESTDIR="${D}" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + MAN3DIR="${EPREFIX}/usr/share/man/man3" \ + INCLUDEDIR="${EPREFIX}/usr/include" \ + install + + mv "${ED}"/usr/share/man/man3/{buffer.3,owfat-buffer.3} || die +} |