fix(tubesync): patch ffmpeg
This commit is contained in:
parent
4341c81c05
commit
73d8353724
|
@ -6,6 +6,7 @@
|
||||||
, callPackage
|
, callPackage
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, fetchPypi
|
, fetchPypi
|
||||||
|
, fetchpatch
|
||||||
, makeWrapper
|
, makeWrapper
|
||||||
, python3Packages }: with python3Packages; let
|
, python3Packages }: with python3Packages; let
|
||||||
mkPypi = pname: version: src: format: buildPythonPackage {
|
mkPypi = pname: version: src: format: buildPythonPackage {
|
||||||
|
@ -88,13 +89,21 @@
|
||||||
mkdir -p "$out"
|
mkdir -p "$out"
|
||||||
cp -r "tubesync" "$out/app"
|
cp -r "tubesync" "$out/app"
|
||||||
|
|
||||||
FFMPEG_VERSION=$(${ffmpeg}/bin/ffmpeg -version | head -n 1 | awk '{ print $3 }')
|
FFMPEG_VERSION=$(${ffmpegFix}/bin/ffmpeg -version | head -n 1 | awk '{ print $3 }')
|
||||||
echo "ffmpeg_version = '$FFMPEG_VERSION'" >> "$out/app/common/third_party_versions.py"
|
echo "ffmpeg_version = '$FFMPEG_VERSION'" >> "$out/app/common/third_party_versions.py"
|
||||||
|
|
||||||
mv "$out/app/static" "$out/static"
|
mv "$out/app/static" "$out/static"
|
||||||
ln -s "/tmp/tubesync/static" "$out/app/static"
|
ln -s "/tmp/tubesync/static" "$out/app/static"
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
ffmpegFix = ffmpeg.overrideAttrs (finalAttrs: previousAttrs: {
|
||||||
|
patches = previousAttrs.patches ++ [ (fetchpatch {
|
||||||
|
name = "avformat-webvttdec-skip-style-region.patch";
|
||||||
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/51d303e20cbb0874172f50b5172c515a973587d4";
|
||||||
|
hash = "sha256-dxCjKZUz2H2QyktsprkzyfNp5aDG6X8deF4ZGdvhvfk=";
|
||||||
|
}) ];
|
||||||
|
});
|
||||||
in stdenvNoCC.mkDerivation {
|
in stdenvNoCC.mkDerivation {
|
||||||
pname = "${app.pname}-wrapped";
|
pname = "${app.pname}-wrapped";
|
||||||
inherit (app) version;
|
inherit (app) version;
|
||||||
|
@ -103,7 +112,7 @@ in stdenvNoCC.mkDerivation {
|
||||||
unpackPhase = "true";
|
unpackPhase = "true";
|
||||||
installPhase = let
|
installPhase = let
|
||||||
prefix = ''--prefix PATH : "${lib.makeBinPath [
|
prefix = ''--prefix PATH : "${lib.makeBinPath [
|
||||||
ffmpeg rtmpdump atomicparsley
|
ffmpegFix rtmpdump atomicparsley
|
||||||
]}"'';
|
]}"'';
|
||||||
in ''
|
in ''
|
||||||
mkdir -p "$out/bin"
|
mkdir -p "$out/bin"
|
||||||
|
|
Loading…
Reference in a new issue