dev-db/kyotocabinet: Fix gcc6 support (#594064 by Peter Levine), port to eapi6, use ltprune.eclass

Package-Manager: Portage-2.3.5, Repoman-2.3.2
This commit is contained in:
Pacho Ramos
2017-04-08 12:06:47 +02:00
parent 8f477fede7
commit 361ae0e37e
2 changed files with 26 additions and 9 deletions

View File

@@ -0,0 +1,11 @@
--- a/kcdbext.h
+++ b/kcdbext.h
@@ -1278,7 +1278,7 @@
if (omode_ == 0) {
set_error(_KCCODELINE_, BasicDB::Error::INVALID, "not opened");
*sp = 0;
- return false;
+ return NULL;
}
if (!cache_) return db_.get(kbuf, ksiz, sp);
size_t dvsiz = 0;

View File

@@ -1,9 +1,9 @@
# Copyright 1999-2016 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
EAPI=6
inherit autotools eutils toolchain-funcs
inherit autotools ltprune toolchain-funcs
DESCRIPTION="A straightforward implementation of DBM"
HOMEPAGE="http://fallabs.com/kyotocabinet/"
@@ -18,13 +18,20 @@ DEPEND="sys-libs/zlib[static-libs?]
app-arch/xz-utils[static-libs?]"
RDEPEND="${DEPEND}"
PATCHES=(
"${FILESDIR}"/fix_configure-1.2.62.patch
"${FILESDIR}"/${PN}-1.2.76-configure-8-byte-atomics.patch
"${FILESDIR}"/${PN}-1.2.76-flags.patch
"${FILESDIR}"/${PN}-1.2.76-gcc6.patch
)
src_prepare() {
epatch "${FILESDIR}"/fix_configure-1.2.62.patch
epatch "${FILESDIR}"/${PN}-1.2.76-configure-8-byte-atomics.patch
epatch "${FILESDIR}"/${PN}-1.2.76-flags.patch
default
sed -i -e "/DOCDIR/d" Makefile.in || die
tc-export AR
mv configure.in configure.ac || die
eautoreconf
}
@@ -32,7 +39,7 @@ src_configure() {
econf $(use_enable debug) \
$(use_enable static-libs static) \
$(use_enable !static-libs shared) \
--enable-lzma --docdir=/usr/share/doc/${PF}
--enable-lzma
}
src_test() {
@@ -40,8 +47,7 @@ src_test() {
}
src_install() {
emake DESTDIR="${D}" install
default
prune_libtool_files
if use examples; then