diff mbox series

[bug#47274] Linphone Packages

Message ID 66991ebb-4074-efab-4331-1ed195d55d26@raghavgururajan.name
State Accepted
Headers show
Series [bug#47274] Linphone Packages | expand

Checks

Context Check Description
cbaines/applying patch fail View Laminar job
cbaines/issue success View issue

Commit Message

Raghav Gururajan March 22, 2021, 1:48 a.m. UTC
Hello Guix!

Please find the attached patch-set, which contains modifications in 
0046-gnu-linphoneqt-Update-to-4.2.5.patch w.r.t to previous patch-set.

HELP! The app crashes upon launch.

I tried creating symlink "{out}/lib" --> "{liblinphone}/lib", which 
didn't work.

Regards,
RG.

Comments

Maxim Cournoyer March 25, 2021, 1:55 a.m. UTC | #1
Hi,

Raghav Gururajan <rg@raghavgururajan.name> writes:

> * gnu/packages/linphone.scm (bctoolbox) [arguments]<#:phases>['patch-source]: Modify.
> [inputs]: Add libdecaf.
> ---
>  gnu/packages/linphone.scm | 13 ++++++++++++-
>  1 file changed, 12 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/linphone.scm b/gnu/packages/linphone.scm
> index 9d54b1b874..1a83105334 100644
> --- a/gnu/packages/linphone.scm
> +++ b/gnu/packages/linphone.scm
> @@ -25,6 +25,7 @@
>    #:use-module (gnu packages audio)
>    #:use-module (gnu packages base)
>    #:use-module (gnu packages compression)
> +  #:use-module (gnu packages crypto)
>    #:use-module (gnu packages documentation)
>    #:use-module (gnu packages gettext)
>    #:use-module (gnu packages gl)
> @@ -151,7 +152,16 @@ administering, and running unit tests in C.")
>         #:phases
>         (modify-phases %standard-phases
>           (add-after 'unpack 'patch-source
> -           (lambda _
> +           (lambda* (#:key inputs #:allow-other-keys)
> +             ;; Fix decaf dependency.
> +             (let* ((decaf (assoc-ref inputs "decaf")))
> +               (substitute* (find-files "." "CMakeLists.txt")
> +                 (("find_package\\(Decaf CONFIG\\)")
> +                  "set(DECAF_FOUND 1)")
> +                 (("\\$\\{DECAF_INCLUDE_DIRS\\}")
> +                  (string-append decaf "/include/decaf"))
> +                 (("\\$\\{DECAF_TARGETNAME\\}")
> +                  "decaf")))
>               ;; Disable failing tests.
>               (substitute* "tester/port.c"
>                 (("[ \t]*TEST_NO_TAG\\(\"Addrinfo sort\", bctbx_addrinfo_sort_test\\)")
> @@ -164,6 +174,7 @@ administering, and running unit tests in C.")
>               #t)))))
>      (inputs
>       `(("bcunit" ,bcunit)
> +       ("decaf" ,libdecaf)
>         ("mbedtls" ,mbedtls-apache)))
>      (synopsis "Belledonne Communications Tool Box")
>      (description "BcToolBox is an utilities library used by Belledonne

I've squashed the 3 bctoolbox commits together, adjusted the commit
message as below:

gnu: bctoolbox: Update to 4.4.34 and enable libdecaf, tests.

* gnu/packages/linphone.scm (bctoolbox)[version]: Update to 4.4.34.
[source]: Switch to git repository.
[arguments]: Remove tests? argument, enabling tests.
[phases]{patch-source}: New phase.
{check}: Override phase.
[inputs]: Add libdecaf.
[license]: Update to GPLv3+.

Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>

1 file changed, 33 insertions(+), 10 deletions(-)
gnu/packages/linphone.scm | 43 +++++++++++++++++++++++++++++++++----------

modified   gnu/packages/linphone.scm
@@ -25,6 +25,7 @@
   #:use-module (gnu packages audio)
   #:use-module (gnu packages base)
   #:use-module (gnu packages compression)
+  #:use-module (gnu packages crypto)
   #:use-module (gnu packages documentation)
   #:use-module (gnu packages gettext)
   #:use-module (gnu packages gl)
@@ -127,28 +128,50 @@ writing, administering, and running unit tests in C.")
 (define-public bctoolbox
   (package
     (name "bctoolbox")
-    (version "0.6.0")
+    (version "4.4.34")
     (source
      (origin
-       (method url-fetch)
-       (uri
-        (string-append "https://www.linphone.org/releases/sources/" name
-                       "/" name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://gitlab.linphone.org/BC/public/bctoolbox.git")
+             (commit version)))

Used their HTTPS GitLab git here as its browsable;

+       (file-name (git-file-name name version))
        (sha256
-        (base32 "1a1i70pb4hhnykkwyhhc7fv67q556l8kprny8xzgfqpj1nby2ms6"))))
+        (base32 "0bfswwvvdshaahg4jd2j10f0sci8809s4khajd0m6b059zwc7y25"))))
     (build-system cmake-build-system)
     (arguments
-     '(#:tests? #f                      ; No test target
-       #:configure-flags
-       (list "-DENABLE_STATIC=OFF")))   ; Not required
+     `(#:configure-flags '("-DENABLE_STATIC=OFF")
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-source
+           (lambda* (#:key inputs #:allow-other-keys)
+             ;; Fix decaf dependency (see:
+             ;; https://gitlab.linphone.org/BC/public/bctoolbox/-/issues/3).

Added an issue upstream for the problem worked around here.

+             (let* ((decaf (assoc-ref inputs "decaf")))
+               (substitute* (find-files "." "CMakeLists.txt")
+                 (("find_package\\(Decaf CONFIG\\)")
+                  "set(DECAF_FOUND 1)")
+                 (("\\$\\{DECAF_INCLUDE_DIRS\\}")
+                  (string-append decaf "/include/decaf"))
+                 (("\\$\\{DECAF_TARGETNAME\\}")
+                  "decaf")))
+             ;; The following test relies on networking; disable it.

Mentioned this had to do with networking, which is inherent to the
absence of networking in the Guix build container (otherwise it'd had
been good to report the test failure upstream).

+             (substitute* "tester/port.c"
+               (("[ \t]*TEST_NO_TAG.*bctbx_addrinfo_sort_test\\)")

Used .* to shorten the line below 80 chars ;-)

+                ""))))
+         (replace 'check
+           (lambda _
+             (with-directory-excursion "tester"
+               (invoke "./bctoolbox_tester")))))))
     (inputs
      `(("bcunit" ,bcunit)
+       ("decaf" ,libdecaf)
        ("mbedtls" ,mbedtls-apache)))
     (synopsis "Belledonne Communications Tool Box")
     (description "BcToolBox is an utilities library used by Belledonne
 Communications software like belle-sip, mediastreamer2 and linphone.")
     (home-page "https://gitlab.linphone.org/BC/public/bctoolbox")
-    (license license:gpl2+)))
+    (license license:gpl3+)))
 
Can't be pushed yet as it breaks stuff.

Maxim
Maxim Cournoyer March 28, 2021, 4:01 a.m. UTC | #2
Hi!

Raghav Gururajan <rg@raghavgururajan.name> writes:

> [39. text/x-patch; 0038-gnu-Add-build.patch]...

I had an old package of build from 2020 with a more fleshed out
description, so I've pushed that version instead as commit 65719505b8.

> From c6e27b74e1f90985513167b52cd0e0f9cc54aa73 Mon Sep 17 00:00:00 2001
> From: Raghav Gururajan <rg@raghavgururajan.name>
> Date: Thu, 18 Mar 2021 13:57:53 -0400
> Subject: [PATCH 39/53] gnu: Add libcutl.
>
> * gnu/packages/codesynthesis.scm (libcutl): New variable.
> ---
>  gnu/packages/codesynthesis.scm | 44 ++++++++++++++++++++++++++++++++++
>  1 file changed, 44 insertions(+)
>
> diff --git a/gnu/packages/codesynthesis.scm b/gnu/packages/codesynthesis.scm
> index 7cb9a427a5..a264692c19 100644
> --- a/gnu/packages/codesynthesis.scm
> +++ b/gnu/packages/codesynthesis.scm
> @@ -19,6 +19,8 @@
>
>  (define-module (gnu packages codesynthesis)
>    #:use-module (gnu packages)
> +  #:use-module (gnu packages pkg-config)

pkg-config turned out not to be needed.

> +  #:use-module (gnu packages xml)
>    #:use-module ((guix licenses) #:prefix license:)
>    #:use-module (guix packages)
>    #:use-module (guix download)
> @@ -53,3 +55,45 @@
>  implemented on top of GNU make.")
>      (home-page "https://www.codesynthesis.com/projects/libxsd-frontend/")
>      (license license:gpl2+)))
> +
> +(define-public libcutl
> +  (package
> +    (name "libcutl")
> +    (version "1.10.0")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (string-append "https://www.codesynthesis.com/download/libcutl/"
> +                           (version-major+minor version)
> +                           "/libcutl-" version ".tar.bz2"))
> +       (sha256
> +        (base32 "070j2x02m4gm1fn7gnymrkbdxflgzxwl7m96aryv8wp3f3366l8j"))
> +       (modules '((guix build utils)))
> +       (snippet
> +        `(begin
> +           ;; Remove bundled sources.
> +           (with-directory-excursion "cutl/details"
> +             (for-each delete-file-recursively
> +                       ;; FIXME: Boost_RegEx isn't being detected.
> +                       (list
> +                        ;; "boost"
> +                        "expat")))
> +           #t))))

I removed the trailing #t.

> +    (build-system gnu-build-system)
> +    (arguments
> +     `(#:configure-flags
> +       (list
> +        "--disable-static"
> +        ;; "--with-external-boost"
> +        "--with-external-expat")))
> +    (native-inputs
> +     `(("pkg-config" ,pkg-config)))

Removed the native-inputs field.

> +    (inputs
> +     `(;; ("boost" ,boost)
> +       ("expat" ,expat)))
> +    (synopsis "C++ utility library")
> +    (description "@package{libcutl} is a C++ utility library.  It contains a
> +collection of generic and independent components such as meta-programming tests,
> +smart pointers, containers, compiler building blocks, etc.")
> +    (home-page "https://www.codesynthesis.com/projects/libcutl/")
> +    (license license:expat)))
> --
> 2.31.0

And pushed as ae479f1834.

> From e3abe6dbfcbd6bfb352694fd5efcb9db9da6dce6 Mon Sep 17 00:00:00 2001
> From: Raghav Gururajan <rg@raghavgururajan.name>
> Date: Thu, 18 Mar 2021 14:00:13 -0400
> Subject: [PATCH 40/53] gnu: Add libxsd-frontend.
>
> * gnu/packages/codesynthesis.scm (libxsd-frontend): New variable.
> ---
>  gnu/packages/codesynthesis.scm | 54 ++++++++++++++++++++++++++++++++++
>  1 file changed, 54 insertions(+)
>
> diff --git a/gnu/packages/codesynthesis.scm b/gnu/packages/codesynthesis.scm
> index a264692c19..f24fb760de 100644
> --- a/gnu/packages/codesynthesis.scm
> +++ b/gnu/packages/codesynthesis.scm
> @@ -97,3 +97,57 @@ collection of generic and independent components such as meta-programming tests,
>  smart pointers, containers, compiler building blocks, etc.")
>      (home-page "https://www.codesynthesis.com/projects/libcutl/")
>      (license license:expat)))
> +
> +(define-public libxsd-frontend
> +  (package
> +    (name "libxsd-frontend")
> +    (version "2.0.0")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (string-append "https://www.codesynthesis.com/download/"
> +                           "libxsd-frontend/" (version-major+minor version)
> +                           "/libxsd-frontend-" version ".tar.bz2"))
> +       (sha256
> +        (base32 "1nmzchsvwvn66jpmcx18anzyl1a3l309x1ld4zllrg37ijc31fim"))))
> +    (build-system gnu-build-system)
> +    (arguments
> +     `(#:test-target "test"
> +       #:imported-modules
> +       ((guix build copy-build-system)
> +        ,@%gnu-build-system-modules)
> +       #:modules
> +       (((guix build copy-build-system)
> +         #:prefix copy:)
> +        (guix build gnu-build-system)
> +        (guix build utils))
> +       #:phases
> +       (modify-phases %standard-phases
> +         (add-after 'unpack 'patch
> +           (lambda _
> +             (substitute* (find-files "." "\\.make$")
> +               (("build-0\\.3")
> +                (string-append (assoc-ref %build-inputs "build") "/include/build-0.3")))
> +             #t))

I could turn this patch phase into a make flag:

--8<---------------cut here---------------start------------->8---
        #:modules (((guix build copy-build-system) #:prefix copy:)
                   (guix build gnu-build-system)
                   (guix build utils))
+       #:make-flags (list (string-append "--include-dir="
+                                         (assoc-ref %build-inputs "build")
+                                         "/include/"))
        #:phases
        (modify-phases %standard-phases
-         (add-after 'unpack 'patch
-           (lambda _
-             (substitute* (find-files "." "\\.make$")
-               (("build-0\\.3")
-                (string-append (assoc-ref %build-inputs "build")
-                               "/include/build-0.3")))))
          (delete 'configure)
          (replace 'install
--8<---------------cut here---------------end--------------->8---


> +         (delete 'configure)
> +         (replace 'install
> +           (lambda args
> +             (apply (assoc-ref copy:%standard-phases 'install)
> +                    #:install-plan
> +                    '(("xsd-frontend" "include/xsd-frontend"
> +                       #:include-regexp ("\\.?xx$"))
> +                      ("xsd-frontend" "lib"
> +                       #:include-regexp ("\\.so$")))
> +                    args))))))
> +    (native-inputs
> +     `(("build" ,build)
> +       ("pkg-config" ,pkg-config)))

Removed pkg-config, which was not needed.

> +    (inputs
> +     `(("libcutl" ,libcutl)
> +       ("libxerces-c" ,xerces-c)))
> +    (synopsis "XSD Front-end")
> +    (description "@package{libxsd-frontend} is a compiler frontend
> for the W3C

Replaced @package by @code, as the former is not valid Texinfo markup.

> +XML Schema definition language.  It includes a parser, semantic graph types and
> +a traversal mechanism.")
> +    (home-page "https://www.codesynthesis.com/projects/libxsd-frontend/")
> +    (license license:gpl2+)))
> --
> 2.31.0

And pushed as 111004cc58.

>
> From 2c1e262e549b928a624513e2c91b059b88b8e822 Mon Sep 17 00:00:00 2001
> From: Raghav Gururajan <rg@raghavgururajan.name>
> Date: Thu, 18 Mar 2021 14:33:34 -0400
> Subject: [PATCH 41/53] gnu: Add cli.
>
> * gnu/packages/codesynthesis.scm (cli): New variable.
> ---
>  gnu/packages/codesynthesis.scm | 45 ++++++++++++++++++++++++++++++++++
>  1 file changed, 45 insertions(+)
>
> diff --git a/gnu/packages/codesynthesis.scm b/gnu/packages/codesynthesis.scm
> index f24fb760de..b70e53cd7c 100644
> --- a/gnu/packages/codesynthesis.scm
> +++ b/gnu/packages/codesynthesis.scm
> @@ -151,3 +151,48 @@ XML Schema definition language.  It includes a parser, semantic graph types and
>  a traversal mechanism.")
>      (home-page "https://www.codesynthesis.com/projects/libxsd-frontend/")
>      (license license:gpl2+)))
> +
> +(define-public cli
> +  (package
> +    (name "cli")
> +    (version "1.1.0")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (string-append "https://www.codesynthesis.com/download/"
> +                           "cli/" (version-major+minor version)
> +                           "/cli-" version ".tar.bz2"))
> +       (sha256
> +        (base32 "0bg0nsai2q4h3mldpnj0jz4iy4svs0bcfvmq0v0c9cdyknny606g"))))
> +    (build-system gnu-build-system)
> +    (arguments
> +     `(#:test-target "test"
> +       #:make-flags
> +       (list
> +        (string-append "install_prefix=" (assoc-ref %outputs "out")))
> +       #:phases
> +       (modify-phases %standard-phases
> +         (add-after 'unpack 'patch
> +           (lambda _
> +             (substitute* (find-files "." "\\.make$")
> +               (("build-0\\.3")
> +                (string-append (assoc-ref %build-inputs "build")
> +                               "/include/build-0.3")))

I used the same --include-dir make flag trick here.

> +             (substitute* (find-files "." "\\.?xx$")
> +               (("add \\(typeid \\(type\\), \\*this\\);")
> +                "traverser_map<B>::add (typeid (type), *this);")
> +               (("iterate_and_dispatch \\(s\\.names_begin \\(\\), s\\.names_end \\(\\), d\\);")
> +                "edge_dispatcher::iterate_and_dispatch (s.names_begin (), s.names_end (), d);"))
> +             #t))

Dropped the #t, added a comment and added the prefix to the default
regexp group bound to 'all', like this:

+             ;; Add the namespace prefix, to avoid errors such as "error:
+             ;; ‘iterate_and_dispatch’ was not declared in this scope".
+             (substitute* (find-files "." "\\.?xx$")
+               (("add \\(typeid \\(type\\), \\*this\\);" all)
+                (string-append "traverser_map<B>::" all))
+               (("iterate_and_dispatch \\(s\\.names_begin.*;" all)
+                (string-append "edge_dispatcher::" all)))))

> +         (delete 'configure))))
> +    (native-inputs
> +     `(("build" ,build)
> +       ("pkg-config" ,pkg-config)))

Removed pkg-config, which was not needed.

> +    (inputs
> +     `(("libcutl" ,libcutl)))
> +    (synopsis "Command Line Interface (CLI) definition language")
> +    (description "@package{cli} is a domain-specific language (DSL)
> for defining

s/@package/@code/, as for the previous package.

> +command line interfaces of C++ programs.  It allows you to describe the options
> +that your program supports, their types, default values, and documentation.")
> +    (home-page "https://codesynthesis.com/projects/cli/")
> +    (license license:expat)))
> --
> 2.31.0

And pushed as commit f649a0a557.

>
> From d46ed1d4bd1d85ad5c89d2c713f387714f152358 Mon Sep 17 00:00:00 2001
> From: Raghav Gururajan <rg@raghavgururajan.name>
> Date: Thu, 18 Mar 2021 15:51:18 -0400
> Subject: [PATCH 42/53] gnu: Add xsd.
>
> * gnu/packages/codesynthesis.scm (xsd): New variable.
> ---
>  gnu/packages/codesynthesis.scm | 48 ++++++++++++++++++++++++++++++++++
>  1 file changed, 48 insertions(+)
>
> diff --git a/gnu/packages/codesynthesis.scm b/gnu/packages/codesynthesis.scm
> index b70e53cd7c..58f4fa9301 100644
> --- a/gnu/packages/codesynthesis.scm
> +++ b/gnu/packages/codesynthesis.scm
> @@ -19,6 +19,7 @@
>
>  (define-module (gnu packages codesynthesis)
>    #:use-module (gnu packages)
> +  #:use-module (gnu packages onc-rpc)
>    #:use-module (gnu packages pkg-config)
>    #:use-module (gnu packages xml)
>    #:use-module ((guix licenses) #:prefix license:)
> @@ -196,3 +197,50 @@ command line interfaces of C++ programs.  It allows you to describe the options
>  that your program supports, their types, default values, and documentation.")
>      (home-page "https://codesynthesis.com/projects/cli/")
>      (license license:expat)))
> +
> +(define-public xsd
> +  (package
> +    (name "xsd")
> +    (version "4.0.0")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (string-append "https://www.codesynthesis.com/download/"
> +                           "xsd/" (version-major+minor version)
> +                           "/xsd-" version ".tar.bz2"))
> +       (sha256
> +        (base32 "1hi9ppxd34np8ydv1h0vgc2qpdmgcd1cdzgk30aidv670xjg91fx"))))
> +    (build-system gnu-build-system)
> +    (arguments
> +     `(#:test-target "test"
> +       #:make-flags
> +       (list
> +        (string-append "install_prefix=" (assoc-ref %outputs "out")))
> +       #:phases
> +       (modify-phases %standard-phases
> +         (add-after 'unpack 'patch
> +           (lambda _
> +             (substitute* (find-files "." "\\.make$")
> +               (("build-0\\.3")
> +                (string-append (assoc-ref %build-inputs "build")
> +                               "/include/build-0.3")))
> +             #t))

I added a doc output to hold the multi-megabyte documentation and
examples and used the same make flag trick to allow finding build-0.3
files:

+    (outputs '("out" "doc"))            ;3.8 MiB of doc and examples
+    (arguments
+     `(#:test-target "test"
+       #:make-flags (list (string-append "--include-dir="
+                                         (assoc-ref %build-inputs "build")
+                                         "/include/")
+                          (string-append "install_prefix="
+                                         (assoc-ref %outputs "out")))
+       #:phases (modify-phases %standard-phases
+                  (add-after 'install 'move-doc
+                    (lambda* (#:key outputs #:allow-other-keys)
+                      (let ((out (assoc-ref outputs "out"))
+                            (doc (assoc-ref outputs "doc")))
+                        (mkdir-p (string-append doc "/share/doc"))
+                        (rename-file (string-append out "/share/doc/xsd")
+                                     (string-append doc "/share/doc/xsd-"
+                                                    ,version)))))
+                  (delete 'configure))))

> +         (delete 'configure))))
> +    (native-inputs
> +     `(("build" ,build)
> +       ("cli" ,cli)
> +       ("pkg-config" ,pkg-config)))

Dropped pkg-config here as well.

> +    (inputs
> +     `(("libcutl" ,libcutl)
> +       ("libnsl" ,libnsl)
> +       ("libxsd-frontend" ,libxsd-frontend)))
> +    (propagated-inputs
> +     `(("libexpat" ,expat)
> +       ("libxerces-c" ,xerces-c)))

I removed expat from propagated-inputs, as the xsd generated code
default to using xerces-c.  Someone wanting to use expat could add it
manually.  I've also added a comment like this, as it was not clear to
me initially why propagation was useful:

    (propagated-inputs
     ;; The code XSD generates requires the following library at run time;
     ;; propagate it for convenience.
     `(("xerces-c" ,xerces-c)))

> +    (synopsis "XML Schema to C++ translator")
> +    (description "@package{xsd} is a W3C XML Schema to C++ translator.  It
> +generates vocabulary-specific, statically-typed C++ mappings/bindings from XML
> +Schema definitions.  It supports two C++ mappings: in-memory C++/Tree and
> +event-driven C++/Parser.")
> +    (home-page "https://codesynthesis.com/projects/xsd/")
> +    (license license:gpl2+)))

For this package, I also had an unfinished version locally; the
description was slightly more accurate, with an extra comment for the
license:

+    (synopsis "XML Data Binding for C++")
+    (description "CodeSynthesis XSD (also known as libxsd or xsdcxx) is an XML
+Schema to C++ data binding compiler.  Provided with an XML instance
+specification (XML Schema), it generates C++ classes that represent the given
+vocabulary as well as XML parsing and serialization code.  The data stored in
+XML can then be accessed using types and functions that semantically
+correspond to an application domain rather than dealing with the intricacies
+of reading and writing XML.")
+    (home-page "https://codesynthesis.com/projects/xsd/")
+    ;; Exceptions are made to allow using the generated source files as well
+    ;; as the libxsd library in free software projects whose license is
+    ;; incompatible with the GPL v2.  Refer to the file named FLOSSE for the
+    ;; details.

So I've used those parts and pushed as commit 510e24f973.

Phew.  I've now reached the core bits of the review, to be continued.

Thanks :-)

Maxim
Raghav Gururajan March 29, 2021, 5:13 a.m. UTC | #3
Hi Maxim!

> I've squashed the 3 bctoolbox commits together, adjusted the commit
> message as below:

Thanks.

> Used their HTTPS GitLab git here as its browsable;

Okay. I prefer git://git.linphone.org, as it is generic and not tied to 
specific platform and will even work when upstream moves to another 
platform like gitea etc., but no big deal.

> Added an issue upstream for the problem worked around here.

Cool.

> Mentioned this had to do with networking, which is inherent to the
> absence of networking in the Guix build container (otherwise it'd had
> been good to report the test failure upstream).

Makes sense.

Regards,
RG.
Raghav Gururajan March 29, 2021, 6:01 a.m. UTC | #4
Hi Maxim!

> I had an old package of build from 2020 with a more fleshed out
> description, so I've pushed that version instead as commit 65719505b8.

Sounds good.

> pkg-config turned out not to be needed.
> 
> I removed the trailing #t.
> 
> Removed the native-inputs field.
> 
> And pushed as ae479f1834.
> 
> I could turn this patch phase into a make flag:
> 
> Removed pkg-config, which was not needed.
> 
> Replaced @package by @code, as the former is not valid Texinfo markup.
> 
> And pushed as 111004cc58.
> 
> I used the same --include-dir make flag trick here.
> 
> Removed pkg-config, which was not needed.
> 
> s/@package/@code/, as for the previous package.
> 
> And pushed as commit f649a0a557.
> 
> I added a doc output to hold the multi-megabyte documentation and
> examples and used the same make flag trick to allow finding build-0.3
> files:
> 
> Dropped pkg-config here as well.
> 
> I removed expat from propagated-inputs, as the xsd generated code
> default to using xerces-c.  Someone wanting to use expat could add it
> manually.  I've also added a comment like this, as it was not clear to
> me initially why propagation was useful:

Thanks a lot for making the changes.

> For this package, I also had an unfinished version locally; the
> description was slightly more accurate, with an extra comment for the
> license:

Sounds good.

Regards,
RG.
diff mbox series

Patch

From badbc3847d58c36525539b263ed9197265e94c62 Mon Sep 17 00:00:00 2001
From: Raghav Gururajan <rg@raghavgururajan.name>
Date: Sat, 20 Mar 2021 00:01:26 -0400
Subject: [PATCH 53/53] gnu: msamr: Update to 1.1.3-11.

* gnu/packages/linphone.scm (msamr) [source]: Switch to git repository.
[version]: Update to 1.1.3-11.
[inputs]: Add bctoolbox.
---
 gnu/packages/linphone.scm | 56 +++++++++++++++++++++------------------
 1 file changed, 30 insertions(+), 26 deletions(-)

diff --git a/gnu/packages/linphone.scm b/gnu/packages/linphone.scm
index 4fdf4c0125..e0aabbf7a0 100644
--- a/gnu/packages/linphone.scm
+++ b/gnu/packages/linphone.scm
@@ -1014,30 +1014,34 @@  WebRTC codec.  It includes features from WebRTC, such as, iSAC and AECM.")
       (license license:gpl2+))))
 
 (define-public msamr
-  (package
-    (name "msamr")
-    (version "1.1.3")
-    (source
-     (origin
-       (method url-fetch)
-       (uri
-        (string-append "https://www.linphone.org/releases/sources/plugins/"
-                       name "/" name "-" version ".tar.gz"))
-       (sha256
-        (base32 "16c9f3z4wnj73k7y8gb0fgpr4axsm7b5zrbjvy8vsgz9gyg3agm5"))))
-    (build-system cmake-build-system)
-    (arguments
-     `(#:tests? #f                      ; No test target
-       #:configure-flags
-       (list "-DENABLE_STATIC=NO"       ; Not required
-             "-DENABLE_WIDEBAND=YES")))
-    (inputs
-     `(("mediastreamer2" ,mediastreamer2)
-       ("opencoreamr" ,opencore-amr)
-       ("ortp" ,ortp)
-       ("voamrwbenc" ,vo-amrwbenc)))
-    (synopsis "Media Streamer AMR Codec")
-    (description "MSAMR is a plugin of MediaStreamer, adding support for AMR
+  (let ((commit "5ab5c098299107048dfcbfc741f7392faef167bd")
+        (revision "11"))
+    (package
+      (name "msamr")
+      (version (git-version "1.1.3" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "git://git.linphone.org/msamr")
+               (commit commit)))
+         (file-name (git-file-name name version))
+         (sha256
+          (base32 "1g79lw1qi1mlw3v1b0cixmqiwjql81gz9naakb15n8pvaag9aaqm"))))
+      (build-system cmake-build-system)
+      (arguments
+       `(#:tests? #f                    ; No test target
+         #:configure-flags
+         (list "-DENABLE_STATIC=NO"     ; Not required
+               "-DENABLE_WIDEBAND=YES")))
+      (inputs
+       `(("bctoolbox" ,bctoolbox)
+         ("mediastreamer2" ,mediastreamer2)
+         ("opencoreamr" ,opencore-amr)
+         ("ortp" ,ortp)
+         ("voamrwbenc" ,vo-amrwbenc)))
+      (synopsis "Media Streamer AMR Codec")
+      (description "MSAMR is a plugin of MediaStreamer, adding support for AMR
 codec.  It is based on the opencore-amr implementation.")
-    (home-page "https://gitlab.linphone.org/BC/public/msamr")
-    (license license:gpl3+)))
+      (home-page "https://gitlab.linphone.org/BC/public/msamr")
+      (license license:gpl3+))))
-- 
2.31.0