|
28 | 28 | # Optional build dependency install request with syntax `./build.sh --install-dependencies` |
29 | 29 | if [ "$1" = "--install-dependencies" ] |
30 | 30 | then |
31 | | - # fontmake |
32 | | - pip install --upgrade fontmake |
33 | | - # fontTools (installed with fontmake at this time. leave this as dependency check as python scripts for fixes require it should fontTools eliminate dep) |
34 | | - pip install --upgrade fonttools |
35 | 31 | # ttfautohint v1.6 (must be pinned to v1.6 and above for Hack instruction sets) |
36 | 32 | tools/scripts/install/ttfautohint-build.sh |
37 | 33 |
|
|
40 | 36 | # confirm executable installs and library imports for build dependencies |
41 | 37 | INSTALLFLAG=0 |
42 | 38 |
|
43 | | -echo "Confirming that build dependencies are installed..." |
44 | | -echo " " |
45 | | -# fontmake installed |
46 | | -if ! which fontmake |
47 | | - then |
48 | | - echo "Unable to install fontmake with 'pip install fontmake'. Please attempt a manual install of this build dependency and then repeat your build attempt." 1>&2 |
49 | | - INSTALLFLAG=1 |
50 | | -fi |
51 | | -# fontTools python library can be imported |
52 | | -if ! python -c "import fontTools" |
53 | | - then |
54 | | - echo "Unable to install fontTools with 'pip install fonttools'. Please attempt a manual install of this build dependency and then repeat your build attempt." 1>&2 |
55 | | - INSTALLFLAG=1 |
56 | | -else |
57 | | - echo "fontTools Python library identified" |
58 | | -fi |
| 39 | + |
59 | 40 | # ttfautohint installed |
60 | 41 | # - tests for install to local path from ttfautohint-build.sh script |
61 | 42 | # - if not found on this path, tests for install on system PATH - if found, revises TTFAH to the string "ttfautohint" for execution of instruction sets |
|
106 | 87 |
|
107 | 88 | # build regular set |
108 | 89 |
|
109 | | -if ! fontmake -u "source/Hack-Regular.ufo" -o ttf |
| 90 | +if ! pipenv run fontmake -u "source/Hack-Regular.ufo" -o ttf |
110 | 91 | then |
111 | 92 | echo "Unable to build the Hack-Regular variant set. Build canceled." 1>&2 |
112 | 93 | exit 1 |
113 | 94 | fi |
114 | 95 |
|
115 | 96 | # build bold set |
116 | | -if ! fontmake -u "source/Hack-Bold.ufo" -o ttf |
| 97 | +if ! pipenv run fontmake -u "source/Hack-Bold.ufo" -o ttf |
117 | 98 | then |
118 | 99 | echo "Unable to build the Hack-Bold variant set. Build canceled." 1>&2 |
119 | 100 | exit 1 |
120 | 101 | fi |
121 | 102 |
|
122 | 103 | # build italic set |
123 | | -if ! fontmake -u "source/Hack-Italic.ufo" -o ttf |
| 104 | +if ! pipenv run fontmake -u "source/Hack-Italic.ufo" -o ttf |
124 | 105 | then |
125 | 106 | echo "Unable to build the Hack-Italic variant set. Build canceled." 1>&2 |
126 | 107 | exit 1 |
127 | 108 | fi |
128 | 109 |
|
129 | 110 | # build bold italic set |
130 | 111 |
|
131 | | -if ! fontmake -u "source/Hack-BoldItalic.ufo" -o ttf |
| 112 | +if ! pipenv run fontmake -u "source/Hack-BoldItalic.ufo" -o ttf |
132 | 113 | then |
133 | 114 | echo "Unable to build the Hack-BoldItalic variant set. Build canceled." 1>&2 |
134 | 115 | exit 1 |
|
140 | 121 | echo " " |
141 | 122 | echo "Attempting DSIG table fixes with fontbakery..." |
142 | 123 | echo " " |
143 | | -if ! python postbuild_processing/fixes/fix-dsig.py master_ttf/*.ttf |
| 124 | +if ! pipenv run python postbuild_processing/fixes/fix-dsig.py master_ttf/*.ttf |
144 | 125 | then |
145 | 126 | echo "Unable to complete DSIG table fixes on the release files" |
146 | 127 | exit 1 |
|
150 | 131 | echo " " |
151 | 132 | echo "Attempting fstype fixes with fontbakery..." |
152 | 133 | echo " " |
153 | | -if ! python postbuild_processing/fixes/fix-fstype.py master_ttf/*.ttf |
| 134 | +if ! pipenv run python postbuild_processing/fixes/fix-fstype.py master_ttf/*.ttf |
154 | 135 | then |
155 | 136 | echo "Unable to complete fstype fixes on the release files" |
156 | 137 | exit 1 |
|
0 commit comments