19 stdenv.mkDerivation rec {
23 outputs = [ "out" "dev" "man" ];
26 url = "https://download.drobilla.net/${pname}-${version}.tar.xz";
27 hash = "sha256-a7a+n4hQQXbQZC8S3oCbK54txVYhporbjH7bma76u08=";
30 nativeBuildInputs = [ meson ninja pkg-config python3 ];
31 buildInputs = [ libsndfile serd sord sratom ];
32 propagatedBuildInputs = [ lv2 ];
35 (lib.mesonOption "docs" "disabled")
36 # Tests require building a shared library.
37 (lib.mesonEnable "tests" (!stdenv.hostPlatform.isStatic))
38 ] # Add nix and NixOS specific lv2 paths
39 # The default values are from: https://github.com/lv2/lilv/blob/master/src/lilv_config.h
40 ++ lib.optional stdenv.isDarwin (lib.mesonOption "default_lv2_path"
41 "~/.lv2:~/Library/Audio/Plug-Ins/LV2:"
42 + "/usr/local/lib/lv2:/usr/lib/lv2:"
43 + "/Library/Audio/Plug-Ins/LV2:"
44 + "~/.nix-profile/lib/lv2")
45 ++ lib.optional stdenv.isLinux (lib.mesonOption "default_lv2_path"
46 "~/.lv2:/usr/local/lib/lv2:/usr/lib/lv2:"
47 + "~/.nix-profile/lib/lv2:/run/current-system/sw/lib/lv2");
53 updateScript = gitUpdater {
54 url = "https://gitlab.com/lv2/lilv.git";
60 homepage = "http://drobilla.net/software/lilv";
61 description = "C library to make the use of LV2 plugins";
62 license = licenses.mit;
64 platforms = platforms.unix;