blob: 063a3b4e6a2a65e4dae907066dc47880421cba4a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="7"
inherit toolchain-funcs
DESCRIPTION="A very fast and simple package for creating and reading constant data bases"
HOMEPAGE="http://www.corpit.ru/mjt/tinycdb.html"
SRC_URI="http://www.corpit.ru/mjt/${PN}/${P}.tar.gz"
LICENSE="public-domain"
SLOT="0"
KEYWORDS="~amd64 ~arm64 ~hppa ~ia64 ~mips ~ppc ~x86"
IUSE="static-libs"
RESTRICT="test"
RDEPEND="!dev-db/cdb"
PATCHES=(
"${FILESDIR}"/${PN}-gentoo.patch
"${FILESDIR}"/${PN}-uclibc.patch
)
src_prepare() {
default
sed -i "/^libdir/s:/lib:/$(get_libdir):" Makefile
}
src_compile() {
local targets="shared"
use static-libs && targets+=" staticlib piclib"
emake \
CC="$(tc-getCC)" \
CFLAGS="${CFLAGS}" \
LDFLAGS="${LDFLAGS}" \
${targets}
}
src_install() {
local targets="install install-sharedlib"
use static-libs && targets+=" install-piclib"
emake \
prefix="${EPREFIX}"/usr \
mandir="${EPREFIX}"/usr/share/man \
DESTDIR="${D}" \
${targets}
einstalldocs
}
|