From ed96039297bf33398031b0af76e774d7f7ea6d29 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Fri, 2 May 2008 18:36:01 +0000 Subject: [PATCH] make it so you can build commented out modules using make git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@8251 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- configure.in | 14 +++++++++++++- src/mod/Makefile.am | 2 +- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/configure.in b/configure.in index 57686a8413..ce5385b4a1 100644 --- a/configure.in +++ b/configure.in @@ -445,19 +445,31 @@ AM_CONDITIONAL(IS64BITLINUX, [test `uname -m` = x86_64]) LIBTOOL='`if test -z "$(VERBOSE)" ; then echo $(SHELL) $(switch_builddir)/quiet_libtool ;else echo $(switch_builddir)/libtool; fi;`' TOUCH_TARGET='if test -f "$@";then touch "$@";fi;' CONF_MODULES='\`grep -v "\#" $(switch_builddir)/modules.conf | sed -e "s|^.*/||" | sort | uniq \`' +CONF_DISABLED_MODULES='\`grep "\#" $(switch_builddir)/modules.conf | sed -e "s|^.*/||" | sort | uniq \`' OUR_MODS='`if test -z "$(MODULES)" ; then tmp_mods="$(CONF_MODULES)"; else tmp_mods="$(MODULES)" ; fi ; mods=\`for i in $$tmp_mods ; do echo $$i-all ; done \`; echo $$mods `' OUR_CLEAN_MODS='`if test -z "$(MODULES)" ; then tmp_mods="$(CONF_MODULES)"; else tmp_mods="$(MODULES)" ; fi ; mods=\`for i in $$tmp_mods ; do echo $$i-clean ; done \`; echo $$mods `' OUR_INSTALL_MODS='`if test -z "$(MODULES)" ; then tmp_mods="$(CONF_MODULES)"; else tmp_mods="$(MODULES)" ; fi ; mods=\`for i in $$tmp_mods ; do echo $$i-install ; done\`; echo $$mods `' OUR_UNINSTALL_MODS='`if test -z "$(MODULES)" ; then tmp_mods="$(CONF_MODULES)"; else tmp_mods="$(MODULES)" ; fi ; mods=\`for i in $$tmp_mods ; do echo $$i-uninstall ; done\`; echo $$mods `' -AM_MAKEFLAGS='"OUR_MODULES=$(OUR_MODS)" "OUR_CLEAN_MODULES=$(OUR_CLEAN_MODS)" "OUR_INSTALL_MODULES=$(OUR_INSTALL_MODS)" "OUR_UNINSTALL_MODULES=$(OUR_UNINSTALL_MODS)" `test -n "$(VERBOSE)" || echo -s`' +OUR_DISABLED_MODS='`tmp_mods="$(CONF_DISABLED_MODULES)"; mods=\`for i in $$tmp_mods ; do echo $$i-all ; done \`; echo $$mods `' +OUR_DISABLED_CLEAN_MODS='`tmp_mods="$(CONF_DISABLED_MODULES)"; mods=\`for i in $$tmp_mods ; do echo $$i-clean ; done \`; echo $$mods `' +OUR_DISABLED_INSTALL_MODS='`tmp_mods="$(CONF_DISABLED_MODULES)"; mods=\`for i in $$tmp_mods ; do echo $$i-install ; done\`; echo $$mods `' +OUR_DISABLED_UNINSTALL_MODS='`tmp_mods="$(CONF_DISABLED_MODULES)"; mods=\`for i in $$tmp_mods ; do echo $$i-uninstall ; done\`; echo $$mods `' + +AM_MAKEFLAGS='"OUR_MODULES=$(OUR_MODS)" "OUR_CLEAN_MODULES=$(OUR_CLEAN_MODS)" "OUR_INSTALL_MODULES=$(OUR_INSTALL_MODS)" "OUR_UNINSTALL_MODULES=$(OUR_UNINSTALL_MODS)" "OUR_DISABLED_MODULES=$(OUR_DISABLED_MODS)" "OUR_DISABLED_CLEAN_MODULES=$(OUR_DISABLED_CLEAN_MODS)" "OUR_DISABLED_INSTALL_MODULES=$(OUR_DISABLED_INSTALL_MODS)" "OUR_DISABLED_UNINSTALL_MODULES=$(OUR_DISABLED_UNINSTALL_MODS)" `test -n "$(VERBOSE)" || echo -s`' #AM_MAKEFLAGS='`test -n "$(VERBOSE)" || echo -s`' AC_SUBST(LIBTOOL) AC_SUBST(TOUCH_TARGET) +AC_SUBST(CONF_DISABLED_MODULES) AC_SUBST(CONF_MODULES) + AC_SUBST(OUR_MODS) AC_SUBST(OUR_CLEAN_MODS) AC_SUBST(OUR_INSTALL_MODS) AC_SUBST(OUR_UNINSTALL_MODS) +AC_SUBST(OUR_DISABLED_MODS) +AC_SUBST(OUR_DISABLED_CLEAN_MODS) +AC_SUBST(OUR_DISABLED_INSTALL_MODS) +AC_SUBST(OUR_DISABLED_UNINSTALL_MODS) AC_SUBST(AM_MAKEFLAGS) # Run configure in all the subdirs diff --git a/src/mod/Makefile.am b/src/mod/Makefile.am index d0db5038c2..2acbf53246 100644 --- a/src/mod/Makefile.am +++ b/src/mod/Makefile.am @@ -3,7 +3,7 @@ clean: $(OUR_CLEAN_MODULES) install: $(OUR_INSTALL_MODULES) uninstall: $(OUR_UNINSTALL_MODULES) -$(OUR_MODULES) $(OUR_CLEAN_MODULES) $(OUR_INSTALL_MODULES) $(OUR_UNINSTALL_MODULES): +$(OUR_MODULES) $(OUR_CLEAN_MODULES) $(OUR_INSTALL_MODULES) $(OUR_UNINSTALL_MODULES) $(OUR_DISABLED_MODULES) $(OUR_DISABLED_CLEAN_MODULES) $(OUR_DISABLED_INSTALL_MODULES) $(OUR_DISABLED_UNINSTALL_MODULES): @set fnord $$MAKEFLAGS; amf=$$2; \ target=`echo $@ | sed -e 's|^.*-||'`; \ modname=`echo $@ | sed -e 's|-.*||' | sed -e 's|^.*/||'`; \