2018-04-08 03:42:13 +02:00
|
|
|
{ stdenv
|
|
|
|
, fetchurl
|
|
|
|
, makeWrapper
|
|
|
|
|
|
|
|
, perlPackages
|
|
|
|
|
|
|
|
, cdparanoia
|
|
|
|
, coreutils
|
|
|
|
, eject
|
|
|
|
, flac
|
|
|
|
, gnugrep
|
|
|
|
, nano
|
|
|
|
, sox
|
|
|
|
, vorbis-tools
|
|
|
|
, vorbisgain
|
|
|
|
, which
|
|
|
|
}:
|
|
|
|
|
|
|
|
with stdenv.lib;
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "crip-3.9";
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://bach.dynet.com/crip/src/${name}.tar.gz";
|
|
|
|
sha256 = "0pk9152wll6fmkj1pki3fz3ijlf06jyk32v31yarwvdkwrk7s9xz";
|
|
|
|
};
|
|
|
|
|
2018-12-15 04:50:31 +01:00
|
|
|
buildInputs = [ perlPackages.perl perlPackages.CDDB_get ];
|
2018-04-08 03:42:13 +02:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
|
|
|
|
toolDeps = makeBinPath [
|
|
|
|
cdparanoia
|
|
|
|
coreutils
|
|
|
|
eject
|
|
|
|
flac
|
|
|
|
gnugrep
|
|
|
|
sox
|
|
|
|
vorbis-tools
|
|
|
|
vorbisgain
|
|
|
|
which
|
|
|
|
];
|
|
|
|
|
|
|
|
scripts = [ "crip" "editcomment" "editfilenames" ];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin/
|
|
|
|
|
|
|
|
for script in ${escapeShellArgs scripts}; do
|
|
|
|
cp $script $out/bin/
|
|
|
|
|
|
|
|
substituteInPlace $out/bin/$script \
|
|
|
|
--replace '$editor = "vim";' '$editor = "${nano}/bin/nano";'
|
|
|
|
|
|
|
|
wrapProgram $out/bin/$script \
|
2018-12-15 04:50:31 +01:00
|
|
|
--set PERL5LIB "${perlPackages.makePerlPath [ perlPackages.CDDB_get ]}" \
|
2018-04-08 03:42:13 +02:00
|
|
|
--set PATH "${toolDeps}"
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "http://bach.dynet.com/crip/";
|
2018-04-08 03:42:13 +02:00
|
|
|
description = "Terminal-based ripper/encoder/tagger tool for creating Ogg Vorbis/FLAC files";
|
|
|
|
license = stdenv.lib.licenses.gpl1;
|
|
|
|
platforms = stdenv.lib.platforms.linux;
|
|
|
|
maintainers = [ maintainers.endgame ];
|
|
|
|
};
|
|
|
|
}
|