diff options
| author | SilverlightningY <reband.florian@googlemail.com> | 2026-05-04 19:20:23 +0200 |
|---|---|---|
| committer | Andreas Enge <andreas@enge.fr> | 2026-06-27 12:03:15 +0200 |
| commit | 123cbe6f6e5b1bbd9893392c9c2aca269213f8a9 (patch) | |
| tree | 953d7010c104225b3f763c10a683bf186cc8b67a | |
| parent | 9c74a2501373e14a0f85449f287f97eba725630a (diff) | |
gnu: opus-tools: Fix cross compilation issue.
* gnu/packages/xiph.scm (opus-tools): Fix cross compilation issue.
Reformat.
[source]: Switch to git-fetch.
[arguments]: Inherit from libopusenc.
{#:configure-flags}: Override pkg-config detection.
Change-Id: I9e5748bfab3a77450584e9d9b69511704265f95f
Signed-off-by: Gabriel Wicki <gabriel@erlikon.ch>
| -rw-r--r-- | gnu/packages/xiph.scm | 39 |
1 files changed, 18 insertions, 21 deletions
diff --git a/gnu/packages/xiph.scm b/gnu/packages/xiph.scm index e37d35f6d99..fa2640b917a 100644 --- a/gnu/packages/xiph.scm +++ b/gnu/packages/xiph.scm | |||
| @@ -396,31 +396,28 @@ incorporated technology from Skype's SILK codec and Xiph.Org's CELT codec.") | |||
| 396 | (package | 396 | (package |
| 397 | (name "opus-tools") | 397 | (name "opus-tools") |
| 398 | (version "0.2") | 398 | (version "0.2") |
| 399 | (source (origin | 399 | (source |
| 400 | (method url-fetch) | 400 | (origin |
| 401 | (uri (string-append | 401 | (method git-fetch) |
| 402 | "https://downloads.xiph.org/releases/opus/opus-tools-" | 402 | (uri (git-reference |
| 403 | version ".tar.gz")) | 403 | (url "https://gitlab.xiph.org/xiph/opus-tools.git") |
| 404 | (sha256 | 404 | (commit (string-append "v" version)))) |
| 405 | (base32 | 405 | (sha256 |
| 406 | "11pzl27s4vcz4m18ch72nivbhww2zmzn56wspb7rll1y1nq6rrdl")))) | 406 | (base32 "1g1lrhi0jqk9i9pxmay8jhmy4zhaffbqh2rjhxkacildzl6xrvyz")) |
| 407 | (file-name (git-file-name name version)))) | ||
| 407 | (build-system gnu-build-system) | 408 | (build-system gnu-build-system) |
| 408 | (arguments | 409 | (arguments |
| 409 | ;; The package developers misuse pkg-config such that it doesn't work | 410 | (substitute-keyword-arguments (package-arguments libopusenc) |
| 410 | ;; when cross compiling. Therefore we avoid it completely and set the | 411 | ((#:configure-flags configure-flags) |
| 411 | ;; necessary flags ourselves. | 412 | ;; The mechanism for detecting pkg-config does not work while cross |
| 412 | `(#:configure-flags (list (string-append "CFLAGS=-I" | 413 | ;; compiling. Therefore we skip the test by overriding it. |
| 413 | (assoc-ref %build-inputs "libogg") | 414 | #~(list "HAVE_PKG_CONFIG=yes")))) |
| 414 | "/include -I" | 415 | (native-inputs (list autoconf automake libtool pkg-config)) |
| 415 | (assoc-ref %build-inputs "opus") | 416 | (inputs (list flac libopusenc opusfile)) |
| 416 | "/include/opus")))) | ||
| 417 | (native-inputs | ||
| 418 | (list pkg-config)) | ||
| 419 | (inputs | ||
| 420 | (list libopusenc opusfile flac)) | ||
| 421 | (synopsis | 417 | (synopsis |
| 422 | "Command line utilities to encode, inspect, and decode .opus files") | 418 | "Command line utilities to encode, inspect, and decode .opus files") |
| 423 | (description "Opus is a royalty-free, highly versatile audio codec. | 419 | (description |
| 420 | "Opus is a royalty-free, highly versatile audio codec. | ||
| 424 | Opus-tools provide command line utilities for creating, inspecting and | 421 | Opus-tools provide command line utilities for creating, inspecting and |
| 425 | decoding .opus files.") | 422 | decoding .opus files.") |
| 426 | (license license:bsd-3) | 423 | (license license:bsd-3) |
