From: Otto Moerbeek Date: Thu, 11 Sep 2025 14:07:10 +0000 (+0200) Subject: This does not try to generate the man pages if they are found in the tarball X-Git-Tag: auth-5.0.1~9^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f25d850b69cf86f375cf1a6b2f5d84871ec15df7;p=thirdparty%2Fpdns.git This does not try to generate the man pages if they are found in the tarball Same method as dnsdist and rec Signed-off-by: Otto Moerbeek (cherry picked from commit aa22142831bdbe665dced6202d890c6e6aeb72ee) --- diff --git a/meson.build b/meson.build index 4b6aa8b850..6ef229d64f 100644 --- a/meson.build +++ b/meson.build @@ -1019,11 +1019,20 @@ if python.found() foreach tool, info: tools if 'manpages' in info foreach man_page: info['manpages'] - generated_man_pages += man_page + if not fs.is_file('docs' / man_page) + generated_man_pages += man_page + else + install_man( + 'docs' / man_page, + install_dir: join_paths(get_option('mandir'), 'man1'), + ) + endif endforeach endif endforeach - custom_target( + if generated_man_pages.length() != 0 + summary('Generating man pages', true, section: 'Manual Pages') + custom_target( 'man-pages', input: man_pages, output: generated_man_pages, @@ -1039,7 +1048,10 @@ if python.found() '--source-directory', docs_dir, '--target-directory', '@BUILD_ROOT@', ] + man_pages, - ) + ) + else + summary('Generating man pages', false, section: 'Manual Pages') + endif endif if get_option('unit-tests')