Merge branch 'master' into core-updates
[jackhill/guix/guix.git] / gnu / packages / video.scm
index dc5a375..32b3257 100644 (file)
@@ -19,7 +19,7 @@
 ;;; Copyright © 2017 Chris Marusich <cmmarusich@gmail.com>
 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
 ;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com>
-;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
+;;; Copyright © 2017, 2018 Clément Lassieur <clement@lassieur.org>
 ;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
 ;;; Copyright © 2017, 2018 Rutger Helling <rhelling@mykolab.com>
 ;;; Copyright © 2018 Roel Janssen <roel@gnu.org>
                     (let ((out     (assoc-ref outputs "out"))
                           (ncurses (assoc-ref inputs "ncurses")))
                       (setenv "CONFIG_SHELL" (which "bash"))
-                      (zero? (system* "./configure"
-                                      (string-append "--prefix=" out)
-                                      (string-append "--build=" build)
-                                      ;; The ancient config.guess is unable to
-                                      ;; guess the host triplet on mips64el.
-                                      ,@(if (string=? "mips64el-linux"
-                                                      (%current-system))
-                                            '("--host=mips64el-unknown-linux-gnu")
-                                            '())
-                                      ;; The same is also true with aarch64.
-                                      ,@(if (string=? "aarch64-linux"
-                                                      (%current-system))
-                                            '("--host=aarch64-unknown-linux-gnu")
-                                            '())
-                                      (string-append "--with-ncurses="
-                                                     ncurses)))))))))
+                      (invoke "./configure"
+                              (string-append "--prefix=" out)
+                              (string-append "--build=" build)
+                              ;; The ancient config.guess is unable to
+                              ;; guess the host triplet on mips64el.
+                              ,@(if (string=? "mips64el-linux"
+                                              (%current-system))
+                                    '("--host=mips64el-unknown-linux-gnu")
+                                    '())
+                              ;; The same is also true with aarch64.
+                              ,@(if (string=? "aarch64-linux"
+                                              (%current-system))
+                                    '("--host=aarch64-unknown-linux-gnu")
+                                    '())
+                              (string-append "--with-ncurses="
+                                             ncurses))))))))
     (home-page "http://aa-project.sourceforge.net/aalib/")
     (synopsis "ASCII-art library")
     (description
@@ -208,9 +208,8 @@ old-fashioned output methods with powerful ascii-art renderer.")
                  (modify-phases %standard-phases
                    ;; XXX We need to run ./bootstrap because of the build
                    ;; system fixes above.
-                   (add-after
-                    'unpack 'bootstrap
-                    (lambda _ (zero? (system* "sh" "bootstrap")))))))
+                   (replace 'bootstrap
+                     (lambda _ (invoke "sh" "bootstrap"))))))
     (home-page "http://liba52.sourceforge.net/")
     (synopsis "ATSC A/52 stream decoder")
     (description "liba52 is a library for decoding ATSC A/52 streams.  The
@@ -306,15 +305,15 @@ H.264 (MPEG-4 AVC) video streams.")
         (base32
          "0hknnnnx9661igm1r73dc7aqxnnrl5a8yvyvr1nhd9ymn2klwpl5"))
        (modules '((guix build utils)))
-       (snippet
-        '(begin
-           ;; Delete bundled libraries.
-           (for-each delete-file-recursively
-                     '("lib/libebml"
-                       "lib/libmatroska"
-                       "lib/nlohmann-json"
-                       "lib/pugixml"
-                       "lib/utf8-cpp"))))))
+       (snippet '(begin
+                   ;; Delete bundled libraries.
+                   (for-each delete-file-recursively
+                             '("lib/libebml"
+                               "lib/libmatroska"
+                               "lib/nlohmann-json"
+                               "lib/pugixml"
+                               "lib/utf8-cpp"))
+                   #t))))
     (build-system gnu-build-system)
     (inputs
      `(("boost" ,boost)
@@ -380,7 +379,7 @@ and creating Matroska files from other media files (@code{mkvmerge}).")
 (define-public x265
   (package
     (name "x265")
-    (version "2.6")
+    (version "2.8")
     (source
       (origin
         (method url-fetch)
@@ -388,14 +387,15 @@ and creating Matroska files from other media files (@code{mkvmerge}).")
                             "x265_" version ".tar.gz"))
         (sha256
          (base32
-          "1gyd94jkwdii9308m07nymsbxrmrcl81c0j8i10zhslr2mj07w0v"))
+          "0qx8mavwdzdpkkby7n29i9av7zsnklavacwfz537mf62q2pzjnbf"))
         (modules '((guix build utils)))
-        (snippet
-         '(delete-file-recursively "source/compat/getopt"))))
+        (snippet '(begin
+                    (delete-file-recursively "source/compat/getopt")
+                    #t))))
     (build-system cmake-build-system)
     (arguments
      `(#:tests? #f ; tests are skipped if cpu-optimized code isn't built
-       ;; Currently the source code doesn't check for aarch64
+       ;; Currently the source code doesn't check for aarch64.
        ,@(if (string-prefix? "aarch64" (or (%current-target-system) (%current-system)))
            '(#:configure-flags '("-DENABLE_PIC=TRUE"))
            '())
@@ -472,7 +472,7 @@ canvas operations.")
 (define-public libdca
   (package
     (name "libdca")
-    (version "0.0.5")
+    (version "0.0.6")
     (source (origin
               (method url-fetch)
               (uri (string-append
@@ -480,7 +480,7 @@ canvas operations.")
                     version "/libdca-" version ".tar.bz2"))
               (sha256
                (base32
-                "0hh6a7l8vvccsd5i1fkv9av2gzv9fy8m0b8jpsn5p6hh4bh2586v"))))
+                "0h0zvcn97i9kyljdpifzi8in9xnw31fx3b3ggj96p8h0l2d8mycq"))))
     (build-system gnu-build-system)
     (home-page "https://www.videolan.org/developers/libdca.html")
     (synopsis "DTS Coherent Acoustics decoder")
