summaryrefslogtreecommitdiff
path: root/inputmethod
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2007-07-04 20:54:31 +0000
committerjlam <jlam@pkgsrc.org>2007-07-04 20:54:31 +0000
commit98cdd9932cde6f42403278ca908a087e5bca9d36 (patch)
tree651c1d29a5b557efafa04d2bb6f2cb512a979f64 /inputmethod
parent0247ab7847e69210ea87ced5b0d8bf19ddb094c8 (diff)
downloadpkgsrc-98cdd9932cde6f42403278ca908a087e5bca9d36.tar.gz
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.
Diffstat (limited to 'inputmethod')
-rw-r--r--inputmethod/canna-server/Makefile3
-rw-r--r--inputmethod/canna/Makefile.common5
-rw-r--r--inputmethod/ja-freewnn-lib/Makefile.common4
-rw-r--r--inputmethod/ja-freewnn-server-bin/Makefile6
-rw-r--r--inputmethod/sj3-server-bin/Makefile5
5 files changed, 16 insertions, 7 deletions
diff --git a/inputmethod/canna-server/Makefile b/inputmethod/canna-server/Makefile
index ff3b6452ac9..6f5a8e2e7cc 100644
--- a/inputmethod/canna-server/Makefile
+++ b/inputmethod/canna-server/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.18 2007/02/22 19:26:37 wiz Exp $
+# $NetBSD: Makefile,v 1.19 2007/07/04 20:54:39 jlam Exp $
PKGREVISION= 2
CANNA_MODULE= server
@@ -7,7 +7,6 @@ CANNA_MODULE= server
INSTALL_TARGET= instserver
-BUILD_DEFS+= CANNA_USER CANNA_GROUP
MESSAGE_SUBST+= CANNA_USER=${CANNA_USER}
MESSAGE_SUBST+= CANNA_GROUP=${CANNA_GROUP}
diff --git a/inputmethod/canna/Makefile.common b/inputmethod/canna/Makefile.common
index 562d0f2a8d7..ea939821820 100644
--- a/inputmethod/canna/Makefile.common
+++ b/inputmethod/canna/Makefile.common
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.16 2006/07/05 04:48:28 jlam Exp $
+# $NetBSD: Makefile.common,v 1.17 2007/07/04 20:54:39 jlam Exp $
#
# Canna common makefile.
#
@@ -24,6 +24,9 @@ USE_IMAKE= yes
CANNA_SPOOL= ${VARBASE}/spool/canna
CANNA_MODE= 0755
+PKG_GROUPS_VARS+= CANNA_GROUP
+PKG_USERS_VARS+= CANNA_USER
+
# XXX IPv6 support. To be done.
#BUILD_DEFS+= USE_INET6
#.include "../../mk/bsd.prefs.mk"
diff --git a/inputmethod/ja-freewnn-lib/Makefile.common b/inputmethod/ja-freewnn-lib/Makefile.common
index 89aebcbdcdd..e92b80e2ba7 100644
--- a/inputmethod/ja-freewnn-lib/Makefile.common
+++ b/inputmethod/ja-freewnn-lib/Makefile.common
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.12 2006/07/05 06:53:13 jlam Exp $
+# $NetBSD: Makefile.common,v 1.13 2007/07/04 20:54:39 jlam Exp $
#
DISTNAME= FreeWnn-1.10
@@ -21,6 +21,8 @@ WNNOWNER?= ${FREEWNN_USER}
SEDSCRIPT+= -e 's|\(WNNOWNER = \).*|\1${WNNOWNER}|'
SEDSCRIPT+= -e 's|\([JCKT]\)\(WNNDICDIR = \).*|\1\2${IMDICTDIR}/wnn/$$(\1WNNLANG)|'
+PKG_USERS_VARS+= WNNOWNER FREEWNN_USER
+
.if defined(WNN_TARGET) && (${WNN_TARGET} == "SERVER")
MAKE_ENV+= "WNN_TARGET=SERVER"
SEDSCRIPT+= -e 's|$$([CK]*WNNJLIBSRC)/lib\([ck]*wnn\).a|-l\1|'
diff --git a/inputmethod/ja-freewnn-server-bin/Makefile b/inputmethod/ja-freewnn-server-bin/Makefile
index f233f69ba87..880ca0a7691 100644
--- a/inputmethod/ja-freewnn-server-bin/Makefile
+++ b/inputmethod/ja-freewnn-server-bin/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.15 2006/07/05 06:53:13 jlam Exp $
+# $NetBSD: Makefile,v 1.16 2007/07/04 20:54:40 jlam Exp $
#
PKGNAME= ja-FreeWnn-server-bin-1.10
@@ -24,10 +24,12 @@ RCD_SCRIPTS= ja_freewnn
FREEWNN_USER?= wnn
FREEWNN_GROUP?= jserver
-BUILD_DEFS+= FREEWNN_USER FREEWNN_GROUP
PKG_GROUPS= ${FREEWNN_GROUP}
PKG_USERS= ${FREEWNN_USER}:${FREEWNN_GROUP}
+PKG_GROUPS_VARS+= FREEWNN_GROUP
+PKG_USERS_VARS+= FREEWNN_USER
+
.include "../../inputmethod/ja-freewnn-lib/buildlink3.mk"
.include "../../inputmethod/ja-freewnn-lib/Makefile.common"
diff --git a/inputmethod/sj3-server-bin/Makefile b/inputmethod/sj3-server-bin/Makefile
index d2dfb0d88c8..0361596895b 100644
--- a/inputmethod/sj3-server-bin/Makefile
+++ b/inputmethod/sj3-server-bin/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.14 2006/07/05 04:55:24 jlam Exp $
+# $NetBSD: Makefile,v 1.15 2007/07/04 20:54:40 jlam Exp $
#
DISTNAME= sj3-2.0.1.20
@@ -31,6 +31,9 @@ FILES_SUBST+= SJ3GROUP=${SJ3GROUP:Q}
PKG_GROUPS+= ${SJ3GROUP}
PKG_USERS+= ${SJ3OWNER}:${SJ3GROUP}
+PKG_GROUPS_VARS+= SJ3GROUP
+PKG_USERS_VARS+= SJ3USER
+
MAKE_DIRS+= ${IMDICTDIR}
OWN_DIRS+= ${IMDICTDIR}/sj3
OWN_DIRS_PERMS+= ${IMDICTDIR}/sj3/user ${SJ3OWNER} ${SJ3GROUP} 0755