/[gentoo-x86]/net-p2p/bitcoind/bitcoind-0.6.4_rc4-r1.ebuild
Gentoo

Contents of /net-p2p/bitcoind/bitcoind-0.6.4_rc4-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Sun Jan 13 22:34:40 2013 UTC (23 months 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.4_rc4-r1.ebuild,v 1.1 2012/12/06 13:21:24 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}-r1.tgz
14 eligius? ( http://luke.dashjr.org/programs/bitcoin/files/bitcoind/eligius/sendfee/0.6.1-eligius_sendfee.patch.xz )
15 logrotate? ( https://github.com/bitcoin/bitcoin/commit/9af080c351c40a4f56d37174253d33a9f4ffdb69.diff -> 0.6.3-reopen_log_file.patch )
16 "
17
18 LICENSE="MIT ISC GPL-2"
19 SLOT="0"
20 KEYWORDS="~amd64 ~arm ~x86"
21 IUSE="+eligius examples logrotate upnp"
22
23 RDEPEND="
24 >=dev-libs/boost-1.41.0[threads(+)]
25 dev-libs/openssl[-bindist]
26 logrotate? (
27 app-admin/logrotate
28 )
29 upnp? (
30 net-libs/miniupnpc
31 )
32 sys-libs/db:$(db_ver_to_slot "${DB_VER}")[cxx]
33 "
34 DEPEND="${RDEPEND}
35 >=app-shells/bash-4.1
36 "
37
38 S="${WORKDIR}/bitcoin-bitcoind-stable"
39
40 pkg_setup() {
41 local UG='bitcoin'
42 enewgroup "${UG}"
43 enewuser "${UG}" -1 -1 /var/lib/bitcoin "${UG}"
44 }
45
46 src_prepare() {
47 cd src || die
48 use eligius && epatch "${WORKDIR}/0.6.1-eligius_sendfee.patch"
49 use logrotate && epatch "${DISTDIR}/0.6.3-reopen_log_file.patch"
50 }
51
52 src_compile() {
53 OPTS=()
54
55 OPTS+=("DEBUGFLAGS=")
56 OPTS+=("CXXFLAGS=${CXXFLAGS}")
57 OPTS+=("LDFLAGS=${LDFLAGS}")
58
59 OPTS+=("BDB_INCLUDE_PATH=$(db_includedir "${DB_VER}")")
60 OPTS+=("BDB_LIB_SUFFIX=-${DB_VER}")
61
62 if use upnp; then
63 OPTS+=(USE_UPNP=1)
64 else
65 OPTS+=(USE_UPNP=)
66 fi
67
68 # Workaround for bug #440034
69 share/genbuild.sh src/obj/build.h
70
71 cd src || die
72 emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" -f makefile.unix "${OPTS[@]}" ${PN}
73 }
74
75 src_test() {
76 cd src || die
77 emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" -f makefile.unix "${OPTS[@]}" test_bitcoin
78 ./test_bitcoin || die 'Tests failed'
79 }
80
81 src_install() {
82 dobin src/${PN}
83
84 insinto /etc/bitcoin
85 newins "${FILESDIR}/bitcoin.conf" bitcoin.conf
86 fowners bitcoin:bitcoin /etc/bitcoin/bitcoin.conf
87 fperms 600 /etc/bitcoin/bitcoin.conf
88
89 newconfd "${FILESDIR}/bitcoin.confd" ${PN}
90 newinitd "${FILESDIR}/bitcoin.initd" ${PN}
91
92 keepdir /var/lib/bitcoin/.bitcoin
93 fperms 700 /var/lib/bitcoin
94 fowners bitcoin:bitcoin /var/lib/bitcoin/
95 fowners bitcoin:bitcoin /var/lib/bitcoin/.bitcoin
96 dosym /etc/bitcoin/bitcoin.conf /var/lib/bitcoin/.bitcoin/bitcoin.conf
97
98 dodoc doc/README
99
100 if use examples; then
101 docinto examples
102 dodoc -r contrib/{bitrpc,pyminer,wallettools}
103 fi
104
105 if use logrotate; then
106 insinto /etc/logrotate.d
107 newins "${FILESDIR}/bitcoind.logrotate" bitcoind
108 fi
109 }

  ViewVC Help
Powered by ViewVC 1.1.20