[38/49,v2] package/libpjsip: add option to enable G.711 codec

Message ID 528297671d94a208c1c5a18e1bb34895347da626.1504993178.git.yann.morin.1998@free.fr
State Changes Requested
Headers show
Series
  • [01/49,v2] package/asterisk: new package
Related show

Commit Message

Yann E. MORIN Sept. 9, 2017, 9:39 p.m.
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
---
 package/libpjsip/Config.in   | 3 +++
 package/libpjsip/libpjsip.mk | 5 ++++-
 2 files changed, 7 insertions(+), 1 deletion(-)

Comments

Arnout Vandecappelle Sept. 23, 2017, 5:06 p.m. | #1
On 09-09-17 23:39, Yann E. MORIN wrote:
> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
> ---
>  package/libpjsip/Config.in   | 3 +++
>  package/libpjsip/libpjsip.mk | 5 ++++-
>  2 files changed, 7 insertions(+), 1 deletion(-)
> 
> diff --git a/package/libpjsip/Config.in b/package/libpjsip/Config.in
> index 0bb446e9d9..1c9d2ce900 100644
> --- a/package/libpjsip/Config.in
> +++ b/package/libpjsip/Config.in
> @@ -12,6 +12,9 @@ config BR2_PACKAGE_LIBPJSIP
>  
>  if BR2_PACKAGE_LIBPJSIP
>  
> +config BR2_PACKAGE_LIBPJSIP_CODEC_G711
> +	bool "G.711 codec"

 I believe this codec (and the other ones as well) is rather small. Is there any
reason to make it optional?

 Regards,
 Arnout

> +
>  config BR2_PACKAGE_LIBPJSIP_CODEC_GSM
>      bool "GSM codec"
>      depends on !BR2_STATIC_LIBS # libgsm
> diff --git a/package/libpjsip/libpjsip.mk b/package/libpjsip/libpjsip.mk
> index 1259a292e4..10016fa732 100644
> --- a/package/libpjsip/libpjsip.mk
> +++ b/package/libpjsip/libpjsip.mk
> @@ -37,7 +37,6 @@ LIBPJSIP_CONF_OPTS = \
>  	--disable-ext-sound \
>  	--disable-small-filter \
>  	--disable-large-filter \
> -	--disable-g711-codec \
>  	--disable-l16-codec \
>  	--disable-g722-codec \
>  	--disable-libsamplerate \
> @@ -73,6 +72,10 @@ endif
>  # and we do not explictly enable it, so we get the configure log in
>  # both cases.
>  
> +ifneq ($(BR2_PACKAGE_LIBPJSIP_CODEC_G711),y)
> +LIBPJSIP_CONF_OPTS += --disable-g711-codec
> +endif
> +
>  ifeq ($(BR2_PACKAGE_LIBPJSIP_CODEC_GSM),y)
>  LIBPJSIP_DEPENDENCIES += libgsm
>  LIBPJSIP_CONF_OPTS += --with-external-gsm
>
Yann E. MORIN Sept. 25, 2017, 4:20 p.m. | #2
Arnout, All,

On 2017-09-23 19:06 +0200, Arnout Vandecappelle spake thusly:
> On 09-09-17 23:39, Yann E. MORIN wrote:
> > Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
> > ---
> >  package/libpjsip/Config.in   | 3 +++
> >  package/libpjsip/libpjsip.mk | 5 ++++-
> >  2 files changed, 7 insertions(+), 1 deletion(-)
> > 
> > diff --git a/package/libpjsip/Config.in b/package/libpjsip/Config.in
> > index 0bb446e9d9..1c9d2ce900 100644
> > --- a/package/libpjsip/Config.in
> > +++ b/package/libpjsip/Config.in
> > @@ -12,6 +12,9 @@ config BR2_PACKAGE_LIBPJSIP
> >  
> >  if BR2_PACKAGE_LIBPJSIP
> >  
> > +config BR2_PACKAGE_LIBPJSIP_CODEC_G711
> > +	bool "G.711 codec"
> 
>  I believe this codec (and the other ones as well) is rather small. Is there any
> reason to make it optional?

Please see my reply to your comment on adding the GSM codec.

Regards,
Yann E. MORIN.

Patch

diff --git a/package/libpjsip/Config.in b/package/libpjsip/Config.in
index 0bb446e9d9..1c9d2ce900 100644
--- a/package/libpjsip/Config.in
+++ b/package/libpjsip/Config.in
@@ -12,6 +12,9 @@  config BR2_PACKAGE_LIBPJSIP
 
 if BR2_PACKAGE_LIBPJSIP
 
+config BR2_PACKAGE_LIBPJSIP_CODEC_G711
+	bool "G.711 codec"
+
 config BR2_PACKAGE_LIBPJSIP_CODEC_GSM
     bool "GSM codec"
     depends on !BR2_STATIC_LIBS # libgsm
diff --git a/package/libpjsip/libpjsip.mk b/package/libpjsip/libpjsip.mk
index 1259a292e4..10016fa732 100644
--- a/package/libpjsip/libpjsip.mk
+++ b/package/libpjsip/libpjsip.mk
@@ -37,7 +37,6 @@  LIBPJSIP_CONF_OPTS = \
 	--disable-ext-sound \
 	--disable-small-filter \
 	--disable-large-filter \
-	--disable-g711-codec \
 	--disable-l16-codec \
 	--disable-g722-codec \
 	--disable-libsamplerate \
@@ -73,6 +72,10 @@  endif
 # and we do not explictly enable it, so we get the configure log in
 # both cases.
 
+ifneq ($(BR2_PACKAGE_LIBPJSIP_CODEC_G711),y)
+LIBPJSIP_CONF_OPTS += --disable-g711-codec
+endif
+
 ifeq ($(BR2_PACKAGE_LIBPJSIP_CODEC_GSM),y)
 LIBPJSIP_DEPENDENCIES += libgsm
 LIBPJSIP_CONF_OPTS += --with-external-gsm