blob: 19fd126e9034b6297ac743944806877fabb7d862 (
plain) (
blame)
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
|
# Created by: Chad J. Milios <milios@ccsys.com>
# $FreeBSD$
PORTNAME= namecoin
PORTVERSION= 0.3.80
PORTREVISION= 1
DISTVERSIONPREFIX= nc
PORTEPOCH= 1
CATEGORIES= net-p2p dns
MAINTAINER= milios@ccsys.com
COMMENT= Decentralized, open DNS system and general purpose key/value store
LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/COPYING
LIB_DEPENDS= libboost_date_time.so:devel/boost-libs
OPTIONS_DEFINE= X11 UPNP QRCODES DBUS
OPTIONS_DEFAULT= X11 QRCODES
UPNP_DESC= Build with UPNP support
QRCODES_DESC= Build with QR code display
USE_GITHUB= yes
USES= gmake compiler:c++11-lib
MAKE_JOBS_UNSAFE=yes
USE_OPENSSL= yes
USE_BDB= yes
WANT_BDB_VER= 48
CXXFLAGS+= -I${LOCALBASE}/include -I${BDB_INCLUDE_DIR}
CXXFLAGS+= -L${LOCALBASE}/lib -L${BDB_LIB_DIR}
CXXFLAGS+= -DCRYPTOPP_DISABLE_ASM
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MX11}
USE_QT4= corelib network gui qmake_build linguist_build uic_build moc_build rcc_build
BINARY= namecoin-qt
LIB_DEPENDS+= libprotobuf.so:devel/protobuf
.else
BINARY= namecoind
MAKE_ARGS+= -C ${WRKSRC}/src
USE_GNOME= glib20
.endif
.if ${PORT_OPTIONS:MQRCODES}
LIB_DEPENDS+= libqrencode.so:graphics/libqrencode
QMAKE_USE_QRCODE=1
.else
QMAKE_USE_QRCODE=0
.endif
.if ${PORT_OPTIONS:MDBUS}
USE_QT4+= dbus
QMAKE_USE_DBUS= 1
.else
QMAKE_USE_DBUS= 0
.endif
PLIST_FILES+= bin/${BINARY}
.if ${PORT_OPTIONS:MUPNP}
LIB_DEPENDS+= libminiupnpc.so:net/miniupnpc
CXXFLAGS+= -I${LOCALBASE}/include/miniupnpc
QMAKE_USE_UPNP= 1
.else
QMAKE_USE_UPNP= -
.endif
.include <bsd.port.pre.mk>
post-patch:
.if !${PORT_OPTIONS:MX11}
@cd ${WRKSRC}/src && ${CP} ${FILESDIR}/makefile.unix Makefile
@${REINPLACE_CMD} \
-e 's|^USE_UPNP.*$$|USE_UPNP=${QMAKE_USE_UPNP}|' \
${WRKSRC}/src/Makefile
.endif
do-configure:
.if ${PORT_OPTIONS:MX11}
cd ${WRKSRC} && ${SETENV} ${QMAKE_ENV} \
${QMAKE} ${QMAKE_ARGS} USE_UPNP=${QMAKE_USE_UPNP} USE_QRCODE=${QMAKE_USE_QRCODE} \
QMAKE_LRELEASE=${LRELEASE} INCLUDEPATH+=${BDB_INCLUDE_DIR} \
QMAKE_LIBDIR+=${BDB_LIB_DIR} ${BINARY}.pro
.endif
do-install:
@${MKDIR} ${STAGEDIR}${PREFIX}/bin
.if ${PORT_OPTIONS:MX11}
${INSTALL_PROGRAM} ${WRKSRC}/${BINARY} ${STAGEDIR}${PREFIX}/bin/
.else
${INSTALL_PROGRAM} ${WRKSRC}/src/${BINARY} ${STAGEDIR}${PREFIX}/bin/
.endif
.include <bsd.port.post.mk>
|