add UPnP-Inspector-0.2.2, a UPnP debug tool
[pkgsrc.git] / net / entropy / Makefile
1 # $NetBSD$
2 #
3
4 DISTNAME=               entropy-${ENTROPY_VERSION}
5 PKGNAME=                entropy-${ENTROPY_VERSION:S/-/./}
6 WRKSRC=                 ${WRKDIR}/entropy-${ENTROPY_VERSION:C/-.*$//}
7 CATEGORIES=             net
8 MASTER_SITES=           http://entropy.stop1984.com/files/ \
9                         http://www.duh.org/entropy/files/
10 EXTRACT_SUFX=           .tgz
11
12 MAINTAINER=             tv@duh.org
13 HOMEPAGE=               http://entropy.stop1984.com/
14 COMMENT=                Anonymous peer-to-peer networking node (similar to Freenet)
15
16 GNU_CONFIGURE=          yes
17 USE_BUILDLINK3=         yes
18 USE_GNU_TOOLS+=         make
19
20 ENTROPY_VERSION=        0.8.2-415
21
22 CONFIGURE_ARGS+=        --enable-verbose --disable-posix-sem
23
24 post-patch:
25         ${SED} -e '/^# /!s/^#//' <${WRKSRC}/seed.txt-dist >${WRKSRC}/seed.txt
26
27 do-install:
28         ${INSTALL_PROGRAM} ${WRKSRC}/entropy ${PREFIX}/bin/entropy
29         ${INSTALL_PROGRAM} ${WRKSRC}/monoopt ${PREFIX}/bin/entropy-monoopt
30         ${INSTALL_PROGRAM} ${WRKSRC}/storechg ${PREFIX}/bin/entropy-storechg
31         ${INSTALL_DATA_DIR} ${PREFIX}/share/examples/entropy
32         ${INSTALL_DATA_DIR} ${PREFIX}/share/examples/entropy/node
33         ${INSTALL_DATA} ${WRKSRC}/entropy.conf-dist ${PREFIX}/share/examples/entropy/entropy.conf
34         ${INSTALL_DATA} ${WRKSRC}/seed.txt ${PREFIX}/share/examples/entropy/
35         ${INSTALL_DATA} ${WRKSRC}/node/[0-9a-z]* ${PREFIX}/share/examples/entropy/node/
36
37 .include "../../mk/bsd.prefs.mk"
38
39 # tree is most efficient on *ix; can also be "monolithic" or "mysql"
40 ENTROPY_STORE_TYPE?=    tree
41
42 .if ${ENTROPY_STORE_TYPE} == "tree"
43 CONFIGURE_ARGS+=        --with-tree
44 .elif ${ENTROPY_STORE_TYPE} == "mysql"
45 CONFIGURE_ARGS+=        --with-mysql=${LOCALBASE}
46 .include "../../databases/mysql-client/buildlink2.mk"
47 .elif ${ENTROPY_STORE_TYPE} != "monolithic"
48 .error unknown ENTROPY_STORE_TYPE: ${ENTROPY_STORE_TYPE}
49 .endif
50
51 # maximum allowed peer connections (and child processes); default 64
52 .ifdef ENTROPY_MAX_PEERS
53 CONFIGURE_ARGS+=        --enable-max-peers=${ENTROPY_MAX_PEERS}
54 .endif
55
56 .include "../../devel/zlib/buildlink3.mk"
57 .include "../../textproc/expat/buildlink3.mk"
58 .include "../../mk/bsd.pkg.mk"