[asterisk-commits] qwell: branch qwell/pjproject-cleanup r380056 - /team/qwell/pjproject-cleanup/
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Thu Jan 24 14:45:59 CST 2013
Author: qwell
Date: Thu Jan 24 14:45:55 2013
New Revision: 380056
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=380056
Log:
Fix build dependencies in the top-most Makefile.
This should fix the underlying issue in ASTERISK-20681.
Modified:
team/qwell/pjproject-cleanup/Makefile
Modified: team/qwell/pjproject-cleanup/Makefile
URL: http://svnview.digium.com/svn/asterisk/team/qwell/pjproject-cleanup/Makefile?view=diff&rev=380056&r1=380055&r2=380056
==============================================================================
--- team/qwell/pjproject-cleanup/Makefile (original)
+++ team/qwell/pjproject-cleanup/Makefile Thu Jan 24 14:45:55 2013
@@ -98,12 +98,7 @@
export LDCONFIG_FLAGS
export PYTHON
-# even though we could use '-include makeopts' here, use a wildcard
-# lookup anyway, so that make won't try to build makeopts if it doesn't
-# exist (other rules will force it to be built if needed)
-ifneq ($(wildcard makeopts),)
- include makeopts
-endif
+-include makeopts
# start the primary CFLAGS and LDFLAGS with any that were provided
# to the configure script
@@ -311,7 +306,7 @@
mK=" make"
endif
-all: _cleantest_all
+all: _all
@echo " +--------- Asterisk Build Complete ---------+"
@echo " + Asterisk has successfully been built, and +"
@echo " + can be installed by running: +"
@@ -319,7 +314,7 @@
@echo " + $(mK) install +"
@echo " +-------------------------------------------+"
-full: _cleantest_all_full
+full: _full
@echo " +--------- Asterisk Build Complete ---------+"
@echo " + Asterisk has successfully been built, and +"
@echo " + can be installed by running: +"
@@ -328,19 +323,9 @@
@echo " +-------------------------------------------+"
-# For parallel builds, we must call cleantest *before* running the
-# other dependencies on _all.
-_cleantest_all: cleantest
- @$(MAKE) _all
-
-# For parallel builds, we must call cleantest *before* running the
-# other dependencies on _all.
-_cleantest_all_full: cleantest
- @$(MAKE) _all_full
-
_all: makeopts $(SUBDIRS) doc/core-en_US.xml $(ADDL_TARGETS)
-_all_full: makeopts $(SUBDIRS) doc/full-en_US.xml $(ADDL_TARGETS)
+_full: makeopts $(SUBDIRS) doc/full-en_US.xml $(ADDL_TARGETS)
makeopts: configure
@echo "****"
@@ -375,7 +360,7 @@
+@$(SUBMAKE) $(MOD_SUBDIRS_EMBED_LDFLAGS)
+@$(SUBMAKE) $(MOD_SUBDIRS_EMBED_LIBS)
-$(SUBDIRS): main/version.c include/asterisk/build.h include/asterisk/buildopts.h defaults.h makeopts.embed_rules
+$(SUBDIRS): makeopts cleantest main/version.c include/asterisk/build.h include/asterisk/buildopts.h defaults.h makeopts.embed_rules
ifeq ($(findstring $(OSARCH), mingw32 cygwin ),)
# Non-windows:
@@ -395,10 +380,10 @@
res: main
endif
-$(MOD_SUBDIRS):
+$(MOD_SUBDIRS): makeopts
+ at _ASTCFLAGS="$(MOD_SUBDIR_CFLAGS) $(_ASTCFLAGS)" ASTCFLAGS="$(ASTCFLAGS)" _ASTLDFLAGS="$(_ASTLDFLAGS)" ASTLDFLAGS="$(ASTLDFLAGS)" $(SUBMAKE) --no-builtin-rules -C $@ SUBDIR=$@ all
-$(OTHER_SUBDIRS):
+$(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 build_tools/make_defaults_h
@@ -421,10 +406,10 @@
@cmp -s $@.tmp $@ || mv $@.tmp $@
@rm -f $@.tmp
-$(SUBDIRS_CLEAN):
+$(SUBDIRS_CLEAN): makeopts
+@$(SUBMAKE) -C $(@:-clean=) clean
-$(SUBDIRS_DIST_CLEAN):
+$(SUBDIRS_DIST_CLEAN): makeopts
+@$(SUBMAKE) -C $(@:-dist-clean=) dist-clean
clean: $(SUBDIRS_CLEAN) _clean
@@ -452,7 +437,7 @@
rm -rf doc/api
rm -f build_tools/menuselect-deps
-datafiles: _cleantest_all doc/core-en_US.xml
+datafiles: _all doc/core-en_US.xml
CFLAGS="$(_ASTCFLAGS) $(ASTCFLAGS)" build_tools/mkpkgconfig "$(DESTDIR)$(libdir)/pkgconfig";
# Should static HTTP be installed during make samples or even with its own target ala
# webvoicemail? There are portions here that *could* be customized but might also be
@@ -473,7 +458,7 @@
done
$(MAKE) -C sounds install
-doc/core-en_US.xml: $(foreach dir,$(MOD_SUBDIRS),$(shell $(GREP) -l "language=\"en_US\"" $(dir)/*.c $(dir)/*.cc 2>/dev/null))
+doc/core-en_US.xml: makeopts $(foreach dir,$(MOD_SUBDIRS),$(shell $(GREP) -l "language=\"en_US\"" $(dir)/*.c $(dir)/*.cc 2>/dev/null))
@printf "Building Documentation For: "
@echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" > $@
@echo "<!DOCTYPE docs SYSTEM \"appdocsxml.dtd\">" >> $@
@@ -487,7 +472,7 @@
@echo
@echo "</docs>" >> $@
-doc/full-en_US.xml: $(foreach dir,$(MOD_SUBDIRS),$(shell $(GREP) -l "language=\"en_US\"" $(dir)/*.c $(dir)/*.cc 2>/dev/null))
+doc/full-en_US.xml: makeopts $(foreach dir,$(MOD_SUBDIRS),$(shell $(GREP) -l "language=\"en_US\"" $(dir)/*.c $(dir)/*.cc 2>/dev/null))
ifeq ($(PYTHON),:)
@echo "--------------------------------------------------------------------------"
@echo "--- Please install python to build full documentation ---"
@@ -561,7 +546,7 @@
main-bininstall:
+ at DESTDIR="$(DESTDIR)" ASTSBINDIR="$(ASTSBINDIR)" ASTLIBDIR="$(ASTLIBDIR)" $(SUBMAKE) -C main bininstall
-bininstall: _cleantest_all installdirs $(SUBDIRS_INSTALL) main-bininstall
+bininstall: _all installdirs $(SUBDIRS_INSTALL) main-bininstall
$(INSTALL) -m 755 contrib/scripts/astgenkey "$(DESTDIR)$(ASTSBINDIR)/"
$(INSTALL) -m 755 contrib/scripts/autosupport "$(DESTDIR)$(ASTSBINDIR)/"
if [ ! -f "$(DESTDIR)$(ASTSBINDIR)/safe_asterisk" -a ! -f /sbin/launchd ]; then \
@@ -916,19 +901,19 @@
CFLAGS="$(BUILD_CFLAGS)" LDFLAGS="$(BUILD_LDFLAGS)" \
$(MAKE) -C menuselect CONFIGURE_SILENT="--silent"
-menuselect/menuselect: menuselect/makeopts
+menuselect/menuselect: menuselect/makeopts cleantest
+$(MAKE_MENUSELECT) menuselect
-menuselect/cmenuselect: menuselect/makeopts
+menuselect/cmenuselect: menuselect/makeopts cleantest
+$(MAKE_MENUSELECT) cmenuselect
-menuselect/gmenuselect: menuselect/makeopts
+menuselect/gmenuselect: menuselect/makeopts cleantest
+$(MAKE_MENUSELECT) gmenuselect
-menuselect/nmenuselect: menuselect/makeopts
+menuselect/nmenuselect: menuselect/makeopts cleantest
+$(MAKE_MENUSELECT) nmenuselect
-menuselect/makeopts: makeopts
+menuselect/makeopts: makeopts cleantest
+$(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
@@ -956,7 +941,8 @@
.PHONY: distclean
.PHONY: all
.PHONY: _all
-.PHONY: _cleantest_all
+.PHONY: full
+.PHONY: _full
.PHONY: prereqs
.PHONY: cleantest
.PHONY: uninstall
More information about the asterisk-commits
mailing list