refactor(gsr): clean up deriv and remove path warning
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
f68fcce055
commit
2c070a4be0
3 changed files with 18 additions and 9 deletions
|
@ -11,7 +11,7 @@ in {
|
||||||
|
|
||||||
package =
|
package =
|
||||||
(pkgs.searxng.override {
|
(pkgs.searxng.override {
|
||||||
# FIXME: https://github.com/NixOS/nixpkgs/issues/380351
|
# FIXME: https://pr-tracker.nelim.org/?pr=381174
|
||||||
python3 = pkgs.python3.override {
|
python3 = pkgs.python3.override {
|
||||||
packageOverrides = pyFinal: pyPrev: {
|
packageOverrides = pyFinal: pyPrev: {
|
||||||
httpx = pyPrev.httpx.overridePythonAttrs (o: rec {
|
httpx = pyPrev.httpx.overridePythonAttrs (o: rec {
|
||||||
|
|
|
@ -1,6 +1,10 @@
|
||||||
{
|
{
|
||||||
lib,
|
# Params
|
||||||
|
pname,
|
||||||
gpu-screen-recorder-src,
|
gpu-screen-recorder-src,
|
||||||
|
isKmsServer ? false,
|
||||||
|
# Derivation deps
|
||||||
|
lib,
|
||||||
addDriverRunpath,
|
addDriverRunpath,
|
||||||
dbus,
|
dbus,
|
||||||
ffmpeg,
|
ffmpeg,
|
||||||
|
@ -17,7 +21,6 @@
|
||||||
vulkan-headers,
|
vulkan-headers,
|
||||||
wayland,
|
wayland,
|
||||||
xorg,
|
xorg,
|
||||||
pname,
|
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (lib) makeLibraryPath;
|
inherit (lib) makeLibraryPath;
|
||||||
|
@ -34,6 +37,11 @@ in
|
||||||
|
|
||||||
src = gpu-screen-recorder-src;
|
src = gpu-screen-recorder-src;
|
||||||
|
|
||||||
|
# Get rid of useless warning
|
||||||
|
postPatch = ''
|
||||||
|
sed -i 's/.*gsr-kms-server is not installed in the same directory.*//' ./kms/client/kms_client.c
|
||||||
|
'';
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
pkg-config
|
pkg-config
|
||||||
makeWrapper
|
makeWrapper
|
||||||
|
@ -79,17 +87,17 @@ in
|
||||||
# This is needed to force gsr to lookup kms in PATH
|
# This is needed to force gsr to lookup kms in PATH
|
||||||
# to get the security wrapper
|
# to get the security wrapper
|
||||||
postFixup =
|
postFixup =
|
||||||
if pname == "gpu-screen-recorder"
|
if isKmsServer
|
||||||
then
|
then
|
||||||
# bash
|
|
||||||
''
|
|
||||||
rm $out/bin/gsr-kms-server
|
|
||||||
''
|
|
||||||
else
|
|
||||||
# bash
|
# bash
|
||||||
''
|
''
|
||||||
rm $out/bin/gpu-screen-recorder
|
rm $out/bin/gpu-screen-recorder
|
||||||
rm $out/bin/.gpu-screen-recorder-wrapped
|
rm $out/bin/.gpu-screen-recorder-wrapped
|
||||||
|
''
|
||||||
|
else
|
||||||
|
# bash
|
||||||
|
''
|
||||||
|
rm $out/bin/gsr-kms-server
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
|
|
|
@ -5,5 +5,6 @@
|
||||||
}:
|
}:
|
||||||
callPackage ./generic.nix {
|
callPackage ./generic.nix {
|
||||||
pname = "gsr-kms-server";
|
pname = "gsr-kms-server";
|
||||||
|
isKmsServer = true;
|
||||||
inherit gpu-screen-recorder-src;
|
inherit gpu-screen-recorder-src;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue