Gumbo via build.zig#
Gumbo is Google's dependency-free C99-only HTML5 parser implementation. As far as I'm aware, there are no other HTML5 parsers with comparably easy embedding and integration. Cool, right?
Well... despite being complete, it's also deprecated for reasons I do not understand, so I've cleaned and copied the source into this library. It also uses a gnu autotools based build without actually using autotools features (??? why), which just makes it harder to use as a dependency. Instead, use build.zig!
Using this#
To use the library directly: the build.zig here exports a gumbo library artifact as well as a gumbo-c module, which contains all of the C source files. You should also use the gumbo.h header, located in gumbo (b.path("gumbo")),
If you want to use this from C, you can build this library and then install the lib/ and include/ build artifacts however you'd like (e.g. copying to ~/.local/ or /usr/local/).
For Zig programmers: I've hacked together a Zig wrapper (gumbo module), but I've written this ad hoc for personal use. There are likely bugs and holes in functionality currently, and I don't currently plan to document it. So, user beware!