source-foundry / ttfautohint-build

Build ttfautohint from source on Linux and macOS platforms
MIT License
27 stars 12 forks source link

ttfautohint-build

Linux Build CI macOS Build CI

About

ttfautohint-build includes a simple, straightforward ttfautohint build from scratch approach on Linux and macOS platforms. FreeType and Harfbuzz build dependencies (at appropriate release versions) are included in the installation.

The build script is ttfautohint-build.sh (located in the root of the repository). This script is linted with shellcheck & checkbashisms and is tested for build execution completion on Ubuntu Linux and macOS v10.10-v10.15 using the Travis CI service.

Builds employ a simple make workflow that does not require super user permissions.

If you are looking for a simple way to install + use ttfautohint and do not need to build the application from source, check out the free, open ttfautohint-py project.

Pre-Install Build Dependencies

Linux

macOS

Usage

Select one of the following approaches to install the current release of ttfautohint.

git clone Approach

$ git clone https://github.com/source-foundry/ttfautohint-build.git
$ cd ttfautohint-build
$ make

cURL Approach

$ curl -L -O https://github.com/source-foundry/ttfautohint-build/archive/v1.8.3.2.tar.gz
$ tar -xzvf v1.8.3.2.tar.gz
$ cd ttfautohint-build-1.8.3.2
$ make

With both of the above approaches, the ttfautohint executable is installed on the path $HOME/ttfautohint-build/local/bin/ttfautohint.

ttfautohint Execution

You can use the following approaches to execute ttfautohint with your font files:

Shell Scripts

# without shell script constant

"$HOME/ttfautohint-build/local/bin/ttfautohint" [ttfautohint args]
# with shell script constant

TTFAH="$HOME/ttfautohint-build/local/bin/ttfautohint"

"$TTFAH" [ttfautohint args]

Command Line

Modify the PATH definition in your shell settings file (e.g. .bashrc if you are using bash) with the following line after PATH is defined in the file:

export PATH="$HOME/ttfautohint-build/local/bin/:$PATH"

then, source your shell settings file on the command line with:

$ source [shell settings file path]

You can then use ttfautohint on the command line as follows:

$ ttfautohint [ttfautohint args]

Changes

Please see the changelog in the project releases.

License

MIT License