docs: Migrate from gtk-doc to gi-docgen

gtk-doc has been slowly dying for the past few years; with gi-docgen we
have a nice successor.

This also makes sure the C documentation also uses the GIR file, which
in turn means faster build times (since all the C code doesn't have to
be parsed and recompiled again), and has a clear dependency graph.

See the [gi-docgen tutorial] for more info on how the system works.

[gi-docgen tutorial]: https://gnome.pages.gitlab.gnome.org/gi-docgen/tutorial.html
This commit is contained in:
Niels De Graef
2021-11-28 19:36:07 +01:00
parent 3fe01513e7
commit 92e80d12e8
134 changed files with 546 additions and 25972 deletions

View File

@ -0,0 +1,26 @@
## Process this file with automake to produce Makefile.in
GIMP_DOC_LOGO = $(abs_top_srcdir)/data/images/gimp-logo.ong
gimp-ui-3.0.toml: gimp-ui-3.0.toml.in
$(AM_V_GEN) sed \
-e 's/@GIMP_VERSION[@]/$(GIMP_VERSION)/' \
-e 's/@GIMP_LOGO[@]/$(GIMP_DOC_LOGO)/' \
$< $@
# Markdown content files
content_files = \
widget-gallery.md \
$(NULL)
GimpUi-reference: $(top_builddir)/libgimp/GimpUi-@GIMP_API_VERSION@.gir $(top_builddir)/libgimp/Gimp-@GIMP_API_VERSION@.gir $(content_files) gimp-ui-3.0.toml
$(GI_DOCGEN) \
generate \
--quiet \
--fatal-warnings \
--config=gimp-ui-3.0.toml \
--output-dir=$(abs_builddir)/Gimp-3.0 \
--no-namespace-dir \
--content-dir=$(abs_srcdir) \
--add-include-path=$(top_abs_builddir)/gimp \
$<