Nix: patch in search dir

This commit is contained in:
Mihai Fufezan 2024-04-04 08:48:42 +03:00
parent 752cc44779
commit be7e9f93cf
Signed by: fufexan
SSH key fingerprint: SHA256:SdnKmEpJrDu1+2UO1QpB/Eg4HKcdDi6n+xSRqFNJVpg
2 changed files with 18 additions and 0 deletions

View file

@ -14,6 +14,11 @@ stdenv.mkDerivation {
inherit version; inherit version;
src = ../.; src = ../.;
patches = [
# adds /run/current-system/sw/share/icons to the icon lookup directories
./dirs.patch
];
nativeBuildInputs = [ nativeBuildInputs = [
cmake cmake
pkg-config pkg-config

13
nix/dirs.patch Normal file
View file

@ -0,0 +1,13 @@
diff --git a/libhyprcursor/hyprcursor.cpp b/libhyprcursor/hyprcursor.cpp
index 304ab9f..1f7e95d 100644
--- a/libhyprcursor/hyprcursor.cpp
+++ b/libhyprcursor/hyprcursor.cpp
@@ -14,7 +14,7 @@
using namespace Hyprcursor;
// directories for lookup
-constexpr const std::array<const char*, 1> systemThemeDirs = {"/usr/share/icons"};
+constexpr const std::array<const char*, 2> systemThemeDirs = {"/usr/share/icons", "/run/current-system/sw/share/icons"};
constexpr const std::array<const char*, 2> userThemeDirs = {"/.local/share/icons", "/.icons"};
//