diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 11:11:40 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 11:11:40 +0000 |
commit | 7731832751ab9f3c6ddeb66f186d3d7fa1934a6d (patch) | |
tree | e91015872543a59be2aad26c2fea02e41b57005d /build/man.mk | |
parent | Initial commit. (diff) | |
download | openldap-7731832751ab9f3c6ddeb66f186d3d7fa1934a6d.tar.xz openldap-7731832751ab9f3c6ddeb66f186d3d7fa1934a6d.zip |
Adding upstream version 2.4.57+dfsg.upstream/2.4.57+dfsgupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | build/man.mk | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/build/man.mk b/build/man.mk new file mode 100644 index 0000000..c53ecc9 --- /dev/null +++ b/build/man.mk @@ -0,0 +1,59 @@ +# $OpenLDAP$ +## This work is part of OpenLDAP Software <http://www.openldap.org/>. +## +## Copyright 1998-2021 The OpenLDAP Foundation. +## All rights reserved. +## +## Redistribution and use in source and binary forms, with or without +## modification, are permitted only as authorized by the OpenLDAP +## Public License. +## +## A copy of this license is available in the file LICENSE in the +## top-level directory of the distribution or, alternatively, at +## <http://www.OpenLDAP.org/license.html>. +##--------------------------------------------------------------------------- +# +# Makefile Template for Manual Pages +# + +MANDIR=$(mandir)/man$(MANSECT) +TMP_SUFFIX=tmp + +all-common: + PAGES=`cd $(srcdir); echo *.$(MANSECT)`; \ + for page in $$PAGES; do \ + $(SED) -e "s%LDVERSION%$(VERSION)%" \ + -e 's%ETCDIR%$(sysconfdir)%g' \ + -e 's%LOCALSTATEDIR%$(localstatedir)%' \ + -e 's%SYSCONFDIR%$(sysconfdir)%' \ + -e 's%DATADIR%$(datadir)%' \ + -e 's%SBINDIR%$(sbindir)%' \ + -e 's%BINDIR%$(bindir)%' \ + -e 's%LIBDIR%$(libdir)%' \ + -e 's%LIBEXECDIR%$(libexecdir)%' \ + -e 's%MODULEDIR%$(moduledir)%' \ + -e 's%RELEASEDATE%$(RELEASEDATE)%' \ + $(srcdir)/$$page \ + | (cd $(srcdir); $(SOELIM) -) > $$page.$(TMP_SUFFIX); \ + done + +install-common: + -$(MKDIR) $(DESTDIR)$(MANDIR) + PAGES=`cd $(srcdir); echo *.$(MANSECT)`; \ + for page in $$PAGES; do \ + echo "installing $$page in $(DESTDIR)$(MANDIR)"; \ + $(RM) $(DESTDIR)$(MANDIR)/$$page; \ + $(INSTALL) $(INSTALLFLAGS) -m 644 $$page.$(TMP_SUFFIX) $(DESTDIR)$(MANDIR)/$$page; \ + if test -f "$(srcdir)/$$page.links" ; then \ + for link in `$(CAT) $(srcdir)/$$page.links`; do \ + echo "installing $$link in $(DESTDIR)$(MANDIR) as link to $$page"; \ + $(RM) $(DESTDIR)$(MANDIR)/$$link ; \ + $(LN_S) $(DESTDIR)$(MANDIR)/$$page $(DESTDIR)$(MANDIR)/$$link; \ + done; \ + fi; \ + done + +clean-common: FORCE + $(RM) *.tmp all-common + +Makefile: $(top_srcdir)/build/man.mk |