aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-06-22 12:14:29 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-06-22 12:14:29 +0000
commitb4f3b629b6245fb16f8987ad03ddd09b60ee3ef5 (patch)
tree7bd8159a3cc56e31beacc03d8df392be21dec1cc /Makefile
parent3d668d2424348470284bc0104df87bdb3a08164f (diff)
instead of using a for loop to call make on each subdirectory, use a target for
each subdirectory. - the shell code in the for loop doesn't have a manually catch errors from make on a subdirectory - you can now run something like "make apps" or "make channels" from the root source directory - This should allow for better support for parallel instances of make (the -j option) since make can work on each subdirectory target in parallel git-svn-id: http://svn.digium.com/svn/asterisk/trunk@35436 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile11
1 files changed, 6 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index ef4030231..0f6abca58 100644
--- a/Makefile
+++ b/Makefile
@@ -368,7 +368,7 @@ _all: all
@echo " + make install +"
@echo " +-------------------------------------------+"
-all: cleantest config.status menuselect.makeopts depend asterisk subdirs
+all: cleantest config.status menuselect.makeopts depend asterisk $(SUBDIRS)
config.status: configure
@CFLAGS="" ./configure
@@ -480,10 +480,11 @@ asterisk: include/asterisk/buildopts.h editline/libedit.a db1-ast/libdb1.a $(OBJ
muted: muted.o
$(CC) $(AUDIO_LIBS) -o muted muted.o
-subdirs:
- @for x in $(MOD_SUBDIRS); do CFLAGS="$(MOD_SUBDIR_CFLAGS)$(ASTCFLAGS)" $(MAKE) -C $$x || exit 1 ; done
- @CFLAGS="$(OTHER_SUBDIR_CFLAGS)$(ASTCFLAGS)" $(MAKE) -C utils
- @CFLAGS="$(OTHER_SUBDIR_CFLAGS)$(ASTCFLAGS)" $(MAKE) -C agi
+$(MOD_SUBDIRS): FORCE
+ @CFLAGS="$(MOD_SUBDIR_CFLAGS)$(ASTCFLAGS)" $(MAKE) -C $@
+
+$(OTHER_SUBDIRS): FORCE
+ @CFLAGS="$(OTHER_SUBDIR_CFLAGS)$(ASTCFLAGS)" $(MAKE) -C $@
clean-depend:
@for x in $(SUBDIRS); do $(MAKE) -C $$x clean-depend || exit 1 ; done