Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 07 Aug 2004 04:31:47 +0900 (JST)
From:      Hiroki Sato <hrs@FreeBSD.org>
To:        den@FreeBSD.org
Cc:        freebsd-doc@FreeBSD.org
Subject:   Re: [patch] SP_ENCODING support in doc.docbook.mk
Message-ID:  <20040807.043147.99822694.hrs@eos.ocn.ne.jp>
In-Reply-To: <4110CB82.8000204@FreeBSD.org>
References:  <4110CB82.8000204@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
----Security_Multipart0(Sat_Aug__7_04_31_47_2004_853)--
Content-Type: Multipart/Mixed;
 boundary="--Next_Part(Sat_Aug__7_04_31_47_2004_540)--"
Content-Transfer-Encoding: 7bit

----Next_Part(Sat_Aug__7_04_31_47_2004_540)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hi,

Denis Peplin <den@freebsd.org> wrote
  in <4110CB82.8000204@FreeBSD.org>:

den> Patch in attacment can fix encoding of printed
den> formats, at least for KOI8-R (and for encodings,
den> supported by jade).

 I think this should depend on <langcode>/share directory,
 not on share/.  What do you think about separating such
 customizations for a specific language like the attached patch?

-- 
| Hiroki SATO

----Next_Part(Sat_Aug__7_04_31_47_2004_540)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="doc-spenc.diff"

Index: en_US.ISO8859-1/share/mk/doc.local.mk
===================================================================
RCS file: en_US.ISO8859-1/share/mk/doc.local.mk
diff -N en_US.ISO8859-1/share/mk/doc.local.mk
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ en_US.ISO8859-1/share/mk/doc.local.mk	6 Aug 2004 19:19:09 -0000
@@ -0,0 +1,3 @@
+# $FreeBSD$
+
+SP_ENCODING?=	${LANGCODE:C,^.*\.,,:C,^ISO,ISO-,}
Index: ru_RU.KOI8-R/share/mk/doc.local.mk
===================================================================
RCS file: ru_RU.KOI8-R/share/mk/doc.local.mk
diff -N ru_RU.KOI8-R/share/mk/doc.local.mk
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ ru_RU.KOI8-R/share/mk/doc.local.mk	6 Aug 2004 19:17:37 -0000
@@ -0,0 +1,3 @@
+# $FreeBSD$
+
+SP_ENCODING?=	KOI8-R
Index: share/mk/doc.docbook.mk
===================================================================
RCS file: /home/ncvs/doc/share/mk/doc.docbook.mk,v
retrieving revision 1.110
diff -d -u -I\$FreeBSD:.*\$ -I\$NetBSD:.*\$ -I\$OpenBSD:.*\$ -I\$DragonFly:.*\$ -I\$Id:.*\$ -I\$hrs:.*\$ -r1.110 doc.docbook.mk
--- share/mk/doc.docbook.mk	6 Aug 2004 09:33:17 -0000	1.110
+++ share/mk/doc.docbook.mk	6 Aug 2004 19:16:28 -0000
@@ -147,7 +147,10 @@
 SX?=		${PREFIX}/bin/sx
 .endif
 
-JADE_CMD=	${JADE}
+.if defined(SP_ENCODING)
+JADE_ENV+=	SP_ENCODING=${SP_ENCODING}
+.endif
+JADE_CMD=	env ${JADE_ENV} ${JADE}
 
 DSLHTML?=	${DOC_PREFIX}/share/sgml/default.dsl
 DSLPRINT?=	${DOC_PREFIX}/share/sgml/default.dsl
@@ -451,17 +454,6 @@
 .MAIN: all
 
 all: ${_docs}
-
-#
-# SP_ENCODING support
-#
-CUR_ENCODING!= 	${ECHO} ${LANGCODE} | ${SED} 's/^.*\.//' | \
-	${SED} 's/^ISO/ISO\-/'
-.for _sp_encoding in ${SP_ENCODING_LIST}
-.if ${CUR_ENCODING} == ${_sp_encoding}
-JADE_CMD=	SP_ENCODING=${CUR_ENCODING} ${JADE}
-.endif
-.endfor
 
 # XML --------------------------------------------------------------------
 
Index: share/mk/doc.project.mk
===================================================================
RCS file: /home/ncvs/doc/share/mk/doc.project.mk,v
retrieving revision 1.18
diff -d -u -I\$FreeBSD:.*\$ -I\$NetBSD:.*\$ -I\$OpenBSD:.*\$ -I\$DragonFly:.*\$ -I\$Id:.*\$ -I\$hrs:.*\$ -r1.18 doc.project.mk
--- share/mk/doc.project.mk	23 Jul 2004 18:58:56 -0000	1.18
+++ share/mk/doc.project.mk	6 Aug 2004 19:16:28 -0000
@@ -99,6 +99,12 @@
 # targets and variables commonly used in doc/ and www/ tree.
 .include "doc.common.mk"
 
+DOC_LOCAL_MK=	${DOC_PREFIX}/${LANGCODE}/share/mk/doc.local.mk
+
+.if exists(${DOC_LOCAL_MK})
+.include "${DOC_LOCAL_MK}"
+.endif
+
 # Ownership information.
 .include "doc.install.mk"
 

----Next_Part(Sat_Aug__7_04_31_47_2004_540)----

----Security_Multipart0(Sat_Aug__7_04_31_47_2004_853)--
Content-Type: application/pgp-signature
Content-Transfer-Encoding: 7bit

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (FreeBSD)

iD8DBQBBE9yjTyzT2CeTzy0RAsoTAKCW6GlGpFl2s82XJz9ZV0hD4prt3QCfUkMC
6FR5o0NdNYZqFoxwsxE/HiY=
=Ds17
-----END PGP SIGNATURE-----

----Security_Multipart0(Sat_Aug__7_04_31_47_2004_853)----



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040807.043147.99822694.hrs>