summaryrefslogtreecommitdiffstats
path: root/dehydrated/Makefile
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2021-09-07 04:20:23 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2021-09-07 04:20:23 +0000
commit0ef915a3ce5f39005e279d2513f1473ff862add5 (patch)
tree6a328e762efe05666963a482e3c000760afb930f /dehydrated/Makefile
parentAdding upstream version 20210906. (diff)
downloadopen-infrastructure-service-tools-0ef915a3ce5f39005e279d2513f1473ff862add5.tar.xz
open-infrastructure-service-tools-0ef915a3ce5f39005e279d2513f1473ff862add5.zip
Adding upstream version 20210907.upstream/20210907
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'dehydrated/Makefile')
-rw-r--r--dehydrated/Makefile21
1 files changed, 20 insertions, 1 deletions
diff --git a/dehydrated/Makefile b/dehydrated/Makefile
index 5a6239d..534adf8 100644
--- a/dehydrated/Makefile
+++ b/dehydrated/Makefile
@@ -58,7 +58,8 @@ test:
fi
@echo " done."
-build:
+build: share/man/*.rst
+ $(MAKE) -C share/man
install: build
mkdir -p $(DESTDIR)/etc/dehydrated/hook.d
@@ -81,7 +82,25 @@ install: build
ln -sf /usr/bin/dehydrated-nsupdate $(DESTDIR)/usr/share/dehydrated/hooks/clean_challenge.nsupdate
ln -sf /usr/bin/dehydrated-nsupdate $(DESTDIR)/usr/share/dehydrated/hooks/deploy_challenge.nsupdate
+ for SECTION in $$(seq 1 8); \
+ do \
+ if ls share/man/*.$${SECTION} > /dev/null 2>&1; \
+ then \
+ mkdir -p $(DESTDIR)/usr/share/man/man$${SECTION}; \
+ cp share/man/*.$${SECTION} $(DESTDIR)/usr/share/man/man$${SECTION}; \
+ fi; \
+ done
+
uninstall:
+ for SECTION in $$(seq 1 8); \
+ do \
+ for FILE in share/man/*.$${SECTION}; \
+ do \
+ rm -f $(DESTDIR)/usr/share/man/man$${SECTION}/$$(basename $${FILE}); \
+ done; \
+ rmdir --ignore-fail-on-non-empty --parents $(DESTDIR)/usr/share/man/man$${SECTION} || true; \
+ done
+
rm -rf $(DESTDIR)/usr/share/dehydrated/hooks
rmdir --ignore-fail-on-non-empty --parents $(DESTDIR)/usr/share/dehydrated || true