-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Temporary v4l2 overrideAttrs to work around breaking change in NixOS/nixpkgs#134311
- Loading branch information
Showing
1 changed file
with
18 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,21 @@ | ||
{ pkgs, ... }: { | ||
{ config, pkgs, ... }: { | ||
programs.adb.enable = true; | ||
|
||
boot = { | ||
extraModulePackages = [ (config.boot.kernelPackages.v4l2loopback.overrideAttrs (old: { | ||
outputs = ["out"]; | ||
postInstall = '' | ||
make install-utils PREFIX=$out | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
frogamic
Author
Owner
|
||
''; | ||
})) ]; | ||
kernelModules = [ "v4l2loopback" ]; | ||
extraModprobeConfig = '' | ||
options v4l2loopback exclusive_caps=1 | ||
''; | ||
}; | ||
|
||
environment.systemPackages = with pkgs; [ | ||
droidcam | ||
adbfs-rootless | ||
android-file-transfer | ||
android-udev-rules | ||
|
@@ -18,19 +32,13 @@ | |
crop = "1080:2204:0:136"; | ||
title = "Touhou LostWord"; | ||
}) | ||
|
||
(mylib.mkAdbApp { | ||
bin="adbscreen"; | ||
}) | ||
(pkgs.writeShellScriptBin "adbshot" '' | ||
FILENAME="$(date --iso-8601=seconds).png" | ||
adb shell screencap -p > "$FILENAME" && \ | ||
${pkgs.file}/bin/file "$FILENAME" | ||
'') | ||
(pkgs.writeShellScriptBin "adbscreen" '' | ||
args=( | ||
"--render-driver" "opengl" \ | ||
"--bit-rate" "12M" \ | ||
"$''\@" \ | ||
) | ||
exec ${pkgs.scrcpy}/bin/scrcpy "''${args[''\@]}" | ||
'') | ||
]; | ||
} |
Why do you want the utils?