mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-26 04:43:09 +03:00
lucenepp: Add new package, version 3.0.6.
Required as a dependency of the Tomahawk music player. The latest upstream release needs to be patched quite a bit in order to build and to correctly install the header files. Other distributions seem to largely use the latest Git master version, because all those build problems have been fixed there already. In order to ensure we have version 3.0.6, we just cherry-pick the relevant patches, so as soon as the next upstream version is released we just need to drop the patches/postPatch attributes. The postPatch is needed in order to get rid of the subversion dependency, which the upstream build process tries to use for fetching gtest. We don't have networking support inside the Nix build process, so let's pass that dependency directly. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
This commit is contained in:
parent
281a95b454
commit
0a271c00be
46
pkgs/development/libraries/lucene++/default.nix
Normal file
46
pkgs/development/libraries/lucene++/default.nix
Normal file
@ -0,0 +1,46 @@
|
||||
{ stdenv, fetchurl, fetchpatch, cmake, boost, gtest }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "lucene++-${version}";
|
||||
version = "3.0.6";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/luceneplusplus/LucenePlusPlus/"
|
||||
+ "archive/rel_${version}.tar.gz";
|
||||
sha256 = "068msvh05gsbfj1wwdqj698kxxfjdqy8zb6pqvail3ayjfj94w1y";
|
||||
};
|
||||
|
||||
patches = let
|
||||
baseurl = "https://github.com/luceneplusplus/LucenePlusPlus";
|
||||
in [
|
||||
(fetchpatch {
|
||||
url = "${baseurl}/pull/62.diff";
|
||||
sha256 = "0v314877mjb0hljg4mcqi317m1p1v27rgsgf5wdr9swix43vmhgw";
|
||||
})
|
||||
(fetchpatch {
|
||||
url = "${baseurl}/commit/994f03cf736229044a168835ae7387696041658f.diff";
|
||||
sha256 = "0fcm5b87nxw062wjd7b4qrfcwsyblmcw19s64004pklj9grk30zz";
|
||||
})
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
sed -i -e '/Subversion *REQUIRED/d' \
|
||||
-e '/include.*CMakeExternal/d' \
|
||||
CMakeLists.txt
|
||||
# not using -f because we want it to fail for the next release
|
||||
rm CMakeExternal.txt
|
||||
'';
|
||||
|
||||
cmakeFlags = [ "-DGTEST_INCLUDE_DIR=${gtest}/include" ];
|
||||
buildInputs = [ cmake boost gtest ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
doCheck = true;
|
||||
checkTarget = "test";
|
||||
|
||||
meta = {
|
||||
description = "C++ port of the popular Java Lucene search engine";
|
||||
homepage = "https://github.com/luceneplusplus/LucenePlusPlus";
|
||||
license = with stdenv.lib.licenses; [ asl20 lgpl3Plus ];
|
||||
};
|
||||
}
|
@ -7198,6 +7198,8 @@ let
|
||||
|
||||
lucene = callPackage ../development/libraries/java/lucene { };
|
||||
|
||||
lucenepp = callPackage ../development/libraries/lucene++ { };
|
||||
|
||||
mockobjects = callPackage ../development/libraries/java/mockobjects { };
|
||||
|
||||
saxon = callPackage ../development/libraries/java/saxon { };
|
||||
|
Loading…
Reference in New Issue
Block a user