Skip to content

Commit ce56ca4

Browse files
committed
meson: fix doc install error
Setup doxygem build in the doc directory. Fixes the following error: RuntimeError: File 'html' could not be found
1 parent e5b7e76 commit ce56ca4

File tree

2 files changed

+18
-17
lines changed

2 files changed

+18
-17
lines changed

doc/meson.build

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
doxygen_data = configuration_data()
2+
doxygen_data.set('PACKAGE_NAME', 'libdsm')
3+
doxygen_data.set('BDSM_PACKAGE_VERSION', meson.project_version())
4+
doxygen_data.set('abs_top_srcdir', meson.source_root())
5+
6+
doxyfile = configure_file(
7+
input: 'Doxyfile.in',
8+
output: 'Doxyfile',
9+
configuration: doxygen_data,
10+
install: false)
11+
doc_dir = join_paths(get_option('datadir'), 'doc', 'libdsm')
12+
custom_target('doc',
13+
command: [doxygen, doxyfile],
14+
input: doxyfile,
15+
output: 'html',
16+
install: true,
17+
install_dir: doc_dir)

meson.build

+1-17
Original file line numberDiff line numberDiff line change
@@ -260,23 +260,7 @@ pkg_mod.generate(
260260
# We only add the doc target if doxygen is found
261261
doxygen = find_program('doxygen', required: false)
262262
if doxygen.found()
263-
doxygen_data = configuration_data()
264-
doxygen_data.set('PACKAGE_NAME', 'libdsm')
265-
doxygen_data.set('BDSM_PACKAGE_VERSION', meson.project_version())
266-
doxygen_data.set('abs_top_srcdir', meson.source_root())
267-
268-
doxyfile = configure_file(
269-
input: 'doc/Doxyfile.in',
270-
output: 'Doxyfile',
271-
configuration: doxygen_data,
272-
install: false)
273-
doc_dir = join_paths(get_option('datadir'), 'doc', 'libdsm')
274-
custom_target('doc',
275-
command: [doxygen, doxyfile],
276-
input: doxyfile,
277-
output: 'html',
278-
install: true,
279-
install_dir: doc_dir)
263+
subdir('doc')
280264
else
281265
warning('Doxygen not found - continuing without Doxygen support')
282266
endif

0 commit comments

Comments
 (0)