From owner-freebsd-doc@FreeBSD.ORG Sun Apr 20 03:53:46 2003 Return-Path: Delivered-To: freebsd-doc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 558C037B404; Sun, 20 Apr 2003 03:53:45 -0700 (PDT) Received: from smtp.eos.ocn.ne.jp (eos.ocn.ne.jp [211.6.83.117]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8F91843FA3; Sun, 20 Apr 2003 03:53:44 -0700 (PDT) (envelope-from hrs@eos.ocn.ne.jp) Received: from mail.allbsd.org (p53054-adsao12honb4-acca.tokyo.ocn.ne.jp [220.96.135.54]) by smtp.eos.ocn.ne.jp (Postfix) with ESMTP id 7879C278B; Sun, 20 Apr 2003 19:53:43 +0900 (JST) Received: from localhost (alph.allbsd.org [192.168.0.10]) h3KAqpJp071300; Sun, 20 Apr 2003 19:52:51 +0900 (JST) (envelope-from hrs@eos.ocn.ne.jp) Date: Sun, 20 Apr 2003 19:52:05 +0900 (JST) Message-Id: <20030420.195205.50333554.hrs@eos.ocn.ne.jp> To: bmah@FreeBSD.org From: Hiroki Sato In-Reply-To: <200304191749.h3JHndxV053505@bmah.dyndns.org> References: <200304191540.h3JFeSxV052609@bmah.dyndns.org> <20030420.020436.102903006.hrs@eos.ocn.ne.jp> <200304191749.h3JHndxV053505@bmah.dyndns.org> X-PGPkey-fingerprint: BDB3 443F A5DD B3D0 A530 FFD7 4F2C D3D8 2793 CF2D X-Mailer: Mew version 2.2 on Emacs 20.7 / Mule 4.0 (HANANOEN) Mime-Version: 1.0 Content-Type: Multipart/Mixed; boundary="--Next_Part(Sun_Apr_20_19:52:05_2003_003)--" Content-Transfer-Encoding: 7bit cc: doc@FreeBSD.org Subject: Re: suggestion for adding a l10n-capable doc-format navi X-BeenThere: freebsd-doc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Documentation project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Apr 2003 10:53:46 -0000 ----Next_Part(Sun_Apr_20_19:52:05_2003_003)-- Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit bmah@FreeBSD.org (Bruce A. Mah) wrote in <200304191749.h3JHndxV053505@bmah.dyndns.org>: bmah> > Yes, you have got a point. I made another patch that makes the link bmah> > be generated only when ${FORMATS} includes both of "html" and "html-split," bmah> > and "WITH_DOCFORMAT_NAVI_LINK=YES." bmah> bmah> OK. I *think* this is better. This will make it more conservative bmah> about adding the navi-link, but it will give it to us whenever we know bmah> that we have both versions available. (Plus we can still override it bmah> if for some reason we need to do this.) How about the following: 1) WITH_FOO is defined and WITH_FOO!=NO, it means YES. 2) WITH_FOO is defined and WITH_FOO==NO, it means NO. 3) WITH_FOO is not defined, it means NO. A problem of that defining of WITH_FOO always means YES is that we cannot disable it if it is enabled by default in Makefile using WITH_FOO?=YES. But as you pointed out, in other places this sort of variables that is defined mean YES regardless of what the value was. The above behavior is not against the old one, I think. Besides, I changed the logic for WITH_DOCFORMAT_NAVI_LINK again in the attached patch like this: if $WITH_DOCFORMAT_NAVI_LINK is defined if $WITH_DOCFORMAT_NAVI_LINK != NO endif else if $FORMATS includes both "html" and "html-split" endif Namely, $WITH_DOCFORMAT_NAVI_LINK has priority. Even if html and/or html-split version do not exist, specifying WITH_DOCFORMAT_NAVI_LINK=YES we can generate the navi-link. If the variable is not defined, the link is generated only when the two versions are built at the same time. I guess the latter behavior does not become harmful. I think I will commit the patch and backout WITH_DOCFORMAT_NAVI_LINK?=YES in doc/en_US.ISO8859-1. Any comments? -- | Hiroki SATO / ----Next_Part(Sun_Apr_20_19:52:05_2003_003)-- Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="doc.docbook.mk.diff" Index: doc.docbook.mk =================================================================== RCS file: /home/dcvs/doc/share/mk/doc.docbook.mk,v retrieving revision 1.82 diff -d -u -I\$FreeBSD:.*\$ -I\$Id:.*\$ -I\$hrs:.*\$ -r1.82 doc.docbook.mk --- doc.docbook.mk 19 Apr 2003 11:39:30 -0000 1.82 +++ doc.docbook.mk 20 Apr 2003 10:39:51 -0000 @@ -192,18 +192,22 @@ PNMTOPSFLAGS+= -rle .endif -.if !defined(WITH_INLINE_LEGALNOTICE) || empty(WITH_INLINE_LEGALNOTICE) +.if !defined(WITH_INLINE_LEGALNOTICE) || (${WITH_INLINE_LEGALNOTICE} == "NO") HTMLFLAGS+= -V %generate-legalnotice-link% .endif -.if defined(WITH_ARTICLE_TOC) && !empty(WITH_ARTICLE_TOC) +.if defined(WITH_ARTICLE_TOC) && (${WITH_ARTICLE_TOC} != "NO") HTMLFLAGS+= -V %generate-article-toc% PRINTFLAGS+= -V %generate-article-toc% .endif -.if defined(WITH_BIBLIOXREF_TITLE) && !empty(WITH_BIBLIOXREF_TITLE) +.if defined(WITH_BIBLIOXREF_TITLE) && (${WITH_BIBLIOXREF_TITLE} != "NO") HTMLFLAGS+= -V biblio-xref-title PRINTFLAGS+= -V biblio-xref-title .endif -.if defined(WITH_DOCFORMAT_NAVI_LINK) && !empty(WITH_DOCFORMAT_NAVI_LINK) +.if defined(WITH_DOCFORMAT_NAVI_LINK) +.if (${WITH_DOCFORMAT_NAVI_LINK} != "NO") +HTMLFLAGS+= -V %generate-docformat-navi-link% +.endif +.elif (${FORMATS:Mhtml} == "html") && (${FORMATS:Mhtml-split} == "html-split") HTMLFLAGS+= -V %generate-docformat-navi-link% .endif ----Next_Part(Sun_Apr_20_19:52:05_2003_003)----