summaryrefslogtreecommitdiffstats
path: root/share/mk
diff options
context:
space:
mode:
authorwosch <wosch@FreeBSD.org>1997-03-08 23:46:56 +0000
committerwosch <wosch@FreeBSD.org>1997-03-08 23:46:56 +0000
commitb3214dac27a4faf584604ae7945297f5c5ed52e8 (patch)
tree19570b2bf4473813bccf1244b60a8b7044ccf991 /share/mk
parentbe1a7b3ecea2baf4949a167f614de479ecff1896 (diff)
downloadFreeBSD-src-b3214dac27a4faf584604ae7945297f5c5ed52e8.zip
FreeBSD-src-b3214dac27a4faf584604ae7945297f5c5ed52e8.tar.gz
Add new variables COMPRESS_CMD and COMPRESS_EXT.
bsd.doc.mk: rename GZIPCMD to DCOMPRESS_CMD, add DCOMPRESS_EXT bsd.info.mk: rename GZIPCMD to ICOMPRESS_CMD, add ICOMPRESS_EXT set INFOTMPL to ${INFODIR}/dir-tmpl bsd.man.mk rename ZEXTENSION to MCOMPRESS_EXT, MCOMPRESS to MCOMPRESS_CMD
Diffstat (limited to 'share/mk')
-rw-r--r--share/mk/bsd.doc.mk24
-rw-r--r--share/mk/bsd.info.mk21
-rw-r--r--share/mk/bsd.man.mk24
-rw-r--r--share/mk/bsd.own.mk9
4 files changed, 44 insertions, 34 deletions
diff --git a/share/mk/bsd.doc.mk b/share/mk/bsd.doc.mk
index ea9ec78..d943b24 100644
--- a/share/mk/bsd.doc.mk
+++ b/share/mk/bsd.doc.mk
@@ -1,5 +1,5 @@
# from: @(#)bsd.doc.mk 5.3 (Berkeley) 1/2/91
-# $Id: bsd.doc.mk,v 1.33 1997/03/02 00:16:49 wosch Exp $
+# $Id: bsd.doc.mk,v 1.34 1997/03/02 15:52:34 wosch Exp $
PRINTERDEVICE?= ascii
@@ -42,12 +42,13 @@ TRFLAGS+= -s
TRFALGS+= -R
.endif
+DCOMPRESS_EXT?= ${COMPRESS_EXT}
.if defined(NODOCCOMPRESS) || ${PRINTERDEVICE} == "html"
DFILE= ${DOC}.${PRINTERDEVICE}
-GZIPCMD= cat
+DCOMPRESS_CMD= cat
.else
-DFILE= ${DOC}.${PRINTERDEVICE}.gz
-GZIPCMD= gzip -c
+DFILE= ${DOC}.${PRINTERDEVICE}${DCOMPRESS_EXT}
+DCOMPRESS_CMD?= ${COMPRESS_CMD}
.endif
PAGES?= 1-
@@ -73,13 +74,14 @@ print: ${DFILE}
.if defined(NODOCCOMPRESS)
lpr ${DFILE}
.else
- ${GZIPCMD} -d ${DFILE} | lpr
+ ${DCOMPRESS_CMD} -d ${DFILE} | lpr
.endif
.endif
-CLEANFILES+= ${DOC}.${PRINTERDEVICE} ${DOC}.${PRINTERDEVICE}.gz \
- ${DOC}.ascii ${DOC}.ascii.gz \
- ${DOC}.ps ${DOC}.ps.gz \
+CLEANFILES+= ${DOC}.${PRINTERDEVICE} \
+ ${DOC}.${PRINTERDEVICE}${DCOMPRESS_EXT} \
+ ${DOC}.ascii ${DOC}.ascii${DCOMPRESS_EXT} \
+ ${DOC}.ps ${DOC}.ps${DCOMPRESS_EXT} \
${DOC}.html ${DOC}-*.html
@@ -131,14 +133,14 @@ ${DFILE}:: ${SRCS} ${EXTRA} ${OBJS}
ALLSRCS= ${SRCS:S;^;${SRCDIR}/;}
${DFILE}:: ${SRCS}
.if defined(USE_SOELIMPP)
- ${SOELIMPP} ${ALLSRCS} | ${ROFF} | ${GZIPCMD} > ${.TARGET}
+ ${SOELIMPP} ${ALLSRCS} | ${ROFF} | ${DCOMPRESS_CMD} > ${.TARGET}
.else
- (cd ${SRCDIR}; ${ROFF} ${.ALLSRC}) | ${GZIPCMD} > ${.TARGET}
+ (cd ${SRCDIR}; ${ROFF} ${.ALLSRC}) | ${DCOMPRESS_CMD} > ${.TARGET}
.endif
.else
.if !defined(NODOCCOMPRESS)
${DFILE}: ${DOC}.${PRINTERDEVICE}
- ${GZIPCMD} ${DOC}.${PRINTERDEVICE} > ${.TARGET}
+ ${DCOMPRESS_CMD} ${DOC}.${PRINTERDEVICE} > ${.TARGET}
.endif
.endif
.endif
diff --git a/share/mk/bsd.info.mk b/share/mk/bsd.info.mk
index 2cf3eb0..30dfde5 100644
--- a/share/mk/bsd.info.mk
+++ b/share/mk/bsd.info.mk
@@ -1,4 +1,4 @@
-# $Id$
+# $Id: bsd.info.mk,v 1.31 1997/02/22 13:56:09 peter Exp $
#
# The include file <bsd.info.mk> handles installing GNU (tech)info files.
# Texinfo is a documentation system that uses a single source
@@ -14,8 +14,8 @@
#
# DISTRIBUTION Name of distribution. [info]
#
-# GZIPCMD Program to compress info files. Output is to
-# stdout. [gzip -c]
+# ICOMPRESS_CMD Program to compress info files. Output is to
+# stdout. [${COMPRESS_CMD}]
#
# INFO ???
#
@@ -32,7 +32,7 @@
#
# INFOSECTION ??? [Miscellaneous]
#
-# INFOTMPL ??? [/usr/share/info/dir-tmpl]
+# INFOTMPL ??? [${INFODIR}/dir-tmpl]
#
# INSTALLINFO ??? [install-info]
#
@@ -74,13 +74,13 @@ MAKEINFO?= makeinfo
MAKEINFOFLAGS+= --no-split # simplify some things, e.g., compression
SRCDIR?= ${.CURDIR}
INFODIRFILE?= dir
-INFOTMPL?= /usr/share/info/dir-tmpl
+INFOTMPL?= ${INFODIR}/dir-tmpl
INSTALLINFO?= install-info
INFOSECTION?= Miscellaneous
.MAIN: all
-.SUFFIXES: .gz .info .texi .texinfo
+.SUFFIXES: ${ICOMPRESS_EXT} .info .texi .texinfo
.texi.info:
${MAKEINFO} ${MAKEINFOFLAGS} -I ${.CURDIR} -I ${SRCDIR} ${.IMPSRC} -o ${.TARGET}
.texinfo.info:
@@ -92,7 +92,7 @@ IFILENS= ${INFO:S/$/.info/g}
.if !defined(NOINFO)
.if !defined(NOINFOCOMPRESS)
-IFILES= ${INFO:S/$/.info.gz/g}
+IFILES= ${INFO:S/$/.info${ICOMPRESS_EXT}/g}
all: ${IFILES} _SUBDIR
.else
IFILES= ${IFILENS}
@@ -102,11 +102,12 @@ all: ${IFILES} _SUBDIR
all:
.endif
-GZIPCMD?= gzip -c
+ICOMPRESS_CMD?= ${COMPRESS_CMD}
+ICOMPRESS_EXT?= ${COMPRESS_EXT}
.for x in ${INFO:S/$/.info/g}
-${x:S/$/.gz/}: ${x}
- ${GZIPCMD} ${.ALLSRC} > ${.TARGET}
+${x:S/$/${ICOMPRESS_EXT}/}: ${x}
+ ${ICOMPRESS_CMD} ${.ALLSRC} > ${.TARGET}
.endfor
# What to do if there's no dir file there. This is really gross!!!
diff --git a/share/mk/bsd.man.mk b/share/mk/bsd.man.mk
index 2b7d5fc..7128557 100644
--- a/share/mk/bsd.man.mk
+++ b/share/mk/bsd.man.mk
@@ -1,4 +1,4 @@
-# $Id$
+# $Id: bsd.man.mk,v 1.20 1997/02/22 13:56:12 peter Exp $
#
# The include file <bsd.man.mk> handles installing manual pages and
# their links. <bsd.man.mk> includes the file named "../Makefile.inc"
@@ -26,8 +26,8 @@
# _MANPAGES List of all man pages to be installed.
# (``_MANPAGES=$MAN1 $MAN2 ... $MANn'')
#
-# MCOMPRESS Program to compress man pages. Output is to
-# stdout. [gzip -c]
+# MCOMPRESS_CMD Program to compress man pages. Output is to
+# stdout. [${COMPRESS_CMD}]
#
# MLINKS List of manual page links (using a suffix). The
# linked-to file must come first, the linked file
@@ -56,8 +56,8 @@
MANSRC?= ${.CURDIR}
MINSTALL= ${INSTALL} ${COPY} -o ${MANOWN} -g ${MANGRP} -m ${MANMODE}
-MCOMPRESS= gzip -c
-ZEXTENSION= .gz
+MCOMPRESS_CMD?= ${COMPRESS_CMD}
+MCOMPRESS_EXT?= ${COMPRESS_EXT}
SECTIONS= 1 2 3 4 5 6 7 8 9 n
@@ -103,19 +103,19 @@ ${target}: ${page}
.else
-ZEXT= ${ZEXTENSION}
+ZEXT= ${MCOMPRESS_EXT}
.for sect in ${SECTIONS}
.if defined(MAN${sect}) && !empty(MAN${sect})
-CLEANFILES+= ${MAN${sect}:T:S/$/${ZEXTENSION}/g}
+CLEANFILES+= ${MAN${sect}:T:S/$/${MCOMPRESS_EXT}/g}
.for page in ${MAN${sect}}
-.for target in ${page:T:S/$/${ZEXTENSION}/}
+.for target in ${page:T:S/$/${MCOMPRESS_EXT}/}
all-man: ${target}
${target}: ${page}
.if defined(MANFILTER)
- ${MANFILTER} < ${.ALLSRC} | ${MCOMPRESS} > ${.TARGET}
+ ${MANFILTER} < ${.ALLSRC} | ${MCOMPRESS_CMD} > ${.TARGET}
.else
- ${MCOMPRESS} ${.ALLSRC} > ${.TARGET}
+ ${MCOMPRESS_CMD} ${.ALLSRC} > ${.TARGET}
.endif
.endfor
.endfor
@@ -137,7 +137,7 @@ maninstall:: ${MAN${sect}}
${MINSTALL} ${.ALLSRC} ${DESTDIR}${MANDIR}${sect}${MANSUBDIR}
.endif
.else
- ${MINSTALL} ${.ALLSRC:T:S/$/${ZEXTENSION}/g} \
+ ${MINSTALL} ${.ALLSRC:T:S/$/${MCOMPRESS_EXT}/g} \
${DESTDIR}${MANDIR}${sect}${MANSUBDIR}
.endif
.endif
@@ -155,7 +155,7 @@ maninstall:: ${MAN${sect}}
name=$$1; shift; sect=$$1; shift; \
t=${DESTDIR}${MANDIR}$${sect}${MANSUBDIR}/$$name; \
${ECHO} $${t}${ZEXT} -\> $${l}${ZEXT}; \
- rm -f $${t} $${t}${ZEXTENSION}; \
+ rm -f $${t} $${t}${MCOMPRESS_EXT}; \
ln $${l}${ZEXT} $${t}${ZEXT}; \
done
.endif
diff --git a/share/mk/bsd.own.mk b/share/mk/bsd.own.mk
index 00860a1..631c7eb 100644
--- a/share/mk/bsd.own.mk
+++ b/share/mk/bsd.own.mk
@@ -1,4 +1,4 @@
-# $Id$
+# $Id: bsd.own.mk,v 1.9 1997/02/22 13:56:12 peter Exp $
#
# The include file <bsd.own.mk> set common variables for owner,
# group, mode, and directories. Defaults are in brackets.
@@ -18,6 +18,11 @@
# 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 -c]
+#
+# 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
@@ -158,3 +163,5 @@ STRIP?= -s
.endif
COPY?= -c
+COMPRESS_CMD?= gzip -c
+COMPRESS_EXT?= .gz
OpenPOWER on IntegriCloud