Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 fetchpatch, 6 cmake, 7 neon, 8 libdiscid, 9 libxml2, 10 pkg-config, 11}: 12 13stdenv.mkDerivation rec { 14 version = "5.1.0"; 15 pname = "libmusicbrainz"; 16 17 nativeBuildInputs = [ 18 cmake 19 pkg-config 20 ]; 21 buildInputs = [ 22 neon 23 libdiscid 24 libxml2 25 ]; 26 27 src = fetchFromGitHub { 28 owner = "metabrainz"; 29 repo = "libmusicbrainz"; 30 sha256 = "0ah9kaf3g3iv1cps2vs1hs33nfbjfx1xscpjgxr1cg28p4ri6jhq"; 31 rev = "release-${version}"; 32 }; 33 34 patches = [ 35 # Fix build with libxml2 2.12 36 (fetchpatch { 37 url = "https://github.com/metabrainz/libmusicbrainz/commit/9ba00067a15479a52262a5126bcb6889da5884b7.patch"; 38 hash = "sha256-4VxTohLpjUNnNZGIoRpBjUz71mLP3blg4oFL7itnJnY="; 39 }) 40 (fetchpatch { 41 url = "https://github.com/metabrainz/libmusicbrainz/commit/558c9ba0e6d702d5c877f75be98176f57abf1b02.patch"; 42 hash = "sha256-hKYY4BJLh/Real3NugLwzc4gPBQ3NB/F63iI/aV8Wh8="; 43 }) 44 ]; 45 46 dontUseCmakeBuildDir = true; 47 48 meta = with lib; { 49 homepage = "http://musicbrainz.org/doc/libmusicbrainz"; 50 description = "MusicBrainz Client Library (5.x version)"; 51 longDescription = '' 52 The libmusicbrainz (also known as mb_client or MusicBrainz Client 53 Library) is a development library geared towards developers who wish to 54 add MusicBrainz lookup capabilities to their applications.''; 55 platforms = platforms.all; 56 license = licenses.lgpl21; 57 }; 58}