| @@ -1,36 +1,79 @@ | | | @@ -1,36 +1,79 @@ |
1 | # $NetBSD: Makefile,v 1.15 2011/06/19 16:15:57 pettai Exp $ | | 1 | # $NetBSD: Makefile,v 1.16 2011/07/27 04:11:25 pettai Exp $ |
2 | | | 2 | |
3 | DISTNAME= unbound-1.4.10 | | 3 | DISTNAME= unbound-1.4.12 |
4 | CATEGORIES= net | | 4 | CATEGORIES= net |
5 | MASTER_SITES= http://www.unbound.net/downloads/ | | 5 | MASTER_SITES= http://www.unbound.net/downloads/ |
6 | | | 6 | |
7 | MAINTAINER= joerg@NetBSD.org | | 7 | MAINTAINER= joerg@NetBSD.org |
8 | HOMEPAGE= http://www.unbound.net/ | | 8 | HOMEPAGE= http://www.unbound.net/ |
9 | COMMENT= DNS resolver and recursive server | | 9 | COMMENT= DNS resolver and recursive server |
10 | LICENSE= modified-bsd | | 10 | LICENSE= modified-bsd |
11 | | | 11 | |
12 | PKG_DESTDIR_SUPPORT= user-destdir | | 12 | PKG_DESTDIR_SUPPORT= user-destdir |
13 | | | 13 | |
14 | BUILD_DEFS+= VARBASE | | 14 | BUILD_DEFS+= VARBASE |
15 | | | 15 | |
16 | GNU_CONFIGURE= yes | | 16 | GNU_CONFIGURE= yes |
17 | USE_LIBTOOL= yes | | 17 | USE_LIBTOOL= yes |
18 | USE_TOOLS+= gmake | | 18 | USE_TOOLS+= gmake |
19 | | | 19 | |
20 | CONFIGURE_ARGS+= --with-ldns=${BUILDLINK_PREFIX.ldns} | | 20 | CONFIGURE_ARGS+= --with-ldns=${BUILDLINK_PREFIX.ldns} |
21 | CONFIGURE_ARGS+= --with-libexpat=${BUILDLINK_PREFIX.expat} | | 21 | CONFIGURE_ARGS+= --with-libexpat=${BUILDLINK_PREFIX.expat} |
22 | CONFIGURE_ARGS+= --with-pidfile=${VARBASE}/run/unbound.pid | | 22 | CONFIGURE_ARGS+= --with-pidfile=${VARBASE}/run/unbound.pid |
23 | CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFBASE} | | 23 | CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFBASE} |
| | | 24 | CONFIGURE_ARGS+= --enable-allsymbols |
| | | 25 | |
| | | 26 | # Add the same logic as for ldns, so sha2/gost is configured automatically |
| | | 27 | .include "../../security/openssl/buildlink3.mk" |
| | | 28 | |
| | | 29 | PLIST_VARS+= sha2 gost |
| | | 30 | .if defined(USE_BUILTIN.openssl) && !empty(USE_BUILTIN.openssl:M[yY][eE][sS]) |
| | | 31 | PLIST_VARS.gost!= \ |
| | | 32 | if ${PKG_ADMIN} pmatch 'openssl>=1.0.0' ${BUILTIN_PKG.openssl:Q}; then \ |
| | | 33 | ${ECHO} "yes"; \ |
| | | 34 | else \ |
| | | 35 | ${ECHO} "no"; \ |
| | | 36 | fi |
| | | 37 | PLIST_VARS.sha2!= \ |
| | | 38 | if ${PKG_ADMIN} pmatch 'openssl>=0.9.8' ${BUILTIN_PKG.openssl:Q}; then \ |
| | | 39 | ${ECHO} "yes"; \ |
| | | 40 | else \ |
| | | 41 | ${ECHO} "no"; \ |
| | | 42 | fi |
| | | 43 | .else |
| | | 44 | PLIST_VARS.gost!= \ |
| | | 45 | if ${PKG_INFO} -qe 'openssl>=1.0.0'; then \ |
| | | 46 | ${ECHO} yes; \ |
| | | 47 | else \ |
| | | 48 | ${ECHO} no; \ |
| | | 49 | fi |
| | | 50 | PLIST_VARS.sha2!= \ |
| | | 51 | if ${PKG_INFO} -qe 'openssl>=0.9.8'; then \ |
| | | 52 | ${ECHO} yes; \ |
| | | 53 | else \ |
| | | 54 | ${ECHO} no; \ |
| | | 55 | fi |
| | | 56 | .endif |
| | | 57 | .if ${PLIST_VARS.gost} == "yes" |
| | | 58 | CONFIGURE_ARGS+= --enable-gost |
| | | 59 | .else |
| | | 60 | CONFIGURE_ARGS+= --disable-gost |
| | | 61 | .endif |
| | | 62 | .if ${PLIST_VARS.sha2} == "yes" |
| | | 63 | CONFIGURE_ARGS+= --enable-sha2 |
| | | 64 | .else |
| | | 65 | CONFIGURE_ARGS+= --disable-sha2 |
| | | 66 | .endif |
24 | | | 67 | |
25 | SUBST_CLASSES+= paths | | 68 | SUBST_CLASSES+= paths |
26 | SUBST_STAGE.paths= post-configure | | 69 | SUBST_STAGE.paths= post-configure |
27 | SUBST_MESSAGE.paths= Fixing path names | | 70 | SUBST_MESSAGE.paths= Fixing path names |
28 | SUBST_FILES.paths= doc/example.conf doc/*.5 doc/*.8 | | 71 | SUBST_FILES.paths= doc/example.conf doc/*.5 doc/*.8 |
29 | SUBST_SED.paths= -e "s|/usr/local|${PREFIX}|" | | 72 | SUBST_SED.paths= -e "s|/usr/local|${PREFIX}|" |
30 | | | 73 | |
31 | INSTALL_MAKE_FLAGS+= \ | | 74 | INSTALL_MAKE_FLAGS+= \ |
32 | configfile=${PREFIX}/share/examples/unbound/unbound.conf | | 75 | configfile=${PREFIX}/share/examples/unbound/unbound.conf |
33 | | | 76 | |
34 | PKG_SYSCONFSUBDIR= unbound | | 77 | PKG_SYSCONFSUBDIR= unbound |
35 | | | 78 | |
36 | CONF_FILES+= share/examples/unbound/unbound.conf \ | | 79 | CONF_FILES+= share/examples/unbound/unbound.conf \ |
| @@ -38,15 +81,14 @@ CONF_FILES+= share/examples/unbound/unbo | | | @@ -38,15 +81,14 @@ CONF_FILES+= share/examples/unbound/unbo |
38 | | | 81 | |
39 | RCD_SCRIPTS= unbound | | 82 | RCD_SCRIPTS= unbound |
40 | | | 83 | |
41 | UNBOUND_USER?= unbound | | 84 | UNBOUND_USER?= unbound |
42 | UNBOUND_GROUP?= unbound | | 85 | UNBOUND_GROUP?= unbound |
43 | | | 86 | |
44 | PKG_GROUPS= ${UNBOUND_GROUP} | | 87 | PKG_GROUPS= ${UNBOUND_GROUP} |
45 | PKG_USERS= ${UNBOUND_USER}:${UNBOUND_GROUP} | | 88 | PKG_USERS= ${UNBOUND_USER}:${UNBOUND_GROUP} |
46 | | | 89 | |
47 | .include "options.mk" | | 90 | .include "options.mk" |
48 | | | 91 | |
49 | .include "../../textproc/expat/buildlink3.mk" | | 92 | .include "../../textproc/expat/buildlink3.mk" |
50 | .include "../../net/ldns/buildlink3.mk" | | 93 | .include "../../net/ldns/buildlink3.mk" |
51 | .include "../../security/openssl/buildlink3.mk" | | | |
52 | .include "../../mk/bsd.pkg.mk" | | 94 | .include "../../mk/bsd.pkg.mk" |