1 # $NetBSD: Makefile,v 1.36 2010/03/10 12:54:27 obache Exp $
3 DISTNAME= nntpcache-3.0.2
6 MASTER_SITES= http://www.xs4all.nl/~suelette/
8 MAINTAINER= pkgsrc-users@NetBSD.org
9 HOMEPAGE= http://iq.org/~proff/nntpcache.org/
10 COMMENT= NNTP multi-server caching daemon
11 LICENSE= nntpcache-license
13 PKG_DESTDIR_SUPPORT= user-destdir
15 .include "../../mk/bsd.prefs.mk"
18 NNTPCACHE_GROUP?= news
19 PKG_GROUPS= ${NNTPCACHE_GROUP}
20 PKG_USERS= ${NNTPCACHE_USER}:${NNTPCACHE_GROUP}
21 PKG_GROUPS_VARS+= NNTPCACHE_GROUP
22 PKG_USERS_VARS+= NNTPCACHE_USER
24 NNTPCACHE_DIR= ${VARBASE}/spool/nntpcache
26 REQD_DIRS_PERMS+= ${NNTPCACHE_DIR} ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 700
31 CONFIGURE_ENV+= cacheDir=${NNTPCACHE_DIR}
32 CONFIGURE_ENV+= configDir=${PKG_SYSCONFDIR}
33 CONFIGURE_ENV+= INSTALL_SCRIPT=${INSTALL_SCRIPT:Q}
34 CONFIGURE_ENV+= nc_cv_UID=${NNTPCACHE_USER}
35 CONFIGURE_ENV+= nc_cv_GID=${NNTPCACHE_GROUP}
36 USE_TOOLS+= gmake perl:run
39 PKG_SYSCONFSUBDIR= nntpcache
41 INSTALL_MAKE_FLAGS+= SUBDIRS="cf src filters http doc pgp contrib/newshound contrib/perlnewshound innreport scripts unixauth"
42 INSTALL_MAKE_FLAGS+= sysconfdir=${PREFIX}/share/examples/nntpcache
43 INSTALLATION_DIRS= libexec share/doc/nntpcache share/examples/nntpcache
45 RCD_SCRIPTS= nntpcached
47 REQD_FILES_PERMS+= share/examples/nntpcache/VERSION \
48 ${NNTPCACHE_DIR}/VERSION \
49 ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 600
50 PKG_SYSCONFDIR_PERMS+= ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 700
51 CONF_FILES_PERMS+= share/examples/nntpcache/nntpcache.access \
52 ${PKG_SYSCONFDIR}/nntpcache.access \
53 ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 600
54 CONF_FILES_PERMS+= share/examples/nntpcache/nntpcache.config \
55 ${PKG_SYSCONFDIR}/nntpcache.config \
56 ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 600
57 CONF_FILES_PERMS+= share/examples/nntpcache/nntpcache.servers \
58 ${PKG_SYSCONFDIR}/nntpcache.servers \
59 ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 600
60 CONF_FILES_PERMS+= share/examples/nntpcache/pubring.asc \
61 ${PKG_SYSCONFDIR}/pubring.asc \
62 ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 600
63 CONF_FILES_PERMS+= share/examples/nntpcache/pubring.asc \
64 ${PKG_SYSCONFDIR}/pubring.asc \
65 ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 600
66 CONF_FILES_PERMS+= share/examples/nntpcache/pubring.pgp \
67 ${PKG_SYSCONFDIR}/pubring.pgp \
68 ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 600
69 CONF_FILES_PERMS+= share/examples/nntpcache/spam.filter \
70 ${PKG_SYSCONFDIR}/spam.filter \
71 ${NNTPCACHE_USER} ${NNTPCACHE_GROUP} 600
72 SPECIAL_PERMS+= libexec/unixauth ${ROOT_USER} ${NNTPCACHE_GROUP} 4554
74 REPLACE_PERL+= innreport/innreport.pl innreport/innreport.pm
75 REPLACE_PERL+= contrib/perlnewshound/newshound.pl
78 cd ${WRKSRC} && ${INSTALL_DATA} README INSTALL FAQ FAQ.html LICENSING \
79 README.INN README.pam ChangeLog ${DESTDIR}${PREFIX}/share/doc/nntpcache/
81 .include "../../mk/bsd.pkg.mk"