pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mk Introduce new variables:



details:   https://anonhg.NetBSD.org/pkgsrc/rev/bf23decdd221
branches:  trunk
changeset: 475200:bf23decdd221
user:      jschauma <jschauma%pkgsrc.org@localhost>
date:      Wed May 12 01:03:58 2004 +0000

description:
Introduce new variables:

SETGIDGAME:  specifies whether or not certain games are installed setgid
GAMEGRP:     the group owning games if SETGIDGAME is set
GAMEOWN:     the user owning games if SETFIDGAME is set
GAMEMODE:    the mode to install games as

Use these to provide INSTALL_GAME (for example for PR pkg/25313), and
set them to meaningful values under NetBSD.

diffstat:

 mk/bsd.pkg.defaults.mk |  32 +++++++++++++++++++++++++++++++-
 mk/bsd.pkg.mk          |  30 +++++++++++++++++-------------
 mk/defs.NetBSD.mk      |  10 +++++++++-
 3 files changed, 57 insertions(+), 15 deletions(-)

diffs (129 lines):

diff -r 6e63fe33744a -r bf23decdd221 mk/bsd.pkg.defaults.mk
--- a/mk/bsd.pkg.defaults.mk    Tue May 11 21:01:05 2004 +0000
+++ b/mk/bsd.pkg.defaults.mk    Wed May 12 01:03:58 2004 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.defaults.mk,v 1.237 2004/05/02 20:04:36 xtraeme Exp $
+# $NetBSD: bsd.pkg.defaults.mk,v 1.238 2004/05/12 01:03:58 jschauma Exp $
 #
 
 # A file providing defaults for pkgsrc and the packages collection.
@@ -490,6 +490,13 @@
 # Possible: any shell commands
 # Default: none
 
+SETGIDGAME?=   no
+# This flags specifies whether or not certain games are installed setgid,
+# which would allow them to write to a group-owned score file.
+# See also:    GAMEGRP, GAMEMODE, GAMEOWN
+# Possible:    yes, no
+# Default:     no
+
 SU_CMD?= ${ROOT_CMD}
 # Command to perform before "make install", if the user does not have
 # an effective uid of 0.  A possible substitute is "sudo sh -c"
@@ -905,6 +912,29 @@
 # Possible: any group name
 # Default: jserver
 
+GAMEGRP?=      ${BINGRP}
+# Used for various games to allow writing to a group-owned score file.
+# If SETGIDGAME is 'yes', setting this to a dedicated group, such as 'games'
+# would make sense.
+# See also:    GAMEMODE, GAMEOWN, SETGIDGAME
+# Possible:    any group name
+# Default:     ${BINGRP}
+
+GAMEMODE?=     ${BINMODE}
+# Used for various games to allow writing to a group-owned score file.
+# If SETGIDGAME is 'yes', setting this to 2555 would make sense.
+# See also:    GAMEGRP, GAMEOWN, SETGIDGAME
+# Possible:    any mode
+# Default:     ${BINMODE}
+
+GAMEOWN?=      ${BINOWN}
+# Used for various games to allow writing to a group-owned score file.
+# If SETGIDGAME is 'yes', setting this to a dedicated user, such as 'games'
+# would make sense.
+# See also:    GAMEGRP, GAMEMODE, SETGIDGAME
+# Possible:    any user name
+# Default:     ${BINOWN}
+
 GAWK_ENABLE_PORTALS?=  NO
 # Used by gawk package to enable/disable handling file names that start with
 # `/p/' as a 4.4 BSD type portal file, i.e., a two-way pipe for `|&'.
diff -r 6e63fe33744a -r bf23decdd221 mk/bsd.pkg.mk
--- a/mk/bsd.pkg.mk     Tue May 11 21:01:05 2004 +0000
+++ b/mk/bsd.pkg.mk     Wed May 12 01:03:58 2004 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: bsd.pkg.mk,v 1.1456 2004/05/08 16:14:55 reed Exp $
+#      $NetBSD: bsd.pkg.mk,v 1.1457 2004/05/12 01:03:59 jschauma Exp $
 #
 # This file is in the public domain.
 #
@@ -572,29 +572,33 @@
 
 # A few aliases for *-install targets
 .if !defined(INSTALL_UNSTRIPPED) || empty(INSTALL_UNSTRIPPED:M[yY][eE][sS])
-INSTALL_PROGRAM?= \
+INSTALL_PROGRAM?=      \
        ${INSTALL} ${COPY} ${_STRIPFLAG_INSTALL} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE}
+INSTALL_GAME?=         \
+       ${INSTALL} ${COPY} ${_STRIPFLAG_INSTALL} -o ${GAMEOWN} -g ${GAMEGRP} -m ${GAMEMODE}
 .else
-INSTALL_PROGRAM?= \
+INSTALL_PROGRAM?=      \
        ${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE}
-.endif
-INSTALL_SCRIPT?= \
+INSTALL_GAME?=         \
+       ${INSTALL} ${COPY} -o ${GAMEOWN} -g ${GAMEGRP} -m ${GAMEMODE}
+.endif
+INSTALL_SCRIPT?=       \
        ${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE}
-INSTALL_LIB?= \
+INSTALL_LIB?=          \
        ${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE}
-INSTALL_DATA?= \
+INSTALL_DATA?=                 \
        ${INSTALL} ${COPY} -o ${SHAREOWN} -g ${SHAREGRP} -m ${SHAREMODE}
-INSTALL_MAN?= \
+INSTALL_MAN?=          \
        ${INSTALL} ${COPY} -o ${MANOWN} -g ${MANGRP} -m ${MANMODE}
-INSTALL_PROGRAM_DIR?= \
+INSTALL_PROGRAM_DIR?=  \
        ${INSTALL} -d -o ${BINOWN} -g ${BINGRP} -m ${PKGDIRMODE}
-INSTALL_SCRIPT_DIR?= \
+INSTALL_SCRIPT_DIR?=   \
        ${INSTALL_PROGRAM_DIR}
-INSTALL_LIB_DIR?= \
+INSTALL_LIB_DIR?=      \
        ${INSTALL_PROGRAM_DIR}
-INSTALL_DATA_DIR?= \
+INSTALL_DATA_DIR?=     \
        ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP} -m ${PKGDIRMODE}
-INSTALL_MAN_DIR?= \
+INSTALL_MAN_DIR?=      \
        ${INSTALL} -d -o ${MANOWN} -g ${MANGRP} -m ${PKGDIRMODE}
 
 INSTALL_MACROS=        BSD_INSTALL_PROGRAM="${INSTALL_PROGRAM}"                \
diff -r 6e63fe33744a -r bf23decdd221 mk/defs.NetBSD.mk
--- a/mk/defs.NetBSD.mk Tue May 11 21:01:05 2004 +0000
+++ b/mk/defs.NetBSD.mk Wed May 12 01:03:58 2004 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: defs.NetBSD.mk,v 1.64 2004/04/27 13:43:05 tv Exp $
+# $NetBSD: defs.NetBSD.mk,v 1.65 2004/05/12 01:04:00 jschauma Exp $
 #
 # Variable definitions for the NetBSD operating system.
 
@@ -207,3 +207,11 @@
 _OPSYS_MAX_CMDLEN!=    /sbin/sysctl -n kern.argmax
 CONFIGURE_ENV+=                lt_cv_sys_max_cmd_len=${_OPSYS_MAX_CMDLEN}
 .endif
+
+# if games are to be installed setgid, set the group and mode to meaningful
+# values
+.if !(empty(SETGIDGAME:M[yY][eE][sS]))
+GAMEOWN=               games
+GAMEGRP=               games
+GAMEMODE=              2555
+.endif



Home | Main Index | Thread Index | Old Index