home-assistant: 2025.2.0 -> 2025.2.1 (#380183)
[NixPkgs.git] / pkgs / desktops / plasma-5 / 3rdparty / addons / krunner-symbols.nix
blob6703944b01ffebbb9ebf40c46269dba9e4103cb9
2   lib,
3   stdenv,
4   cmake,
5   fetchFromGitHub,
6   extra-cmake-modules,
7   qtbase,
8   wrapQtAppsHook,
9   ki18n,
10   kdelibs4support,
11   krunner,
14 stdenv.mkDerivation rec {
15   pname = "krunner-symbols";
16   version = "1.1.0";
18   src = fetchFromGitHub {
19     owner = "domschrei";
20     repo = "krunner-symbols";
21     rev = version;
22     sha256 = "sha256-YsoZdPTWpk3/YERwerrVEcaf2IfGVJwpq32onhP8Exo=";
23   };
25   buildInputs = [
26     qtbase
27     ki18n
28     kdelibs4support
29     krunner
30   ];
31   nativeBuildInputs = [
32     cmake
33     wrapQtAppsHook
34     extra-cmake-modules
35   ];
37   postPatch = ''
38     # symbols.cpp hardcodes the location of configuration files
39     substituteInPlace symbols.cpp \
40       --replace "/usr/share/config/krunner-symbol" "$out/share/config/krunner-symbol"
42     # change cmake flag names to output using the correct qt-plugin prefix and kservice location
43     substituteInPlace CMakeLists.txt \
44       --replace "LOCATION_PLUGIN" "KDE_INSTALL_PLUGINDIR" \
45       --replace "LOCATION_DESKTOP" "KDE_INSTALL_KSERVICES5DIR"
46   '';
48   cmakeFlags = [ "-DLOCATION_CONFIG=share/config" ];
50   meta = with lib; {
51     description = "Little krunner plugin (Plasma 5) to retrieve unicode symbols, or any other string, based on a corresponding keyword";
52     homepage = "https://github.com/domschrei/krunner-symbols";
53     license = licenses.gpl3Plus;
54     maintainers = with maintainers; [ hqurve ];
55     platforms = platforms.linux;
56   };