1 # Do "make install" to copy the pages to their destination.
5 MANDIR
=$(prefix)/share
/man
11 rm -f
$(MANDIR
)/"$$i" $(MANDIR
)/"$$i".
*; \
15 # make HTDIR=/some/dir HTOPTS=whatever html
16 # The sed removes the lines "Content-type: text/html\n\n"
18 @if
[ x
$(HTDIR
) = x
]; then echo
"You must set HTDIR."; else \
20 [ -d
$(HTDIR
)/"$$i" ] || mkdir
-p
$(HTDIR
)/"$$i"; \
21 find
"$$i/" -type f | while read f
; do \
22 (cd
"$$i"; man2html
$(HTOPTS
) `basename $$f`) | \
23 sed
-e
'1,2d' > $(HTDIR
)/"$$i"/`basename $$f`.html
; \
29 install -d
-m
755 $(DESTDIR
)$(MANDIR
)/"$$i" || exit
$$?
; \
30 install -m
644 "$$i"/* $(DESTDIR
)$(MANDIR
)/"$$i" || exit
$$?
; \
33 # Check if groff reports warnings (may be words of sentences not displayed)
34 # from http://lintian.debian.org/tags/manpage-has-errors-from-man.html
36 GROFF_LOG
="$$(mktemp --tmpdir manpages-checksXXXX)" || exit
$$?
; \
37 for i in man?
/*.
[1-9]; \
39 if grep
-q
'SH.*NAME' "$$i"; then \
40 LC_ALL
=en_US.UTF-8 MANWIDTH
=80 man
--warnings
-E UTF-8
-l
"$$i" > /dev
/null
2>|
"$$GROFF_LOG"; \
41 [ -s
"$$GROFF_LOG" ] && { echo
"$$i: "; cat
"$$GROFF_LOG"; echo
; }; \
46 # someone might also want to look at /var/catman/cat2 or so ...
47 # a problem is that the location of cat pages varies a lot