#
#ident	"@(#)smail/man:RELEASE-3_2_0_118:Makefile,v 1.17 2003/12/10 05:05:36 woods Exp"
#
# Makefile for the smail man directories
#
#    Copyright (C) 1987, 1988 Ronald S. Karr and Landon Curt Noll
#    Copyright (C) 1992  Ronald S. Karr
# 
# See the file COPYING, distributed with smail, for restriction
# and warranty information.

SHELL=/bin/sh

ROOT=../..
MANS=man1 man5 man8

all depend mkdefs install installman install.man clean clobber: .MAKE
	@for i in ${MANS}; do				\
		echo "Making $@ under $$i ...";		\
		(cd $$i && { if [ -f .depend ] ; then	\
			DEPMKFILE="-f Makefile -f .depend"; \
		fi; ${MAKE} $$DEPMKFILE $@; } );	\
		rc=$$?;					\
		if [ $$rc -ne 0 ] ; then		\
			exit $$rc;			\
		fi;					\
	 done

# for testing....
#
#	man -M . -k smail
#
whatis.db makewhatis: all .FORCE
	/usr/libexec/makewhatis .

clobber: clean

clean: local-clean

local-clean:
	rm -f whatis.db

.MAKE:

.FORCE:

.PHONY: all install local-install clean local-clean clobber local-clobber depend local-depend lint mkdefs check_defs tags TAGS
.PHONY: .MAKE installman install.man
