diff --git a/release/doc/README b/release/doc/README index cd7ed8b3507..e1cab3806da 100644 --- a/release/doc/README +++ b/release/doc/README @@ -18,10 +18,17 @@ DOC_PREFIX Makefile variable. RELNOTESng also requires the DocProj build tools, which can easily be installed with the textproc/docproj port in the Ports Collection. -share/sgml/*.dsl - Architecture-dependent stylesheets. These stylesheets support - the arch= attribute on (all?) DocBook elements. Currently- - supported values are: i386, alpha. +share/mk/doc.relnotes.mk + Common Makefile definitions for RELNOTESng. These definitions + mostly accomodate the fact that we're building DocProj-like + documents outside the doc/ tree. +share/sgml/release.dsl + Language-neutral stylesheet. This stylesheet supports + the arch= attribute on (all?) DocBook elements; elements with + an arch= attribute are only included in the output if their + value is equal to the value of the &arch; entity. In the + future, arch= could be a list of possible &arch; entity values + that match, such as "i386,alpha". share/sgml/release.ent Release information. Need to update the entry definitions in this file when rolling new revisions; these should take effect diff --git a/release/doc/en_US.ISO8859-1/errata/Makefile b/release/doc/en_US.ISO8859-1/errata/Makefile index 7ae9443537e..87801ca415d 100644 --- a/release/doc/en_US.ISO8859-1/errata/Makefile +++ b/release/doc/en_US.ISO8859-1/errata/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml diff --git a/release/doc/en_US.ISO8859-1/hardware/alpha/Makefile b/release/doc/en_US.ISO8859-1/hardware/alpha/Makefile index 7b69f8892b2..69e9a3c3dd2 100644 --- a/release/doc/en_US.ISO8859-1/hardware/alpha/Makefile +++ b/release/doc/en_US.ISO8859-1/hardware/alpha/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -16,9 +15,5 @@ SRCS+= ../common/artheader.sgml SRCS+= ../common/dev.sgml SRCS+= ../common/config.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-alpha.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-alpha.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO8859-1/hardware/i386/Makefile b/release/doc/en_US.ISO8859-1/hardware/i386/Makefile index 6b396a1a3ae..7e02d19f7e5 100644 --- a/release/doc/en_US.ISO8859-1/hardware/i386/Makefile +++ b/release/doc/en_US.ISO8859-1/hardware/i386/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -16,9 +15,5 @@ SRCS+= ../common/artheader.sgml SRCS+= ../common/dev.sgml SRCS+= ../common/config.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-i386.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-i386.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO8859-1/installation/alpha/Makefile b/release/doc/en_US.ISO8859-1/installation/alpha/Makefile index 5fa420f3ee4..19de1c1f1e4 100644 --- a/release/doc/en_US.ISO8859-1/installation/alpha/Makefile +++ b/release/doc/en_US.ISO8859-1/installation/alpha/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -17,9 +16,5 @@ SRCS+= ../common/layout.sgml SRCS+= ../common/trouble.sgml SRCS+= ../common/upgrade.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-alpha.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-alpha.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO8859-1/installation/i386/Makefile b/release/doc/en_US.ISO8859-1/installation/i386/Makefile index 9f80ef82d7e..19de1c1f1e4 100644 --- a/release/doc/en_US.ISO8859-1/installation/i386/Makefile +++ b/release/doc/en_US.ISO8859-1/installation/i386/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -17,9 +16,5 @@ SRCS+= ../common/layout.sgml SRCS+= ../common/trouble.sgml SRCS+= ../common/upgrade.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-i386.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-i386.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO8859-1/readme/Makefile b/release/doc/en_US.ISO8859-1/readme/Makefile index adc8a247786..5dd73b90717 100644 --- a/release/doc/en_US.ISO8859-1/readme/Makefile +++ b/release/doc/en_US.ISO8859-1/readme/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # # SRCS lists the individual SGML files that make up the document. Changes diff --git a/release/doc/en_US.ISO8859-1/relnotes/alpha/Makefile b/release/doc/en_US.ISO8859-1/relnotes/alpha/Makefile index 29edd54939c..2c0390b4f10 100644 --- a/release/doc/en_US.ISO8859-1/relnotes/alpha/Makefile +++ b/release/doc/en_US.ISO8859-1/relnotes/alpha/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -15,9 +14,5 @@ SRCS+= ../common/artheader.sgml SRCS+= ../common/new.sgml SRCS+= ../common/upgrading.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-alpha.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-alpha.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO8859-1/relnotes/i386/Makefile b/release/doc/en_US.ISO8859-1/relnotes/i386/Makefile index 862e9f109eb..2c0390b4f10 100644 --- a/release/doc/en_US.ISO8859-1/relnotes/i386/Makefile +++ b/release/doc/en_US.ISO8859-1/relnotes/i386/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -15,9 +14,5 @@ SRCS+= ../common/artheader.sgml SRCS+= ../common/new.sgml SRCS+= ../common/upgrading.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-i386.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-i386.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO_8859-1/errata/Makefile b/release/doc/en_US.ISO_8859-1/errata/Makefile index 7ae9443537e..87801ca415d 100644 --- a/release/doc/en_US.ISO_8859-1/errata/Makefile +++ b/release/doc/en_US.ISO_8859-1/errata/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml diff --git a/release/doc/en_US.ISO_8859-1/hardware/alpha/Makefile b/release/doc/en_US.ISO_8859-1/hardware/alpha/Makefile index 7b69f8892b2..69e9a3c3dd2 100644 --- a/release/doc/en_US.ISO_8859-1/hardware/alpha/Makefile +++ b/release/doc/en_US.ISO_8859-1/hardware/alpha/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -16,9 +15,5 @@ SRCS+= ../common/artheader.sgml SRCS+= ../common/dev.sgml SRCS+= ../common/config.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-alpha.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-alpha.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO_8859-1/hardware/i386/Makefile b/release/doc/en_US.ISO_8859-1/hardware/i386/Makefile index 6b396a1a3ae..7e02d19f7e5 100644 --- a/release/doc/en_US.ISO_8859-1/hardware/i386/Makefile +++ b/release/doc/en_US.ISO_8859-1/hardware/i386/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -16,9 +15,5 @@ SRCS+= ../common/artheader.sgml SRCS+= ../common/dev.sgml SRCS+= ../common/config.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-i386.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-i386.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO_8859-1/installation/alpha/Makefile b/release/doc/en_US.ISO_8859-1/installation/alpha/Makefile index 5fa420f3ee4..19de1c1f1e4 100644 --- a/release/doc/en_US.ISO_8859-1/installation/alpha/Makefile +++ b/release/doc/en_US.ISO_8859-1/installation/alpha/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -17,9 +16,5 @@ SRCS+= ../common/layout.sgml SRCS+= ../common/trouble.sgml SRCS+= ../common/upgrade.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-alpha.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-alpha.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO_8859-1/installation/i386/Makefile b/release/doc/en_US.ISO_8859-1/installation/i386/Makefile index 9f80ef82d7e..19de1c1f1e4 100644 --- a/release/doc/en_US.ISO_8859-1/installation/i386/Makefile +++ b/release/doc/en_US.ISO_8859-1/installation/i386/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -17,9 +16,5 @@ SRCS+= ../common/layout.sgml SRCS+= ../common/trouble.sgml SRCS+= ../common/upgrade.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-i386.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-i386.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO_8859-1/readme/Makefile b/release/doc/en_US.ISO_8859-1/readme/Makefile index adc8a247786..5dd73b90717 100644 --- a/release/doc/en_US.ISO_8859-1/readme/Makefile +++ b/release/doc/en_US.ISO_8859-1/readme/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # # SRCS lists the individual SGML files that make up the document. Changes diff --git a/release/doc/en_US.ISO_8859-1/relnotes/alpha/Makefile b/release/doc/en_US.ISO_8859-1/relnotes/alpha/Makefile index 29edd54939c..2c0390b4f10 100644 --- a/release/doc/en_US.ISO_8859-1/relnotes/alpha/Makefile +++ b/release/doc/en_US.ISO_8859-1/relnotes/alpha/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -15,9 +14,5 @@ SRCS+= ../common/artheader.sgml SRCS+= ../common/new.sgml SRCS+= ../common/upgrading.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-alpha.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-alpha.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/en_US.ISO_8859-1/relnotes/i386/Makefile b/release/doc/en_US.ISO_8859-1/relnotes/i386/Makefile index 862e9f109eb..2c0390b4f10 100644 --- a/release/doc/en_US.ISO_8859-1/relnotes/i386/Makefile +++ b/release/doc/en_US.ISO_8859-1/relnotes/i386/Makefile @@ -6,7 +6,6 @@ DOC?= article FORMATS?= html INSTALL_COMPRESSED?= gz INSTALL_ONLY_COMPRESSED?= -EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog # SGML content SRCS+= article.sgml @@ -15,9 +14,5 @@ SRCS+= ../common/artheader.sgml SRCS+= ../common/new.sgml SRCS+= ../common/upgrading.sgml -# Use the appropriate architecture-dependent RELNOTESng stylesheet -DSLHTML?= ${RELN_ROOT}/share/sgml/release-i386.dsl -DSLPRINT?= ${RELN_ROOT}/share/sgml/release-i386.dsl - .include "${RELN_ROOT}/share/mk/doc.relnotes.mk" .include "${DOC_PREFIX}/share/mk/doc.project.mk" diff --git a/release/doc/share/mk/doc.relnotes.mk b/release/doc/share/mk/doc.relnotes.mk index 8248441e87e..51f84443a5b 100644 --- a/release/doc/share/mk/doc.relnotes.mk +++ b/release/doc/share/mk/doc.relnotes.mk @@ -2,5 +2,12 @@ DOC_PREFIX?= ${RELN_ROOT}/../../../doc +# Find the RELNOTESng document catalog +EXTRA_CATALOGS+= ${RELN_ROOT}/share/sgml/catalog + +# Use the appropriate architecture-dependent RELNOTESng stylesheet +DSLHTML?= ${RELN_ROOT}/share/sgml/release.dsl +DSLPRINT?= ${RELN_ROOT}/share/sgml/release.dsl + # XXX using /release/doc as anchor! DESTDIR?= ${DOCDIR}/${.CURDIR:C/^.*\/release\/doc//} diff --git a/release/doc/share/sgml/release-i386.dsl b/release/doc/share/sgml/release-i386.dsl deleted file mode 100644 index f3e52f76f1a..00000000000 --- a/release/doc/share/sgml/release-i386.dsl +++ /dev/null @@ -1,32 +0,0 @@ - - - -]> - - - - - -; The architecture we're building for. We really need to pull this out of a -; entity somewhere, so it can be defined without needing to munge the -; stylesheet. Or do we? -(define for-arch "i386") - -(default - (let* ((arch (attribute-string (normalize "arch")))) - (if (or (equal? arch #f) - (equal? arch "")) - (next-match) -; We can do a lot more flexible things here. Like it'd be nice to -; tokenize the arch= attribute and do comparisons of for-arch against -; different substrings. - (cond ((equal? arch for-arch) (next-match)) - (else (empty-sosofo)))))) - - - - - - - diff --git a/release/doc/share/sgml/release-alpha.dsl b/release/doc/share/sgml/release.dsl similarity index 71% rename from release/doc/share/sgml/release-alpha.dsl rename to release/doc/share/sgml/release.dsl index 5515c65406c..a1666f64fcf 100644 --- a/release/doc/share/sgml/release-alpha.dsl +++ b/release/doc/share/sgml/release.dsl @@ -8,13 +8,13 @@ -; The architecture we're building for. We really need to pull this out of a -; entity somewhere, so it can be defined without needing to munge the -; stylesheet. Or do we? -(define for-arch "alpha") +; The architecture we're building for. We need to define this as a +; procedure, because we may not be able to evaluate it until we are +; at a point in formatting where (current-node) is defined. (default - (let* ((arch (attribute-string (normalize "arch")))) + (let* ((arch (attribute-string (normalize "arch"))) + (for-arch (entity-text "arch"))) (if (or (equal? arch #f) (equal? arch "")) (next-match)