GdkPixbuf 2.42.0 introduced new build-time options to increase consistency with the rest of the GNOME core platform:
the docs option has been deprecated; it’s now recommended to use the gtk_doc option to build the API reference for GdkPixbuf, and the man option to build the manual pages for the various tools
the gir option has been renamed to introspection, and it uses a “feature” type instead of a boolean one
In both cases, the change was made to match what other GNOME libraries already do.
Out of curiosity: would it be possible to have all options consistent by using the dash to separate words? So it should read gtk-doc instead of gtk_doc. Right now, for example, all other options in meson_options.txt · main · GNOME / gtk · GitLab use the dash.
In particular, from the guidelines that Emmanuele just linked to:
Use a consistent separator character for multi-word options, preferably the underscore _, like cert_file or cups_print_backend
So to comply with these guidelines, GTK should rename all its build options to use underscores, instead. It’s going to be a lot easier to do that before GTK 4 is released, rather than later…
The counter here is that it is not “gtk doc” for underscore to be used for multi-word options. It actually is quite literally gtk-doc, hence a hyphen is appropriate, as it’s not a multi-word that’s being put together here.
It’s not gtk docs, it’s gtk-doc format documentation.
However I’ve stopped worrying about this and accept I get to sometimes (more often) write $(meson_use gtk-doc gtk_doc) instead of $(meson_use gtk-doc) in my downstream packages.