<p>George Joseph <strong>merged</strong> this change.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/11498">View Change</a></p><div style="white-space:pre-wrap">Approvals:
  Joshua Colp: Looks good to me, but someone else must approve
  George Joseph: Looks good to me, approved; Approved for Submit

</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">app_voicemail.c: Build all three variants for app_voicemail at the same time<br><br>Changes made to apps/Makefile to optionally build all three app_voicemail<br>variations at the same time: 1) file (default), 2) odbc, and 3) imap.<br>This functionality was requested by users. modules.conf.sample warns the<br>user to make sure only one voicemail is loaded at a time.<br><br>Change-Id: Iba3cd8ffb4b7e8b1c64a11dd383e1eafcd3ed0e7<br>---<br>M apps/Makefile<br>A apps/app_voicemail_imap.c<br>A apps/app_voicemail_imap.exports.in<br>A apps/app_voicemail_odbc.c<br>A apps/app_voicemail_odbc.exports.in<br>M configs/samples/modules.conf.sample<br>A doc/UPGRADE-staging/Build_all_3_app_voicemail_variants_at_the_same_time.txt<br>7 files changed, 49 insertions(+), 7 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/apps/Makefile b/apps/Makefile</span><br><span>index 589293c..02b705d 100644</span><br><span>--- a/apps/Makefile</span><br><span>+++ b/apps/Makefile</span><br><span>@@ -16,23 +16,45 @@</span><br><span> MENUSELECT_DESCRIPTION=Applications</span><br><span> </span><br><span> MENUSELECT_OPTS_app_directory:=$(MENUSELECT_OPTS_app_voicemail)</span><br><span style="color: hsl(0, 100%, 40%);">-ifneq ($(findstring ODBC_STORAGE,$(MENUSELECT_OPTS_app_voicemail)),)</span><br><span style="color: hsl(0, 100%, 40%);">-  MENUSELECT_DEPENDS_app_voicemail+=$(MENUSELECT_DEPENDS_ODBC_STORAGE)</span><br><span style="color: hsl(0, 100%, 40%);">-endif</span><br><span style="color: hsl(0, 100%, 40%);">-ifneq ($(findstring IMAP_STORAGE,$(MENUSELECT_OPTS_app_voicemail)),)</span><br><span style="color: hsl(0, 100%, 40%);">-  MENUSELECT_DEPENDS_app_voicemail+=$(MENUSELECT_DEPENDS_IMAP_STORAGE)</span><br><span style="color: hsl(0, 100%, 40%);">-endif</span><br><span> </span><br><span> all: _all</span><br><span> </span><br><span> include $(ASTTOPDIR)/Makefile.moddir_rules</span><br><span> </span><br><span style="color: hsl(120, 100%, 40%);">+.app_voicemail.moduleinfo: app_voicemail.c</span><br><span style="color: hsl(120, 100%, 40%);">+     @echo "<member name=\"app_voicemail\" displayname=\"$(shell $(GREP) -e AST_MODULE_INFO $< | head -n 1 | cut -d '"' -f 2)\" remove_on_change=\"$(SUBDIR)/$*.o $(SUBDIR)/$*.so\">" > $@</span><br><span style="color: hsl(120, 100%, 40%);">+        echo "<support_level>core</support_level>"  >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+ echo "<defaultenabled>yes</defaultenabled>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+ echo "<use type=\"module\">res_adsi</use>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+        echo "<use type=\"module\">res_smdi</use>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+        echo "</member>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+.app_voicemail_imap.moduleinfo: app_voicemail_imap.c</span><br><span style="color: hsl(120, 100%, 40%);">+  @echo "<member name=\"app_voicemail_imap\" displayname=\"$(shell $(GREP) -e AST_MODULE_INFO $< | head -n 1 | cut -d '"' -f 2)\" remove_on_change=\"$(SUBDIR)/$*.o $(SUBDIR)/$*.so\">" > $@</span><br><span style="color: hsl(120, 100%, 40%);">+   echo "<support_level>core</support_level>"  >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+ echo "<defaultenabled>no</defaultenabled>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+  echo "<depend>imap_tk</depend>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+     echo "<use type=\"module\">res_adsi</use>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+        echo "<use type=\"module\">res_smdi</use>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+        echo "</member>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+.app_voicemail_odbc.moduleinfo: app_voicemail_odbc.c</span><br><span style="color: hsl(120, 100%, 40%);">+  @echo "<member name=\"app_voicemail_odbc\" displayname=\"$(shell $(GREP) -e AST_MODULE_INFO $< | head -n 1 | cut -d '"' -f 2)\" remove_on_change=\"$(SUBDIR)/$*.o $(SUBDIR)/$*.so\">" > $@</span><br><span style="color: hsl(120, 100%, 40%);">+   echo "<support_level>core</support_level>"  >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+ echo "<defaultenabled>no</defaultenabled>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+  echo "<depend>generic_odbc</depend>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+        echo "<use type=\"module\">res_adsi</use>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+        echo "<use type=\"module\">res_smdi</use>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+        echo "</member>" >> $@</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span> $(call MOD_ADD_C,app_confbridge,$(wildcard confbridge/*.c))</span><br><span> </span><br><span> app_confbridge.o: _ASTCFLAGS+=$(AST_NO_FORMAT_TRUNCATION)</span><br><span> app_meetme.o: _ASTCFLAGS+=$(AST_NO_FORMAT_TRUNCATION)</span><br><span> app_minivm.o: _ASTCFLAGS+=$(AST_NO_FORMAT_TRUNCATION)</span><br><span style="color: hsl(0, 100%, 40%);">-app_voicemail.o: _ASTCFLAGS+=$(AST_NO_FORMAT_TRUNCATION)</span><br><span style="color: hsl(120, 100%, 40%);">+app_voicemail.o: _ASTCFLAGS+=$(AST_NO_FORMAT_TRUNCATION) -DFILE_STORAGE</span><br><span style="color: hsl(120, 100%, 40%);">+app_voicemail_odbc.o: _ASTCFLAGS+=$(AST_NO_FORMAT_TRUNCATION) -DODBC_STORAGE</span><br><span style="color: hsl(120, 100%, 40%);">+app_voicemail_imap.o: _ASTCFLAGS+=$(AST_NO_FORMAT_TRUNCATION) -DIMAP_STORAGE</span><br><span> app_while.o: _ASTCFLAGS+=$(AST_NO_FORMAT_TRUNCATION)</span><br><span> </span><br><span> ifneq ($(findstring $(OSARCH), mingw32 cygwin ),)</span><br><span>diff --git a/apps/app_voicemail_imap.c b/apps/app_voicemail_imap.c</span><br><span>new file mode 120000</span><br><span>index 0000000..fdb024a</span><br><span>--- /dev/null</span><br><span>+++ b/apps/app_voicemail_imap.c</span><br><span>@@ -0,0 +1 @@</span><br><span style="color: hsl(120, 100%, 40%);">+app_voicemail.c</span><br><span>\ No newline at end of file</span><br><span>diff --git a/apps/app_voicemail_imap.exports.in b/apps/app_voicemail_imap.exports.in</span><br><span>new file mode 120000</span><br><span>index 0000000..401e8f2</span><br><span>--- /dev/null</span><br><span>+++ b/apps/app_voicemail_imap.exports.in</span><br><span>@@ -0,0 +1 @@</span><br><span style="color: hsl(120, 100%, 40%);">+app_voicemail.exports.in</span><br><span>\ No newline at end of file</span><br><span>diff --git a/apps/app_voicemail_odbc.c b/apps/app_voicemail_odbc.c</span><br><span>new file mode 120000</span><br><span>index 0000000..fdb024a</span><br><span>--- /dev/null</span><br><span>+++ b/apps/app_voicemail_odbc.c</span><br><span>@@ -0,0 +1 @@</span><br><span style="color: hsl(120, 100%, 40%);">+app_voicemail.c</span><br><span>\ No newline at end of file</span><br><span>diff --git a/apps/app_voicemail_odbc.exports.in b/apps/app_voicemail_odbc.exports.in</span><br><span>new file mode 120000</span><br><span>index 0000000..401e8f2</span><br><span>--- /dev/null</span><br><span>+++ b/apps/app_voicemail_odbc.exports.in</span><br><span>@@ -0,0 +1 @@</span><br><span style="color: hsl(120, 100%, 40%);">+app_voicemail.exports.in</span><br><span>\ No newline at end of file</span><br><span>diff --git a/configs/samples/modules.conf.sample b/configs/samples/modules.conf.sample</span><br><span>index 793245d..134ab89 100644</span><br><span>--- a/configs/samples/modules.conf.sample</span><br><span>+++ b/configs/samples/modules.conf.sample</span><br><span>@@ -44,3 +44,10 @@</span><br><span> </span><br><span> ; Do not load chan_sip by default, it may conflict with res_pjsip.</span><br><span> noload => chan_sip.so</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+; The default voicemail module is app_voicemal. All voicemail modules</span><br><span style="color: hsl(120, 100%, 40%);">+; are mutually exclusive. Therefore it is better to make sure they</span><br><span style="color: hsl(120, 100%, 40%);">+; are not loaded at startup</span><br><span style="color: hsl(120, 100%, 40%);">+;</span><br><span style="color: hsl(120, 100%, 40%);">+noload => app_voicemail_odbc.so</span><br><span style="color: hsl(120, 100%, 40%);">+noload => app_voicemail_imap.so</span><br><span>diff --git a/doc/UPGRADE-staging/Build_all_3_app_voicemail_variants_at_the_same_time.txt b/doc/UPGRADE-staging/Build_all_3_app_voicemail_variants_at_the_same_time.txt</span><br><span>new file mode 100644</span><br><span>index 0000000..22fb4f7</span><br><span>--- /dev/null</span><br><span>+++ b/doc/UPGRADE-staging/Build_all_3_app_voicemail_variants_at_the_same_time.txt</span><br><span>@@ -0,0 +1,9 @@</span><br><span style="color: hsl(120, 100%, 40%);">+Subject: app_voicemail.c</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+The "Voicemail Build Options" section of menuselect has been removed along with</span><br><span style="color: hsl(120, 100%, 40%);">+the FILE_STORAGE, ODBC_STORAGE and IMAP_STORAGE menuselect options.  All 3 variants</span><br><span style="color: hsl(120, 100%, 40%);">+of the voicemail app can now be built at the same by enabling app_voicemail,</span><br><span style="color: hsl(120, 100%, 40%);">+app_voicemail_imap, and app_voicemail_odbc under the "Applications" section.</span><br><span style="color: hsl(120, 100%, 40%);">+By default, only app_voicemail is enabled.  Also, the modules.conf sample has</span><br><span style="color: hsl(120, 100%, 40%);">+been updated to "noload" app_voicemail_imap and app_voicemail_odbc should they</span><br><span style="color: hsl(120, 100%, 40%);">+all be built.  Packagers must update their build scripts appropriately.</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/11498">change 11498</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/c/asterisk/+/11498"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: Iba3cd8ffb4b7e8b1c64a11dd383e1eafcd3ed0e7 </div>
<div style="display:none"> Gerrit-Change-Number: 11498 </div>
<div style="display:none"> Gerrit-PatchSet: 3 </div>
<div style="display:none"> Gerrit-Owner: Christian Savinovich <csavinovich@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Joshua Colp <jcolp@digium.com> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>