Subject: Re: [bug#40264] Linphone: 12-add-belle-sip-v2

From: Maxim Cournoyer <[email-masked]>
Date: Sat, 04 Apr 2020 13:36:32 -0400

Hello Danny and Raghav,

Danny Milosavljevic <[email-masked]> writes:

> Hi Raghav,
>
> On Thu, 02 Apr 2020 17:19:29 +0000
> "Raghav Gururajan" <[email-masked]> wrote:
>
>> I suspect it could be due to having two different definitions for bctoolbox and ortp. Could you try belle-sip after applying the patch http://debbugs.gnu.org/cgi/bugreport.cgi?bug=40326
>
> I tried and it didn't help.
>
> However, I found and fixed the problem:
>
> From 1f847861de4ab73011d6243fb652f098e16106cb Mon Sep 17 00:00:00 2001
> From: Raghav Gururajan <[email-masked]>
> Date: Wed, 1 Apr 2020 20:42:33 -0400
> Subject: [FIXME 2/2] gnu: Add belle-sip.
> Tags: patch
>
> * gnu/packages/linphone.scm (belle-sip): New variable.
>
> Signed-off-by: Danny Milosavljevic <[email-masked]>
> ---
>  gnu/packages/linphone.scm | 42 +++++++++++++++++++++++++++++++++++++++
>  1 file changed, 42 insertions(+)
>
> diff --git a/gnu/packages/linphone.scm b/gnu/packages/linphone.scm
> index 18a11776e8..9cbbd5e7d6 100644
> --- a/gnu/packages/linphone.scm
> +++ b/gnu/packages/linphone.scm
> @@ -22,11 +22,13 @@
>    #:use-module (gnu packages admin)
>    #:use-module (gnu packages audio)
>    #:use-module (gnu packages base)
> +  #:use-module (gnu packages compression)
>    #:use-module (gnu packages documentation)
>    #:use-module (gnu packages gl)
>    #:use-module (gnu packages gnome)
>    #:use-module (gnu packages graphviz)
>    #:use-module (gnu packages image)
> +  #:use-module (gnu packages java)
>    #:use-module (gnu packages linux)
>    #:use-module (gnu packages pulseaudio)
>    #:use-module (gnu packages python)
> @@ -335,3 +337,43 @@ is responsible for receiving and sending all multimedia streams in Linphone,
>  including media capture, encoding and decoding, and rendering.")
>      (home-page "https://gitlab.linphone.org/BC/public/mediastreamer2")
>      (license license:gpl2+)))
> +
> +(define-public belle-sip
> +  (package
> +    (name "belle-sip")
> +    (version "1.6.3")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri
> +        (string-append "https://www.linphone.org/releases/sources/" name
> +                       "/" name "-" version ".tar.gz"))
> +       (sha256
> +        (base32 "0s55kggmgxap54dkw5856bgk4xg7yvbzialpxnjm0zhpic3hff1z"))))
> +    (build-system cmake-build-system)
> +    (arguments
> +     `(#:tests? #f                      ; Requires network access
> +       #:configure-flags
> +       (list
> +        "-DENABLE_STATIC=NO")
> +       #:phases
> +       (modify-phases %standard-phases
> +         (add-after 'unpack 'patch
> +           (lambda _
> +             (substitute* "src/CMakeLists.txt"
> +              ;; ANTLR would use multithreaded DFA generation
> +              ;; otherwise--which would not be reproducible.
> +              (("-Xmultithreaded ") ""))
> +             #t)))))

Nice find!  Although note that this doesn't exist in the latest code,
and that the latest release is nearly 3 years old (2017-07-21).  Perhaps
we should just try to package the latest master?  Their git history
suggests many bug fixes, including a memory leak.

Maxim