blob: 471df23c8dbadbe60cf25a03b267b8ae4a729c54 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
|
# Copyright 2009 Karl Berry.
# You may freely use, modify and/or distribute this file.
default: fonttable.pdf inconsolata.pdf
# ly1-nfsstest.pdf # check-coverage # compare-ts1-fix
# nice dump of what's in the font, showing glyph names.
fonttable.pdf: fonttable.ps
ps2pdf -dEmbedAllFonts -dPDFX=true $< $@
fonttable.ps: Inconsolata.pfa
t1testpage Inconsolata.pfa -o $@
inconsolata.pdf: inconsolata.tex test.pdf
pdflatex '\nonstopmode\input $<' || { rm -f $@; exit 1; }
# test document. We handcrafted the fd and map files.
test.pdf: test.tex \
inconsolata.sty fi4.map \
ec-inconsolata.tfm t1fi4.fd \
ei1-inconsolata.tfm ei1fi4.fd \
qx-inconsolata.tfm qxfi4.fd \
rm-inconsolata.tfm ot1fi4.fd \
texnansi-inconsolata.tfm ly1fi4.fd \
ts1-inconsolata.tfm ts1fi4.fd \
#
pdflatex '\nonstopmode\input $<' || { rm -f $@; exit 1; }
# make individual tfm's from our handcrafted encoding files using otftotfm.
# This being a typewriter font, there are no kerns or ligatures, so no
# -fkern -fliga.
otftotfm = otftotfm $(otftotfm_opt)
otftotfm_opt = --no-virtual --no-encoding
ec-inconsolata.tfm: Inconsolata.otf Inconsolata.pfb fi4-ec.enc
$(otftotfm) -e fi4-ec.enc $< `basename $@ .tfm`
ei1-inconsolata.tfm: Inconsolata.otf Inconsolata.pfb fi4-ei1.enc
$(otftotfm) -e fi4-ei1.enc $< `basename $@ .tfm`
rm-inconsolata.tfm: Inconsolata.otf Inconsolata.pfb fi4-ot1tt.enc
$(otftotfm) -e fi4-ot1tt.enc $< `basename $@ .tfm`
qx-inconsolata.tfm: Inconsolata.otf Inconsolata.pfb
$(otftotfm) -e fi4-qxtt.enc $< `basename $@ .tfm`
texnansi-inconsolata.tfm: Inconsolata.otf Inconsolata.pfb fi4-texnansi.enc
$(otftotfm) -e fi4-texnansi.enc $< `basename $@ .tfm`
ts1-inconsolata.tfm: Inconsolata.otf Inconsolata.pfb fi4-ts1.enc
$(otftotfm) -e fi4-ts1.enc $< `basename $@ .tfm`
# The original distribution only has pfa; we want to work with pfb.
Inconsolata.pfb: Inconsolata.pfa
t1binary $< >$@
# testing with the nfsstest document.
ly1-nfsstest.pdf:
printf "\nLY1\nfi4\n\n\n\n%s\n" '\bigtest\bye' | pdflatex nfsstest
# create list of glyph names using otfinfo.
# the NameMe glyphs are empty, so leave them out.
names/inconsolata.nam: Inconsolata.otf
otfinfo -g $< | fgrep -v NameMe | sort >$@ || rm -f $@
# create list of glyph names via creation of an afm; but the afm
# has wrong [OU]dblacute entries with gs 8.64. Did not try to debug.
#names/inconsolata.nam: inconsolata.afm
# awk '$$1=="C" {print $$8}' $< | grep -v NameMe | sort >$@ || rm -f $@
#inconsolata.afm: Inconsolata.pfa
# pf2afm $<
# mv Inconsolata.afm $@
# for a given encoding, extract its names.
# have to mkdir names before running this.
names/%.nam: %.enc GNUmakefile
cat $< \
| sed -e 's/ *%.*$$//' -e 's/ *$$//' -e 's/^ *//' \
| tr ' ' '\n' \
| sed -e 's,^/,,' \
| egrep -v '^$$|[][]' | sort -u >$@
.PRECIOUS: names/%.nam
# step 1: compare names in canonical encoding to inconsolata names.
compare-%-orig: names/inconsolata.nam names/%.nam
comm -13 $^
# step 2: compare names in custom encoding to inconsolata names.
compare-%-fix: names/inconsolata.nam names/fi4-%.nam
comm -13 $^
# at the end, see which glyphs in the font we have not used.
# Exclude checking of Dcroat (=Eth) and uni02C9 (=macron).
check-coverage: names/inconsolata.nam names/all-concat.nam
-comm -23 $^ | egrep -v 'Dcroat|uni02C9'
all-concat.enc: $(wildcard fi4-*.enc)
sort -u $^ >$@
# distribution tarball for CTAN.
dist: inconsolata.zip
inconsolata.zip: Inconsolata.otf Inconsolata.pfb Inconsolata.sfd \
GNUmakefile README fonttable.pdf test.pdf test.tex \
inconsolata.sty *-inconsolata.tfm \
fi4.map fi4*.enc *fi4.fd inconsolata.pdf inconsolata.tex
rm -f $@
zip $@ $^
ls -l $@
|