[Git][pkg-voip-team/asterisk][debian/latest] 5 commits: fix teardown function in autopkgtest

Jonas Smedegaard (@js) gitlab at salsa.debian.org
Sat Feb 12 18:52:04 GMT 2022



Jonas Smedegaard pushed to branch debian/latest at Debian VoIP Packaging Team / asterisk


Commits:
373939b6 by Jonas Smedegaard at 2022-02-12T17:37:27+01:00
fix teardown function in autopkgtest

- - - - -
5285cdd1 by Jonas Smedegaard at 2022-02-12T19:40:41+01:00
fix build module app_macro, and simplify build configuration: revert build rules to explicitly set menuselect target file; reduce and rename patch 2004; drop related obsolete patches 2003 2005 2007 2009 2017; closes: bug#1005381, thanks to James Bottomley

- - - - -
7a48eb51 by Jonas Smedegaard at 2022-02-12T19:40:47+01:00
drop unused obsolete h323 patches 1002 1003 1005

- - - - -
a32f41a4 by Jonas Smedegaard at 2022-02-12T19:40:47+01:00
omit build-depending on default-libmysqlclient-dev for architectures where the package is unavailable

- - - - -
18e4ceed by Jonas Smedegaard at 2022-02-12T19:40:47+01:00
prepare for release: update changelog and copyright hints

- - - - -


15 changed files:

- debian/changelog
- debian/control
- debian/copyright_hints
- − debian/patches/1002_h323_avoid_linking.patch
- − debian/patches/1003_h323_segfault_workaround.patch
- − debian/patches/1005_h323_makefile_workaround.patch
- − debian/patches/2003_enable_addons.patch
- debian/patches/2004_enable_drivers.patch → debian/patches/2004_mgcp.patch
- − debian/patches/2005_enable_smsq.patch
- − debian/patches/2007_enable_aelparse.patch
- − debian/patches/2009_disable_native_arch.patch
- − debian/patches/2017_enable_voicemail.patch
- debian/patches/series
- debian/rules
- debian/tests/asttestmods


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,17 @@
+asterisk (1:18.10.0~dfsg+~cs6.10.40431411-2) unstable; urgency=medium
+
+  * fix teardown function in autopkgtest
+  * fix build module app_macro, and simplify build configuration:
+    + revert build rules to explicitly set menuselect target file
+    + reduce and rename patch 2004
+    + drop related obsolete patches 2003 2005 2007 2009 2017
+    closes: bug#1005381, thanks to James Bottomley
+  * drop unused obsolete h323 patches 1002 1003 1005
+  * omit build-depending on default-libmysqlclient-dev
+    for architectures where the package is unavailable
+
+ -- Jonas Smedegaard <dr at jones.dk>  Sat, 12 Feb 2022 19:24:51 +0100
+
 asterisk (1:18.10.0~dfsg+~cs6.10.40431411-1) unstable; urgency=medium
 
   [ upstream ]


=====================================
debian/control
=====================================
@@ -14,7 +14,7 @@ Build-Depends:
  binutils-dev,
  dahdi-source,
  debhelper-compat (= 13),
- default-libmysqlclient-dev,
+ default-libmysqlclient-dev [!alpha !kfreebsd-amd64 !kfreebsd-i386 !ppc64 !sparc64 !x32],
  freetds-dev,
  libasound2-dev,
  libavcodec-dev,


=====================================
debian/copyright_hints
=====================================
@@ -1288,23 +1288,16 @@ Files: BSDmakefile
  debian/dummyprogs/fetch
  debian/gbp.conf
  debian/not-installed
- debian/patches/1002_h323_avoid_linking.patch
- debian/patches/1003_h323_segfault_workaround.patch
  debian/patches/1004_astgenkey-security.patch
- debian/patches/1005_h323_makefile_workaround.patch
  debian/patches/1006_systemd.patch
  debian/patches/1007_ffmpeg_detect.patch
  debian/patches/1008_ffmpeg_include.patch
  debian/patches/1009_build_reproducibly.patch
  debian/patches/2001_keep_sounds_on_distclean.patch
  debian/patches/2002_no_download_sounds.patch
- debian/patches/2003_enable_addons.patch
- debian/patches/2004_enable_drivers.patch
- debian/patches/2005_enable_smsq.patch
+ debian/patches/2004_mgcp.patch
  debian/patches/2006_enable_test_framework.patch
- debian/patches/2007_enable_aelparse.patch
  debian/patches/2008_disable_ilbc.patch
