File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1717 } ) ;
1818 } ) ;
1919 } ;
20+ ffmpeg = pkgs . ffmpeg-full ; # we need librsvg support
21+
22+ fontconfigConf = pkgs . makeFontsConf {
23+ fontDirectories = [
24+ ( lib . sources . sourceFilesBySuffices ./hackyplayer/resources [ ".ttf" ] )
25+ ] ;
26+ } ;
27+ ffmpegWrapper = pkgs . writeShellScript "ffmpeg-wrapper" ''
28+ export FONTCONFIG_FILE="${ fontconfigConf } "
29+ exec "${ lib . getExe' ffmpeg "ffmpeg" } " "$@"
30+ '' ;
2031in
21- hackyplayer . dependencyEnv . override {
32+ ( hackyplayer . dependencyEnv . override {
2233 app = hackyplayer . overridePythonAttrs ( old : {
2334 postPatch = ''
2435 ${ old . postPatch or "" }
2536
2637 substituteInPlace hackyplayer/formvideo.py \
27- --replace-fail 'FFMPEG_BIN = "ffmpeg"' 'FFMPEG_BIN = "${ lib . getExe' pkgs . ffmpeg "ffmpeg" } "' \
38+ --replace-fail 'FFMPEG_BIN = "ffmpeg"' 'FFMPEG_BIN = "${ ffmpegWrapper } "' \
2839 --replace-fail 'IMAGEMAGICK_BIN = "convert"' 'IMAGEMAGICK_BIN = "${ lib . getExe' pkgs . imagemagick "convert" } "' \
2940 --replace-fail 'APP_ROOT = Path(".")' 'APP_ROOT = Path("${ placeholder "out" } /${ hackyplayer . python . sitePackages } /hackyplayer")'
3041 '' ;
3142 } ) ;
43+ } ) // {
44+ inherit fontconfigConf ffmpegWrapper ;
3245 }
You can’t perform that action at this time.
0 commit comments