@@ -515,7 +515,7 @@ SMPTE 314M.")
 (define-public libmatroska
   (package
     (name "libmatroska")
-    (version "1.4.8")
+    (version "1.4.9")
     (source
      (origin
        (method url-fetch)
@@ -523,12 +523,14 @@ SMPTE 314M.")
                            name "/" name "-" version ".tar.xz"))
        (sha256
         (base32
-         "14n9sw974prr3yp4yjb7aadi6x2yz5a0hjw8fs3qigy5shh2piyq"))))
-    (build-system gnu-build-system)
-    (native-inputs
-     `(("pkg-config" ,pkg-config)))
+         "1j4mjzx6mjzfjf9hz8g4w84krf5jccmr5cyynll0j1vwv3aiv9iq"))))
+    (build-system cmake-build-system)
     (inputs
      `(("libebml" ,libebml)))
+    (arguments
+     `(#:configure-flags
+       (list "-DBUILD_SHARED_LIBS=YES")
+       #:tests? #f))                    ; no test suite
     (home-page "https://www.matroska.org")
     (synopsis "C++ library to parse Matroska files (.mkv and .mka)")
     (description
@@ -564,7 +566,8 @@ libebml is a C++ library to read and write EBML files.")
        ("libx11" ,libx11)
        ("libxext" ,libxext)
        ("libxfixes" ,libxfixes)
-       ("mesa" ,mesa)))
+       ("mesa" ,mesa)
+       ("wayland" ,wayland)))
     (arguments
      `(#:phases
        (modify-phases %standard-phases
@@ -574,7 +577,8 @@ libebml is a C++ library to read and write EBML files.")
             (let ((out (assoc-ref outputs "out")))
               (substitute* "va/drm/va_drm_auth_x11.c"
                 (("\"libva-x11\\.so\\.%d\"")
-                 (string-append "\"" out "/lib/libva-x11.so.%d\"")))))))
+                 (string-append "\"" out "/lib/libva-x11.so.%d\"")))
+              #t))))
        ;; Most drivers are in mesa's $prefix/lib/dri, so use that.  (Can be
        ;; overridden at run-time via LIBVA_DRIVERS_PATH.)
        #:configure-flags
@@ -746,13 +750,13 @@ standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
                 (("#! /bin/sh") (string-append "#!" (which "sh"))))
               (setenv "SHELL" (which "bash"))
               (setenv "CONFIG_SHELL" (which "bash"))
