diff mbox series

[bug#58208,v2,9/9] gnu: Add nnls-chroma.

Message ID 1baa096c94e09e27b676ff40601074ff9bcef635.1685685204.git.lilah@lunabee.space
State New
Headers show
Series Add Sonic Visualiser and VAMP plugins. | expand

Commit Message

Lilah Tascheter June 2, 2023, 5:56 a.m. UTC
* gnu/packages/audio.scm (nnls-chroma): New variable.
---
 gnu/packages/audio.scm | 38 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)
diff mbox series

Patch

diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm
index c34ccb30a5..d7c11b0a5d 100644
--- a/gnu/packages/audio.scm
+++ b/gnu/packages/audio.scm
@@ -659,6 +659,44 @@  (define-public vamp-aubio-plugins
 description, and beat tracking.")
     (license license:gpl3+)))
 
+(define-public nnls-chroma
+  (package
+    (name "nnls-chroma")
+    (version "1.1")
+    (source (origin
+              (method url-fetch)
+              ;; These urls have an "attachment number" :/ which makes this url
+              ;; not generalizable across versions.
+              (uri (string-append
+                     "https://code.soundsoftware.ac.uk/attachments/download/"
+                     "1691/nnls-chroma-" version ".tar.gz"))
+              (sha256
+               (base32
+                "06n66ff4w4a07rfz1kn0hq2g953dsx8a4cx1bhpvswqds1kb70md"))))
+    (build-system gnu-build-system)
+    (arguments
+      (list #:tests? #f ;; no tests available
+            #:make-flags
+            #~(list "-f" "Makefile.linux"
+                    (string-append "CC=" #$(cc-for-target))
+                    (string-append "VAMP_SDK_DIR=" #$(this-package-input "vamp")
+                                   "/include/vamp-sdk"))
+            #:phases
+            #~(modify-phases %standard-phases
+                (delete 'configure) ; no configure script
+                (replace 'install
+                  (lambda _
+                    (install-file "nnls-chroma.so"
+                                  (string-append #$output "/lib/vamp")))))))
+    (inputs (list boost vamp))
+    (home-page "http://www.isophonics.net/nnls-chroma/")
+    (synopsis "VAMP plugins for audio transcription")
+    (description "This is a set of three VAMP plugins used for audio
+transcription: NNLS Chroma, providing chromatic transcription, Chordino,
+providing chord transcription, and Tuning, which estimates local and global
+tuning.")
+    (license license:gpl2+)))
+
 (define-public dsp
   (package
     (name "dsp")