#~!Makefile for makeall
# Name:  Makefile Part No.: _______-____r
#
# Copyright 1994 - J B Systems, Morrison, CO
#
# The recipient of this product specifically agrees not to distribute,
# disclose, or disseminate in any way, to any one, nor use for its own
# benefit, or the benefit of others, any information contained  herein
# without the expressed written consent of J B Systems.
#
#                     RESTRICTED RIGHTS LEGEND
#
# Use, duplication, or disclosure by the Government is  subject  to
# restriction  as  set forth in paragraph (b) (3) (B) of the Rights
# in Technical Data and Computer Software  Clause  in  DAR  7-104.9
# (a).
#

#ident	"@(#)Make:makeall/Makefile	1.0"

# Make parameters when running on MPX

ROOT = /system/system
TARGET = /system/system
VOL = /system
SOURCE = .
PREFIX = nb
INCLUDE = /system/$(PREFIX)include
SINCLUDE = $(INCLUDE)
SBIN = /system/system
BIN = /system/bin
UBIN = /system/bin
LIB = /system/bin
YBIN = /system/bin
CPP = $(LIB)/$(PREFIX)cpp
CPFLAGS = -M
CC = $(UBIN)/$(PREFIX)cc
CFLAGS = -DMPX #-N 
LD = $(UBIN)/$(PREFIX)nbcat
LDFLAGS = -YXXXXmap
YACC = $(YBIN)/$(PREFIX)yacc
YFLAGS =
MAKEFILE = makeall

# Fill in with correct information

DIRS1 = $(VOL)/nbcpp_cmd $(VOL)/nbyacc_cmd $(VOL)/nblex_cmd $(VOL)/nbcc_cmd \
	$(VOL)/ar_cmd $(VOL)/basename_cmd $(VOL)/chgrp_cmd $(VOL)/chmod_cmd \
	$(VOL)/chown_cmd $(VOL)/chtyp_cmd $(VOL)/cmprs_cmd $(VOL)/cp_cmd \
	$(VOL)/date_cmd $(VOL)/dodep_cmd $(VOL)/echo_cmd $(VOL)/expr_cmd

DIRS2 =	$(VOL)/false_cmd $(VOL)/grep_cmd $(VOL)/ln_cmd $(VOL)/ls_cmd \
	$(VOL)/make_cmd $(VOL)/mkdep_cmd $(VOL)/mkdir_cmd $(VOL)/mkfile_cmd \
	$(VOL)/mv_cmd $(VOL)/mvdir_cmd $(VOL)/pwd_cmd $(VOL)/rm_cmd \
	$(VOL)/rmdir_cmd $(VOL)/sed_cmd $(VOL)/sh_cmd $(VOL)/sum_cmd \
	$(VOL)/touch_cmd $(VOL)/true_cmd $(VOL)/uniq_cmd

ALL:	all

all:	
	@for i in $(DIRS1); do \
	$(BIN)/echo "Doing make in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile; \
	done;
	@for i in $(DIRS2); do \
	$(BIN)/echo "Doing make in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile; \
	done;
	$(BIN)/echo makeall is up to date.

CLEAN:  clean

clean:
	@for i in $(DIRS1); do \
	$(BIN)/echo "Doing make clean in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile clean; \
	done;
	@for i in $(DIRS2); do \
	$(BIN)/echo "Doing make clean in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile clean; \
	done;

CLOBBER: clobber

clobber: clean
	@for i in $(DIRS1); do \
	$(BIN)/echo "Doing make clobber in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile clobber; \
	done;
	@for i in $(DIRS2); do \
	$(BIN)/echo "Doing make clobber in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile clobber; \
	done;

INSTALL: install

install:
	@for i in $(DIRS1); do \
	$(BIN)/echo "Doing make install in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile install; \
	done;
	@for i in $(DIRS2); do \
	$(BIN)/echo "Doing make install in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile install; \
	done;

DEPEND: depend

depend:
	@for i in $(DIRS1); do \
	$(BIN)/echo "Doing make depend in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile depend; \
	done;
	@for i in $(DIRS2); do \
	$(BIN)/echo "Doing make depend in directory '$$i'"; \
	cd $$i; \
	$(BIN)/make -f makefile depend; \
	done;

# DO NOT DELETE THIS LINE -- the dependencies begin here
