blob: 615fe8b2d22d3ec88329fc3338c69d1537a1cd9e (
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
|
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-libs/libutp/libutp-0_pre20130213.ebuild,v 1.1 2013/02/13 20:06:49 ssuominen Exp $
EAPI=5
inherit toolchain-funcs
DESCRIPTION="uTorrent Transport Protocol library"
HOMEPAGE="http://github.com/bittorrent/libutp"
SRC_URI="http://dev.gentoo.org/~ssuominen/${P}.tar.xz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
src_prepare() {
# TODO: Build shared library too!
sed -i \
-e "s:g++:$(tc-getCXX):" \
-e '/^CXXFLAGS/s:=:+=:' \
-e 's:-Wall:& $(CFLAGS):' \
Makefile || die
sed -i \
-e "s:g++:$(tc-getCXX):" \
-e 's:-Wall:$(LDFLAGS) $(CXXFLAGS) &:' \
utp_{file,test}/Makefile || die
}
src_compile() {
local d
for d in . utp_file utp_test; do
emake -C ${d}
done
}
src_install() {
dolib.a ${PN}.a
dodoc README.md
dobin utp_file/utp_{recv,send} utp_test/utp_test
}
|