+ if [ -d "./files/etc.packages/$(1)" ]; then \
+ $(INSTALL_DIR) $$(1)/etc/freeswitch ; \
+ $(CP) \
+ ./files/etc.packages/$(1)/* \
+ $$(1)/etc/freeswitch/ ; \
+ fi
+ endef
+
+ define Package/freeswitch-mod-$(1)/postinst
+#!/bin/sh
+sed -i -e 's|^\([ \t]*\)<!-- *\(.*\)"mod_$(1)"\(.*\) *-->\(.*\)$$$$|\1\2"mod_$(1)"\3\4|' $$$${IPKG_INSTROOT}/etc/freeswitch/autoload_configs/modules.conf.xml
+ endef
+
+ define Package/freeswitch-mod-$(1)/postrm
+#!/bin/sh
+sed -i -e 's|^\([ \t]*\)\(.*\)"mod_$(1)"\(.*\)$$$$|\1<!-- \2"mod_$(1)"\3 -->|' $$$${IPKG_INSTROOT}/etc/freeswitch/autoload_configs/modules.conf.xml