Files
pcas/Makefile.subdirs
1996-06-28 15:33:55 +00:00

56 lines
1.1 KiB
Makefile

#
# base $Id$
#
# EPICS Makefile For Subdirectory Recursions
# by Matthew Needes and Mike Bordua
#
TOP=.
include $(TOP)/config/CONFIG_BASE
all: build
build: dirs
@(for DIR in ${DIRS}; \
do \
TMP=`pwd`; echo "${T_A}: $@: $$DIR"; \
cd $$DIR/O.${T_A}; ${MAKE} $@ ; \
cd $$TMP; \
done)
install: dirs
@(for DIR in ${DIRS}; \
do \
TMP=`pwd`; echo "${T_A}: $@: $$DIR"; \
cd $$DIR/O.${T_A}; ${MAKE} $@ ; \
cd $$TMP; \
done)
depends: dirs
@(for DIR in ${DIRS}; \
do \
TMP=`pwd`; echo "${T_A}: $@: $$DIR"; \
cd $$DIR/O.${T_A}; ${MAKE} $@ ; \
cd $$TMP; \
done)
dirs:
@echo ${T_A}: Creating Directories
@for DIR in ${DIRS}; \
do \
TMP=`pwd`; \
cd $$DIR ; \
if [ -f Makefile.${BUILD_TYPE} ] ; then \
test -d O.${T_A} || \
mkdir O.${T_A}; \
test -f O.${T_A}/Makefile || \
( echo "T_A=${T_A}" > O.${T_A}/Makefile; \
echo "include ../Makefile.${BUILD_TYPE}" \
>> O.${T_A}/Makefile;); \
test -f O.${T_A}/.DEPENDS || \
touch O.${T_A}/.DEPENDS; \
fi ; \
cd $$TMP; \
done