more work on av1an
This commit is contained in:
parent
1df5f843dc
commit
21bd5ef1ae
|
@ -1,48 +1,36 @@
|
|||
{lib, fetchFromGitHub, python3, python3Packages, ffmpeg-full, libaom }:
|
||||
{lib, fetchFromGitHub, python3, python3Packages, stdenv, ffmpeg-full, libaom }:
|
||||
|
||||
let
|
||||
scenedetect = python3Packages.buildPythonPackage rec {
|
||||
pname = "scenedetect";
|
||||
version = "0.5.1.1";
|
||||
|
||||
src = python3Packages.fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "097y3v7rjq75rpzysxksqjhbk8m3g7wn46spc380zjhy3if6nlhn";
|
||||
};
|
||||
};
|
||||
|
||||
opencv-python = python3Packages.buildPythonPackage rec {
|
||||
pname = "opencv-python";
|
||||
version = "4.2.0.32";
|
||||
|
||||
src = python3Packages.fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "19xm24vgfqis0bqrg5fc5jxf5yr1md5y49kb7q3792gihykl6yz2";
|
||||
};
|
||||
};
|
||||
|
||||
pythonEnv = python3.withPackages (pythonPackages: [
|
||||
pythonPackages.numpy
|
||||
scenedetect
|
||||
opencv-python
|
||||
pythonEnv = python3.withPackages (pythonPackages: [
|
||||
pythonPackages.tqdm
|
||||
pythonPackages.psutil
|
||||
]);
|
||||
|
||||
in
|
||||
python3Packages.buildPythonApplication rec {
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "av1an";
|
||||
version = "1.6";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "master-of-zen";
|
||||
repo = "AV1an";
|
||||
rev = "${version}";
|
||||
sha256 = "19xm24vgfqis0bqrg5fc5jxf5yr1md5y49kb7q3792gihykl6yz3";
|
||||
};
|
||||
src = ./Av1an;
|
||||
|
||||
# fetchFromGitHub {
|
||||
# owner = "master-of-zen";
|
||||
# repo = "AV1an";
|
||||
# rev = "${version}";
|
||||
# sha256 = "19xm24vgfqis0bqrg5fc5jxf5yr1md5y49kb7q3792gihykl6yz3";
|
||||
# };
|
||||
|
||||
buildInputs = [ pythonEnv ffmpeg-full libaom ];
|
||||
|
||||
meta.broken = true;
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
sed "s!self.FFMPEG = 'ffmpeg -y -hide_banner -loglevel error'!self.FFMPEG = '${ffmpeg-full}/bin/ffmpeg -y -hide_banner -loglevel error'!g" ./av1an.py > $out/bin/av1an
|
||||
sed -i "s!self.AOMENC_BINARY = 'aomenc'!self.AOMENC_BINARY = '${libaom}/bin/aomenc'!g" $out/bin/av1an
|
||||
chmod +x $out/bin/av1an
|
||||
'';
|
||||
|
||||
|
||||
meta.broken = false;
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue