January 4, 2018

Harfbuzz Adventures

Lately, I've been thinking about text layout in Rust. We'll get back to that at some point. This led to me to looking at the Rust bindings for Harfbuzz. Since then, I've started some submitting some fixes to the Rust bindings, including working towards updating to the current version of Harfbuzz. (This was a couple of weeks ago. Then I went on an extended holiday.)

Then, I decided to look at making some improvements upstream in Harfbuzz. I've now had a few minor patch submissions (#669, #670) accepted there as well and am working on more, including improving the support for the cmake build system.

One annoying thing is that since I use ninja as a build tool (instead of make), I have to modify many projects to include this bit of configuration (#674):

    set (CMAKE_CXX_FLAGS "-fcolor-diagnostics ${CMAKE_CXX_FLAGS}")
    set (CMAKE_C_FLAGS "-fcolor-diagnostics ${CMAKE_C_FLAGS}")
  endif ()
    set (CMAKE_CXX_FLAGS "-fdiagnostics-color ${CMAKE_CXX_FLAGS}")
    set (CMAKE_C_FLAGS "-fdiagnostics-color ${CMAKE_C_FLAGS}")
  endif ()
endif ()

This gets old! I wish this could be fixed upstream somewhere, but I haven't had the time / motivation myself to think about this.

I also noticed when building on macOS that …

read more »