pkgsrc/mail/freepops/Makefile
jlam 4390d56940 Make it easier to build and install packages "unprivileged", where
the owner of all installed files is a non-root user.  This change
affects most packages that require special users or groups by making
them use the specified unprivileged user and group instead.

(1) Add two new variables PKG_GROUPS_VARS and PKG_USERS_VARS to
    unprivileged.mk.  These two variables are lists of other bmake
    variables that define package-specific users and groups.  Packages
    that have user-settable variables for users and groups, e.g. apache
    and APACHE_{USER,GROUP}, courier-mta and COURIER_{USER,GROUP},
    etc., should list these variables in PKG_USERS_VARS and PKG_GROUPS_VARS
    so that unprivileged.mk can know to set them to ${UNPRIVILEGED_USER}
    and ${UNPRIVILEGED_GROUP}.

(2) Modify packages to use PKG_GROUPS_VARS and PKG_USERS_VARS.
2007-07-04 20:54:31 +00:00

57 lines
1.8 KiB
Makefile

# $NetBSD: Makefile,v 1.6 2007/07/04 20:54:43 jlam Exp $
#
DISTNAME= freepops-0.2.5
CATEGORIES= mail
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=freepops/}
MAINTAINER= schmonz@NetBSD.org
HOMEPAGE= http://www.freepops.org/
COMMENT= POP3 gateway to AOL, Gmail, Hotmail, Juno, Yahoo, etc.
USE_LANGUAGES= c c++
USE_TOOLS+= bash:run bison gmake gsed patch tar
USE_LIBTOOL= yes
REPLACE_BASH= configure.sh
HAS_CONFIGURE= yes
CONFIGURE_SCRIPT= configure.sh
CONFIGURE_ARGS= pkgsrc
PKG_SYSCONFSUBDIR= freepops
EGDIR= ${PREFIX}/share/examples/${PKGBASE}
CONF_FILES= ${EGDIR}/config.lua ${PKG_SYSCONFDIR}/config.lua
OWN_DIRS+= ${VARBASE}/lib/${PKGBASE}/lua_unofficial
OWN_DIRS+= ${VARBASE}/lib/${PKGBASE}/lua_updates
OWN_DIRS+= ${VARBASE}/lib/${PKGBASE}/lua_updates/lxp
OWN_DIRS+= ${VARBASE}/lib/${PKGBASE}/lua_updates/browser
OWN_DIRS+= ${VARBASE}/lib/${PKGBASE}/lua_updates/soap
SUBST_CLASSES+= paths
SUBST_STAGE.paths= do-configure
SUBST_FILES.paths= config.h doc/freepopsd.1 src/freepops.h
SUBST_FILES.paths+= src/lua/freepops.lua
SUBST_SED.paths= -e 's|@PREFIX@|${PREFIX}|g'
SUBST_SED.paths+= -e 's|@PKG_SYSCONFDIR@|${PKG_SYSCONFDIR}|g'
SUBST_SED.paths+= -e 's|@VARBASE@|${VARBASE}|g'
SUBST_MESSAGE.paths= Adjusting paths.
BUILD_DEFS+= VARBASE
.include "../../mk/bsd.prefs.mk"
RCD_SCRIPTS= freepopsd
FREEPOPSD_USER?= freepops
FREEPOPSD_GROUP?= freepops
PKG_GROUPS= ${FREEPOPSD_GROUP}
PKG_USERS= ${FREEPOPSD_USER}:${FREEPOPSD_GROUP}
PKG_GECOS.${FREEPOPSD_USER}= freepopsd POP3 user
FILES_SUBST+= FREEPOPSD_USER=${FREEPOPSD_USER:Q}
FILES_SUBST+= FREEPOPSD_GROUP=${FREEPOPSD_GROUP:Q}
PKG_GROUPS_VARS+= FREEPOPSD_GROUP
PKG_USERS_VARS+= FREEPOPSD_USER
.include "../../security/openssl/buildlink3.mk"
.include "../../textproc/expat/buildlink3.mk"
.include "../../www/curl/buildlink3.mk"
.include "../../mk/pthread.buildlink3.mk"
.include "../../mk/bsd.pkg.mk"