#
#       Makefile for misc1
#
#       Copyright (C) 2000-2022 GFD Dennou Club. All rights reserved.
#

include ../../Mkinclude

SUBDIRS		= bitlib chglib chklib chnlib datelib fmtlib misclib \
		  timelib clsplib $(MISC1EXT)


object:
	@for i in $(SUBDIRS) ; do \
	  cd $$i ; \
	  echo "Making object files in $$i" ; \
	  $(MAKE) object ; \
	  cd .. ; \
	done

library: archive ranlib

archive:
	@for i in $(SUBDIRS) ; do \
	  cd $$i ; \
	  echo "Archiving $$i" ; \
	  $(MAKE) archive ; \
	  cd .. ; \
	done

ranlib:
	$(RANLIB) $(LDCLLIBFILE)

clean: clean.local clean.dir

clean.local:
	$(RM) *~

clean.dir:
	@for i in $(SUBDIRS) ; do \
	  cd $$i ; \
	  echo "Cleaning $$i" ; \
	  $(MAKE) clean ; \
	  cd .. ; \
	done
