Skip to content

Commit 29c339a

Browse files
committed
doc: Adapt GLib documentation path to GLib 2.79.0
GLib 2.79.0 switched from gtk-doc to gi-docgen, whose format and installation location are both not compatible. The libmodulemd build script reported an error because of the new location. This patch fixes the build failure by using the new location if GLib is 2.79.0 or greater. Although the libmodulemd documentation references to GLib remain unresolved now (i.e. names of the functions and the types are not hyperlinks), we keep using the new location because the new GLib *.devhelp2 indices remain there and they can only improve over the time. If this expection does not fulfill, libmodulemd will either migrate to gi-docgen, or drop the hard build-time dependency on GLib documentation. Reimplements: #611
1 parent 9d28090 commit 29c339a

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

meson.build

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,13 @@ with_docs = get_option('with_docs')
7070
gtk_doc_referred_paths = []
7171
if with_docs
7272
gtkdoc = dependency('gtk-doc')
73-
glib_docpath = join_paths(glib_prefix, 'share', 'gtk-doc', 'html')
73+
74+
if glib.version().version_compare('<2.79.0')
75+
glib_docpath = join_paths(glib_prefix, 'share', 'gtk-doc', 'html')
76+
else
77+
glib_docpath = join_paths(glib_prefix, 'share', 'doc', 'glib-2.0')
78+
warning('glib >= 2.79.0 documention might not be properly referred from libmodulemd documentation.')
79+
endif
7480

7581
foreach referred_module : [ 'glib', 'gobject' ]
7682
doc_module_path = join_paths(glib_docpath, referred_module)

0 commit comments

Comments
 (0)