gnu: ardour: Sort inputs and native-inputs.
[jackhill/guix/guix.git] / gnu / packages / audio.scm
index a65cfa2..d47dd90 100644 (file)
@@ -17,6 +17,7 @@
 ;;; Copyright © 2018 Marius Bakke <mbakke@fastmail.com>
 ;;; Copyright © 2018 Thorsten Wilms <t_w_@freenet.de>
 ;;; Copyright © 2018 Eric Bavier <bavier@member.fsf.org>
+;;; Copyright © 2018 Brendan Tildesley <brendan.tildesley@openmailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -74,6 +75,7 @@
   #:use-module (gnu packages qt)
   #:use-module (gnu packages libbsd)
   #:use-module (gnu packages linux)
+  #:use-module (gnu packages libusb)
   #:use-module (gnu packages llvm)
   #:use-module (gnu packages mp3) ;taglib
   #:use-module (gnu packages perl)
@@ -229,57 +231,79 @@ namespace ARDOUR { const char* revision = \"" version "\" ; }"))
     (arguments
      `(#:configure-flags '("--cxx11"          ; required by gtkmm
                            "--no-phone-home"  ; don't contact ardour.org
-                           "--freedesktop"    ; install .desktop file
+                           "--freedesktop"    ; build .desktop file
                            "--test")          ; build unit tests
        #:phases
        (modify-phases %standard-phases
-         (add-after
-          'unpack 'set-rpath-in-LDFLAGS
-          ,(ardour-rpath-phase (version-major version))))
+         (add-after 'unpack 'set-rpath-in-LDFLAGS
+          ,(ardour-rpath-phase (version-major version)))
+         (add-after 'install 'install-freedesktop-files
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let* ((out   (assoc-ref outputs "out"))
+                    (share (string-append out "/share"))
+                    (ver   ,(version-major version)))
+               (for-each
+                 (lambda (size)
+                   (let ((dir (string-append share "/icons/hicolor/"
+                                             size "x" size "/apps")))
+                     (mkdir-p dir)
+                     (copy-file
+                       (string-append "gtk2_ardour/resources/Ardour-icon_"
+                                      size "px.png")
+                       (string-append dir "/ardour" ver ".png"))))
+                 '("16" "22" "32" "48" "256"))
+               (install-file (string-append "build/gtk2_ardour/ardour"
+                                            ver ".desktop")
+                             (string-append share "/applications/"))
+               (install-file (string-append "build/gtk2_ardour/ardour"
+                                            ver ".appdata.xml")
+                             (string-append share "/appdata/")))
+             #t)))
        #:test-target "test"
        #:python ,python-2))
     (inputs
      `(("alsa-lib" ,alsa-lib)
+       ("atkmm" ,atkmm)
        ("aubio" ,aubio)
-       ("lrdf" ,lrdf)
        ("boost" ,boost)
-       ("atkmm" ,atkmm)
        ("cairomm" ,cairomm)
+       ("curl" ,curl)
        ("eudev" ,eudev)
-       ("gtkmm" ,gtkmm-2)
+       ("fftw" ,fftw)
+       ("fftwf" ,fftwf)
+       ("flac" ,flac)
        ("glibmm" ,glibmm)
+       ("gtkmm" ,gtkmm-2)
+       ("jack" ,jack-1)
+       ("libarchive" ,libarchive)
        ("libart-lgpl" ,libart-lgpl)
        ("libgnomecanvasmm" ,libgnomecanvasmm)
-       ("pangomm" ,pangomm)
        ("liblo" ,liblo)
-       ("libsndfile" ,libsndfile)
-       ("libsamplerate" ,libsamplerate)
-       ("libxml2" ,libxml2)
        ("libogg" ,libogg)
+       ("libsamplerate" ,libsamplerate)
+       ("libsndfile" ,libsndfile)
+       ("libusb" ,libusb)
        ("libvorbis" ,libvorbis)
-       ("flac" ,flac)
+       ("libxml2" ,libxml2)
+       ("lilv" ,lilv)
+       ("lrdf" ,lrdf)
        ("lv2" ,lv2)
-       ("vamp" ,vamp)
-       ("curl" ,curl)
-       ("fftw" ,fftw)
-       ("fftwf" ,fftwf)
-       ("jack" ,jack-1)
+       ("pangomm" ,pangomm)
+       ("python-rdflib" ,python-rdflib)
+       ("readline" ,readline)
+       ("redland" ,redland)
+       ("rubberband" ,rubberband)
        ("serd" ,serd)
        ("sord" ,sord)
        ("sratom" ,sratom)
        ("suil" ,suil)
-       ("lilv" ,lilv)
-       ("readline" ,readline)
-       ("redland" ,redland)
-       ("rubberband" ,rubberband)
-       ("libarchive" ,libarchive)
        ("taglib" ,taglib)
-       ("python-rdflib" ,python-rdflib)))
+       ("vamp" ,vamp)))
     (native-inputs
-     `(("perl" ,perl)
-       ("cppunit" ,cppunit)
-       ("itstool" ,itstool)
+     `(("cppunit" ,cppunit)
        ("gettext" ,gettext-minimal)
+       ("itstool" ,itstool)
+       ("perl" ,perl)
        ("pkg-config" ,pkg-config)))
     (home-page "http://ardour.org")
     (synopsis "Digital audio workstation")
