FreeBSD Bugzilla – Attachment 249297 Details for
Bug 277802
net/yate: convert AMR codec to opencore one
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
experiment patch for net/yate
patch.diff (text/plain), 4.41 KB, created by
Tatsuki Makino
on 2024-03-19 07:20:27 UTC
(
hide
)
Description:
experiment patch for net/yate
Filename:
MIME Type:
Creator:
Tatsuki Makino
Created:
2024-03-19 07:20:27 UTC
Size:
4.41 KB
patch
obsolete
>diff --git a/net/yate/Makefile b/net/yate/Makefile >index 26d4d2e7020..a7885f4263e 100644 >--- a/net/yate/Makefile >+++ b/net/yate/Makefile >@@ -43,10 +43,9 @@ USERS= yate > GROUPS= yate > DOCSDIR= ${PREFIX}/share/doc/${PORTNAME}-${PORTVERSION} > >-OPTIONS_DEFINE= AMRNB DOCS DAHDI H323 ILBC MYSQL PGSQL SCTP SPANDSP SQLITE >+OPTIONS_DEFINE= AMR DOCS DAHDI H323 ILBC MYSQL PGSQL SCTP SPANDSP SQLITE > OPTIONS_DEFAULT=SCTP > >-AMRNB_DESC= Adaptive Multi-Rate Narrowband support > DAHDI_DESC= Dahdi support > H323_DESC= H323 software channel/protocol support > ILBC_DESC= iLBC narrowband speech codec support >@@ -54,8 +53,8 @@ SCTP_DESC= Stream Control Transmission Protocol support > > OPTIONS_SUB= yes > >-AMRNB_CONFIGURE_WITH= amrnb=${LOCALBASE} >-AMRNB_LIB_DEPENDS= libamrnb.so:audio/libamrnb >+AMR_CONFIGURE_WITH= amrnb=${LOCALBASE} >+AMR_LIB_DEPENDS= libopencore-amrnb.so:audio/opencore-amr > > DAHDI_CONFIGURE_ENABLE= dahdi > DAHDI_BUILD_DEPENDS= libpri>=1.4.10:misc/libpri \ >diff --git a/net/yate/files/patch-configure.ac b/net/yate/files/patch-configure.ac >index aac4c2fa90a..4eea839d496 100644 >--- a/net/yate/files/patch-configure.ac >+++ b/net/yate/files/patch-configure.ac >@@ -1,6 +1,6 @@ >---- configure.ac.orig 2018-04-05 08:59:36 UTC >+--- configure.ac.orig 2021-08-02 12:25:49 UTC > +++ configure.ac >-@@ -109,7 +109,8 @@ if [[ "x$ac_cv_no_overload_virt" = "xyes >+@@ -109,7 +109,8 @@ if [[ "x$ac_cv_no_overload_virt" = "xyes" ]]; then > fi > AC_MSG_RESULT([$ac_cv_no_overload_virt]) > >@@ -10,3 +10,25 @@ > ld_unresolved_symbols=no > AC_MSG_CHECKING([if ld supports reporting unresolved symbols]) > SAVE_CFLAGS="$CFLAGS" >+@@ -1181,7 +1182,7 @@ AC_SUBST(SPEEX_LIB) >+ >+ HAVE_AMRNB=no >+ AMRNB_INC="" >+-AMRNB_LIB="-lamrnb" >++AMRNB_LIB="-lopencore-amrnb" >+ AC_ARG_WITH(amrnb,AC_HELP_STRING([--with-amrnb=DIR],[use AMR-NB if available (default)]),[ac_cv_use_amrnb=$withval],[ac_cv_use_amrnb=/usr]) >+ if [[ "x$ac_cv_use_amrnb" = "xstatic" ]]; then >+ ac_cv_use_amrnb=/usr >+@@ -1190,9 +1191,9 @@ fi >+ if [[ "x$ac_cv_use_amrnb" != "xno" ]]; then >+ AC_MSG_CHECKING([for AMR-NB in $ac_cv_use_amrnb]) >+ local_lib="$ARCHLIB" >+-amrinc="$ac_cv_use_amrnb/include/amrnb" >+-test -f "$ac_cv_use_amrnb/$local_lib/libamrnb.so" || local_lib="lib" >+-if [[ -f "$ac_cv_use_amrnb/$local_lib/libamrnb.so" -a -f "$amrinc/interf_rom.h" ]]; then >++amrinc="$ac_cv_use_amrnb/include/opencore-amrnb" >++test -f "$ac_cv_use_amrnb/$local_lib/libopencore-amrnb.so" || local_lib="lib" >++if [[ -f "$ac_cv_use_amrnb/$local_lib/libopencore-amrnb.so" -a -f "$amrinc/interf_enc.h" ]]; then >+ HAVE_AMRNB=yes >+ AMRNB_LIB="-L$ac_cv_use_amrnb/$local_lib $AMRNB_LIB" >+ AMRNB_INC="-I$amrinc" >diff --git a/net/yate/files/patch-modules_amrnbcodec.cpp b/net/yate/files/patch-modules_amrnbcodec.cpp >new file mode 100644 >index 00000000000..f0ac4587c3b >--- /dev/null >+++ b/net/yate/files/patch-modules_amrnbcodec.cpp >@@ -0,0 +1,23 @@ >+--- modules/amrnbcodec.cpp.orig 2017-08-14 12:53:31 UTC >++++ modules/amrnbcodec.cpp >+@@ -30,7 +30,19 @@ extern "C" { >+ } >+ namespace RxTypes { >+ // There is a conflict between encoder and decoder so insulate in a namespace >+-#include <sp_dec.h> >++extern "C" { >++ // copied from ${WRKSRC}/opencore/codecs_v2/audio/gsm_amr/amr_nb/common/include/frame.h of audio/opencore-amr >++ enum RXFrameType { RX_SPEECH_GOOD = 0, >++ RX_SPEECH_DEGRADED, >++ RX_ONSET, >++ RX_SPEECH_BAD, >++ RX_SID_FIRST, >++ RX_SID_UPDATE, >++ RX_SID_BAD, >++ RX_NO_DATA, >++ RX_N_FRAMETYPES /* number of frame types */ >++ }; >++} >+ }; >+ >+ // IF1/GP3 is Bandwidth-Efficient Mode >diff --git a/net/yate/files/patch-modules_efrcodec.cpp b/net/yate/files/patch-modules_efrcodec.cpp >new file mode 100644 >index 00000000000..f5865f06c20 >--- /dev/null >+++ b/net/yate/files/patch-modules_efrcodec.cpp >@@ -0,0 +1,23 @@ >+--- modules/efrcodec.cpp.orig 2017-03-28 09:13:48 UTC >++++ modules/efrcodec.cpp >+@@ -31,7 +31,19 @@ extern "C" { >+ } >+ namespace RxTypes { >+ // There is a conflict between encoder and decoder so insulate in a namespace >+-#include <sp_dec.h> >++extern "C" { >++ // copied from ${WRKSRC}/opencore/codecs_v2/audio/gsm_amr/amr_nb/common/include/frame.h of audio/opencore-amr >++ enum RXFrameType { RX_SPEECH_GOOD = 0, >++ RX_SPEECH_DEGRADED, >++ RX_ONSET, >++ RX_SPEECH_BAD, >++ RX_SID_FIRST, >++ RX_SID_UPDATE, >++ RX_SID_BAD, >++ RX_NO_DATA, >++ RX_N_FRAMETYPES /* number of frame types */ >++ }; >++} >+ }; >+ >+ using namespace TelEngine;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 277802
:
249297
|
250843