fix(gsr): separate binaries to fix cap problem
All checks were successful
Discord / discord commits (push) Has been skipped
All checks were successful
Discord / discord commits (push) Has been skipped
This commit is contained in:
parent
e2c14d000c
commit
685825fb07
2 changed files with 13 additions and 6 deletions
|
@ -11,7 +11,7 @@
|
||||||
|
|
||||||
cfgDesktop = config.roles.desktop;
|
cfgDesktop = config.roles.desktop;
|
||||||
|
|
||||||
gsr = self.packages.${pkgs.system}.gpu-screen-recorder;
|
pkg = self.packages.${pkgs.system}.gpu-screen-recorder;
|
||||||
hyprPkgs = config.home-manager.users.${mainUser}.wayland.windowManager.hyprland.finalPackage;
|
hyprPkgs = config.home-manager.users.${mainUser}.wayland.windowManager.hyprland.finalPackage;
|
||||||
in {
|
in {
|
||||||
security.wrappers = {
|
security.wrappers = {
|
||||||
|
@ -19,21 +19,19 @@ in {
|
||||||
owner = "root";
|
owner = "root";
|
||||||
group = "video";
|
group = "video";
|
||||||
capabilities = "cap_sys_nice+ep";
|
capabilities = "cap_sys_nice+ep";
|
||||||
source = "${gsr}/bin/gpu-screen-recorder";
|
source = "${pkg.gsr}/bin/gpu-screen-recorder";
|
||||||
};
|
};
|
||||||
|
|
||||||
gsr-kms-server = {
|
gsr-kms-server = {
|
||||||
owner = "root";
|
owner = "root";
|
||||||
group = "video";
|
group = "video";
|
||||||
capabilities = "cap_sys_admin+ep";
|
capabilities = "cap_sys_admin+ep";
|
||||||
source = "${gsr}/bin/gsr-kms-server";
|
source = "${pkg.kms}/bin/gsr-kms-server";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
home-manager.users.${mainUser} = {
|
home-manager.users.${mainUser} = {
|
||||||
home.packages = [
|
home.packages = [
|
||||||
gsr
|
|
||||||
|
|
||||||
(pkgs.writeShellApplication {
|
(pkgs.writeShellApplication {
|
||||||
name = "gpu-save-replay";
|
name = "gpu-save-replay";
|
||||||
runtimeInputs = [pkgs.procps];
|
runtimeInputs = [pkgs.procps];
|
||||||
|
@ -55,7 +53,7 @@ in {
|
||||||
gpu-screen-recorder ${concatStringsSep " " [
|
gpu-screen-recorder ${concatStringsSep " " [
|
||||||
''-v no''
|
''-v no''
|
||||||
''-r 1200''
|
''-r 1200''
|
||||||
''-mf yes''
|
''-df yes''
|
||||||
''-o /home/matt/Videos/Replay''
|
''-o /home/matt/Videos/Replay''
|
||||||
# Audio settings
|
# Audio settings
|
||||||
''-ac aac''
|
''-ac aac''
|
||||||
|
|
|
@ -69,8 +69,17 @@ in
|
||||||
libglvnd
|
libglvnd
|
||||||
]
|
]
|
||||||
}"
|
}"
|
||||||
|
|
||||||
|
# This is needed to force gsr to lookup kms in PATH
|
||||||
|
# to get the security wrapper
|
||||||
|
mkdir -p $gsr $kms/bin
|
||||||
|
cp -r $out/bin $gsr
|
||||||
|
mv $gsr/bin/gsr-kms-server $kms/bin
|
||||||
|
rm $out/bin/gsr-kms-server
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
outputs = ["out" "gsr" "kms"];
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
description = "Screen recorder that has minimal impact on system performance by recording a window using the GPU only";
|
description = "Screen recorder that has minimal impact on system performance by recording a window using the GPU only";
|
||||||
homepage = "https://git.dec05eba.com/gpu-screen-recorder/about/";
|
homepage = "https://git.dec05eba.com/gpu-screen-recorder/about/";
|
||||||
|
|
Loading…
Reference in a new issue