@@ -2097,7 +2121,9 @@ buffers, and audio capture.")
                (base32
                 "1agdpwwi42176l4mxj0c4fsvdiv1ig56bfnnx0msckxmy57df8bb"))))
     (build-system waf-build-system)
-    (arguments `(#:tests? #f)) ; no check target
+    (arguments
+     `(#:tests? #f ; no check target
+       #:python ,python-2))
     (inputs
      `(("alsa-lib" ,alsa-lib)
        ("boost" ,boost)
@@ -2118,14 +2144,14 @@ and ALSA.")
 (define-public qjackctl
   (package
     (name "qjackctl")
-    (version "0.5.4")
+    (version "0.5.5")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://sourceforge/qjackctl/qjackctl/"
                                   version "/qjackctl-" version ".tar.gz"))
               (sha256
                (base32
-                "0qr71nb93gkz5q53nfcl5g168z173wc6s8w1yjs3rfn3m4hg0bcq"))))
+                "1rzzqa39a6llr52vjkjr0a86nc776kmr5xs52qqga8ms9697psz5"))))
     (build-system gnu-build-system)
     (arguments
      '(#:tests? #f))                    ; no check target
@@ -2181,7 +2207,7 @@ background file post-processing.")
 (define-public supercollider
   (package
     (name "supercollider")
-    (version "3.9.3")
+    (version "3.10.0")
     (source (origin
               (method url-fetch)
               (uri (string-append
@@ -2190,7 +2216,7 @@ background file post-processing.")
                     "/SuperCollider-" version "-Source-linux.tar.bz2"))
               (sha256
                (base32
-                "1d8ixfl100jvlialxdizp8wqsl1mp5pi2bam25vp97bhjd59cfdr"))))
+                "16j9psa32czx1p1y2vvq0qf2ib0ngrfc604vx35n2b4llyika84v"))))
     (build-system cmake-build-system)
     (arguments
      `(#:configure-flags '("-DSYSTEM_BOOST=on" "-DSYSTEM_YAMLCPP=on"
@@ -2202,6 +2228,12 @@ background file post-processing.")
                   (ice-9 ftw))
        #:phases
        (modify-phases %standard-phases
+         (add-after 'unpack 'fix-build-with-boost-1.68
+           (lambda _
+             (substitute* "server/supernova/utilities/time_tag.hpp"
+               (("(time_duration offset = .+ microseconds\\().*" _ m)
+                (string-append m "static_cast<long>(get_nanoseconds()/1000));\n")))
+             #t))
          (add-after 'unpack 'rm-bundled-libs
            (lambda _
              ;; The build system doesn't allow us to unbundle the following
@@ -2222,13 +2254,13 @@ background file post-processing.")
          ;; https://github.com/supercollider/supercollider/issues/1736
          (add-after 'rm-bundled-libs 'disable-broken-tests
            (lambda _
-             (substitute* "testsuite/supernova/CMakeLists.txt"
+             (substitute* "testsuite/server/supernova/CMakeLists.txt"
                (("server_test.cpp")
                 "")
                (("perf_counter_test.cpp")
                 ""))
-             (delete-file "testsuite/supernova/server_test.cpp")
-             (delete-file "testsuite/supernova/perf_counter_test.cpp")
+             (delete-file "testsuite/server/supernova/server_test.cpp")
+             (delete-file "testsuite/server/supernova/perf_counter_test.cpp")
              (substitute* "testsuite/CMakeLists.txt"
                (("add_subdirectory\\(sclang\\)")
                 ""))
@@ -2266,7 +2298,7 @@ external_libraries/yaml-cpp/include)"))
        ("eudev" ,eudev)                 ;for user interactions with devices
        ("avahi" ,avahi)                 ;zeroconf service discovery support
        ("icu4c" ,icu4c)
-       ("boost" ,boost)
+       ("boost" ,boost-cxx14)
        ("boost-sync" ,boost-sync)
        ("yaml-cpp" ,yaml-cpp)))
     (home-page "https://github.com/supercollider/supercollider")
@@ -2855,7 +2887,7 @@ interface.")
 (define-public qsynth
   (package
     (name "qsynth")
-    (version "0.5.3")
+    (version "0.5.4")
     (source
      (origin
        (method url-fetch)
@@ -2863,7 +2895,7 @@ interface.")
                            "/qsynth-" version ".tar.gz"))
        (sha256
         (base32
-         "1jghczmmva7cyavg1q0j8nr3hmjpzzglzi5ckg92ax4ji8gpks9c"))))
+         "0kpq5fxr96wnii18ax780w1ivq8ksk892ac0bprn92iz0asfysrd"))))
     (build-system gnu-build-system)
     (arguments
      `(#:tests? #f                      ; no "check" phase