Re: latin1 handling of groff (Re: man&groff from woody)
I checked woody's groff 1.15.3-2.
In <[🔎] 20001015195102.A3743@logic.ru>,
on "Sun, 15 Oct 2000 19:51:03 +0400",
with "Re: latin1 handling of groff (Re: man&groff from woody)",
Peter Novodvorsky <nidd@debian.org> wrote:
> ++ 15/10/00 18:47 +0400 - Peter Novodvorsky:
> >
> >
> > I've attached your patch, but I get the same result. ;-(((
> Oops... I meant I've compiled groff with your patch...
> I was thinking about something else.. ;-(
The tree structure of source code is different between 1.15 and 1.16,
so the previous patch needs the manual edit.
Here is the patch for 1.15.3-2:
diff -ruN groff-1.15.3.old/debian/changelog groff-1.15.3/debian/changelog
--- groff-1.15.3.old/debian/changelog Mon Oct 16 12:27:42 2000
+++ groff-1.15.3/debian/changelog Mon Oct 16 12:32:15 2000
@@ -1,3 +1,10 @@
+groff (1.15.3-2.1) local-only; urgency=low
+
+ * non maintainer, local-only test.
+ * try to fix latin1 bug (Bug #66928, #71744)
+
+ -- Taketoshi Sano <sano@debian.org> Mon, 16 Oct 2000 12:28:10 +0900
+
groff (1.15.3-2) unstable; urgency=low
* Applied patch proposed by Karl M.Hegbloom to get a single page from
diff -ruN groff-1.15.3.old/include/device.h groff-1.15.3/include/device.h
--- groff-1.15.3.old/include/device.h Fri May 21 13:50:38 1999
+++ groff-1.15.3/include/device.h Mon Oct 16 12:25:04 2000
@@ -18,4 +18,9 @@
with groff; see the file COPYING. If not, write to the Free Software
Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+#ifndef _DEVICE_H
+#define _DEVICE_H
+
extern const char *device;
+
+#endif /* _DEVICE_H */
diff -ruN groff-1.15.3.old/include/eucmac.h groff-1.15.3/include/eucmac.h
--- groff-1.15.3.old/include/eucmac.h Mon Oct 16 12:27:41 2000
+++ groff-1.15.3/include/eucmac.h Mon Oct 16 12:26:57 2000
@@ -22,6 +22,9 @@
#ifndef _EUCMAC_H
#define _EUCMAC_H
+#include <string.h>
+#include "device.h"
+
typedef unsigned short wchar;
static const int WCTABLE_OFFSET = 0xa1;
@@ -31,11 +34,23 @@
inline int is_euc_code(wchar wc)
{
+ if ( device ) {
+ if ((strncmp(device, "latin1", 6) == 0) ||
+ (strncmp(device, "ascii8", 6) == 0)) {
+ return(0);
+ }
+ }
return((wc & EUCMASK) == EUCMASK);
}
inline int is_euc_byte(unsigned char c)
{
+ if ( device ) {
+ if ((strncmp(device, "latin1", 6) == 0) ||
+ (strncmp(device, "ascii8", 6) == 0)) {
+ return(0);
+ }
+ }
return(c >= 0xa1 && c <= 0xfe);
}
Please check this. I can see russian manpage of rpm using groff
1.15.3-2.1 (1.15-3 modified by this patch) on my woody system.
# I created symlink ru_RU.KOI8R to ru_RU.koi8r in /usr/lib/locale
# according to your hint.
Regards.
--
Taketoshi Sano: <sano@debian.org>,<sano@debian.or.jp>,<kgh12351@nifty.ne.jp>
Reply to: