]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
cleanup Makefile.am based module Makefiles
authorMichael Jerris <mike@jerris.com>
Mon, 7 Dec 2009 06:47:28 +0000 (06:47 +0000)
committerMichael Jerris <mike@jerris.com>
Mon, 7 Dec 2009 06:47:28 +0000 (06:47 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@15811 d0543943-73ff-0310-b7d9-9358b9ac24b2

build/modmake.rulesam [new file with mode: 0644]
src/mod/asr_tts/mod_unimrcp/Makefile.am
src/mod/endpoints/mod_sofia/Makefile.am

diff --git a/build/modmake.rulesam b/build/modmake.rulesam
new file mode 100644 (file)
index 0000000..31bde62
--- /dev/null
@@ -0,0 +1,11 @@
+AM_CFLAGS   = $(SWITCH_AM_CFLAGS) $(SWITCH_ANSI_CFLAGS)
+AM_CPPFLAGS = $(SWITCH_AM_CXXFLAGS)
+AM_LDFLAGS  = $(SWITCH_AM_LDFLAGS)
+#we should set all these vars from configure, no reason to have these in each Makefile.am
+LIBTOOL = echo "`link=\`echo $@|grep .la;echo $@|grep .so;echo $@|grep .dll\`;if test -n "$$link"; then echo Creating $@;fi`";`if test -z "$(VERBOSE)" ; \
+then echo $(SHELL) $(switch_builddir)/quiet_libtool ;else echo $(SHELL) $(switch_builddir)/libtool;  fi`
+AM_MAKEFLAGS=`test -n "$(VERBOSE)" || echo -s`
+# Dirty trick to override the link output
+LIBS+=> $(MODNAME).log || error="yes";if test -n "$(VERBOSE)" -o "$$error" = "yes";then cat $(MODNAME).log;fi;if test "$$error" = "yes";then exit 1;fi
+
+moddir=@modinstdir@
index cd5ead0324d9c49079b8fda4ba13ddbf9aa07585..25be5a6baa25fe4e052b12018ed40fd9cfc582fa 100644 (file)
@@ -1,16 +1,6 @@
-MODNAME=mod_unimrcp
+include $(top_srcdir)/build/modmake.rulesam
 
-AM_CFLAGS   = $(SWITCH_AM_CFLAGS) $(SWITCH_ANSI_CFLAGS)
-AM_CPPFLAGS = $(SWITCH_AM_CXXFLAGS)
-#AM_LDFLAGS  = $(SWITCH_AM_LDFLAGS)
-#we should set all these vars from configure, no reason to have these in each Makefile.am
-LIBTOOL = echo "`link=\`echo $@|grep .la;echo $@|grep .so;echo $@|grep .dll\`;if test -n "$$link"; then echo Creating $@;fi`";`if test -z "$(VERBOSE)" ; \
-then echo $(SHELL) $(switch_builddir)/quiet_libtool ;else echo $(SHELL) $(switch_builddir)/libtool;  fi`
-AM_MAKEFLAGS=`test -n "$(VERBOSE)" || echo -s`
-# Dirty trick to override the link output
-LIBS+=> $(MODNAME).log || error="yes";if test -n "$(VERBOSE)" -o "$$error" = "yes";then cat $(MODNAME).log;fi;if test "$$error" = "yes";then exit 1;fi
-
-moddir=@modinstdir@
+MODNAME=mod_unimrcp
 
 UNIMRCP_DIR=$(switch_builddir)/libs/unimrcp
 UNIMRCPLA=$(UNIMRCP_DIR)/platforms/libunimrcp-client/libunimrcpclient.la
index 2e52e0d64de4e5d35343c12e6a55132e19c33fc7..73e3963f78382af6745a6e6239313d957f5166bb 100644 (file)
@@ -1,14 +1,4 @@
-AM_CFLAGS   = $(SWITCH_AM_CFLAGS)
-AM_CPPFLAGS = $(SWITCH_AM_CXXFLAGS)
-#AM_LDFLAGS  = $(SWITCH_AM_LDFLAGS)
-#we should set all these vars from configure, no reason to have these in each Makefile.am
-LIBTOOL = echo "`link=\`echo $@|grep .la;echo $@|grep .so;echo $@|grep .dll\`;if test -n "$$link"; then echo Creating $@;fi`";`if test -z "$(VERBOSE)" ; \
-then echo $(SHELL) $(switch_builddir)/quiet_libtool ;else echo $(SHELL) $(switch_builddir)/libtool;  fi`
-AM_MAKEFLAGS=`test -n "$(VERBOSE)" || echo -s`
-# Dirty trick to override the link output
-LIBS+=> $(MODNAME).log || error="yes";if test -n "$(VERBOSE)" -o "$$error" = "yes";then cat $(MODNAME).log;fi;if test "$$error" = "yes";then exit 1;fi
-
-moddir=@modinstdir@
+include $(top_srcdir)/build/modmake.rulesam
 
 MODNAME=mod_sofia
 
@@ -18,7 +8,7 @@ SOFIALA=$(SOFIAUA_DIR)/libsofia-sip-ua.la
 
 mod_LTLIBRARIES = mod_sofia.la
 mod_sofia_la_SOURCES = mod_sofia.c sofia.c sofia_glue.c sofia_presence.c sofia_reg.c sofia_sla.c  mod_sofia.h
-mod_sofia_la_CFLAGS  = $(AM_CFLAGS) $(SWITCH_ANSI_CFLAGS)
+mod_sofia_la_CFLAGS  = $(AM_CFLAGS)
 mod_sofia_la_CFLAGS += -I. -I$(SOFIAUA_DIR)/bnf  -I$(SOFIAUA_DIR)/features
 mod_sofia_la_CFLAGS += -I$(SOFIAUA_DIR)/http -I$(SOFIAUA_DIR)/ipt
 mod_sofia_la_CFLAGS += -I$(SOFIAUA_DIR)/iptsec -I$(SOFIAUA_DIR)/msg
@@ -44,7 +34,7 @@ BUILT_SOURCES = $(SOFIALA)
 $(mod_sofia_la_SOURCES) : $(BUILT_SOURCES)
 
 $(SOFIALA): $(SOFIA_DIR) $(SOFIA_DIR)/.update
-       cd $(SOFIA_DIR) && $(MAKE) SOFIA_CFLAGS="$(AM_CFLAGS)"
+       cd $(SOFIA_DIR) && $(MAKE) SOFIA_CFLAGS="$(SWITCH_AM_CFLAGS)"
        $(TOUCH_TARGET)
 
 ../../../../libs/sofia-sip/libsofia-sip-ua/nua/sofia-sip/nua_tag.h: $(SOFIALA)