/[gentoo-x86]/net-p2p/bitcoind/bitcoind-0.6.0.10_rc3.ebuild
Gentoo

Contents of /net-p2p/bitcoind/bitcoind-0.6.0.10_rc3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Sun Jan 13 22:34:40 2013 UTC (17 months, 3 weeks ago) by blueness
Branch: MAIN
Changes since 1.1: +3 -11 lines
Remove boost versioning for remaining versions, bug #445180

(Portage version: 2.1.11.31/cvs/Linux x86_64, signed Manifest commit with key 0xF52D4BBA)

1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-p2p/bitcoind/bitcoind-0.6.0.10_rc3.ebuild,v 1.1 2012/10/08 18:04:56 blueness Exp $
4
5 EAPI="4"
6
7 DB_VER="4.8"
8
9 inherit db-use eutils versionator toolchain-funcs
10
11 DESCRIPTION="Original Bitcoin crypto-currency wallet for automated services"
12 HOMEPAGE="http://bitcoin.org/"
13 SRC_URI="http://gitorious.org/bitcoin/bitcoind-stable/archive-tarball/v${PV/_/} -> bitcoin-v${PV}.tgz
14 eligius? ( http://luke.dashjr.org/programs/bitcoin/files/eligius_sendfee/0.6.0-eligius_sendfee.patch.xz )
15 "
16
17 LICENSE="MIT ISC GPL-2"
18 SLOT="0"
19 KEYWORDS="~amd64 ~arm ~x86"
20 IUSE="+eligius examples logrotate ssl upnp"
21
22 RDEPEND="
23 >=dev-libs/boost-1.41.0[threads(+)]
24 dev-libs/openssl[-bindist]
25 logrotate? (
26 app-admin/logrotate
27 )
28 upnp? (
29 net-libs/miniupnpc
30 )
31 sys-libs/db:$(db_ver_to_slot "${DB_VER}")[cxx]
32 "
33 DEPEND="${RDEPEND}
34 >=app-shells/bash-4.1
35 "
36
37 S="${WORKDIR}/bitcoin-bitcoind-stable"
38
39 pkg_setup() {
40 local UG='bitcoin'
41 enewgroup "${UG}"
42 enewuser "${UG}" -1 -1 /var/lib/bitcoin "${UG}"
43 }
44
45 src_prepare() {
46 cd src || die
47 use eligius && epatch "${WORKDIR}/0.6.0-eligius_sendfee.patch"
48 use logrotate && epatch "${FILESDIR}/0.6.0.8-reopen_log_file.patch"
49 }
50
51 src_compile() {
52 OPTS=()
53
54 OPTS+=("DEBUGFLAGS=")
55 OPTS+=("CXXFLAGS=${CXXFLAGS}")
56 OPTS+=("LDFLAGS=${LDFLAGS}")
57
58 OPTS+=("BDB_INCLUDE_PATH=$(db_includedir "${DB_VER}")")
59 OPTS+=("BDB_LIB_SUFFIX=-${DB_VER}")
60
61 use ssl && OPTS+=(USE_SSL=1)
62 if use upnp; then
63 OPTS+=(USE_UPNP=1)
64 else
65 OPTS+=(USE_UPNP=)
66 fi
67
68 cd src || die
69 emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" -f makefile.unix "${OPTS[@]}" ${PN}
70 }
71
72 src_test() {
73 cd src || die
74 emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" -f makefile.unix "${OPTS[@]}" test_bitcoin
75 ./test_bitcoin || die 'Tests failed'
76 }
77
78 src_install() {
79 dobin src/${PN}
80
81 insinto /etc/bitcoin
82 newins "${FILESDIR}/bitcoin.conf" bitcoin.conf
83 fowners bitcoin:bitcoin /etc/bitcoin/bitcoin.conf
84 fperms 600 /etc/bitcoin/bitcoin.conf
85
86 newconfd "${FILESDIR}/bitcoin.confd" ${PN}
87 newinitd "${FILESDIR}/bitcoin.initd" ${PN}
88
89 keepdir /var/lib/bitcoin/.bitcoin
90 fperms 700 /var/lib/bitcoin
91 fowners bitcoin:bitcoin /var/lib/bitcoin/
92 fowners bitcoin:bitcoin /var/lib/bitcoin/.bitcoin
93 dosym /etc/bitcoin/bitcoin.conf /var/lib/bitcoin/.bitcoin/bitcoin.conf
94
95 dodoc doc/README
96
97 if use examples; then
98 docinto examples
99 dodoc -r contrib/{bitrpc,pyminer,wallettools}
100 fi
101
102 if use logrotate; then
103 insinto /etc/logrotate.d
104 newins "${FILESDIR}/bitcoind.logrotate" bitcoind
105 fi
106 }

  ViewVC Help
Powered by ViewVC 1.1.20