$OpenBSD: patch-Makefile_in,v 1.5 2010/04/05 11:36:55 naddy Exp $

Our groff is too old.  We need to pre-format the man pages with mandoc.

--- Makefile.in.orig	Mon Mar 15 03:46:54 2010
+++ Makefile.in	Mon Apr  5 01:13:55 2010
@@ -6978,3 +6978,19 @@ cpio/test/list.h: Makefile
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+.for s in 1 3 5
+.SUFFIXES: .0 .$s
+.$s.0:
+	mandoc $< >$@
+
+install-man: install-cat$s
+install-cat$s:
+	@for file in ${man_MANS:M*.$s:R:=.0}; do \
+	    $(MKDIR_P) "$(DESTDIR)$(mandir)/cat$s" ; \
+	    echo "$(INSTALL_DATA) '$$file' '$(DESTDIR)$(mandir)/cat$s/'"; \
+	    $(INSTALL_DATA) "$$file" "$(DESTDIR)$(mandir)/cat$s/"; \
+	done
+.endfor
+
+all-am: ${man_MANS:R:=.0}
