summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2011-05-02 12:31:54 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2011-05-02 12:31:54 +0000
commit4911dacf8a9fd770f403274ecc081ebdd19381bd (patch)
tree5e55efd79a8bca63db9e59a35445094581d160cd
parent54bed52730b7a0af68847ac70f93bd1debcaa8dd (diff)
texk/ttf2pk: Add a test case and fix a few small bugs
git-svn-id: svn://tug.org/texlive/trunk@22279 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Build/source/texk/ttf2pk/ChangeLog21
-rw-r--r--Build/source/texk/ttf2pk/Makefile.am53
-rw-r--r--Build/source/texk/ttf2pk/Makefile.in163
-rw-r--r--Build/source/texk/ttf2pk/emtexdir.c2
-rw-r--r--Build/source/texk/ttf2pk/emtexdir.h3
-rw-r--r--Build/source/texk/ttf2pk/errormsg.c3
-rw-r--r--Build/source/texk/ttf2pk/errormsg.h2
-rw-r--r--Build/source/texk/ttf2pk/filesrch.c3
-rw-r--r--Build/source/texk/ttf2pk/parse.c2
-rw-r--r--Build/source/texk/ttf2pk/tests/GenR102.ttfbin0 -> 362664 bytes
-rw-r--r--Build/source/texk/ttf2pk/tests/gentium-ec.enc258
-rw-r--r--Build/source/texk/ttf2pk/tests/ttf2pk.cfg1
-rwxr-xr-xBuild/source/texk/ttf2pk/tests/ttf2pk.test20
-rw-r--r--Build/source/texk/ttf2pk/tests/ttfonts.map1
-rw-r--r--Build/source/texk/ttf2pk/ttf2pk.c2
-rw-r--r--Build/source/texk/ttf2pk/ttf2tfm.113
-rw-r--r--Build/source/texk/ttf2pk/ttf2tfm.c2
-rw-r--r--Build/source/texk/ttf2pk/ttfaux.c2
-rw-r--r--Build/source/texk/ttf2pk/ttfenc.c4
19 files changed, 465 insertions, 90 deletions
diff --git a/Build/source/texk/ttf2pk/ChangeLog b/Build/source/texk/ttf2pk/ChangeLog
index 64e25daed90..e2e21a9403e 100644
--- a/Build/source/texk/ttf2pk/ChangeLog
+++ b/Build/source/texk/ttf2pk/ChangeLog
@@ -1,3 +1,24 @@
+2011-04-29 Peter Breitenlohner <peb@mppmu.mpg.de>
+
+ * parse.c, ttfenc.c: Bug fix. Increase buffer size for increased
+ code/glyph range.
+
+2011-04-28 Peter Breitenlohner <peb@mppmu.mpg.de>
+
+ * tests/ttf2pk.test (new): Shell script for a test case.
+ * tests/GenR102.ttf, tests/gentium-ec.enc, tests/ttf2pk.cfg,
+ tests/ttfonts.map (new}: Test input.
+ * Makefile.am: Adapted.
+
+2011-04-20 Peter Breitenlohner <peb@mppmu.mpg.de>
+
+ * errormsg.c, ttfaux.c: Move 'extern progname' from here ...
+ * errormsg.h: ... to here and make it const.
+ * ttf2pk.c, ttf2tfm.c: Define 'const char *progname'.
+
+ * filesrch.c: Move 'extern setup_list' from here ...
+ * emtexdir..h: ... to here.
+
2009-11-27 Karl Berry <karl@tug.org>
* ttf2pk.c (USAGE): mention email address, update copyrights.
diff --git a/Build/source/texk/ttf2pk/Makefile.am b/Build/source/texk/ttf2pk/Makefile.am
index 51d09ece207..806786f441a 100644
--- a/Build/source/texk/ttf2pk/Makefile.am
+++ b/Build/source/texk/ttf2pk/Makefile.am
@@ -1,6 +1,6 @@
## Makefile.am for the TeX Live subdirectory texk/ttf2pk/
##
-## Copyright (C) 2009 Peter Breitenlohner <tex-live@tug.org>
+## Copyright (C) 2009, 2011 Peter Breitenlohner <tex-live@tug.org>
## You may freely use, modify and/or distribute this file.
##
ACLOCAL_AMFLAGS = -I ../../m4
@@ -11,7 +11,7 @@ AM_CFLAGS = $(WARNING_CFLAGS)
bin_PROGRAMS = ttf2pk ttf2tfm
-ttf2pk_SOURCES = \
+common_sources = \
errormsg.c \
errormsg.h \
filesrch.c \
@@ -22,43 +22,31 @@ ttf2pk_SOURCES = \
newobj.h \
parse.c \
parse.h \
- pklib.c \
- pklib.h \
subfont.c \
subfont.h \
texenc.c \
texenc.h \
- ttf2pk.c \
ttfenc.c \
- ttfenc.h \
+ ttfenc.h
+
+ttf2pk_SOURCES = \
+ $(common_sources) \
+ pklib.c \
+ pklib.h \
+ ttf2pk.c \
ttflib.c \
ttflib.h
ttf2tfm_SOURCES = \
+ $(common_sources) \
case.c \
case.h \
- errormsg.c \
- errormsg.h \
- filesrch.c \
- filesrch.h \
- ligkern.c \
- ligkern.h \
- newobj.c \
- newobj.h \
- parse.c \
- parse.h \
- subfont.c \
- subfont.h \
- texenc.c \
- texenc.h \
tfmaux.c \
tfmaux.h \
ttf2tfm.c \
ttf2tfm.h \
ttfaux.c \
ttfaux.h \
- ttfenc.c \
- ttfenc.h \
vplaux.c \
vplaux.h
@@ -79,10 +67,23 @@ LDADD = $(KPATHSEA_LIBS) $(FREETYPE_LIBS)
dist_man1_MANS = ttf2pk.1 ttf2tfm.1
+EXTRA_DIST = data
+
+# in case of an SVN repository
+dist-hook:
+ rm -rf `find $(distdir) -name .svn`
+
+## Tests.
+##
+TESTS = tests/ttf2pk.test
+EXTRA_DIST += $(TESTS)
+## tests/ttf2pk.test
+EXTRA_DIST += tests/GenR102.ttf tests/gentium-ec.enc tests/ttf2pk.cfg tests/ttfonts.map
+DISTCLEANFILES += GenR-ec.vpl GenR102-ec.*
+
## Not used
##
-EXTRA_DIST = \
- data \
+EXTRA_DIST += \
BUGS \
MakeSub.in \
Makefile.dm \
@@ -94,7 +95,3 @@ EXTRA_DIST = \
emtexdir.h \
ttf2pk.doc
-# in case of an SVN repository
-dist-hook:
- rm -rf `find $(distdir) -name .svn`
-
diff --git a/Build/source/texk/ttf2pk/Makefile.in b/Build/source/texk/ttf2pk/Makefile.in
index 0718c7fecd8..45893727f7f 100644
--- a/Build/source/texk/ttf2pk/Makefile.in
+++ b/Build/source/texk/ttf2pk/Makefile.in
@@ -70,19 +70,17 @@ CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"
PROGRAMS = $(bin_PROGRAMS)
-am_ttf2pk_OBJECTS = errormsg.$(OBJEXT) filesrch.$(OBJEXT) \
+am__objects_1 = errormsg.$(OBJEXT) filesrch.$(OBJEXT) \
ligkern.$(OBJEXT) newobj.$(OBJEXT) parse.$(OBJEXT) \
- pklib.$(OBJEXT) subfont.$(OBJEXT) texenc.$(OBJEXT) \
- ttf2pk.$(OBJEXT) ttfenc.$(OBJEXT) ttflib.$(OBJEXT)
+ subfont.$(OBJEXT) texenc.$(OBJEXT) ttfenc.$(OBJEXT)
+am_ttf2pk_OBJECTS = $(am__objects_1) pklib.$(OBJEXT) ttf2pk.$(OBJEXT) \
+ ttflib.$(OBJEXT)
ttf2pk_OBJECTS = $(am_ttf2pk_OBJECTS)
ttf2pk_LDADD = $(LDADD)
am__DEPENDENCIES_1 =
ttf2pk_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
-am_ttf2tfm_OBJECTS = case.$(OBJEXT) errormsg.$(OBJEXT) \
- filesrch.$(OBJEXT) ligkern.$(OBJEXT) newobj.$(OBJEXT) \
- parse.$(OBJEXT) subfont.$(OBJEXT) texenc.$(OBJEXT) \
- tfmaux.$(OBJEXT) ttf2tfm.$(OBJEXT) ttfaux.$(OBJEXT) \
- ttfenc.$(OBJEXT) vplaux.$(OBJEXT)
+am_ttf2tfm_OBJECTS = $(am__objects_1) case.$(OBJEXT) tfmaux.$(OBJEXT) \
+ ttf2tfm.$(OBJEXT) ttfaux.$(OBJEXT) vplaux.$(OBJEXT)
ttf2tfm_OBJECTS = $(am_ttf2tfm_OBJECTS)
ttf2tfm_LDADD = $(LDADD)
ttf2tfm_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
@@ -127,6 +125,8 @@ NROFF = nroff
MANS = $(dist_man1_MANS)
ETAGS = etags
CTAGS = ctags
+am__tty_colors = \
+red=; grn=; lgn=; blu=; std=
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
distdir = $(PACKAGE)-$(VERSION)
top_distdir = $(distdir)
@@ -264,7 +264,7 @@ ACLOCAL_AMFLAGS = -I ../../m4
INCLUDES = -I$(top_srcdir)/include $(KPATHSEA_INCLUDES) $(FREETYPE_INCLUDES)
AM_CPPFLAGS = -DHAVE_LIBKPATHSEA
AM_CFLAGS = $(WARNING_CFLAGS)
-ttf2pk_SOURCES = \
+common_sources = \
errormsg.c \
errormsg.h \
filesrch.c \
@@ -275,62 +275,42 @@ ttf2pk_SOURCES = \
newobj.h \
parse.c \
parse.h \
- pklib.c \
- pklib.h \
subfont.c \
subfont.h \
texenc.c \
texenc.h \
- ttf2pk.c \
ttfenc.c \
- ttfenc.h \
+ ttfenc.h
+
+ttf2pk_SOURCES = \
+ $(common_sources) \
+ pklib.c \
+ pklib.h \
+ ttf2pk.c \
ttflib.c \
ttflib.h
ttf2tfm_SOURCES = \
+ $(common_sources) \
case.c \
case.h \
- errormsg.c \
- errormsg.h \
- filesrch.c \
- filesrch.h \
- ligkern.c \
- ligkern.h \
- newobj.c \
- newobj.h \
- parse.c \
- parse.h \
- subfont.c \
- subfont.h \
- texenc.c \
- texenc.h \
tfmaux.c \
tfmaux.h \
ttf2tfm.c \
ttf2tfm.h \
ttfaux.c \
ttfaux.h \
- ttfenc.c \
- ttfenc.h \
vplaux.c \
vplaux.h
-DISTCLEANFILES = config.force
+DISTCLEANFILES = config.force GenR-ec.vpl GenR102-ec.*
LDADD = $(KPATHSEA_LIBS) $(FREETYPE_LIBS)
dist_man1_MANS = ttf2pk.1 ttf2tfm.1
-EXTRA_DIST = \
- data \
- BUGS \
- MakeSub.in \
- Makefile.dm \
- dvidrv.btm \
- dvidrv.doc \
- emdir.c \
- emdir.h \
- emtexdir.c \
- emtexdir.h \
+EXTRA_DIST = data $(TESTS) tests/GenR102.ttf tests/gentium-ec.enc \
+ tests/ttf2pk.cfg tests/ttfonts.map BUGS MakeSub.in Makefile.dm \
+ dvidrv.btm dvidrv.doc emdir.c emdir.h emtexdir.c emtexdir.h \
ttf2pk.doc
-
+TESTS = tests/ttf2pk.test
all: c-auto.h
$(MAKE) $(AM_MAKEFLAGS) all-am
@@ -576,6 +556,98 @@ GTAGS:
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+check-TESTS: $(TESTS)
+ @failed=0; all=0; xfail=0; xpass=0; skip=0; \
+ srcdir=$(srcdir); export srcdir; \
+ list=' $(TESTS) '; \
+ $(am__tty_colors); \
+ if test -n "$$list"; then \
+ for tst in $$list; do \
+ if test -f ./$$tst; then dir=./; \
+ elif test -f $$tst; then dir=; \
+ else dir="$(srcdir)/"; fi; \
+ if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \
+ all=`expr $$all + 1`; \
+ case " $(XFAIL_TESTS) " in \
+ *[\ \ ]$$tst[\ \ ]*) \
+ xpass=`expr $$xpass + 1`; \
+ failed=`expr $$failed + 1`; \
+ col=$$red; res=XPASS; \
+ ;; \
+ *) \
+ col=$$grn; res=PASS; \
+ ;; \
+ esac; \
+ elif test $$? -ne 77; then \
+ all=`expr $$all + 1`; \
+ case " $(XFAIL_TESTS) " in \
+ *[\ \ ]$$tst[\ \ ]*) \
+ xfail=`expr $$xfail + 1`; \
+ col=$$lgn; res=XFAIL; \
+ ;; \
+ *) \
+ failed=`expr $$failed + 1`; \
+ col=$$red; res=FAIL; \
+ ;; \
+ esac; \
+ else \
+ skip=`expr $$skip + 1`; \
+ col=$$blu; res=SKIP; \
+ fi; \
+ echo "$${col}$$res$${std}: $$tst"; \
+ done; \
+ if test "$$all" -eq 1; then \
+ tests="test"; \
+ All=""; \
+ else \
+ tests="tests"; \
+ All="All "; \
+ fi; \
+ if test "$$failed" -eq 0; then \
+ if test "$$xfail" -eq 0; then \
+ banner="$$All$$all $$tests passed"; \
+ else \
+ if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
+ banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
+ fi; \
+ else \
+ if test "$$xpass" -eq 0; then \
+ banner="$$failed of $$all $$tests failed"; \
+ else \
+ if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
+ banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
+ fi; \
+ fi; \
+ dashes="$$banner"; \
+ skipped=""; \
+ if test "$$skip" -ne 0; then \
+ if test "$$skip" -eq 1; then \
+ skipped="($$skip test was not run)"; \
+ else \
+ skipped="($$skip tests were not run)"; \
+ fi; \
+ test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
+ dashes="$$skipped"; \
+ fi; \
+ report=""; \
+ if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
+ report="Please report to $(PACKAGE_BUGREPORT)"; \
+ test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
+ dashes="$$report"; \
+ fi; \
+ dashes=`echo "$$dashes" | sed s/./=/g`; \
+ if test "$$failed" -eq 0; then \
+ echo "$$grn$$dashes"; \
+ else \
+ echo "$$red$$dashes"; \
+ fi; \
+ echo "$$banner"; \
+ test -z "$$skipped" || echo "$$skipped"; \
+ test -z "$$report" || echo "$$report"; \
+ echo "$$dashes$$std"; \
+ test "$$failed" -eq 0; \
+ else :; fi
+
distdir: $(DISTFILES)
@list='$(MANS)'; if test -n "$$list"; then \
list=`for p in $$list; do \
@@ -740,6 +812,7 @@ distcleancheck: distclean
$(distcleancheck_listfiles) ; \
exit 1; } >&2
check-am: all-am
+ $(MAKE) $(AM_MAKEFLAGS) check-TESTS
check: check-am
all-am: Makefile $(PROGRAMS) $(MANS) c-auto.h
installdirs:
@@ -847,10 +920,10 @@ uninstall-am: uninstall-binPROGRAMS uninstall-man
uninstall-man: uninstall-man1
-.MAKE: all install-am install-strip
+.MAKE: all check-am install-am install-strip
-.PHONY: CTAGS GTAGS all all-am am--refresh check check-am clean \
- clean-binPROGRAMS clean-generic clean-libtool ctags dist \
+.PHONY: CTAGS GTAGS all all-am am--refresh check check-TESTS check-am \
+ clean clean-binPROGRAMS clean-generic clean-libtool ctags dist \
dist-all dist-bzip2 dist-gzip dist-hook dist-lzma dist-shar \
dist-tarZ dist-xz dist-zip distcheck distclean \
distclean-compile distclean-generic distclean-hdr \
diff --git a/Build/source/texk/ttf2pk/emtexdir.c b/Build/source/texk/ttf2pk/emtexdir.c
index 9a35570adb3..a38686aa7eb 100644
--- a/Build/source/texk/ttf2pk/emtexdir.c
+++ b/Build/source/texk/ttf2pk/emtexdir.c
@@ -133,7 +133,7 @@ static int setup_dir (struct emtex_dir *dst, char *path,
}
-/*static */int setup_list (struct emtex_dir *dst, char *path,
+int setup_list (struct emtex_dir *dst, char *path,
const char *list, unsigned flags)
{
const char *end;
diff --git a/Build/source/texk/ttf2pk/emtexdir.h b/Build/source/texk/ttf2pk/emtexdir.h
index a9a986db05b..5e81a71c4d2 100644
--- a/Build/source/texk/ttf2pk/emtexdir.h
+++ b/Build/source/texk/ttf2pk/emtexdir.h
@@ -41,6 +41,9 @@ struct emtex_dir
extern void (*emtex_dir_find_callback)(const char *name, int ok);
+extern int setup_list(struct emtex_dir *dst, char *path,
+ const char *list, unsigned flags);
+
int emtex_dir_setup (struct emtex_dir *ed, const char *env, const char *dir,
unsigned flags);
diff --git a/Build/source/texk/ttf2pk/errormsg.c b/Build/source/texk/ttf2pk/errormsg.c
index 28233a8bbf4..917036ca7d6 100644
--- a/Build/source/texk/ttf2pk/errormsg.c
+++ b/Build/source/texk/ttf2pk/errormsg.c
@@ -20,9 +20,6 @@
#endif
-extern char progname[]; /* the origin of the error/warning message */
-
-
/*
* Print error message and quit.
*/
diff --git a/Build/source/texk/ttf2pk/errormsg.h b/Build/source/texk/ttf2pk/errormsg.h
index 9b04b56702e..841dd42a036 100644
--- a/Build/source/texk/ttf2pk/errormsg.h
+++ b/Build/source/texk/ttf2pk/errormsg.h
@@ -31,6 +31,8 @@
#endif
+extern const char *progname; /* the origin of the error/warning message */
+
void oops(const char *message,
...);
void boops(const char *buffer,
diff --git a/Build/source/texk/ttf2pk/filesrch.c b/Build/source/texk/ttf2pk/filesrch.c
index 1abf6e573e4..07efe82d161 100644
--- a/Build/source/texk/ttf2pk/filesrch.c
+++ b/Build/source/texk/ttf2pk/filesrch.c
@@ -123,9 +123,6 @@ TeX_search_ttf_file(char **name)
#include "emtexdir.h"
#include "errormsg.h"
-extern int setup_list(struct emtex_dir *dst, char *path,
- const char *list, unsigned flags);
-
char emtex_version_string[] = "emTeXdir";
struct emtex_dir tfm_path,
diff --git a/Build/source/texk/ttf2pk/parse.c b/Build/source/texk/ttf2pk/parse.c
index 3c5b2885ecc..873bf27f9fe 100644
--- a/Build/source/texk/ttf2pk/parse.c
+++ b/Build/source/texk/ttf2pk/parse.c
@@ -126,7 +126,7 @@ readencoding(char **enc, Font *fnt, Boolean ignoreligkern)
FILE *enc_file;
char *p, *q, c;
char *buffer;
- char numbuf[9];
+ char numbuf[11];
size_t offset;
int i;
long l;
diff --git a/Build/source/texk/ttf2pk/tests/GenR102.ttf b/Build/source/texk/ttf2pk/tests/GenR102.ttf
new file mode 100644
index 00000000000..a8c17567437
--- /dev/null
+++ b/Build/source/texk/ttf2pk/tests/GenR102.ttf
Binary files differ
diff --git a/Build/source/texk/ttf2pk/tests/gentium-ec.enc b/Build/source/texk/ttf2pk/tests/gentium-ec.enc
new file mode 100644
index 00000000000..4ec67e3b374
--- /dev/null
+++ b/Build/source/texk/ttf2pk/tests/gentium-ec.enc
@@ -0,0 +1,258 @@
+/gentium-ecEncoding[
+/grave
+/acute
+/circumflex
+/tilde
+/dieresis
+/hungarumlaut
+/ring
+/caron
+/breve
+/macron
+/dotaccent
+/cedilla
+/ogonek
+/quotesinglbase
+/guilsinglleft
+/guilsinglright
+/quotedblleft
+/quotedblright
+/quotedblbase
+/guillemotleft
+/guillemotright
+/endash
+/emdash
+/uni200B
+/.notdef % perthousandzero
+/dotlessi
+/j.dotless
+/ff
+/fi
+/fl
+/ffi
+/ffl
+/.notdef % visiblespace
+/exclam
+/quotedbl
+/numbersign
+/dollar
+/percent
+/ampersand
+/quoteright
+/parenleft
+/parenright
+/asterisk
+/plus
+/comma
+/hyphen
+/period
+/slash
+/zero
+/one
+/two
+/three
+/four
+/five
+/six
+/seven
+/eight
+/nine
+/colon
+/semicolon
+/less
+/equal
+/greater
+/question
+/at
+/A
+/B
+/C
+/D
+/E
+/F
+/G
+/H
+/I
+/J
+/K
+/L
+/M
+/N
+/O
+/P
+/Q
+/R
+/S
+/T
+/U
+/V
+/W
+/X
+/Y
+/Z
+/bracketleft
+/backslash
+/bracketright
+/asciicircum
+/underscore
+/quoteleft
+/a
+/b
+/c
+/d
+/e
+/f
+/g
+/h
+/i
+/j
+/k
+/l
+/m
+/n
+/o
+/p
+/q
+/r
+/s
+/t
+/u
+/v
+/w
+/x
+/y
+/z
+/braceleft
+/bar
+/braceright
+/asciitilde
+/.notdef % /hyphen % hyphen.alt % peb: removed duplicate
+/Abreve
+/Aogonek
+/Cacute
+/Ccaron
+/Dcaron
+/Ecaron
+/Eogonek
+/Gbreve
+/Lacute
+/Lcaron
+/Lslash
+/Nacute
+/Ncaron
+/Eng
+/Ohungarumlaut
+/Racute
+/Rcaron
+/Sacute
+/Scaron
+/Scedilla
+/Tcaron
+/uni021A % Tcommaaccent (Tcedilla)
+/Uhungarumlaut
+/Uring
+/Ydieresis
+/Zacute
+/Zcaron
+/Zdotaccent
+/IJ
+/.notdef % /uni0130 % /Idotaccent % peb: removed, not in font
+/.notdef % /uni0111 % /dmacron % /dcroat % peb: removed, not in font
+/section
+/abreve
+/aogonek
+/cacute
+/ccaron
+/dcaron
+/ecaron
+/eogonek
+/gbreve
+/lacute
+/lcaron
+/lslash
+/nacute
+/ncaron
+/eng
+/ohungarumlaut
+/racute
+/rcaron
+/sacute
+/scaron
+/scedilla
+/tcaron
+/uni021B % tcommaaccent (tcedilla)
+/uhungarumlaut
+/uring
+/ydieresis
+/zacute
+/zcaron
+/zdotaccent
+/ij
+/exclamdown
+/questiondown
+/sterling
+/Agrave
+/Aacute
+/Acircumflex
+/Atilde
+/Adieresis
+/Aring
+/AE
+/Ccedilla
+/Egrave
+/Eacute
+/Ecircumflex
+/Edieresis
+/Igrave
+/Iacute
+/Icircumflex
+/Idieresis
+/Eth
+/Ntilde
+/Ograve
+/Oacute
+/Ocircumflex
+/Otilde
+/Odieresis
+/OE
+/Oslash
+/Ugrave
+/Uacute
+/Ucircumflex
+/Udieresis
+/Yacute
+/Thorn
+/.notdef % Germandbls
+/agrave
+/aacute
+/acircumflex
+/atilde
+/adieresis
+/aring
+/ae
+/ccedilla
+/egrave
+/eacute
+/ecircumflex
+/edieresis
+/igrave
+/iacute
+/icircumflex
+/idieresis
+/eth
+/ntilde
+/ograve
+/oacute
+/ocircumflex
+/otilde
+/odieresis
+/oe
+/oslash
+/ugrave
+/uacute
+/ucircumflex
+/udieresis
+/yacute
+/thorn
+/germandbls
+] def
diff --git a/Build/source/texk/ttf2pk/tests/ttf2pk.cfg b/Build/source/texk/ttf2pk/tests/ttf2pk.cfg
new file mode 100644
index 00000000000..6df52febed4
--- /dev/null
+++ b/Build/source/texk/ttf2pk/tests/ttf2pk.cfg
@@ -0,0 +1 @@
+map ttfonts
diff --git a/Build/source/texk/ttf2pk/tests/ttf2pk.test b/Build/source/texk/ttf2pk/tests/ttf2pk.test
new file mode 100755
index 00000000000..46eb7139e3f
--- /dev/null
+++ b/Build/source/texk/ttf2pk/tests/ttf2pk.test
@@ -0,0 +1,20 @@
+#! /bin/sh
+
+# Copyright (C) 2011 Peter Breitenlohner <tex-live@tug.org>
+# You may freely use, modify and/or distribute this file.
+
+rm -f GenR-ec.vpl GenR102-ec.*
+
+TEXMFCNF=$srcdir/../kpathsea \
+ TEXFONTS=$srcdir/tests \
+ ./ttf2tfm GenR102 -u -q -N -T gentium-ec -v GenR-ec GenR102-ec >GenR102-ec.map || exit 1
+diff $srcdir/tests/ttfonts.map GenR102-ec.map || exit 1
+
+TEXMFCNF=$srcdir/../kpathsea \
+ TEXFONTS=.:$srcdir/tests \
+ TTF2PKINPUTS=$srcdir/tests \
+ ./ttf2pk -q GenR102-ec 100 || exit 1
+
+tftopl GenR102-ec GenR102-ec || exit 77
+pktype GenR102-ec.100pk >GenR102-ec.typ || exit 77
+
diff --git a/Build/source/texk/ttf2pk/tests/ttfonts.map b/Build/source/texk/ttf2pk/tests/ttfonts.map
new file mode 100644
index 00000000000..84d7aed7631
--- /dev/null
+++ b/Build/source/texk/ttf2pk/tests/ttfonts.map
@@ -0,0 +1 @@
+GenR102-ec GenR102 Encoding=gentium-ec.enc PS=Only
diff --git a/Build/source/texk/ttf2pk/ttf2pk.c b/Build/source/texk/ttf2pk/ttf2pk.c
index d24e1e3bc42..5ef405e1c3e 100644
--- a/Build/source/texk/ttf2pk/ttf2pk.c
+++ b/Build/source/texk/ttf2pk/ttf2pk.c
@@ -33,7 +33,7 @@
char ident[] = "ttf2pk version 1.5";
-char progname[] = "ttf2pk"; /* for error/warning messages */
+const char *progname = "ttf2pk"; /* for error/warning messages */
static const char *cfg_filename = "ttf2pk.cfg";
char *mapfiles;
diff --git a/Build/source/texk/ttf2pk/ttf2tfm.1 b/Build/source/texk/ttf2pk/ttf2tfm.1
index a1edc31eaae..482f2ee1ff4 100644
--- a/Build/source/texk/ttf2pk/ttf2tfm.1
+++ b/Build/source/texk/ttf2pk/ttf2tfm.1
@@ -878,9 +878,16 @@ As can be easily seen, this algorithm allows for adding and replacing,
but not for removing entries.
.PP
Subfont mode disables the options
-.BR \-n , \ \-N , \ \-p ,
-.BR \-r , \ \-R , \ \-t ,
-.BR \-T , \ \-u , \ \-v , \ \-V
+.BR \-n ,
+.BR \-N ,
+.BR \-p ,
+.BR \-r ,
+.BR \-R ,
+.BR \-t ,
+.BR \-T ,
+.BR \-u ,
+.BR \-v ,
+.BR \-V
and
.B \-w
for
diff --git a/Build/source/texk/ttf2pk/ttf2tfm.c b/Build/source/texk/ttf2pk/ttf2tfm.c
index d4c10f4f3d1..7f566af32f4 100644
--- a/Build/source/texk/ttf2pk/ttf2tfm.c
+++ b/Build/source/texk/ttf2pk/ttf2tfm.c
@@ -43,7 +43,7 @@
char ident[] = "ttf2tfm version 1.5";
-char progname[] = "ttf2tfm"; /* for error/warning messages */
+const char *progname = "ttf2tfm"; /* for error/warning messages */
/* command line options */
diff --git a/Build/source/texk/ttf2pk/ttfaux.c b/Build/source/texk/ttf2pk/ttfaux.c
index 2761b66f9e8..89327ac5047 100644
--- a/Build/source/texk/ttf2pk/ttfaux.c
+++ b/Build/source/texk/ttf2pk/ttfaux.c
@@ -44,8 +44,6 @@
#define FEATURE_vert MAKE_TT_TAG('v', 'e', 'r', 't')
-extern char progname[];
-
char *real_ttfname;
TT_Engine engine;
diff --git a/Build/source/texk/ttf2pk/ttfenc.c b/Build/source/texk/ttf2pk/ttfenc.c
index 50998e6f396..8439f3c146e 100644
--- a/Build/source/texk/ttf2pk/ttfenc.c
+++ b/Build/source/texk/ttf2pk/ttfenc.c
@@ -1053,7 +1053,7 @@ code_to_adobename(long code)
if (current_encoding_scheme == encFontSpecific)
{
- p = (char *)mymalloc(9);
+ p = (char *)mymalloc(11);
sprintf(p, ".%c0x%lx", (code >= 0x1000000) ? 'g' : 'c',
(code & 0xFFFFFF));
return p;
@@ -1070,7 +1070,7 @@ code_to_adobename(long code)
return current_table[n].adobename;
}
- p = (char *)mymalloc(9);
+ p = (char *)mymalloc(11);
sprintf(p, ".%c0x%lx", (code >= 0x1000000) ? 'g' : 'c',
(code & 0xFFFFFF));
return p;