aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWolfram Schneider <wosch@FreeBSD.org>1998-08-29 11:01:22 +0000
committerWolfram Schneider <wosch@FreeBSD.org>1998-08-29 11:01:22 +0000
commite3706b10d9b46b67ba7b6210000e489bba67ca5e (patch)
tree3e401dbc79bfb17f4642978a167c6648b9dfce84
parent056a66c845653bbef5023eca8f531d6998abfc02 (diff)
Notes
-rw-r--r--share/mk/Makefile4
-rw-r--r--share/mk/bsd.docb.mk55
2 files changed, 58 insertions, 1 deletions
diff --git a/share/mk/Makefile b/share/mk/Makefile
index d7c87a89c44a..7f22b9ab330c 100644
--- a/share/mk/Makefile
+++ b/share/mk/Makefile
@@ -1,4 +1,4 @@
-# $Id: Makefile,v 1.16 1998/01/03 14:04:55 wosch Exp $
+# $Id: Makefile,v 1.18 1998/05/20 22:27:09 jkh Exp $
# From: @(#)Makefile 8.1 (Berkeley) 6/8/93
FILES= bsd.README
@@ -6,6 +6,8 @@ FILES+= bsd.dep.mk bsd.doc.mk bsd.info.mk bsd.kern.mk bsd.kmod.mk
FILES+= bsd.lib.mk bsd.libnames.mk bsd.man.mk bsd.obj.mk bsd.own.mk
FILES+= bsd.port.mk bsd.port.subdir.mk bsd.prog.mk bsd.sgml.mk bsd.subdir.mk
FILES+= sys.mk
+FILES+= bsd.docb.mk
+
NOOBJ= noobj
all clean cleandir depend lint tags:
diff --git a/share/mk/bsd.docb.mk b/share/mk/bsd.docb.mk
new file mode 100644
index 000000000000..2ea5f3da09aa
--- /dev/null
+++ b/share/mk/bsd.docb.mk
@@ -0,0 +1,55 @@
+# The include file <bsd.docb.mk> handles installing SGML/docbook documents.
+#
+# $Id
+#
+# +++ variables +++
+#
+# DOC Name of the document.
+#
+# VOLUME Name of the installation subdirectory.
+#
+# SGMLOPTS Flags to sgmlfmt.
+#
+# SGMLFMT Format sgml files command. [sgmlfmt]
+#
+#
+# +++ targets +++
+#
+# all:
+# Converts sgml files to the specified output format
+# (see ${FORMATS}).
+#
+# install:
+# Install formated output.
+
+
+.if !target(__initialized__)
+__initialized__:
+.if exists(${.CURDIR}/../Makefile.inc)
+.include "${.CURDIR}/../Makefile.inc"
+.endif
+.endif
+
+# Use SGMLOPTS to pass extra flags to sgmlfmt(1).
+VOLUME?= ${.CURDIR:T}
+DOC?= ${.CURDIR:T}
+SGMLFMT?= sgmlfmt
+
+_docs= ${DOC:S/$/.html/g}
+CLEANFILES+=${_docs}
+
+# A DocBook document has the suffix .docb or .sgml. If a document
+# with both suffixes exists, .docb wins.
+.SUFFIXES: .docb .sgml .html
+
+.docb.html .sgml.html: ${SRCS}
+ ${SGMLFMT} -d docbook -f html ${SGMLOPTS} ${.IMPSRC}
+
+.MAIN: all
+all: ${_docs}
+
+install:
+ ${INSTALL} ${COPY} -o ${DOCOWN} -g ${DOCGRP} -m ${DOCMODE} \
+ ${_docs} ${DESTDIR}${DOCDIR}/${VOLUME}
+
+.include <bsd.obj.mk>