about summary refs log tree commit diff
path: root/pkgs/kde/gear/akonadi-search/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/kde/gear/akonadi-search/default.nix')
-rw-r--r--pkgs/kde/gear/akonadi-search/default.nix33
1 files changed, 33 insertions, 0 deletions
diff --git a/pkgs/kde/gear/akonadi-search/default.nix b/pkgs/kde/gear/akonadi-search/default.nix
new file mode 100644
index 000000000000..87f743f86c30
--- /dev/null
+++ b/pkgs/kde/gear/akonadi-search/default.nix
@@ -0,0 +1,33 @@
+{
+  mkKdeDerivation,
+  sources,
+  corrosion,
+  xapian,
+  rustPlatform,
+  cargo,
+  rustc,
+  # provided as callPackage input to enable easier overrides through overlays
+  cargoHash ? "sha256-euUaB+QCwwwPjrUq+3NHt0hjDSW5gch8MwS57KmtIWI=",
+}:
+mkKdeDerivation rec {
+  pname = "akonadi-search";
+  inherit (sources.${pname}) version;
+
+  cargoRoot = "agent/rs/htmlparser";
+
+  cargoDeps = rustPlatform.fetchCargoTarball {
+    # include version in the name so we invalidate the FOD
+    name = "${pname}-${version}";
+    src = sources.${pname};
+    sourceRoot = "${pname}-${version}/${cargoRoot}";
+    hash = cargoHash;
+  };
+
+  extraNativeBuildInputs = [
+    rustPlatform.cargoSetupHook
+    cargo
+    rustc
+  ];
+
+  extraBuildInputs = [corrosion xapian];
+}