- debian/patches/2009_disable_native_arch.patch
  debian/patches/2010_astdatadir.patch
  debian/patches/2011_amr_build_tools.patch
  debian/patches/2012_amr_codec.patch
@@ -1312,7 +1305,6 @@ Files: BSDmakefile
  debian/patches/2014_pjproject_unbreak.patch
  debian/patches/2015_opus.patch
  debian/patches/2016_opus_plc.patch
- debian/patches/2017_enable_voicemail.patch
  debian/patches/README
  debian/patches/series
  debian/rules


=====================================
debian/patches/1002_h323_avoid_linking.patch deleted
=====================================
@@ -1,45 +0,0 @@
-Description: Avoid linking the asterisk binary with the H.323 libraries
- Don't link the Asterisk binary with the H.323 libraries
- since they are only used by separate shared object, chan_h323.so.
- .
- WARNING: this will make Asterisk segfault when loading chan_h323.so
- (see bug #435146),
- because libopenh323 is buggy
- (see bug #438815).
- .
- We are working around this
- (see patch 1003_h323_segfault_workaround.patch).
-Author: Faidon Liambotis <paravoid at debian.org>
-Bug-Debian: https://bugs.debian.org/433884
-Forwarded: no
-Last-Update: 2022-01-22
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/main/Makefile
-+++ b/main/Makefile
-@@ -153,13 +153,6 @@
- AST_EMBED_LIBS:=$(foreach dep,$(EMBED_LIBS),$(value $(dep)))
- OBJS:=$(sort $(OBJS))
- 
--ifneq ($(wildcard ../channels/h323/Makefile.ast),)
--  include ../channels/h323/Makefile.ast
--else
--  H323LDFLAGS=
--  H323LDLIBS=
--endif
--
- ifneq ($(findstring $(OSARCH), mingw32 cygwin ),)
- MAIN_TGT:=asterisk.dll
- asterisk: cygload
-@@ -177,11 +170,7 @@
- $(MAIN_TGT): $(OBJS) editline/libedit.a db1-ast/libdb1.a $(AST_EMBED_LDSCRIPTS)
- 	@$(CC) -c -o buildinfo.o $(_ASTCFLAGS) buildinfo.c $(ASTCFLAGS)
- 	$(ECHO_PREFIX) echo "   [LD] $(OBJS) editline/libedit.a db1-ast/libdb1.a $(AST_EMBED_LDSCRIPTS) -> $@"
--ifneq ($(findstring chan_h323,$(MENUSELECT_CHANNELS)),)
- 	$(CMD_PREFIX) $(CC) $(STATIC_BUILD) -o $@ $(ASTLINK) $(AST_EMBED_LDFLAGS) $(_ASTLDFLAGS) $(ASTLDFLAGS) $(OBJS) editline/libedit.a db1-ast/libdb1.a $(AST_EMBED_LDSCRIPTS) buildinfo.o $(AST_LIBS) $(AST_EMBED_LIBS) $(GMIMELDFLAGS)
--else
--	$(CMD_PREFIX) $(CXX) $(STATIC_BUILD) -o $@ $(ASTLINK) $(AST_EMBED_LDFLAGS) $(_ASTLDFLAGS) $(ASTLDFLAGS) $(H323LDFLAGS) $(OBJS) editline/libedit.a db1-ast/libdb1.a $(AST_EMBED_LDSCRIPTS) buildinfo.o $(AST_LIBS) $(AST_EMBED_LIBS) $(H323LDLIBS) $(GMIMELDFLAGS)
--endif
- 
- ifeq ($(GNU_LD),1)
- $(MAIN_TGT): asterisk.exports


=====================================
debian/patches/1003_h323_segfault_workaround.patch deleted
=====================================
@@ -1,37 +0,0 @@
-Description: Hack dynamic loader to workaround libopenh323 bug
- libopenh323 is buggy and crashes on dlclose()
- when the library was opened with RTLD_LAZY
- (see bug #438815).
- Hack around this
- by opening it with RTLD_NOW by matching the module names
- (chan_h323.so and the external chan_oh323.so).
- .
- This is a very crude hack
- needed because we are removing libopenh323 dependencies
- from the asterisk binary.
- (see patch 1002_h323_avoid_linking.patch)
- Namely, it will have unexpected results
- if e.g. the user renames the module for any reason.
- .
- This patch should be removed when bug #438815 is solved.
-Author: Faidon Liambotis <paravoid at debian.org>
-Bug-Debian: https://bugs.debian.org/435146
-Forwarded: no
-Last-Update: 2022-01-22
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/main/loader.c
-+++ b/main/loader.c
-@@ -382,6 +382,12 @@
- 	if (missing_so)
- 		strcat(resource_being_loaded->resource, ".so");
- 
-+	/* libopenh323 is buggy and segfaults on dlclose() when opened with
-+	 * RTLD_LAZY. Workaround this until it gets fixed */
-+	if (!strcasecmp(resource_being_loaded->resource, "chan_h323.so") ||
-+	    !strcasecmp(resource_being_loaded->resource, "chan_oh323.so"))
-+		lib = dlopen(fn, RTLD_NOW | RTLD_LOCAL);
-+
- 	if (!(lib = dlopen(fn, RTLD_LAZY | RTLD_LOCAL))) {
- 		ast_log(LOG_WARNING, "Error loading module '%s': %s\n", resource_in, dlerror());
- 		ast_free(resource_being_loaded);


=====================================
debian/patches/1005_h323_makefile_workaround.patch deleted
=====================================
@@ -1,22 +0,0 @@
-Description: allow manually generating channels/h323/Makefile.ast
- This patch is a work-around to that bug.
- It allows running 'make h323-mak' from debian/rules
- to generate channels/h323/Makefile.ast
- before running the main 'make' command.
-Author: Tzafrir Cohen <tzafrir.cohen at xorcom.com>
-Bug: https://issues.asterisk.org/jira/browse/ASTERISK-15938
-Last-Update: 2022-01-22
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/Makefile
-+++ b/Makefile
-@@ -965,6 +965,9 @@
- asterisk.txt:
- 	$(MAKE) -C doc/tex asterisk.txt
- 
-+h323-mak:
-+	$(MAKE) -C channels h323/Makefile.ast
-+
- .PHONY: menuselect
- .PHONY: main
- .PHONY: sounds


=====================================
debian/patches/2003_enable_addons.patch deleted
=====================================
@@ -1,75 +0,0 @@
-Description: enable modules formly from asterisk-addons
- The modules under addons/
- are originally from the separate asterisk-addons package.
- As of asterisk 1.8 they are included in the main Asterisk distribution
- but not enabled by default.
- this patch enables them, as it seems valid in Debian.
- .
- format_mp3.c is not enabled, yet, though:
- the complete source is not included.
- See contrib/scripts/get_mp3_source.sh in the source tree.
-Author: Tzafrir Cohen <tzafrir at debian.org>
-Applied-Upsteam: no
-Last-Update: 2022-01-22
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/addons/app_mysql.c
-+++ b/addons/app_mysql.c
-@@ -34,7 +34,6 @@
- 
- /*** MODULEINFO
- 	<depend>mysqlclient</depend>
--	<defaultenabled>no</defaultenabled>
- 	<support_level>deprecated</support_level>
- 	<replacement>func_odbc</replacement>
- 	<deprecated_in>1.8</deprecated_in>
---- a/addons/chan_mobile.c
-+++ b/addons/chan_mobile.c
-@@ -36,7 +36,6 @@
- 
- /*** MODULEINFO
- 	<depend>bluetooth</depend>
--	<defaultenabled>no</defaultenabled>
- 	<support_level>extended</support_level>
-  ***/
- 
---- a/addons/chan_ooh323.c
-+++ b/addons/chan_ooh323.c
-@@ -18,7 +18,6 @@
- 
- 
- /*** MODULEINFO
--	<defaultenabled>no</defaultenabled>
- 	<support_level>extended</support_level>
-  ***/
- 
---- a/addons/res_config_mysql.c
-+++ b/addons/res_config_mysql.c
-@@ -24,7 +24,6 @@
- 
- /*** MODULEINFO
- 	<depend>mysqlclient</depend>
--	<defaultenabled>no</defaultenabled>
- 	<support_level>extended</support_level>
-  ***/
- 
---- a/addons/cdr_mysql.c
-+++ b/addons/cdr_mysql.c
-@@ -35,7 +35,6 @@
- 
- /*** MODULEINFO
- 	<depend>mysqlclient</depend>
--	<defaultenabled>no</defaultenabled>
- 	<support_level>deprecated</support_level>
- 	<replacement>cdr_adaptive_odbc</replacement>
- 	<deprecated_in>1.8</deprecated_in>
---- a/addons/format_mp3.c
-+++ b/addons/format_mp3.c
-@@ -28,7 +28,6 @@
-  */
- 
- /*** MODULEINFO
--	<defaultenabled>no</defaultenabled>
- 	<support_level>extended</support_level>
-  ***/
- 


=====================================
debian/patches/2004_enable_drivers.patch → debian/patches/2004_mgcp.patch
=====================================
@@ -1,19 +1,8 @@
-Description: enable drivers chan_vbp and chan_mgcp
+Description: allow building non-NCS variation of driver chan_mgcp
 Author: Tzafrir Cohen <tzafrir.cohen at xorcom.com>
-Last-Update: 2022-01-22
+Last-Update: 2022-02-12
 ---
 This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/channels/chan_vpb.cc
-+++ b/channels/chan_vpb.cc
-@@ -49,7 +49,7 @@
- 
- /*** MODULEINFO
- 	<depend>vpb</depend>
--	<defaultenabled>no</defaultenabled>
-+	<defaultenabled>yes</defaultenabled>
- 	<support_level>deprecated</support_level>
- 	<deprecated_in>16</deprecated_in>
- 	<removed_in>19</removed_in>
 --- a/channels/chan_mgcp.c
 +++ b/channels/chan_mgcp.c
 @@ -34,7 +34,6 @@


=====================================
debian/patches/2005_enable_smsq.patch deleted
=====================================
@@ -1,18 +0,0 @@
-Description: Enable the smsq application.
-Author: Frederic Van Espen <frederic.ve at gmail.com>
-Forwarded: no
-Bug-Debian: https://bugs.debian.org/738588
-Last-Update: 2022-01-22
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/utils/utils.xml
-+++ b/utils/utils.xml
-@@ -37,7 +37,7 @@
- 	<support_level>deprecated</support_level>
-   </member>
-   <member name="smsq">
--	<defaultenabled>no</defaultenabled>
-+	<defaultenabled>yes</defaultenabled>
- 	<depend>popt</depend>
- 	<support_level>extended</support_level>
-   </member>


=====================================
debian/patches/2007_enable_aelparse.patch deleted
=====================================
@@ -1,17 +0,0 @@
-Description: Enable the aelparse application.
-Author: Jeremy Lainé <jeremy.laine at m4x.org>
-Forwarded: no
-Bug-Debian: https://bugs.debian.org/747866
-Last-Update: 2018-11-17
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/utils/utils.xml
-+++ b/utils/utils.xml
-@@ -1,6 +1,6 @@
- <category name="MENUSELECT_UTILS" displayname="Utilities" positive_output="yes">
-   <member name="aelparse">
--	<defaultenabled>no</defaultenabled>
-+	<defaultenabled>yes</defaultenabled>
- 	<support_level>deprecated</support_level>
-   </member>
-   <member name="astcanary">


=====================================
debian/patches/2009_disable_native_arch.patch deleted
=====================================
@@ -1,20 +0,0 @@
-Description: disable building asterisk with -march=native
- Don't add -march=native to standard CFLAGS.
- We need a generic binary.
-Author: Tzafrir Cohen <tzafrir.cohen at xorcom.com>
-Bug-Debian: https://bugs.debian.org/842917
-Forwarded: no
-Last-Update: 2022-01-22
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/build_tools/cflags.xml
-+++ b/build_tools/cflags.xml
-@@ -125,7 +125,7 @@
- 		</member>
- 		<member name="BUILD_NATIVE" displayname="Allow compiler to generate code optimized for the CPU on which the build is performed.">
- 			<support_level>core</support_level>
--			<defaultenabled>yes</defaultenabled>
-+			<defaultenabled>no</defaultenabled>
- 			<depend>native_arch</depend>
- 		</member>
- 		<member name="TEST_FRAMEWORK" displayname="Enable Test Framework API">


=====================================
debian/patches/2017_enable_voicemail.patch deleted
=====================================
@@ -1,25 +0,0 @@
-Description: enable all app_voicemail_* modules
-Author: Jonas Smedegaard <dr at jones.dk>
-Last-Update: 2022-02-04
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/apps/Makefile
-+++ b/apps/Makefile
-@@ -32,7 +32,7 @@
- .app_voicemail_imap.moduleinfo: app_voicemail_imap.c
- 	@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\">" > $@
- 	echo "<support_level>core</support_level>"  >> $@
--	echo "<defaultenabled>no</defaultenabled>" >> $@
-+	echo "<defaultenabled>yes</defaultenabled>" >> $@
- 	echo "<depend>imap_tk</depend>" >> $@
- 	echo "<use type=\"module\">res_adsi</use>" >> $@
- 	echo "<use type=\"module\">res_smdi</use>" >> $@
-@@ -41,7 +41,7 @@
- .app_voicemail_odbc.moduleinfo: app_voicemail_odbc.c
- 	@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\">" > $@
- 	echo "<support_level>core</support_level>"  >> $@
--	echo "<defaultenabled>no</defaultenabled>" >> $@
-+	echo "<defaultenabled>yes</defaultenabled>" >> $@
- 	echo "<depend>generic_odbc</depend>" >> $@
- 	echo "<use type=\"module\">res_adsi</use>" >> $@
- 	echo "<use type=\"module\">res_smdi</use>" >> $@


=====================================
debian/patches/series
=====================================
@@ -1,20 +1,13 @@
-#1002_h323_avoid_linking.patch
-#1003_h323_segfault_workaround.patch
 1004_astgenkey-security.patch
-#1005_h323_makefile_workaround.patch
 1006_systemd.patch
 1007_ffmpeg_detect.patch
 1008_ffmpeg_include.patch
 1009_build_reproducibly.patch
 #2001_keep_sounds_on_distclean.patch
 2002_no_download_sounds.patch
-2003_enable_addons.patch
-2004_enable_drivers.patch
-2005_enable_smsq.patch
+2004_mgcp.patch
 2006_enable_test_framework.patch
-2007_enable_aelparse.patch
 2008_disable_ilbc.patch
-2009_disable_native_arch.patch
 2010_astdatadir.patch
 2011_amr_build_tools.patch
 2012_amr_codec.patch
@@ -22,4 +15,3 @@
 2014_pjproject_unbreak.patch
 2015_opus.patch
 2016_opus_plc.patch
-2017_enable_voicemail.patch


=====================================
debian/rules
=====================================
@@ -49,6 +49,15 @@ ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
 	INSTALL_PROGRAM += -s
 endif
 
+ADDONS_ENABLE = app_macro app_voicemail_imap app_voicemail_odbc
+ADDONS_ENABLE += app_mysql res_config_mysql cdr_mysql
+ADDONS_ENABLE += chan_mobile chan_ooh323 chan_vpb
+ADDONS_ENABLE += aelparse format_mp3 smsq TEST_FRAMEWORK
+ADDONS_DISABLE = BUILD_NATIVE
+ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
+ADDONS_ENABLE += BETTER_BACKTRACES DEBUG_THREADS
+endif
+
 # make sure we have 'fetch' . We need to have either wget or fetch
 # on the system. However it is generally not a good idea to actually
 # get remote tarballs at build time. So if neither wget nor fetch
@@ -99,14 +108,8 @@ override_dh_auto_configure:
 
 execute_before_dh_auto_build:
 	$(MAKE) menuselect.makeopts BUILD_CFLAGS="$(CFLAGS)" BUILD_LDFLAGS="$(LDFLAGS)"
-	menuselect/menuselect --enable app_macro
-	menuselect/menuselect --enable app_voicemail_imap
-	menuselect/menuselect --enable app_voicemail_odbc
-	menuselect/menuselect --disable BUILD_NATIVE
-ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
-	menuselect/menuselect --enable BETTER_BACKTRACES
-	menuselect/menuselect --enable DEBUG_THREADS
-endif
+	for module in $(ADDONS_ENABLE); do menuselect/menuselect --enable $$module menuselect.makeopts; done
+	for module in $(ADDONS_DISABLE); do menuselect/menuselect --disable $$module menuselect.makeopts; done
 
 override_dh_auto_build:
 	$(FETCH_ENV) dh_auto_build -- $(BUILDFLAGS)


=====================================
debian/tests/asttestmods
=====================================
@@ -61,7 +61,7 @@ run() {
 
 teardown() {
 	$asterisk -rx 'core stop now'
-	service asterisk start
+	service asterisk stop
 }
 
 setup



View it on GitLab: https://salsa.debian.org/pkg-voip-team/asterisk/-/compare/e6038b8c339acaabbb590c837f3134c7da9ca5e8...18e4ceedf72444f7ff2cdc0b4f3ce8afa6ceb70b

-- 
View it on GitLab: https://salsa.debian.org/pkg-voip-team/asterisk/-/compare/e6038b8c339acaabbb590c837f3134c7da9ca5e8...18e4ceedf72444f7ff2cdc0b4f3ce8afa6ceb70b
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-voip-maintainers/attachments/20220212/f5e8b97e/attachment-0001.htm>


More information about the Pkg-voip-maintainers mailing list