Lines 1-135
Link Here
|
1 |
# Created by: Shaun Amott <shaun@FreeBSD.org> |
1 |
# Created by: Shaun Amott <shaun@FreeBSD.org> |
2 |
# $FreeBSD$ |
2 |
# $FreeBSD$ |
3 |
|
3 |
|
4 |
PORTNAME= bitcoin |
4 |
PORTNAME= bitcoin |
5 |
PORTVERSION= 0.16.0 |
5 |
PORTVERSION= 0.16.1 |
6 |
DISTVERSIONPREFIX= v |
6 |
DISTVERSIONPREFIX= v |
7 |
PORTREVISION?= 3 |
7 |
PORTREVISION?= 0 |
8 |
CATEGORIES= net-p2p finance |
8 |
CATEGORIES= net-p2p finance |
9 |
|
9 |
|
10 |
MAINTAINER= kbowling@FreeBSD.org |
10 |
MAINTAINER= kbowling@FreeBSD.org |
11 |
COMMENT?= Virtual Peer-to-Peer Currency Client (QT) |
11 |
COMMENT?= Virtual Peer-to-Peer Currency Client (QT) |
12 |
|
12 |
|
13 |
LICENSE= MIT |
13 |
LICENSE= MIT |
14 |
|
14 |
|
15 |
LIB_DEPENDS= libboost_date_time.so:devel/boost-libs \ |
15 |
LIB_DEPENDS= libboost_date_time.so:devel/boost-libs \ |
16 |
libevent.so:devel/libevent |
16 |
libevent.so:devel/libevent |
17 |
|
17 |
|
18 |
BROKEN_powerpc64= fails to compile: util.cpp: undefined reference to boost::program_options::to_internal |
18 |
BROKEN_powerpc64= fails to compile: util.cpp: undefined reference to boost::program_options::to_internal |
19 |
|
19 |
|
20 |
USES= autoreconf compiler:c++11-lib gmake libtool pkgconfig shebangfix ssl |
20 |
USES= autoreconf compiler:c++11-lib gmake libtool pkgconfig shebangfix ssl |
21 |
USE_GITHUB= yes |
21 |
USE_GITHUB= yes |
22 |
GNU_CONFIGURE= yes |
22 |
GNU_CONFIGURE= yes |
23 |
|
23 |
|
24 |
SLAVE_PORT?= no |
24 |
SLAVE_PORT?= no |
25 |
|
25 |
|
26 |
.if defined(SLAVE_PORT) && ${SLAVE_PORT} == "no" |
26 |
.if defined(SLAVE_PORT) && ${SLAVE_PORT} == "no" |
27 |
USES+= desktop-file-utils |
27 |
USES+= desktop-file-utils |
28 |
USE_QT5= core gui network widgets \ |
28 |
USE_QT5= core gui network widgets \ |
29 |
buildtools_build linguisttools_build qmake_build |
29 |
buildtools_build linguisttools_build qmake_build |
30 |
|
30 |
|
31 |
BUILD_DEPENDS+= protoc:devel/protobuf |
31 |
BUILD_DEPENDS+= protoc:devel/protobuf |
32 |
LIB_DEPENDS+= libprotobuf.so:devel/protobuf |
32 |
LIB_DEPENDS+= libprotobuf.so:devel/protobuf |
33 |
|
33 |
|
34 |
TESTS_USE= QT5=testlib |
34 |
TESTS_USE= QT5=testlib |
35 |
TESTS_PLIST_FILES= bin/test_bitcoin-qt \ |
35 |
TESTS_PLIST_FILES= bin/test_bitcoin-qt \ |
36 |
bin/test_bitcoin |
36 |
bin/test_bitcoin |
37 |
.endif |
37 |
.endif |
38 |
|
38 |
|
39 |
OPTIONS_DEFINE?= DBUS DEBUG HARDENING QRCODES TESTS UPNP ZMQ |
39 |
OPTIONS_DEFINE?= DBUS DEBUG HARDENING QRCODES TESTS UPNP ZMQ |
40 |
OPTIONS_RADIO?= WALLET |
40 |
OPTIONS_RADIO?= WALLET |
41 |
OPTIONS_RADIO_WALLET?= WALLET_BDB48 WALLET_BDBMODERN |
41 |
OPTIONS_RADIO_WALLET?= WALLET_BDB48 WALLET_BDBMODERN |
42 |
OPTIONS_DEFAULT?= DBUS HARDENING QRCODES UPNP WALLET_BDBMODERN |
42 |
OPTIONS_DEFAULT?= DBUS HARDENING QRCODES UPNP WALLET_BDBMODERN |
43 |
OPTIONS_SUB= yes |
43 |
OPTIONS_SUB= yes |
44 |
|
44 |
|
45 |
HARDENING_DESC= Attempt to harden binaries (PIE for ASLR, NX Stack) |
45 |
HARDENING_DESC= Attempt to harden binaries (PIE for ASLR, NX Stack) |
46 |
QRCODES_DESC= Display QR Codes |
46 |
QRCODES_DESC= Display QR Codes |
47 |
TESTS_DESC= Build test binary and unit tests |
47 |
TESTS_DESC= Build test binary and unit tests |
48 |
WALLET_DESC= Wallet Management Support |
48 |
WALLET_DESC= Wallet Management Support |
49 |
WALLET_BDB48_DESC= Wallet using BDB 4.8 |
49 |
WALLET_BDB48_DESC= Wallet using BDB 4.8 |
50 |
WALLET_BDBMODERN_DESC= Wallet using modern BDB 5.x or 6.x |
50 |
WALLET_BDBMODERN_DESC= Wallet using modern BDB 5.x or 6.x |
51 |
ZMQ_DESC= Block and transaction broadcasting with ZeroMQ |
51 |
ZMQ_DESC= Block and transaction broadcasting with ZeroMQ |
52 |
|
52 |
|
53 |
DBUS_CONFIGURE_WITH= dbus |
53 |
DBUS_CONFIGURE_WITH= dbus |
54 |
DBUS_USE= QT5=dbus |
54 |
DBUS_USE= QT5=dbus |
55 |
|
55 |
|
56 |
DEBUG_CONFIGURE_ENABLE= debug |
56 |
DEBUG_CONFIGURE_ENABLE= debug |
57 |
DEBUG_INSTALL_TARGET_OFF= install-strip |
57 |
DEBUG_INSTALL_TARGET_OFF= install-strip |
58 |
|
58 |
|
59 |
HARDENING_CONFIGURE_ENABLE= hardening |
59 |
HARDENING_CONFIGURE_ENABLE= hardening |
60 |
|
60 |
|
61 |
TESTS_CONFIGURE_ENABLE= tests bench |
61 |
TESTS_CONFIGURE_ENABLE= tests bench |
62 |
.if defined(SLAVE_PORT) && ${SLAVE_PORT} == "yes" |
62 |
.if defined(SLAVE_PORT) && ${SLAVE_PORT} == "yes" |
63 |
TESTS_PLIST_FILES= bin/test_bitcoin |
63 |
TESTS_PLIST_FILES= bin/test_bitcoin |
64 |
.endif |
64 |
.endif |
65 |
TESTS_PLIST_FILES+= bin/bench_bitcoin |
65 |
TESTS_PLIST_FILES+= bin/bench_bitcoin |
66 |
|
66 |
|
67 |
UPNP_CONFIGURE_WITH= miniupnpc |
67 |
UPNP_CONFIGURE_WITH= miniupnpc |
68 |
UPNP_LIB_DEPENDS= libminiupnpc.so:net/miniupnpc |
68 |
UPNP_LIB_DEPENDS= libminiupnpc.so:net/miniupnpc |
69 |
UPNP_CPPFLAGS= -I${LOCALBASE}/include |
69 |
UPNP_CPPFLAGS= -I${LOCALBASE}/include |
70 |
UPNP_LIBS= -L${LOCALBASE}/lib |
70 |
UPNP_LIBS= -L${LOCALBASE}/lib |
71 |
|
71 |
|
72 |
QRCODES_CONFIGURE_WITH= qrencode |
72 |
QRCODES_CONFIGURE_WITH= qrencode |
73 |
QRCODES_LIB_DEPENDS= libqrencode.so:graphics/libqrencode |
73 |
QRCODES_LIB_DEPENDS= libqrencode.so:graphics/libqrencode |
74 |
|
74 |
|
75 |
ZMQ_CONFIGURE_ENABLE= zmq |
75 |
ZMQ_CONFIGURE_ENABLE= zmq |
76 |
ZMQ_BUILD_DEPENDS= libzmq4>0:net/libzmq4 |
76 |
ZMQ_BUILD_DEPENDS= libzmq4>0:net/libzmq4 |
77 |
ZMQ_RUN_DEPENDS= libzmq4>0:net/libzmq4 |
77 |
ZMQ_RUN_DEPENDS= libzmq4>0:net/libzmq4 |
78 |
|
78 |
|
79 |
GH_ACCOUNT= bitcoin |
79 |
GH_ACCOUNT= bitcoin |
80 |
|
80 |
|
81 |
CONFIGURE_ARGS?= --without-libs \ |
81 |
CONFIGURE_ARGS?= --without-libs \ |
82 |
--with-gui=qt5 \ |
82 |
--with-gui=qt5 \ |
83 |
--without-daemon \ |
83 |
--without-daemon \ |
84 |
--without-utils |
84 |
--without-utils |
85 |
|
85 |
|
86 |
CONFIGURE_ENV= CRYPTO_CFLAGS="-I${OPENSSLINC}" CRYPTO_LIBS="-L${OPENSSLLIB} -lcrypto" \ |
86 |
CONFIGURE_ENV= CRYPTO_CFLAGS="-I${OPENSSLINC}" CRYPTO_LIBS="-L${OPENSSLLIB} -lcrypto" \ |
87 |
SSL_CFLAGS="-I${OPENSSLINC}" SSL_LIBS="-L${OPENSSLLIB} -lssl" \ |
87 |
SSL_CFLAGS="-I${OPENSSLINC}" SSL_LIBS="-L${OPENSSLLIB} -lssl" \ |
88 |
OBJCXX="${CXX}" OBJCXXFLAGS="${CXXFLAGS}" |
88 |
OBJCXX="${CXX}" OBJCXXFLAGS="${CXXFLAGS}" |
89 |
MAKE_ENV+= V=1 |
89 |
MAKE_ENV+= V=1 |
90 |
|
90 |
|
91 |
PLIST_FILES?= bin/bitcoin-qt man/man1/bitcoin-qt.1.gz \ |
91 |
PLIST_FILES?= bin/bitcoin-qt man/man1/bitcoin-qt.1.gz \ |
92 |
share/applications/bitcoin-qt.desktop share/pixmaps/bitcoin128.png |
92 |
share/applications/bitcoin-qt.desktop share/pixmaps/bitcoin128.png |
93 |
|
93 |
|
94 |
.include <bsd.port.options.mk> |
94 |
.include <bsd.port.options.mk> |
95 |
|
95 |
|
96 |
.if ${PORT_OPTIONS:MWALLET_BDB48} |
96 |
.if ${PORT_OPTIONS:MWALLET_BDB48} |
97 |
CONFIGURE_ARGS+= --enable-wallet |
97 |
CONFIGURE_ARGS+= --enable-wallet |
98 |
USES+= bdb:48 |
98 |
USES+= bdb:48 |
99 |
.elif ${PORT_OPTIONS:MWALLET_BDBMODERN} |
99 |
.elif ${PORT_OPTIONS:MWALLET_BDBMODERN} |
100 |
CONFIGURE_ARGS+= --enable-wallet --with-incompatible-bdb |
100 |
CONFIGURE_ARGS+= --enable-wallet --with-incompatible-bdb |
101 |
USES+= bdb:5+ |
101 |
USES+= bdb:5+ |
102 |
.else |
102 |
.else |
103 |
CONFIGURE_ARGS+= --disable-wallet |
103 |
CONFIGURE_ARGS+= --disable-wallet |
104 |
.endif |
104 |
.endif |
105 |
|
105 |
|
106 |
.include <bsd.port.pre.mk> |
106 |
.include <bsd.port.pre.mk> |
107 |
|
107 |
|
108 |
.if ${PORT_OPTIONS:MWALLET_BDB48} || ${PORT_OPTIONS:MWALLET_BDBMODERN} |
108 |
.if ${PORT_OPTIONS:MWALLET_BDB48} || ${PORT_OPTIONS:MWALLET_BDBMODERN} |
109 |
CPPFLAGS+= -I${BDB_INCLUDE_DIR} |
109 |
CPPFLAGS+= -I${BDB_INCLUDE_DIR} |
110 |
LIBS+= -L${BDB_LIB_DIR} |
110 |
LIBS+= -L${BDB_LIB_DIR} |
111 |
.endif |
111 |
.endif |
112 |
|
112 |
|
113 |
.if ${OSVERSION} < 1100000 |
113 |
.if ${OSVERSION} < 1100000 |
114 |
CONFIGURE_ARGS+=--disable-asm |
114 |
CONFIGURE_ARGS+=--disable-asm |
115 |
.endif |
115 |
.endif |
116 |
|
116 |
|
117 |
.if defined(SLAVE_PORT) && ${SLAVE_PORT} == "no" |
117 |
.if defined(SLAVE_PORT) && ${SLAVE_PORT} == "no" |
118 |
|
118 |
|
119 |
post-install: |
119 |
post-install: |
120 |
${REINPLACE_CMD} -e 's,=/usr,=${PREFIX},' \ |
120 |
${REINPLACE_CMD} -e 's,=/usr,=${PREFIX},' \ |
121 |
${WRKSRC}/contrib/debian/bitcoin-qt.desktop |
121 |
${WRKSRC}/contrib/debian/bitcoin-qt.desktop |
122 |
${INSTALL} ${WRKSRC}/contrib/debian/bitcoin-qt.desktop \ |
122 |
${INSTALL} ${WRKSRC}/contrib/debian/bitcoin-qt.desktop \ |
123 |
${STAGEDIR}${PREFIX}/share/applications |
123 |
${STAGEDIR}${PREFIX}/share/applications |
124 |
${INSTALL} ${WRKSRC}/share/pixmaps/bitcoin128.png \ |
124 |
${INSTALL} ${WRKSRC}/share/pixmaps/bitcoin128.png \ |
125 |
${STAGEDIR}${PREFIX}/share/pixmaps/ |
125 |
${STAGEDIR}${PREFIX}/share/pixmaps/ |
126 |
|
126 |
|
127 |
.endif |
127 |
.endif |
128 |
|
128 |
|
129 |
regression-test: build |
129 |
regression-test: build |
130 |
# To use this sucessfully, remove --without-daemon and --without-utils |
130 |
# To use this sucessfully, remove --without-daemon and --without-utils |
131 |
# from CONFIGURE_ARGS above. |
131 |
# from CONFIGURE_ARGS above. |
132 |
|
132 |
|
133 |
@cd ${WRKSRC} && ${GMAKE} check |
133 |
@cd ${WRKSRC} && ${GMAKE} check |
134 |
|
134 |
|
135 |
.include <bsd.port.post.mk> |
135 |
.include <bsd.port.post.mk> |