Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 73 lines 1.4 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 fetchpatch, 6 icu, 7 meson, 8 ninja, 9 pkg-config, 10 python3, 11 xapian, 12 xz, 13 zstd, 14}: 15 16stdenv.mkDerivation rec { 17 pname = "libzim"; 18 version = "9.3.0"; 19 20 src = fetchFromGitHub { 21 owner = "openzim"; 22 repo = "libzim"; 23 tag = version; 24 hash = "sha256-DZiFeZ2ry3JpXDs3mvf0q7diwhkjQ2730KQkDQPbgcY="; 25 }; 26 27 patches = [ 28 # Upstream patch for ICU76 compatibility. 29 # https://github.com/openzim/libzim/pull/936 30 (fetchpatch { 31 url = "https://github.com/openzim/libzim/commit/4a42b3c6971c9534b104f48f6d13db8630a97d2f.patch"; 32 hash = "sha256-FjaGZ2bI1ROLg3rvWIGLbVoImGr51MbWjbBj+lGj1rs="; 33 }) 34 ]; 35 36 nativeBuildInputs = [ 37 ninja 38 meson 39 pkg-config 40 python3 41 ]; 42 43 buildInputs = [ 44 icu 45 zstd 46 ]; 47 48 propagatedBuildInputs = [ 49 xapian 50 xz 51 ]; 52 53 postPatch = '' 54 patchShebangs scripts 55 ''; 56 57 mesonFlags = [ 58 # Tests are located at https://github.com/openzim/zim-testing-suite 59 # "...some tests need up to 16GB of memory..." 60 "-Dtest_data_dir=none" 61 ]; 62 63 meta = { 64 description = "Reference implementation of the ZIM specification"; 65 homepage = "https://github.com/openzim/libzim"; 66 changelog = "https://github.com/openzim/libzim/releases/tag/${version}"; 67 license = lib.licenses.gpl2Plus; 68 maintainers = with lib.maintainers; [ 69 fab 70 greg 71 ]; 72 }; 73}