2020-02-11 19:02:24 +01:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
2022-02-21 02:11:49 +01:00
|
|
|
, gitUpdater
|
2020-02-11 19:02:24 +01:00
|
|
|
, substituteAll
|
2021-04-26 21:57:30 +02:00
|
|
|
, ffmpeg
|
2020-02-11 19:02:24 +01:00
|
|
|
, python3Packages
|
|
|
|
, sox
|
|
|
|
}:
|
2019-08-18 21:31:15 +02:00
|
|
|
|
|
|
|
python3Packages.buildPythonApplication rec {
|
|
|
|
pname = "r128gain";
|
2020-09-30 21:30:26 +02:00
|
|
|
version = "1.0.3";
|
2019-08-18 21:31:15 +02:00
|
|
|
|
2020-02-11 19:02:24 +01:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "desbma";
|
|
|
|
repo = "r128gain";
|
|
|
|
rev = version;
|
2020-09-30 21:30:26 +02:00
|
|
|
sha256 = "0w2i2szajv1vcmc96w0fczdr8xc28ijcf1gdg180f21gi6yh96sc";
|
2019-08-18 21:31:15 +02:00
|
|
|
};
|
|
|
|
|
2020-02-11 19:02:24 +01:00
|
|
|
patches = [
|
2021-04-26 21:57:30 +02:00
|
|
|
(substituteAll {
|
|
|
|
src = ./ffmpeg-location.patch;
|
|
|
|
inherit ffmpeg;
|
|
|
|
})
|
2020-02-11 19:02:24 +01:00
|
|
|
];
|
2019-08-18 21:31:15 +02:00
|
|
|
|
2020-02-11 19:02:24 +01:00
|
|
|
propagatedBuildInputs = with python3Packages; [ crcmod ffmpeg-python mutagen tqdm ];
|
2023-01-21 13:00:00 +01:00
|
|
|
nativeCheckInputs = with python3Packages; [ requests sox ];
|
2020-02-11 19:02:24 +01:00
|
|
|
|
|
|
|
# Testing downloads media files for testing, which requires the
|
|
|
|
# sandbox to be disabled.
|
|
|
|
doCheck = false;
|
2019-08-18 21:31:15 +02:00
|
|
|
|
2022-09-27 23:12:05 +02:00
|
|
|
passthru.updateScript = gitUpdater { };
|
2020-09-30 21:30:08 +02:00
|
|
|
|
2019-08-18 21:31:15 +02:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Fast audio loudness scanner & tagger (ReplayGain v2 / R128)";
|
2024-03-19 03:14:51 +01:00
|
|
|
mainProgram = "r128gain";
|
2019-08-18 21:31:15 +02:00
|
|
|
homepage = "https://github.com/desbma/r128gain";
|
|
|
|
license = licenses.lgpl2Plus;
|
|
|
|
maintainers = [ maintainers.AluisioASG ];
|
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|