GNU bug report logs - #66271
[PATCH 0/2] Add ffmpeg-normalize

Previous Next

Package: guix-patches;

Reported by: Vinicius Monego <monego <at> posteo.net>

Date: Sat, 30 Sep 2023 03:08:02 UTC

Severity: normal

Tags: patch

Done: Christopher Baines <mail <at> cbaines.net>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 66271 in the body.
You can then email your comments to 66271 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#66271; Package guix-patches. (Sat, 30 Sep 2023 03:08:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Vinicius Monego <monego <at> posteo.net>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sat, 30 Sep 2023 03:08:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Vinicius Monego <monego <at> posteo.net>
To: guix-patches <at> gnu.org
Cc: Vinicius Monego <monego <at> posteo.net>
Subject: [PATCH 0/2] Add ffmpeg-normalize
Date: Sat, 30 Sep 2023 03:06:39 +0000
Vinicius Monego (2):
  gnu: Add ffmpeg-progress-yield.
  gnu: Add ffmpeg-normalize.

 gnu/packages/video.scm | 75 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 75 insertions(+)

-- 
2.39.2





Information forwarded to guix-patches <at> gnu.org:
bug#66271; Package guix-patches. (Sat, 30 Sep 2023 03:09:02 GMT) Full text and rfc822 format available.

Message #8 received at 66271 <at> debbugs.gnu.org (full text, mbox):

From: Vinicius Monego <monego <at> posteo.net>
To: 66271 <at> debbugs.gnu.org
Cc: Vinicius Monego <monego <at> posteo.net>
Subject: [PATCH 1/2] gnu: Add ffmpeg-progress-yield.
Date: Sat, 30 Sep 2023 03:08:22 +0000
* gnu/packages/video.scm (ffmpeg-progress-yield): New variable.
---
 gnu/packages/video.scm | 33 +++++++++++++++++++++++++++++++++
 1 file changed, 33 insertions(+)

diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index 5375424ce6..a707541b68 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -1940,6 +1940,39 @@ (define-public ffmpegthumbnailer
 videoformats depend on the configuration flags of ffmpeg.")
     (license license:gpl2+)))
 
