linux_xanmod: 5.11.14 -> 5.11.15
[NixPkgs.git] / pkgs / development / libraries / xapian / default.nix
blobe2d049cd7b3c72b5d16f962596703e5006f5de70
1 { lib, stdenv, fetchurl, autoreconfHook
2 , libuuid, zlib }:
4 let
5   generic = version: sha256: stdenv.mkDerivation {
6     pname = "xapian";
7     inherit version;
8     passthru = { inherit version; };
10     src = fetchurl {
11       url = "https://oligarchy.co.uk/xapian/${version}/xapian-core-${version}.tar.xz";
12       inherit sha256;
13     };
15     outputs = [ "out" "man" "doc" ];
17     buildInputs = [ libuuid zlib ];
18     nativeBuildInputs = [ autoreconfHook ];
20     doCheck = true;
21     AUTOMATED_TESTING = true; # https://trac.xapian.org/changeset/8be35f5e1/git
23     patches = lib.optionals stdenv.isDarwin [ ./skip-flaky-darwin-test.patch ];
25     # the configure script thinks that Darwin has ___exp10
26     # but it’s not available on my systems (or hydra apparently)
27     postConfigure = lib.optionalString stdenv.isDarwin ''
28       substituteInPlace config.h \
29         --replace "#define HAVE___EXP10 1" "#undef HAVE___EXP10"
30     '';
32     meta = with lib; {
33       description = "Search engine library";
34       homepage = "https://xapian.org/";
35       license = licenses.gpl2Plus;
36       maintainers = with maintainers; [ ];
37       platforms = platforms.unix;
38     };
39   };
40 in {
41   xapian_1_4 = generic "1.4.18" "sha256-GW3btK0QRQEA8JkaWZ5O2UTLrZLkpv6BO+bc4WAkS3c=";