summaryrefslogtreecommitdiff
blob: 13a92e7cdd4100d7c7663d0841038de188092468 (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
EAPI="5"
inherit waf-utils

DESCRIPTION="Seek"
HOMEPAGE="https://github.com/zougloub/libseek/"
SRC_URI="https://github.com/zougloub/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
http://ftp.waf.io/pub/release/waf-1.8.5"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 amd64-linux"
IUSE=""

src_prepare() {
        cp "${DISTDIR}"/waf-1.8.5 waf
        chmod +x waf

        epatch "${FILESDIR}"/${P}-shared_library.patch
}

# note: libseek waf fails when passed --libdir:
# waf: error: no such option: --libdir
src_configure() {
	${WAF_BINARY:="${S}/waf"}

	tc-export AR CC CPP CXX RANLIB
	echo "CCFLAGS=\"${CFLAGS}\" LINKFLAGS=\"${LDFLAGS}\" \"${WAF_BINARY}\" --prefix=${EPREFIX}/usr $@ configure"

	CCFLAGS="${CFLAGS}" LINKFLAGS="${LDFLAGS}" "${WAF_BINARY}" \
		"--prefix=${EPREFIX}/usr" \
		"$@" \
		configure || die "configure failed"
}