2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv
|
2020-04-24 23:36:52 +00:00
|
|
|
, substituteAll
|
|
|
|
, fetchFromGitHub
|
|
|
|
, pkg-config
|
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, gobject-introspection
|
|
|
|
, python3
|
|
|
|
, libyaml
|
|
|
|
, rpm
|
|
|
|
, file
|
|
|
|
, gtk-doc
|
|
|
|
, docbook-xsl-nons
|
|
|
|
, help2man
|
|
|
|
, docbook_xml_dtd_412
|
|
|
|
, glib
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "libmodulemd";
|
2021-07-21 07:28:18 +00:00
|
|
|
version = "2.13.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
outputs = [ "bin" "out" "dev" "devdoc" "man" "py" ];
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "fedora-modularity";
|
|
|
|
repo = pname;
|
|
|
|
rev = "${pname}-${version}";
|
2021-07-21 07:28:18 +00:00
|
|
|
sha256 = "sha256-hg/it3pHUnEYsmKcLzQKcZNthHZZwdXBjzTlOS1Losk=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
# Use proper glib devdoc path.
|
|
|
|
(substituteAll {
|
|
|
|
src = ./glib-devdoc.patch;
|
|
|
|
glib_devdoc = glib.devdoc;
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkg-config
|
|
|
|
meson
|
|
|
|
ninja
|
|
|
|
gtk-doc
|
|
|
|
docbook-xsl-nons
|
|
|
|
help2man
|
|
|
|
docbook_xml_dtd_412
|
|
|
|
gobject-introspection
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
libyaml
|
|
|
|
rpm
|
|
|
|
file # for libmagic
|
|
|
|
glib
|
|
|
|
];
|
|
|
|
|
|
|
|
mesonFlags = [
|
|
|
|
"-Ddeveloper_build=false"
|
|
|
|
"-Dgobject_overrides_dir_py3=${placeholder "py"}/${python3.sitePackages}/gi/overrides"
|
|
|
|
];
|
|
|
|
|
|
|
|
postFixup = ''
|
|
|
|
# Python overrides depend our own typelibs and other packages
|
|
|
|
mkdir -p "$py/nix-support"
|
|
|
|
echo "$out ${python3.pkgs.pygobject3} ${python3.pkgs.six}" > "$py/nix-support/propagated-build-inputs"
|
|
|
|
'';
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "C Library for manipulating module metadata files";
|
|
|
|
homepage = "https://github.com/fedora-modularity/libmodulemd";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ ];
|
2020-12-25 13:55:36 +00:00
|
|
|
platforms = platforms.linux ++ platforms.darwin ;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|