[asterisk-commits] dlee: branch dlee/stasis-http r385788 - in /team/dlee/stasis-http: ./ Makefile
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Apr 15 13:05:16 CDT 2013
Author: dlee
Date: Mon Apr 15 13:05:13 2013
New Revision: 385788
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=385788
Log:
Don't unnecessarily rebuild things on every run of 'make'.
Review: https://reviewboard.asterisk.org/r/2449/
........
Merged revisions 385745 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 385768 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 385782 from http://svn.asterisk.org/svn/asterisk/trunk
Modified:
team/dlee/stasis-http/ (props changed)
team/dlee/stasis-http/Makefile
Propchange: team/dlee/stasis-http/
------------------------------------------------------------------------------
Binary property 'branch-11-merged' - no diff available.
Propchange: team/dlee/stasis-http/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Mon Apr 15 13:05:13 2013
@@ -1,1 +1,1 @@
-/trunk:1-385746
+/trunk:1-385787
Modified: team/dlee/stasis-http/Makefile
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/Makefile?view=diff&rev=385788&r1=385787&r2=385788
==============================================================================
--- team/dlee/stasis-http/Makefile (original)
+++ team/dlee/stasis-http/Makefile Mon Apr 15 13:05:13 2013
@@ -356,7 +356,7 @@
+@$(SUBMAKE) $(MOD_SUBDIRS_EMBED_LDFLAGS)
+@$(SUBMAKE) $(MOD_SUBDIRS_EMBED_LIBS)
-$(SUBDIRS): makeopts cleantest main/version.c include/asterisk/build.h include/asterisk/buildopts.h defaults.h makeopts.embed_rules
+$(SUBDIRS): makeopts .lastclean main/version.c include/asterisk/build.h include/asterisk/buildopts.h defaults.h makeopts.embed_rules
ifeq ($(findstring $(OSARCH), mingw32 cygwin ),)
# Non-windows:
@@ -382,26 +382,25 @@
$(OTHER_SUBDIRS): makeopts
+ at _ASTCFLAGS="$(OTHER_SUBDIR_CFLAGS) $(_ASTCFLAGS)" ASTCFLAGS="$(ASTCFLAGS)" _ASTLDFLAGS="$(_ASTLDFLAGS)" ASTLDFLAGS="$(ASTLDFLAGS)" $(SUBMAKE) --no-builtin-rules -C $@ SUBDIR=$@ all
-defaults.h: makeopts cleantest build_tools/make_defaults_h
+defaults.h: makeopts .lastclean build_tools/make_defaults_h
@build_tools/make_defaults_h > $@.tmp
@cmp -s $@.tmp $@ || mv $@.tmp $@
@rm -f $@.tmp
-main/version.c: FORCE cleantest
+main/version.c: FORCE .lastclean
@build_tools/make_version_c > $@.tmp
@cmp -s $@.tmp $@ || mv $@.tmp $@
@rm -f $@.tmp
-include/asterisk/buildopts.h: menuselect.makeopts cleantest
+include/asterisk/buildopts.h: menuselect.makeopts .lastclean
@build_tools/make_buildopts_h > $@.tmp
@cmp -s $@.tmp $@ || mv $@.tmp $@
@rm -f $@.tmp
-# build.h must depend on cleantest, or parallel make may wipe it out after it's
-# been created. But since build.h contains a timestamp, the cmp trick used above
-# won't work. Just testing for existence is good enough.
-include/asterisk/build.h: cleantest
- @test -f $@ || build_tools/make_build_h > $@
+# build.h must depend on .lastclean, or parallel make may wipe it out after it's
+# been created.
+include/asterisk/build.h: .lastclean
+ @build_tools/make_build_h > $@
$(SUBDIRS_CLEAN):
+@$(SUBMAKE) -C $(@:-clean=) clean
@@ -462,7 +461,7 @@
XML_core_en_US = $(foreach dir,$(MOD_SUBDIRS),$(shell $(GREP) -l "language=\"en_US\"" $(dir)/*.c $(dir)/*.cc 2>/dev/null))
endif
-doc/core-en_US.xml: makeopts cleantest $(XML_core_en_US)
+doc/core-en_US.xml: makeopts .lastclean $(XML_core_en_US)
@printf "Building Documentation For: "
@echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" > $@
@echo "<!DOCTYPE docs SYSTEM \"appdocsxml.dtd\">" >> $@
@@ -480,7 +479,7 @@
XMX_full_en_US = $(foreach dir,$(MOD_SUBDIRS),$(shell $(GREP) -l "language=\"en_US\"" $(dir)/*.c $(dir)/*.cc 2>/dev/null))
endif
-doc/full-en_US.xml: makeopts cleantest $(XML_full_en_US)
+doc/full-en_US.xml: makeopts .lastclean $(XML_full_en_US)
ifeq ($(PYTHON),:)
@echo "--------------------------------------------------------------------------"
@echo "--- Please install python to build full documentation ---"
@@ -851,8 +850,8 @@
# .cleancount is the global clean count, and .lastclean is the
# last clean count we had
-cleantest:
- @cmp -s .cleancount .lastclean || $(MAKE) clean
+.lastclean: .cleancount
+ @$(MAKE) clean
@[ -f "$(DESTDIR)$(ASTDBDIR)/astdb.sqlite3" ] || [ ! -f "$(DESTDIR)$(ASTDBDIR)/astdb" ] || [ ! -f menuselect.makeopts ] || grep -q MENUSELECT_UTILS=.*astdb2sqlite3 menuselect.makeopts || (sed -i.orig -e's/MENUSELECT_UTILS=\(.*\)/MENUSELECT_UTILS=\1 astdb2sqlite3/' menuselect.makeopts && echo "Updating menuselect.makeopts to include astdb2sqlite3" && echo "Original version backed up to menuselect.makeopts.orig")
$(SUBDIRS_UNINSTALL):
@@ -930,19 +929,19 @@
CFLAGS="$(BUILD_CFLAGS)" LDFLAGS="$(BUILD_LDFLAGS)" \
$(MAKE) -C menuselect CONFIGURE_SILENT="--silent"
-menuselect/menuselect: menuselect/makeopts cleantest
+menuselect/menuselect: menuselect/makeopts .lastclean
+$(MAKE_MENUSELECT) menuselect
-menuselect/cmenuselect: menuselect/makeopts cleantest
+menuselect/cmenuselect: menuselect/makeopts .lastclean
+$(MAKE_MENUSELECT) cmenuselect
-menuselect/gmenuselect: menuselect/makeopts cleantest
+menuselect/gmenuselect: menuselect/makeopts .lastclean
+$(MAKE_MENUSELECT) gmenuselect
-menuselect/nmenuselect: menuselect/makeopts cleantest
+menuselect/nmenuselect: menuselect/makeopts .lastclean
+$(MAKE_MENUSELECT) nmenuselect
-menuselect/makeopts: makeopts cleantest
+menuselect/makeopts: makeopts .lastclean
+$(MAKE_MENUSELECT) makeopts
menuselect-tree: $(foreach dir,$(filter-out main,$(MOD_SUBDIRS)),$(wildcard $(dir)/*.c) $(wildcard $(dir)/*.cc)) build_tools/cflags.xml build_tools/cflags-devmode.xml sounds/sounds.xml build_tools/embed_modules.xml utils/utils.xml agi/agi.xml configure makeopts
@@ -986,7 +985,6 @@
.PHONY: full
.PHONY: _full
.PHONY: prereqs
-.PHONY: cleantest
.PHONY: uninstall
.PHONY: _uninstall
.PHONY: uninstall-all
More information about the asterisk-commits
mailing list