at 22.05-pre 76 lines 1.6 kB view raw
1{ lib, stdenv 2, substituteAll 3, fetchFromGitHub 4, pkg-config 5, meson 6, ninja 7, gobject-introspection 8, python3 9, libyaml 10, rpm 11, file 12, gtk-doc 13, docbook-xsl-nons 14, help2man 15, docbook_xml_dtd_412 16, glib 17}: 18 19stdenv.mkDerivation rec { 20 pname = "libmodulemd"; 21 version = "2.13.0"; 22 23 outputs = [ "bin" "out" "dev" "devdoc" "man" "py" ]; 24 25 src = fetchFromGitHub { 26 owner = "fedora-modularity"; 27 repo = pname; 28 rev = "${pname}-${version}"; 29 sha256 = "sha256-hg/it3pHUnEYsmKcLzQKcZNthHZZwdXBjzTlOS1Losk="; 30 }; 31 32 patches = [ 33 # Use proper glib devdoc path. 34 (substituteAll { 35 src = ./glib-devdoc.patch; 36 glib_devdoc = glib.devdoc; 37 }) 38 ]; 39 40 nativeBuildInputs = [ 41 pkg-config 42 meson 43 ninja 44 gtk-doc 45 docbook-xsl-nons 46 help2man 47 docbook_xml_dtd_412 48 gobject-introspection 49 ]; 50 51 buildInputs = [ 52 libyaml 53 rpm 54 file # for libmagic 55 glib 56 ]; 57 58 mesonFlags = [ 59 "-Ddeveloper_build=false" 60 "-Dgobject_overrides_dir_py3=${placeholder "py"}/${python3.sitePackages}/gi/overrides" 61 ]; 62 63 postFixup = '' 64 # Python overrides depend our own typelibs and other packages 65 mkdir -p "$py/nix-support" 66 echo "$out ${python3.pkgs.pygobject3} ${python3.pkgs.six}" > "$py/nix-support/propagated-build-inputs" 67 ''; 68 69 meta = with lib; { 70 description = "C Library for manipulating module metadata files"; 71 homepage = "https://github.com/fedora-modularity/libmodulemd"; 72 license = licenses.mit; 73 maintainers = with maintainers; [ ]; 74 platforms = platforms.linux ++ platforms.darwin ; 75 }; 76}