emacsPackages.notdeft: improve build process of notdeft-xapian
Before, the upstream Makefile[1] is used, which does not work well with nix: - Hardening flags of nix are ignored. - One binary of buildInput xapian is run at build time. [1]: https://github.com/hasu/notdeft/blob/1b7054dcfc3547a7cafeb621552cec01d0540478/xapian/Makefile#L10
This commit is contained in:
@@ -30,14 +30,23 @@ let
|
||||
pname = "notdeft-xapian";
|
||||
inherit version src;
|
||||
|
||||
sourceRoot = "${src.name}/xapian";
|
||||
strictDeps = true;
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
buildInputs = [
|
||||
tclap
|
||||
xapian
|
||||
];
|
||||
|
||||
buildPhase = ''
|
||||
runHook preBuild
|
||||
|
||||
$CXX -std=c++11 -o notdeft-xapian xapian/notdeft-xapian.cc -lxapian
|
||||
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
@@ -66,6 +75,10 @@ melpaBuild {
|
||||
${lib.optionalString withIvy ''"extras/notdeft-ivy.el"''})
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
inherit notdeft-xapian;
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = "https://tero.hasu.is/notdeft/";
|
||||
description = "Fork of Deft that uses Xapian as a search engine";
|
||||
|
||||
Reference in New Issue
Block a user