aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2022-11-02 00:37:57 +0000
committerSam James <sam@gentoo.org>2022-11-02 00:38:55 +0000
commit502631b86d63c4604b0ed78ad86a054e9726e897 (patch)
tree94992bb08fffd67d9a72c50c5e4c1eeb22b5d7ca /meson.build
parentpylint: reformat with black (diff)
downloadpax-utils-502631b86d63c4604b0ed78ad86a054e9726e897.tar.gz
pax-utils-502631b86d63c4604b0ed78ad86a054e9726e897.tar.bz2
pax-utils-502631b86d63c4604b0ed78ad86a054e9726e897.zip
meson: include generated man pages in dist tarballs
Meson doesn't have an idiomatic way of doing this (for once!) so we have to (per Eli Schwartz, thanks!) have: 1. a dist script which duplicates the build rule; 2. some meson.build if/else logic with fs.exists() to prefer the built manpage when using tarballs Sadly, still can't easily regenerate man pages if you apply a patch downstream though. We use Michael Stapelberg's example from the linked bug as inspiration. Bug: https://github.com/mesonbuild/meson/issues/2166 Reported-by: psykose <alice@ayaya.dev> Thanks-to: Eli Schwartz <eschwartz@archlinux.org> Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build2
1 files changed, 2 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 0ee2630..0054ba4 100644
--- a/meson.build
+++ b/meson.build
@@ -138,6 +138,8 @@ install_data('symtree.sh',
subdir('man')
+meson.add_dist_script('meson-build-dist-man.sh')
+
do_tests = get_option('tests')
if do_tests
subdir('tests/lddtree')