2021-01-21 18:00:13 +01:00
|
|
|
{ lib, stdenv
|
2020-04-05 03:54:09 +02:00
|
|
|
, substituteAll
|
2019-07-31 03:46:13 +02:00
|
|
|
, fetchFromGitHub
|
2020-04-05 03:54:09 +02:00
|
|
|
, pkg-config
|
2019-07-31 03:46:13 +02:00
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, gobject-introspection
|
|
|
|
, python3
|
|
|
|
, libyaml
|
2020-04-05 03:54:09 +02:00
|
|
|
, rpm
|
|
|
|
, file
|
2019-07-31 03:46:13 +02:00
|
|
|
, gtk-doc
|
2020-04-05 03:54:09 +02:00
|
|
|
, docbook-xsl-nons
|
2019-07-31 03:46:13 +02:00
|
|
|
, docbook_xml_dtd_412
|
|
|
|
, glib
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "libmodulemd";
|
2022-02-12 11:56:19 +01:00
|
|
|
version = "2.14.0";
|
2019-07-31 03:46:13 +02:00
|
|
|
|
2020-04-05 03:54:09 +02:00
|
|
|
outputs = [ "bin" "out" "dev" "devdoc" "man" "py" ];
|
2019-07-31 03:46:13 +02:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "fedora-modularity";
|
|
|
|
repo = pname;
|
|
|
|
rev = "${pname}-${version}";
|
2022-02-12 11:56:19 +01:00
|
|
|
sha256 = "sha256-ccLk8O0UJwy7WZYr5Bq2XqaSFNe4i7HQehmVoB5C2Yg=";
|
2019-07-31 03:46:13 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
patches = [
|
2020-04-05 03:54:09 +02:00
|
|
|
# Use proper glib devdoc path.
|
|
|
|
(substituteAll {
|
|
|
|
src = ./glib-devdoc.patch;
|
|
|
|
glib_devdoc = glib.devdoc;
|
|
|
|
})
|
2019-07-31 03:46:13 +02:00
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2020-04-05 03:54:09 +02:00
|
|
|
pkg-config
|
2019-07-31 03:46:13 +02:00
|
|
|
meson
|
|
|
|
ninja
|
|
|
|
gtk-doc
|
2020-04-05 03:54:09 +02:00
|
|
|
docbook-xsl-nons
|
2019-07-31 03:46:13 +02:00
|
|
|
docbook_xml_dtd_412
|
|
|
|
gobject-introspection
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
libyaml
|
2020-04-05 03:54:09 +02:00
|
|
|
rpm
|
|
|
|
file # for libmagic
|
2019-07-31 03:46:13 +02:00
|
|
|
glib
|
|
|
|
];
|
|
|
|
|
|
|
|
mesonFlags = [
|
2020-04-07 19:14:55 +02:00
|
|
|
"-Dgobject_overrides_dir_py3=${placeholder "py"}/${python3.sitePackages}/gi/overrides"
|
2019-07-31 03:46:13 +02:00
|
|
|
];
|
|
|
|
|
2020-04-07 19:14:55 +02:00
|
|
|
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-01-21 18:00:13 +01:00
|
|
|
meta = with lib; {
|
2019-07-31 03:46:13 +02:00
|
|
|
description = "C Library for manipulating module metadata files";
|
|
|
|
homepage = "https://github.com/fedora-modularity/libmodulemd";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ ];
|
2020-12-17 16:31:51 +01:00
|
|
|
platforms = platforms.linux ++ platforms.darwin ;
|
2019-07-31 03:46:13 +02:00
|
|
|
};
|
|
|
|
}
|