-              (zero? (apply system*
-                            "./configure"
-                            (string-append "--prefix=" out)
-                            ;; Add $libdir to the RUNPATH of all the binaries.
-                            (string-append "--extra-ldflags=-Wl,-rpath="
-                                           out "/lib")
-                            configure-flags)))))
+              (apply invoke
+                     "./configure"
+                     (string-append "--prefix=" out)
+                     ;; Add $libdir to the RUNPATH of all the binaries.
+                     (string-append "--extra-ldflags=-Wl,-rpath="
+                                    out "/lib")
+                     configure-flags))))
          (add-before
           'check 'set-ld-library-path
           (lambda _
@@ -1067,7 +1071,8 @@ SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.")
           'configure 'setup-waf
           (lambda* (#:key inputs #:allow-other-keys)
             (copy-file (assoc-ref inputs "waf") "waf")
-            (setenv "CC" "gcc"))))
+            (setenv "CC" "gcc")
+            #t)))
        #:configure-flags (list "--enable-libmpv-shared"
                                "--enable-cdda"
                                "--enable-dvdread"
@@ -1153,7 +1158,7 @@ access to mpv's powerful playback capabilities.")
 (define-public youtube-dl
   (package
     (name "youtube-dl")
-    (version "2018.04.16")
+    (version "2018.05.09")
     (source (origin
               (method url-fetch)
               (uri (string-append "https://yt-dl.org/downloads/"
@@ -1161,7 +1166,7 @@ access to mpv's powerful playback capabilities.")
                                   version ".tar.gz"))
               (sha256
                (base32
-                "046zg8pww2xg1yibh7c1a8jcg8f1znr4hsz1l1da03djcp6na99d"))))
+                "0sl4bi2jls3417rd62awbqdq1b6wskkjbfwpnyw4a61qarfxid1d"))))
     (build-system python-build-system)
     (arguments
      ;; The problem here is that the directory for the man page and completion
@@ -1310,7 +1315,7 @@ audio, images) from the Web.  It can use either mpv or vlc for playback.")
 (define-public youtube-viewer
   (package
     (name "youtube-viewer")
-    (version "3.3.3")
+    (version "3.3.4")
     (source (origin
               (method url-fetch)
               (uri (string-append
@@ -1319,7 +1324,7 @@ audio, images) from the Web.  It can use either mpv or vlc for playback.")
               (file-name (string-append name "-" version ".tar.gz"))
               (sha256
                (base32
-                "1j572his6qmazlmyrbnfq62s9bqml875ay7wy26byy9hfc7m0vgk"))))
+                "1dqaxkz5svv0lmxds6lppcpzhkq6gar2raw9gx6imrd7yz02fpgn"))))
     (build-system perl-build-system)
     (native-inputs
      `(("perl-module-build" ,perl-module-build)))
@@ -1823,10 +1828,11 @@ from sites like Twitch.tv and pipes them into a video player of choice.")
                (base32
                 "10m3ry0b2pvqx3bk34qh5dq337nn8pkc2gzfyhsj4nv9abskln47"))
               (modules '((guix build utils)))
-              (snippet
-               ;; As of glibc 2.26, <xlocale.h> no longer is.
-               '(substitute* "src/framework/mlt_property.h"
-                  (("xlocale\\.h") "locale.h")))))
+              (snippet '(begin
+                          ;; As of glibc 2.26, <xlocale.h> no longer is.
+                          (substitute* "src/framework/mlt_property.h"
+                            (("xlocale\\.h") "locale.h"))
+                          #t))))
     (build-system gnu-build-system)
     (arguments
      `(#:tests? #f ; no tests
@@ -1963,9 +1969,9 @@ and JACK.")
     (native-inputs
      `(("pkg-config" ,pkg-config)))
     (inputs
-     `(("dri2proto" ,dri2proto)
-       ("libx11" ,libx11 "out")
-       ("libxext" ,libxext)))
+     `(("libx11" ,libx11 "out")
+       ("libxext" ,libxext)
+       ("xorgproto" ,xorgproto)))
     (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
     (synopsis "Video Decode and Presentation API")
     (description "VDPAU is the Video Decode and Presentation API for UNIX.  It
@@ -2012,7 +2018,8 @@ implementation.")
           "1x2ag1f2fwa4yh1g5spv99w9x1m33hbxlqwyhm205ssq0ra234bx"))
         (patches (search-patches "libvdpau-va-gl-unbundle.patch"))
         (modules '((guix build utils)))
-        (snippet '(delete-file-recursively "3rdparty"))))
+        (snippet '(begin (delete-file-recursively "3rdparty")
+                         #t))))
     (build-system cmake-build-system)
     (arguments
      '(#:tests? #f)) ; Tests require a running X11 server, with VA-API support.
@@ -2066,7 +2073,7 @@ making @dfn{screencasts}.")
 (define-public simplescreenrecorder
   (package
     (name "simplescreenrecorder")
-    (version "0.3.10")
+    (version "0.3.11")
     (source
      (origin
        (method url-fetch)
@@ -2075,14 +2082,14 @@ making @dfn{screencasts}.")
        (file-name (string-append name "-" version ".tar.gz"))
        (sha256
         (base32
-         "02rl9yyx3hlz9fqvgzv7ipmvx2qahj7ws5wx2m7zs3lssq3qag3g"))))
+         "0l6irdadqpajvv0dj3ngs1231n559l0y1pykhs2h7526qm4w7xal"))))
     (build-system cmake-build-system)
     ;; Although libx11, libxfixes, libxext are listed as build dependencies in
     ;; README.md, the program builds and functions properly without them.
     ;; As a result, they are omitted. Please add them back if problems appear.
     (inputs
      `(("alsa-lib" ,alsa-lib)
-       ("ffmpeg" ,ffmpeg-3.4)
+       ("ffmpeg" ,ffmpeg)
        ("glu" ,glu)
        ("jack" ,jack-1)
        ("libxi" ,libxi)
@@ -2188,7 +2195,7 @@ Content System specification.")
 (define-public mps-youtube
   (package
     (name "mps-youtube")
-    (version "0.2.7.1")
+    (version "0.2.8")
     (source
      (origin
        (method url-fetch)
@@ -2197,7 +2204,7 @@ Content System specification.")
        (file-name (string-append name "-" version ".tar.gz"))
        (sha256
         (base32
-         "1s7h35yx6f0szf8mm8612ic913w3v05m2kwphjfcxnpq0ammhyci"))))
+         "0x7cmfh199q9j396v7bz81nnvanfllhsg86489i5dw2p3yyc9wnm"))))
     (build-system python-build-system)
     (arguments
      ;; Tests need to be disabled until #556 upstream is fixed. It reads as if the
@@ -2279,7 +2286,7 @@ supported players in addition to this package.")
      `(#:tests? #f             ;tests require Ruby and claim to be unsupported
        #:phases
        (modify-phases %standard-phases
-         (add-before 'patch-source-shebangs 'bootstrap-gtk
+         (replace 'bootstrap
            ;; Run bootstrap ahead of time so that shebangs get patched.
            (lambda _
              (setenv "CONFIG_SHELL" (which "sh"))
@@ -2524,10 +2531,11 @@ many codecs and formats supported by libmediainfo.")
                (base32
                 "0f5kxpayqn3yhabqrd2cqlc74i6x2xr01jfkank1lcilxnfyrsnq"))
               (modules '((guix build utils)))
-              (snippet
-               ;; As of glibc 2.26, <xlocale.h> no longer is.
-               '(substitute* "liveMedia/include/Locale.hh"
-                  (("xlocale\\.h") "locale.h")))))
+              (snippet '(begin
+                          ;; As of glibc 2.26, <xlocale.h> no longer is.
+                          (substitute* "liveMedia/include/Locale.hh"
+                            (("xlocale\\.h") "locale.h"))
+                          #t))))
     (build-system gnu-build-system)
     (arguments
      '(#:tests? #f ; no tests
@@ -2798,7 +2806,7 @@ It counts more than 100 plugins.")
        ("sqlite" ,sqlite)))
     (arguments
      '(#:phases (modify-phases %standard-phases
-                  (add-after 'unpack 'bootstrap
+                  (replace 'bootstrap
                     (lambda _
                       (patch-shebang "version.sh")
                       (invoke "autoreconf" "-vfi"))))
@@ -2852,3 +2860,41 @@ the results, download the highest-rated result in the requested language and
 save it to the appropriate filename.")
       (license license:gpl3+)
       (home-page "https://github.com/alexanderwink/subdl"))))
+
+(define-public l-smash
+  (package
+    (name "l-smash")
+    (version "2.14.5")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append
+                    "https://github.com/" name "/" name "/archive/v"
+                    version ".tar.gz"))
+              (file-name (string-append name "-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0dary0h65kq6sv93iabv25djlvzr5ckdcp3ywagbix44wqfw7xz6"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:tests? #f                      ;no tests
+       #:make-flags
+       (list (string-append "LDFLAGS=-Wl,-L.,-rpath="
+                            (assoc-ref %outputs "out") "/lib"))
+       #:phases
+       (modify-phases %standard-phases
+         ;; configure fails if it is followed by CONFIG_SHELL
+         (replace 'configure
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let ((out (assoc-ref outputs "out")))
+               (invoke "./configure" (string-append "--prefix=" out)
+                       "--disable-static")))))))
+    (native-inputs
+     `(("which" ,which)))
+    (home-page "https://l-smash.github.io/l-smash/")
+    (synopsis "MP4 multiplexer and demultiplexer library")
+    (description
+     "L-SMASH is a cross-platform library that handles the ISO base media file
+format and some of its derived file formats, including MP4.  It operates as a
+multiplexer and demultiplexer, and can mux video and audio in several formats
+using standalone executable files.")
+    (license license:isc)))