diff --git a/pkgs/by-name/hy/hyprland/package.nix b/pkgs/by-name/hy/hyprland/package.nix index 6fb149c7fb6f..215cc6a4560b 100644 --- a/pkgs/by-name/hy/hyprland/package.nix +++ b/pkgs/by-name/hy/hyprland/package.nix @@ -12,7 +12,6 @@ binutils, cairo, epoll-shim, - git, glaze, hyprcursor, hyprgraphics, @@ -104,17 +103,22 @@ customStdenv.mkDerivation (finalAttrs: { postPatch = '' # Fix hardcoded paths to /usr installation - sed -i "s#/usr#$out#" src/render/OpenGL.cpp + substituteInPlace src/render/OpenGL.cpp \ + --replace-fail /usr $out # Remove extra @PREFIX@ to fix pkg-config paths - sed -i "s#@PREFIX@/##g" hyprland.pc.in - sed -i "s#@PREFIX@/##g" example/hyprland.desktop.in + substituteInPlace hyprland.pc.in \ + --replace-fail @PREFIX@ "" + substituteInPlace example/hyprland.desktop.in \ + --replace-fail @PREFIX@ "" ''; # variables used by CMake, and shown in `hyprctl version` env = { GIT_BRANCH = info.branch; - GIT_COMMITS = info.commit_hash; + # The amount of commits altogether. Not really worth getting that info from + # GitHub's API, so we set a dummy value. + GIT_COMMITS = "-1"; GIT_COMMIT_DATE = info.date; GIT_DIRTY = "clean"; GIT_COMMIT_HASH = info.commit_hash; @@ -152,7 +156,6 @@ customStdenv.mkDerivation (finalAttrs: { aquamarine cairo glaze - git hyprcursor.dev hyprgraphics hyprlang