Message ID | f3b2a47a3a8abfa7492c6caa042e516f81303563.camel@courrier.dev |
---|---|
State | Accepted |
Headers | show |
Series | [bug#50369] gnu: Add video-contact-sheet | expand |
Context | Check | Description |
---|---|---|
cbaines/applying patch | fail | View Laminar job |
cbaines/issue | success | View issue |
On Sat, Sep 04, 2021 at 11:52:57AM +0200, Pradana Adrinusa AUMARS via Guix-patches via wrote: > From 9851db2b3036ee3d5e8ef85ed8bae2f6398702e0 Mon Sep 17 00:00:00 2001 > From: Pradana AUMARS <paumars@courrier.dev> > Date: Fri, 18 Jun 2021 16:13:07 +0200 > Subject: [PATCH] gnu: Add video-contact-sheet Thank you for packaging this very useful program! And sorry for the long delay in reviewing your contribution. I've pushed your patch as commit 61ae42e773526373f0dc3ca99c7251d20434d3d1 with the following changes: > + (uri (string-append "http://p.outlyer.net/files/vcs/-" version > + ".tar.gz")) This URL was incorrect. This can happen when you first download the source code with `guix download`. Since you will already have the tarball in /gnu/store, Guix will not try to download it again based on the package definition, and you won't notice that the URL is wrong. For that reason, when making new packages I suggest downloading the tarball in another way and then using `guix hash` to get the hash, or using `guix build --source video-contact-sheet --check`. > + (arguments > + `(#:phases (modify-phases %standard-phases > + (delete 'configure) > + (delete 'build) > + (delete 'check)) > + #:make-flags (list (string-append "prefix=" (assoc-ref %outputs "out"))))) > + (inputs > + `(("bash" ,bash) > + ("ffmpeg" ,ffmpeg) > + ("imagemagick" ,imagemagick))) I added a "wrap-program" phase to ensure that the built package will retain its dependencies on ffmpeg and imagemagick. Without this, it did not keep any "references" to those packages, and so they would not be made available when installing video-contact-sheet. You can check these references like this: $ guix gc --references $(guix build video-contact-sheet) /gnu/store/czv41lxhgrmmvbabrqhshxjaj1z3qgvq-ffmpeg-4.4.1 /gnu/store/frs0cv3f6r8frqan91wlm05hm6iwlyn1-bash-minimal-5.1.8 /gnu/store/ph6ikrlflwp240cw9r0sp9zwri9x44sz-imagemagick-6.9.12-4 /gnu/store/rjqgadyzrxdhpr00kwybwyyi7pw7sc1l-video-contact-sheet-1.13.4 I also changed the bash dependency to bash-minimal, which is more suitable for non-interactive use. I partially updated the package to the new style described here: https://guix.gnu.org/en/blog/2021/the-big-change/ > + (synopsis "Bash script to create contact sheets (preview images) from videos") > + (description "This is a bash script meant to create video contact sheets (previews) of videos. > Any video supported by mplayer and ffmpeg can be used. A note of warning: Unlike most similar tools it, > by default, makes screenshots the same size as the video, see the manual for details on how to change > this.") In a follow-up commit, I tweaked the synopsis and description a little bit. I meant to do this in the same commit but forgot to include these changes. > + (license license:lgpl3))) Finally, I changed the license to lgpl2.1+, since that is what is specified in the `vcs` shell script. Thanks again for this patch!
diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index e3f4f59b4c..ba3035cf45 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -51,6 +51,7 @@ ;;; Copyright © 2021 Andrew Tropin <andrew@trop.in> ;;; Copyright © 2021 David Wilson <david@daviwil.com> ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2021 Pradana Aumars <paumars@courrier.dev> ;;; ;;; This file is part of GNU Guix. ;;; @@ -96,6 +97,7 @@ #:use-module (gnu packages avahi) #:use-module (gnu packages backup) #:use-module (gnu packages base) + #:use-module (gnu packages bash) #:use-module (gnu packages bison) #:use-module (gnu packages boost) #:use-module (gnu packages cdrom) @@ -5180,3 +5182,32 @@ information) NALUs (Network Abstraction Layer Unit) for inclusion into an h.264 elementary stream are provided.") (home-page "https://github.com/szatmary/libcaption") (license license:expat))) + +(define-public video-contact-sheet + (package + (name "video-contact-sheet") + (version "1.13.4") + (source (origin + (method url-fetch) + (uri (string-append "http://p.outlyer.net/files/vcs/-" version + ".tar.gz")) + (sha256 + (base32 + "0jsl93r0rnybjcipqbww5hwsr9ln6kz1qnf32qfxdvhfw52n27fw")))) + (build-system gnu-build-system) + (arguments + `(#:phases (modify-phases %standard-phases + (delete 'configure) + (delete 'build) + (delete 'check)) + #:make-flags (list (string-append "prefix=" (assoc-ref %outputs "out"))))) + (inputs + `(("bash" ,bash) + ("ffmpeg" ,ffmpeg) + ("imagemagick" ,imagemagick))) + (synopsis "Bash script to create contact sheets (preview images) from videos") + (description "This is a bash script meant to create video contact sheets (previews) of videos. Any video supported by mplayer and ffmpeg can be used. A note of warning: Unlike most similar tools it, by default, makes screenshots the same size as the video, see the manual for details on how to change this.") + (home-page "http://p.outlyer.net/vcs/")
From 9851db2b3036ee3d5e8ef85ed8bae2f6398702e0 Mon Sep 17 00:00:00 2001 From: Pradana AUMARS <paumars@courrier.dev> Date: Fri, 18 Jun 2021 16:13:07 +0200 Subject: [PATCH] gnu: Add video-contact-sheet --- gnu/packages/video.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) + (license license:lgpl3)))