tests: fix broken overlay in mpv test

This commit is contained in:
midchildan 2024-05-29 00:02:06 +09:00 committed by GitHub
parent 10c7c219b7
commit 373ead2060
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,14 +1,20 @@
{ pkgs, ... }:
{ {
nixpkgs.overlays = [ nixpkgs.overlays = [
(self: super: { (final: prev: {
mpvScript = pkgs.runCommandLocal "mpvScript" { scriptName = "something"; } mpvScript = prev.runCommandLocal "mpvScript" { scriptName = "something"; }
"mkdir $out"; "mkdir $out";
mpv-unwrapped = super.mpv-unwrapped.overrideAttrs { mpv-unwrapped = let
builder = pkgs.writeShellScript "dummy" '' lua = prev.emptyDirectory.overrideAttrs {
PATH=${pkgs.coreutils}/bin luaversion = "0";
passthru.withPackages = pkgsFn: prev.emptyDirectory;
};
mpv-unwrapped' = prev.mpv-unwrapped.override { inherit lua; };
in mpv-unwrapped'.overrideAttrs {
buildInputs = [ ];
nativeBuildInputs = [ ];
builder = prev.writeShellScript "dummy" ''
PATH=${final.coreutils}/bin
mkdir -p $dev $doc $man $out/bin $out/Applications/mpv.app/Contents/MacOS mkdir -p $dev $doc $man $out/bin $out/Applications/mpv.app/Contents/MacOS
touch $out/bin/{mpv,umpv} \ touch $out/bin/{mpv,umpv} \
$out/Applications/mpv.app/Contents/MacOS/{mpv,mpv-bundle} $out/Applications/mpv.app/Contents/MacOS/{mpv,mpv-bundle}
@ -16,11 +22,6 @@
$out/Applications/mpv.app/Contents/MacOS/{mpv,mpv-bundle} $out/Applications/mpv.app/Contents/MacOS/{mpv,mpv-bundle}
''; '';
}; };
lua = pkgs.emptyDirectory.overrideAttrs {
luaversion = "0";
withPackages = ps: pkgs.emptyDirectory;
};
}) })
]; ];