1 { lib, stdenv, fetchFromGitHub, fetchpatch, cmake, boost, gtest, zlib }:
3 stdenv.mkDerivation rec {
7 src = fetchFromGitHub {
8 owner = "luceneplusplus";
9 repo = "LucenePlusPlus";
10 rev = "rel_${version}";
11 sha256 = "12v7r62f7pqh5h210pb74sfx6h70lj4pgfpva8ya2d55fn0qxrr2";
14 nativeBuildInputs = [ cmake ];
15 buildInputs = [ boost gtest zlib ];
17 cmakeFlags = [ "-DCMAKE_INSTALL_LIBDIR=lib" ];
21 name = "pkgconfig_use_correct_LIBDIR_for_destination_library";
22 url = "https://github.com/luceneplusplus/LucenePlusPlus/commit/39cd44bd54e918d25ee464477992ad0dc234dcba.patch";
23 sha256 = "sha256-PP6ENNhPJMWrYDlTnr156XV8d5aX/VNX8v4vvi9ZiWo";
28 substituteInPlace src/test/CMakeLists.txt \
29 --replace "add_subdirectory(gtest)" ""
36 LD_LIBRARY_PATH=$PWD/src/contrib:$PWD/src/core \
37 src/test/lucene++-tester
42 mv $out/include/pkgconfig $out/lib/
43 cp $src/src/contrib/include/*h $out/include/lucene++/
47 description = "C++ port of the popular Java Lucene search engine";
48 homepage = "https://github.com/luceneplusplus/LucenePlusPlus";
49 license = with lib.licenses; [ asl20 lgpl3Plus ];
50 platforms = lib.platforms.linux;