OSDN Git Service

Avoid Unicode hyphens in generated ASCII document files.
authorKeith Marshall <keithmarshall@users.sourceforge.net>
Tue, 22 Mar 2011 19:34:43 +0000 (19:34 +0000)
committerKeith Marshall <keithmarshall@users.sourceforge.net>
Tue, 22 Mar 2011 19:34:43 +0000 (19:34 +0000)
ChangeLog
Makefile.in

index 76f7eeb..36af126 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2011-03-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
+
+       Avoid Unicode hyphens in generated ASCII document files.
+
+       * Makefile.in (NROFF): New macro; define it to invoke `nroff -Tascii'.
+       (%.dist, readme.txt): Use it to ensure that output is pure ASCII.
+
 2011-03-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
 
        mingw-get-0.2-mingw32-alpha-2 released.
index ddcea8c..521dbc2 100644 (file)
@@ -224,8 +224,15 @@ srcdist: pkginfo.c srcdist-doc
 vpath %.in ${srcdir}/srcdist-doc
 srcdist-doc: README.dist NEWS.dist INSTALL.dist
 
+# We need to ensure that, when we invoke nroff, the generated output
+# will be suited to an ASCII class of typesetter; without the -Tascii
+# option, GNU nroff will substitute Unicode hyphens (u2010) in place
+# of ASCII hyphens (code 45).
+#
+NROFF = nroff -Tascii
+
 %.dist: %.in gendoc.simple.sed
-       sed -f gendoc.simple.sed $< | nroff > $*
+       sed -f gendoc.simple.sed $< | $(NROFF) > $*
 
 %.simple.sed: %.sed.in
        sed -e s,'$${PACKAGE_DIRNAME}',"${PACKAGE_DISTROOT}", \
@@ -243,7 +250,7 @@ readme.txt: README.in NEWS.in INSTALL.in gendoc.combined.sed
        rm -f $@
        for input in $^; do \
          case $$input in *.in) \
-           sed -f gendoc.combined.sed $$input | nroff >> $@ ;; \
+           sed -f gendoc.combined.sed $$input | $(NROFF) >> $@ ;; \
            esac; \
          done
        echo '$$Document: $@ $$: end of file' >> $@