Index: stable/4/games/Makefile.inc =================================================================== --- stable/4/games/Makefile.inc (revision 90855) +++ stable/4/games/Makefile.inc (revision 90856) @@ -1,10 +1,12 @@ # @(#)Makefile.inc 8.1 (Berkeley) 5/31/93 +# $FreeBSD$ -BINGRP= ${GAMEGRP} -BINDIR?= /usr/games +BINDIR?= /usr/games .if defined(HIDEGAME) -GBINDIR:= ${BINDIR} -BINDIR:= ${BINDIR}/hide -BINMODE= 550 +ORIGBINDIR:= ${BINDIR} +BINDIR:= ${BINDIR}/hide +ORIGBINGRP:= ${BINGRP} +BINGRP= games +BINMODE= 550 .endif Index: stable/4/games/atc/Makefile =================================================================== --- stable/4/games/atc/Makefile (revision 90855) +++ stable/4/games/atc/Makefile (revision 90856) @@ -1,18 +1,18 @@ # @(#)Makefile 8.1 (Berkeley) 5/31/93 # $FreeBSD$ PROG= atc CFLAGS+=-DBSD -I${.CURDIR} -I. SRCS= extern.c grammar.y graphics.c input.c lex.l list.c log.c \ main.c tunable.c update.c y.tab.h MAN= atc.6 DPADD= ${LIBL} ${LIBM} ${LIBCURSES} ${LIBTERMCAP} LDADD= -ll -lm -lcurses -ltermcap GAMES= Game_List Killer crossover default easy game_2 HIDEGAME=hidegame beforeinstall: - (cd ${.CURDIR}/games; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${GAMES} ${DESTDIR}${SHAREDIR}/games/atc) + (cd ${.CURDIR}/games; ${INSTALL} -c -o ${SHAREOWN} -g ${SHAREGRP} \ + -m ${SHAREMODE} ${GAMES} ${DESTDIR}${SHAREDIR}/games/atc) .include Index: stable/4/games/cribbage/Makefile =================================================================== --- stable/4/games/cribbage/Makefile (revision 90855) +++ stable/4/games/cribbage/Makefile (revision 90856) @@ -1,19 +1,19 @@ # @(#)Makefile 8.1 (Berkeley) 5/31/93 # $FreeBSD$ PROG= cribbage DPADD= ${LIBCURSES} ${LIBTERMCAP} ${LIBCOMPAT} LDADD= -lcurses -ltermcap -lcompat SRCS= extern.c crib.c cards.c instr.c io.c score.c support.c MAN= cribbage.6 HIDEGAME=hidegame beforeinstall: - ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${NOBINMODE} \ + ${INSTALL} -c -o ${SHAREOWN} -g ${SHAREGRP} -m ${SHAREMODE} \ ${.CURDIR}/cribbage.n ${DESTDIR}${SHAREDIR}/games/cribbage.instr .if !exists(${DESTDIR}/var/games/criblog) ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \ ${DESTDIR}/var/games/criblog .endif .include Index: stable/4/games/fish/Makefile =================================================================== --- stable/4/games/fish/Makefile (revision 90855) +++ stable/4/games/fish/Makefile (revision 90856) @@ -1,12 +1,12 @@ # @(#)Makefile 8.1 (Berkeley) 5/31/93 # $FreeBSD$ PROG= fish MAN= fish.6 HIDEGAME=hidegame beforeinstall: - ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${NOBINMODE} \ - ${.CURDIR}/fish.instr ${DESTDIR}${SHAREDIR}/games/fish.instr + ${INSTALL} -c -o ${SHAREOWN} -g ${SHAREGRP} -m ${SHAREMODE} \ + ${.CURDIR}/fish.instr ${DESTDIR}${SHAREDIR}/games/fish.instr .include Index: stable/4/games/larn/Makefile =================================================================== --- stable/4/games/larn/Makefile (revision 90855) +++ stable/4/games/larn/Makefile (revision 90856) @@ -1,78 +1,78 @@ # @(#)Makefile 5.12 (Berkeley) 5/30/93 # $FreeBSD$ # EXTRA # Incorporates code to gather additional performance statistics # SYSV # Use system III/V (instead of V7) type ioctl calls # BSD # Use BSD specific features (mostly timer and signal stuff) # BSD4.1 # Use BSD4.1 to avoid some 4.2 dependencies (must be used with # BSD above; do not mix with SYSV) # HIDEBYLINK # If defined, the program attempts to hide from ps # DOCHECKPOINTS # If not defined, checkpoint files are periodically written by the # larn process (no forking) if enabled in the .larnopts description # file. Checkpointing is handy on an unreliable system, but takes # CPU. Inclusion of DOCHECKPOINTS will cause fork()ing to perform the # checkpoints (again if enabled in the .larnopts file). This usually # avoids pauses in larn while the checkpointing is being done (on # large machines). # VER # This is the version of the software, example: 12 # SUBVER # This is the revision of the software, example: 1 # FLUSHNO=# # Set the input queue excess flushing threshold (default 5) # NOVARARGS # Define for systems that don't have varargs (a default varargs will # be used). # MACRORND # Define to use macro version of rnd() and rund() (fast and big) # UIDSCORE # Define to use user id's to manage scoreboard. Leaving this out will # cause player id's from the file ".playerids" to be used instead. # (.playerids is created upon demand). Only one entry per id # is # allowed in each scoreboard (winning & non-winning). # VT100 # Compile for using vt100 family of terminals. Omission of this # define will cause larn to use termcap, but it will be MUCH slower # due to an extra layer of output interpretation. Also, only VT100 # mode allows 2 different standout modes, inverse video, and bold video. # And only in VT100 mode is the scrolling region of the terminal used # (much nicer than insert/delete line sequences to simulate it, if # VT100 is omitted). # NONAP # This causes napms() to return immediately instead of delaying n # milliseconds. This define may be needed on some systems if the nap # stuff does not work correctly (possible hang). nap() is primarilly # used to delay for effect when casting missile type spells. # NOLOG # Turn off logging. PROG= larn MAN= larn.6 CFLAGS+=-DBSD -DVER=12 -DSUBVER=0 -DNONAP -DUIDSCORE -fwritable-strings SRCS= main.c object.c create.c tok.c display.c global.c data.c io.c \ monster.c store.c diag.c help.c config.c nap.c bill.c scores.c \ signal.c moreobj.c movem.c regen.c fortune.c savelev.c DPADD= ${LIBTERMCAP} ${LIBCOMPAT} LDADD= -ltermcap -lcompat HIDEGAME=hidegame beforeinstall: - (cd ${.CURDIR}/datfiles; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} \ - -m ${NOBINMODE} larnmaze larnopts larn.help \ + (cd ${.CURDIR}/datfiles; ${INSTALL} -c -o ${SHAREOWN} -g ${SHAREGRP} \ + -m ${SHAREMODE} larnmaze larnopts larn.help \ ${DESTDIR}${SHAREDIR}/games/larn) .if !exists(${DESTDIR}/var/games/larn/lscore12.0) ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 660 /dev/null \ ${DESTDIR}/var/games/larn/lscore12.0 .endif .if !exists(${DESTDIR}/var/games/larn/llog12.0) ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 660 /dev/null \ ${DESTDIR}/var/games/larn/llog12.0 .endif .include Index: stable/4/games/quiz/Makefile =================================================================== --- stable/4/games/quiz/Makefile (revision 90855) +++ stable/4/games/quiz/Makefile (revision 90856) @@ -1,17 +1,17 @@ # @(#)Makefile 8.1 (Berkeley) 5/31/93 # $FreeBSD$ PROG= quiz SRCS= quiz.c rxp.c MAN= quiz.6 CATS= africa america areas arith asia babies bard chinese collectives \ ed elements europe flowers greek inca index latin locomotive \ midearth morse murders poetry posneg pres province seq-easy seq-hard \ sexes sov spell state trek ucc HIDEGAME=hidegame beforeinstall: - (cd ${.CURDIR}/datfiles; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} \ - -m ${NOBINMODE} ${CATS} ${DESTDIR}${SHAREDIR}/games/quiz.db) + (cd ${.CURDIR}/datfiles; ${INSTALL} -c -o ${SHAREOWN} -g ${SHAREGRP} \ + -m ${SHAREMODE} ${CATS} ${DESTDIR}${SHAREDIR}/games/quiz.db) .include Index: stable/4/games/wump/Makefile =================================================================== --- stable/4/games/wump/Makefile (revision 90855) +++ stable/4/games/wump/Makefile (revision 90856) @@ -1,12 +1,12 @@ # @(#)Makefile 8.1 (Berkeley) 5/31/93 # $FreeBSD$ PROG= wump MAN= wump.6 HIDEGAME=hidegame beforeinstall: - ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${NOBINMODE} \ + ${INSTALL} -c -o ${SHAREOWN} -g ${SHAREGRP} -m ${SHAREMODE} \ ${.CURDIR}/wump.info ${DESTDIR}${SHAREDIR}/games .include Index: stable/4/share/mk/bsd.own.mk =================================================================== --- stable/4/share/mk/bsd.own.mk (revision 90855) +++ stable/4/share/mk/bsd.own.mk (revision 90856) @@ -1,210 +1,208 @@ # $FreeBSD$ # # The include file set common variables for owner, # group, mode, and directories. Defaults are in brackets. # # # +++ variables +++ # # DESTDIR Change the tree where the file gets installed. [not set] # # DISTDIR Change the tree where the file for a distribution # gets installed (see /usr/src/release/Makefile). [not set] # # # COPY The flag passed to the install program to cause the binary # to be copied rather than moved. This is to be used when # building our own install script so that the entire system # can either be installed with copies, or with moves using # a single knob. [-c] # # COMPRESS_CMD Program to compress documents. # Output is to stdout. [gzip -cn] # # COMPRESS_EXT File name extension of ${COMPRESS_CMD} command. [.gz] # # STRIP The flag passed to the install program to cause the binary # to be stripped. This is to be used when building your # own install script so that the entire system can be made # stripped/not-stripped using a single knob. [-s] # # OBJFORMAT Default object format that selects which set of tools to run. # [elf] # # BINOWN Binary owner. [root] # # BINGRP Binary group. [wheel] # # BINMODE Binary mode. [555] # # NOBINMODE Mode for non-executable files. [444] # # INCOWN Include owner. [root] # # INCGRP Include group. [wheel] # # INCMODE Include mode. [444] # # INCDIR Base path for include files. [/usr/include] # # LIBDIR Base path for libraries. [/usr/lib] # # LIBCOMPATDIR Base path for compat libraries. [/usr/lib/compat] # # LIBDATADIR Base path for misc. utility data files. [/usr/libdata] # # LINTLIBDIR Base path for lint libraries. [/usr/libdata/lint] # # SHLIBDIR Base path for shared libraries. [${LIBDIR}] # # LIBOWN Library mode. [${BINOWN}] # # LIBGRP Library group. [${BINGRP}] # # LIBMODE Library mode. [${NOBINMODE}] # # # KMODDIR Base path for loadable kernel modules # (see kld(4)). [/modules] # # KMODOWN KLD owner. [${BINOWN}] # # KMODGRP KLD group. [${BINGRP}] # # KMODMODE KLD mode. [${BINMODE}] # # # SHAREDIR Base path for architecture-independent ascii # text files. [/usr/share] # # SHAREOWN ASCII text file owner. [root] # # SHAREGRP ASCII text file group. [wheel] # # SHAREMODE ASCII text file mode. [${NOBINMODE}] # # # DOCDIR Base path for system documentation (e.g. PSD, USD, # handbook, FAQ etc.). [${SHAREDIR}/doc] # # DOCOWN Documentation owner. [${SHAREOWN}] # # DOCGRP Documentation group. [${SHAREGRP}] # # DOCMODE Documentation mode. [${NOBINMODE}] # # # INFODIR Base path for GNU's hypertext system # called Info (see info(1)). [${SHAREDIR}/info] # # INFOOWN Info owner. [${SHAREOWN}] # # INFOGRP Info group. [${SHAREGRP}] # # INFOMODE Info mode. [${NOBINMODE}] # # # MANDIR Base path for manual installation. [${SHAREDIR}/man/man] # # MANOWN Manual owner. [${SHAREOWN}] # # MANGRP Manual group. [${SHAREGRP}] # # MANMODE Manual mode. [${NOBINMODE}] # # # NLSDIR Base path for National Language Support files # installation (see mklocale(1)). [${SHAREDIR}/nls] # # NLSGRP National Language Support files group. [${SHAREOWN}] # # NLSOWN National Language Support files owner. [${SHAREGRP}] # # NLSMODE National Language Support files mode. [${NOBINMODE}] # # INCLUDEDIR Base path for standard C include files [/usr/include] # This is only here for bootstrapping and is not officially exported # from here. It has normally already been defined in sys.mk. MACHINE_ARCH?= i386 # # The build tools are indirected by /usr/bin/objformat which determines the # object format from the OBJFORMAT environment variable and if this is not # defined, it reads /etc/objformat. # .if exists(/etc/objformat) && !defined(OBJFORMAT) .include "/etc/objformat" .endif # Default executable format OBJFORMAT?= elf # Binaries BINOWN?= root BINGRP?= wheel BINMODE?= 555 NOBINMODE?= 444 -GAMEGRP?= games - INCOWN?= root INCGRP?= wheel INCMODE?= 444 INCDIR?= /usr/include KMODDIR?= /modules KMODOWN?= ${BINOWN} KMODGRP?= ${BINGRP} KMODMODE?= ${BINMODE} .if ${OBJFORMAT} == aout LIBDIR?= /usr/lib/aout .else LIBDIR?= /usr/lib .endif LIBCOMPATDIR?= /usr/lib/compat LIBDATADIR?= /usr/libdata LINTLIBDIR?= /usr/libdata/lint SHLIBDIR?= ${LIBDIR} LIBOWN?= ${BINOWN} LIBGRP?= ${BINGRP} LIBMODE?= ${NOBINMODE} # Share files SHAREDIR?= /usr/share SHAREOWN?= root SHAREGRP?= wheel SHAREMODE?= ${NOBINMODE} MANDIR?= ${SHAREDIR}/man/man MANOWN?= ${SHAREOWN} MANGRP?= ${SHAREGRP} MANMODE?= ${NOBINMODE} DOCDIR?= ${SHAREDIR}/doc DOCOWN?= ${SHAREOWN} DOCGRP?= ${SHAREGRP} DOCMODE?= ${NOBINMODE} INFODIR?= ${SHAREDIR}/info INFOOWN?= ${SHAREOWN} INFOGRP?= ${SHAREGRP} INFOMODE?= ${NOBINMODE} NLSDIR?= ${SHAREDIR}/nls NLSGRP?= ${SHAREOWN} NLSOWN?= ${SHAREGRP} NLSMODE?= ${NOBINMODE} INCLUDEDIR?= /usr/include # Common variables .if !defined(DEBUG_FLAGS) STRIP?= -s .endif COPY?= -c COMPRESS_CMD?= gzip -cn COMPRESS_EXT?= .gz Index: stable/4/share/mk/bsd.prog.mk =================================================================== --- stable/4/share/mk/bsd.prog.mk (revision 90855) +++ stable/4/share/mk/bsd.prog.mk (revision 90856) @@ -1,253 +1,253 @@ # from: @(#)bsd.prog.mk 5.26 (Berkeley) 6/25/91 # $FreeBSD$ .if !target(__initialized__) __initialized__: .if exists(${.CURDIR}/../Makefile.inc) .include "${.CURDIR}/../Makefile.inc" .endif .endif .SUFFIXES: .out .o .c .cc .cpp .cxx .C .m .y .l .s .S CFLAGS+=${COPTS} ${DEBUG_FLAGS} .if defined(DESTDIR) && !defined(BOOTSTRAPPING) CFLAGS+= -I${DESTDIR}/usr/include CXXINCLUDES+= -I${DESTDIR}/usr/include/g++ .endif .if !defined(DEBUG_FLAGS) STRIP?= -s .endif .if defined(NOSHARED) && ( ${NOSHARED} != "no" && ${NOSHARED} != "NO" ) LDFLAGS+= -static .endif .if defined(PROG) .if defined(SRCS) # If there are Objective C sources, link with Objective C libraries. .if ${SRCS:M*.m} != "" OBJCLIBS?= -lobjc LDADD+= ${OBJCLIBS} .endif OBJS+= ${SRCS:N*.h:R:S/$/.o/g} ${PROG}: ${OBJS} ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${OBJS} ${LDDESTDIR} ${LDADD} .else !defined(SRCS) .if !target(${PROG}) SRCS= ${PROG}.c # Always make an intermediate object file because: # - it saves time rebuilding when only the library has changed # - the name of the object gets put into the executable symbol table instead of # the name of a variable temporary object. # - it's useful to keep objects around for crunching. OBJS= ${PROG}.o ${PROG}: ${OBJS} ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${OBJS} ${LDDESTDIR} ${LDADD} .endif .endif .if !defined(NOMAN) && !defined(MAN) && \ !defined(MAN1) && !defined(MAN2) && !defined(MAN3) && \ !defined(MAN4) && !defined(MAN5) && !defined(MAN6) && \ !defined(MAN7) && !defined(MAN8) && !defined(MAN9) && \ !defined(MAN1aout) MAN= ${PROG}.1 MAN1= ${MAN} .endif .endif .MAIN: all all: objwarn ${PROG} ${SCRIPTS} ${FILES} .if !defined(NOMAN) all: all-man .endif all: _SUBDIR CLEANFILES+= ${PROG} ${OBJS} .if defined(PROG) _EXTRADEPEND: .if ${OBJFORMAT} == aout echo ${PROG}: `${CC} -Wl,-f ${CFLAGS} ${LDFLAGS} ${LDDESTDIR} \ ${LDADD:S/^/-Wl,/}` >> ${DEPENDFILE} .else echo ${PROG}: ${LIBC} ${DPADD} >> ${DEPENDFILE} .endif .endif .if !target(install) .if !target(beforeinstall) beforeinstall: .endif _INSTALLFLAGS:= ${INSTALLFLAGS} .for ie in ${INSTALLFLAGS_EDIT} _INSTALLFLAGS:= ${_INSTALLFLAGS${ie}} .endfor realinstall: beforeinstall .if defined(PROG) .if defined(PROGNAME) ${INSTALL} ${COPY} ${STRIP} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \ ${_INSTALLFLAGS} ${PROG} ${DESTDIR}${BINDIR}/${PROGNAME} .else ${INSTALL} ${COPY} ${STRIP} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \ ${_INSTALLFLAGS} ${PROG} ${DESTDIR}${BINDIR} .endif .endif .if defined(HIDEGAME) - (cd ${DESTDIR}/${GBINDIR}; rm -f ${PROG}; ln -s dm ${PROG}; \ - chown games:bin ${PROG}) + (cd ${DESTDIR}${ORIGBINDIR}; ln -fs dm ${PROG}; \ + chown -h ${BINOWN}:${ORIGBINGRP} ${PROG}) .endif .if defined(LINKS) && !empty(LINKS) @set ${LINKS}; \ while test $$# -ge 2; do \ l=${DESTDIR}$$1; \ shift; \ t=${DESTDIR}$$1; \ shift; \ ${ECHO} $$t -\> $$l; \ ln -f $$l $$t; \ done; true .endif .if defined(SYMLINKS) && !empty(SYMLINKS) @set ${SYMLINKS}; \ while test $$# -ge 2; do \ l=$$1; \ shift; \ t=${DESTDIR}$$1; \ shift; \ ${ECHO} $$t -\> $$l; \ ln -fs $$l $$t; \ done; true .endif .if defined(SCRIPTS) && !empty(SCRIPTS) realinstall: _scriptsinstall SCRIPTSDIR?= ${BINDIR} SCRIPTSOWN?= ${BINOWN} SCRIPTSGRP?= ${BINGRP} SCRIPTSMODE?= ${BINMODE} .for script in ${SCRIPTS} .if defined(SCRIPTSNAME) SCRIPTSNAME_${script:T}?= ${SCRIPTSNAME} .else SCRIPTSNAME_${script:T}?= ${script:T:R} .endif SCRIPTSDIR_${script:T}?= ${SCRIPTSDIR} SCRIPTSOWN_${script:T}?= ${SCRIPTSOWN} SCRIPTSGRP_${script:T}?= ${SCRIPTSGRP} SCRIPTSMODE_${script:T}?= ${SCRIPTSMODE} _scriptsinstall: _SCRIPTSINS_${script:T} _SCRIPTSINS_${script:T}: ${script} ${INSTALL} ${COPY} -o ${SCRIPTSOWN_${.ALLSRC:T}} \ -g ${SCRIPTSGRP_${.ALLSRC:T}} -m ${SCRIPTSMODE_${.ALLSRC:T}} \ ${_INSTALLFLAGS} ${.ALLSRC} \ ${DESTDIR}${SCRIPTSDIR_${.ALLSRC:T}}/${SCRIPTSNAME_${.ALLSRC:T}} .endfor .endif .if defined(FILES) && !empty(FILES) realinstall: _filesinstall FILESDIR?= ${BINDIR} FILESOWN?= ${SHAREOWN} FILESGRP?= ${SHAREGRP} FILESMODE?= ${SHAREMODE} .for file in ${FILES} .if defined(FILESNAME) FILESNAME_${file:T}?= ${FILESNAME} .else FILESNAME_${file:T}?= ${file:T} .endif FILESDIR_${file:T}?= ${FILESDIR} FILESOWN_${file:T}?= ${FILESOWN} FILESGRP_${file:T}?= ${FILESGRP} FILESMODE_${file:T}?= ${FILESMODE} _filesinstall: _FILESINS_${file:T} _FILESINS_${file:T}: ${file} ${INSTALL} ${COPY} -o ${FILESOWN_${.ALLSRC:T}} \ -g ${FILESGRP_${.ALLSRC:T}} -m ${FILESMODE_${.ALLSRC:T}} \ ${_INSTALLFLAGS} ${.ALLSRC} \ ${DESTDIR}${FILESDIR_${.ALLSRC:T}}/${FILESNAME_${.ALLSRC:T}} .endfor .endif install: afterinstall _SUBDIR .if !defined(NOMAN) afterinstall: realinstall maninstall .else afterinstall: realinstall .endif .endif DISTRIBUTION?= bin .if !target(distribute) distribute: _SUBDIR .for dist in ${DISTRIBUTION} cd ${.CURDIR} ; $(MAKE) install DESTDIR=${DISTDIR}/${dist} SHARED=copies .endfor .endif .if !target(lint) lint: ${SRCS} _SUBDIR .if defined(PROG) @${LINT} ${LINTFLAGS} ${.ALLSRC} | more 2>&1 .endif .endif .if defined(NOTAGS) tags: .endif .if !target(tags) tags: ${SRCS} _SUBDIR .if defined(PROG) @cd ${.CURDIR} && gtags ${GTAGSFLAGS} ${.OBJDIR} .if defined(HTML) @cd ${.CURDIR} && htags ${HTAGSFLAGS} -d ${.OBJDIR} ${.OBJDIR} .endif .endif .endif .if !defined(NOMAN) .include .else .if !target(all-man) all-man: .endif .if !target(maninstall) maninstall: .endif .endif .if !target(regress) regress: .endif .if ${OBJFORMAT} != aout || make(checkdpadd) || defined(NEED_LIBNAMES) .include .endif .include .if defined(PROG) && !exists(${DEPENDFILE}) ${OBJS}: ${SRCS:M*.h} .endif .include .include