+(define-public ffmpeg-progress-yield
+  (package
+    (name "ffmpeg-progress-yield")
+    (version "0.7.8")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "ffmpeg-progress-yield" version))
+              (sha256
+               (base32
+                "07j6m8p8z8ybl75h0d4xzjl1pvkfzr0i73siysqcgrrahdgsxrls"))))
+    (build-system pyproject-build-system)
+    (arguments
+     ;; Not sure if the test file actually does anything.
+     (list #:phases #~(modify-phases %standard-phases
+                        (replace 'check
+                          (lambda* (#:key tests? #:allow-other-keys)
+                            (when tests?
+                              (invoke "python" "test/test.py"))))
+                        (add-after 'wrap 'wrap-program
+                          ;; Wrap ffmpeg on the executable.
+                          (lambda* (#:key inputs outputs #:allow-other-keys)
+                            (let ((fpy "bin/ffmpeg-progress-yield")
+                                  (ffm "bin/ffmpeg"))
+                              (wrap-program (search-input-file outputs fpy)
+                                `("PATH" ":" prefix
+                                  (,(search-input-file inputs ffm))))))))))
+    (inputs (list bash-minimal ffmpeg))
+    (home-page "https://github.com/slhck/ffmpeg-progress-yield")
+    (synopsis "Run an ffmpeg command with progress")
+    (description "This package allows an ffmpeg command to run with progress.
+It is usually a complement to @code{ffmpeg-normalize}.")
+    (license license:expat)))
+
 (define-public vlc
   (package
     (name "vlc")
-- 
2.39.2





Information forwarded to guix-patches <at> gnu.org:
bug#66271; Package guix-patches. (Sat, 30 Sep 2023 03:10:01 GMT) Full text and rfc822 format available.

Message #11 received at 66271 <at> debbugs.gnu.org (full text, mbox):

From: Vinicius Monego <monego <at> posteo.net>
To: 66271 <at> debbugs.gnu.org
Cc: Vinicius Monego <monego <at> posteo.net>
Subject: [PATCH 2/2] gnu: Add ffmpeg-normalize.
Date: Sat, 30 Sep 2023 03:08:23 +0000
* gnu/packages/video.scm (ffmpeg-normalize): New variable.
---
 gnu/packages/video.scm | 42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index a707541b68..44fe322a3b 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -1973,6 +1973,48 @@ (define-public ffmpeg-progress-yield
 It is usually a complement to @code{ffmpeg-normalize}.")
     (license license:expat)))
 
+(define-public ffmpeg-normalize
+  (package
+    (name "ffmpeg-normalize")
+    (version "1.27.7")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "ffmpeg-normalize" version))
+              (sha256
+               (base32
+                "0idqqgsr3p840vx2x3idn851qwghjdbm6v4yrq2kprppyfvglni7"))))
+    (build-system pyproject-build-system)
+    (arguments
+     (list #:phases
+           #~(modify-phases %standard-phases
+               (replace 'check
+                 (lambda* (#:key tests? #:allow-other-keys)
+                   (when tests?
+                     (invoke "python" "-m" "pytest"
+                             "test/test.py"))))
+               (add-after 'wrap 'wrap-ffmpeg
+                 ;; Wrap ffmpeg on the executable.
+                 (lambda* (#:key inputs outputs #:allow-other-keys)
+                   (let ((ffn (search-input-file outputs
+                                                 "bin/ffmpeg-normalize"))
+                         (ffm (search-input-file inputs "bin/ffmpeg")))
+                     (wrap-program ffn
+                       `("FFMPEG_PATH" = (,ffm)))))))))
+    (native-inputs (list python-pytest))
+    (inputs (list bash-minimal ffmpeg))
+    (propagated-inputs (list ffmpeg-progress-yield
+                             python-colorama
+                             python-colorlog
+                             python-tqdm))
+    (home-page "https://github.com/slhck/ffmpeg-normalize")
+    (synopsis "Normalize audio via ffmpeg")
+    (description "This program normalizes media files to a certain loudness
+level using the EBU R128 loudness normalization procedure.  It can also
+perform RMS-based normalization (where the mean is lifted or attenuated),
+or peak normalization to a certain target level.  Batch processing of several
+input files is possible, including video files.")
+    (license license:expat)))
+
 (define-public vlc
   (package
     (name "vlc")
-- 
2.39.2





Information forwarded to guix-patches <at> gnu.org:
bug#66271; Package guix-patches. (Thu, 19 Oct 2023 20:32:01 GMT) Full text and rfc822 format available.

Message #14 received at 66271 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Vinicius Monego <monego <at> posteo.net>
Cc: 66271 <at> debbugs.gnu.org
Subject: Re: [bug#66271] [PATCH 0/2] Add ffmpeg-normalize
Date: Thu, 19 Oct 2023 22:30:52 +0200
Hi,

Vinicius Monego <monego <at> posteo.net> skribis:

>   gnu: Add ffmpeg-progress-yield.
>   gnu: Add ffmpeg-normalize.

LGTM and to qa.guix.  Go for it!

Ludo’.




Reply sent to Christopher Baines <mail <at> cbaines.net>:
You have taken responsibility. (Mon, 30 Oct 2023 11:26:02 GMT) Full text and rfc822 format available.

Notification sent to Vinicius Monego <monego <at> posteo.net>:
bug acknowledged by developer. (Mon, 30 Oct 2023 11:26:02 GMT) Full text and rfc822 format available.

Message #19 received at 66271-done <at> debbugs.gnu.org (full text, mbox):

From: Christopher Baines <mail <at> cbaines.net>
To: Vinicius Monego <monego <at> posteo.net>
Cc: 66271-done <at> debbugs.gnu.org
Subject: Re: [bug#66271] [PATCH 0/2] Add ffmpeg-normalize
Date: Mon, 30 Oct 2023 11:24:22 +0000
[Message part 1 (text/plain, inline)]
Ludovic Courtès <ludo <at> gnu.org> writes:

> Vinicius Monego <monego <at> posteo.net> skribis:
>
>>   gnu: Add ffmpeg-progress-yield.
>>   gnu: Add ffmpeg-normalize.
>
> LGTM and to qa.guix.  Go for it!

I've gone ahead and pushed this to master as
a0eb6652b3ce386a2d3cceda3dd3723afc87ac59.

Thanks both,

Chris
[signature.asc (application/pgp-signature, inline)]

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 27 Nov 2023 12:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 1 year and 199 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.