Gentoo Archives: gentoo-commits

From: Eray Aslan <eras@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-db/cdb/
Date: Mon, 26 Oct 2015 08:46:46
Message-Id: 1445849092.0a32d771562dcc35dc339a0b9ab386807f3585a8.eras@gentoo
1 commit: 0a32d771562dcc35dc339a0b9ab386807f3585a8
2 Author: Eray Aslan <eras <AT> gentoo <DOT> org>
3 AuthorDate: Mon Oct 26 08:44:52 2015 +0000
4 Commit: Eray Aslan <eras <AT> gentoo <DOT> org>
5 CommitDate: Mon Oct 26 08:44:52 2015 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0a32d771
7
8 dev-db/cdb: compile with -fPIC
9
10 Gentoo-Bug: 563210
11
12 Package-Manager: portage-2.2.23
13
14 dev-db/cdb/cdb-0.75-r4.ebuild | 53 +++++++++++++++++++++++++++++++++++++++++++
15 1 file changed, 53 insertions(+)
16
17 diff --git a/dev-db/cdb/cdb-0.75-r4.ebuild b/dev-db/cdb/cdb-0.75-r4.ebuild
18 new file mode 100644
19 index 0000000..5e335ed
20 --- /dev/null
21 +++ b/dev-db/cdb/cdb-0.75-r4.ebuild
22 @@ -0,0 +1,53 @@
23 +# Copyright 1999-2015 Gentoo Foundation
24 +# Distributed under the terms of the GNU General Public License v2
25 +# $Id$
26 +
27 +EAPI=5
28 +inherit eutils multilib toolchain-funcs
29 +
30 +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos"
31 +
32 +DESCRIPTION="Fast, reliable, simple package for creating and reading constant databases"
33 +HOMEPAGE="http://cr.yp.to/cdb.html"
34 +SRC_URI="http://cr.yp.to/cdb/${P}.tar.gz"
35 +LICENSE="public-domain"
36 +SLOT="0"
37 +IUSE=""
38 +
39 +DEPEND=">=sys-apps/sed-4
40 + !dev-db/tinycdb"
41 +RDEPEND="${DEPEND}"
42 +
43 +src_prepare() {
44 + epatch "${FILESDIR}"/${P}-errno.diff
45 + epatch "${FILESDIR}"/${P}-stdint.diff
46 +
47 + sed -i -e 's/head -1/head -n 1/g' Makefile \
48 + || die "sed Makefile failed"
49 +}
50 +
51 +src_configure() {
52 + echo "$(tc-getCC) ${CFLAGS} -fPIC" > conf-cc
53 + echo "$(tc-getCC) ${LDFLAGS}" > conf-ld
54 + echo "${EPREFIX}/usr" > conf-home
55 +}
56 +
57 +src_install() {
58 + dobin cdbdump cdbget cdbmake cdbmake-12 cdbmake-sv cdbstats cdbtest \
59 + || die "dobin failed"
60 +
61 + # ok so ... first off, some automakes fail at finding
62 + # cdb.a, so install that now
63 + dolib *.a || die "dolib failed"
64 +
65 + # then do this pretty little symlinking to solve the somewhat
66 + # cosmetic library issue at hand
67 + dosym cdb.a /usr/$(get_libdir)/libcdb.a || die "dosym failed"
68 +
69 + # uint32.h needs installation too, otherwise compiles depending
70 + # on it will fail
71 + insinto /usr/include/cdb
72 + doins cdb*.h buffer.h alloc.h uint32.h || die "doins failed"
73 +
74 + dodoc CHANGES FILES README SYSDEPS TODO VERSION
75 +}