summarylogtreecommitdiffstats
path: root/fixes-16.0.0.diff
diff options
context:
space:
mode:
authorOleksandr Natalenko2018-10-10 19:57:58 +0200
committerOleksandr Natalenko2018-10-10 19:57:58 +0200
commit028de84b251f350738b24235330ea00d570d9173 (patch)
treec54be21728a5f72d6f23d36b23836e38d48358b3 /fixes-16.0.0.diff
parent217a47a6170b48a5d049ee42dd9022ab952c4e11 (diff)
downloadaur-028de84b251f350738b24235330ea00d570d9173.tar.gz
introduce Asterisk 16 support
Signed-off-by: Oleksandr Natalenko <oleksandr@natalenko.name>
Diffstat (limited to 'fixes-16.0.0.diff')
-rw-r--r--fixes-16.0.0.diff56
1 files changed, 56 insertions, 0 deletions
diff --git a/fixes-16.0.0.diff b/fixes-16.0.0.diff
new file mode 100644
index 000000000000..d3aa0a9cea00
--- /dev/null
+++ b/fixes-16.0.0.diff
@@ -0,0 +1,56 @@
+diff --git a/codec_g72x.c b/codec_g72x.c
+index 959436e..0a8ea45 100644
+--- a/codec_g72x.c
++++ b/codec_g72x.c
+@@ -469,8 +469,12 @@ static void g72x_destroy(struct ast_trans_pvt *pvt)
+ #if !G72X_BCG729
+ ippsFree(state->coder);
+ ippsFree(state->scratch_mem);
++#else
++#if G72X_ASTERISK >= 160
++ ast_std_free(state->coder);
+ #else
+ free(state->coder);
++#endif
+ #endif
+ /* output the sizes of frames passed to decoder */
+ if (option_verbose > 2 && frame_sizes != NULL) {
+diff --git a/configure.ac b/configure.ac
+index d72b052..43b82f9 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -41,7 +41,7 @@ if test "${prefix}" != "/usr"; then
+ fi
+ #echo new prefix: "${prefix}"
+
+-ASTERISK_VERSION="150";
++ASTERISK_VERSION="160";
+
+ AC_ARG_WITH(asterisk-includes,
+ AS_HELP_STRING([--with-asterisk-includes=PATH], [Path to Asterisk includes (defaults to PREFIX/include, so try --prefix first)]),
+@@ -65,8 +65,11 @@ AC_ARG_WITH(asterisk140,
+ AS_HELP_STRING([--with-asterisk140], [Build for Asterisk 14]),
+ [ASTERISK_VERSION="140"])
+ AC_ARG_WITH(asterisk150,
+- AS_HELP_STRING([--with-asterisk150], [Build for Asterisk 15 (the default)]),
++ AS_HELP_STRING([--with-asterisk150], [Build for Asterisk 15]),
+ [ASTERISK_VERSION="150"])
++AC_ARG_WITH(asterisk160,
++ AS_HELP_STRING([--with-asterisk160], [Build for Asterisk 16 (the default)]),
++ [ASTERISK_VERSION="160"])
+
+ AC_ARG_WITH(ipp,
+ AS_HELP_STRING([--with-ipp=PATH], [Path to Intel IPP (/path/to/ipp)]),
+diff --git a/unsupported/g72x-build.sh b/unsupported/g72x-build.sh
+index e233933..1e16fec 100755
+--- a/unsupported/g72x-build.sh
++++ b/unsupported/g72x-build.sh
+@@ -180,7 +180,7 @@ mkdir -p bin/
+
+ a=ast150
+ ast=/opt/asterisk
+-def2=-DG72X_ASTERISK=150
++def2=-DG72X_ASTERISK=160
+ codec=g729 dir=$srcdir all &
+ codec=g723 dir=$srcdir all &
+