Also switch to building with cmake, and add a patch to build the brotli binary against shared libs (binary size from 700 kb to 70 kb).