2022-02-24 15:16:47 +00:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
2019-08-22 22:31:27 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, docbook_xml_dtd_43
|
2022-04-29 15:38:39 +00:00
|
|
|
, docbook-xsl-nons
|
2019-08-22 22:31:27 +00:00
|
|
|
, glib
|
|
|
|
, gobject-introspection
|
|
|
|
, gtk-doc
|
|
|
|
, meson
|
|
|
|
, ninja
|
2021-01-19 06:50:56 +00:00
|
|
|
, pkg-config
|
2019-08-22 22:31:27 +00:00
|
|
|
, python3
|
|
|
|
, shared-mime-info
|
2019-08-22 23:34:48 +00:00
|
|
|
, nixosTests
|
2022-02-24 15:16:47 +00:00
|
|
|
, xz
|
2019-08-22 22:31:27 +00:00
|
|
|
}:
|
2018-11-10 14:21:27 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-22 22:31:27 +00:00
|
|
|
pname = "libxmlb";
|
2022-04-29 15:38:39 +00:00
|
|
|
version = "0.3.8";
|
2018-11-10 14:21:27 +00:00
|
|
|
|
2019-08-22 22:31:27 +00:00
|
|
|
outputs = [ "out" "lib" "dev" "devdoc" "installedTests" ];
|
2018-11-10 14:21:27 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "hughsie";
|
|
|
|
repo = "libxmlb";
|
|
|
|
rev = version;
|
2022-04-29 15:38:39 +00:00
|
|
|
sha256 = "vT/NGFDzP0ut+TKD8pYVQrjTkepzKEJUo3uKF4MX334=";
|
2018-11-10 14:21:27 +00:00
|
|
|
};
|
|
|
|
|
2019-08-22 22:31:27 +00:00
|
|
|
patches = [
|
|
|
|
./installed-tests-path.patch
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
docbook_xml_dtd_43
|
2022-04-29 15:38:39 +00:00
|
|
|
docbook-xsl-nons
|
2019-08-22 22:31:27 +00:00
|
|
|
gobject-introspection
|
|
|
|
gtk-doc
|
|
|
|
meson
|
|
|
|
ninja
|
2021-01-19 06:50:56 +00:00
|
|
|
pkg-config
|
2022-02-24 15:16:47 +00:00
|
|
|
python3
|
2019-08-22 22:31:27 +00:00
|
|
|
shared-mime-info
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
glib
|
2022-02-24 15:16:47 +00:00
|
|
|
xz
|
2019-08-22 22:31:27 +00:00
|
|
|
];
|
2018-11-10 14:21:27 +00:00
|
|
|
|
|
|
|
mesonFlags = [
|
|
|
|
"--libexecdir=${placeholder "out"}/libexec"
|
|
|
|
"-Dgtkdoc=true"
|
2019-08-22 22:31:27 +00:00
|
|
|
"-Dinstalled_test_prefix=${placeholder "installedTests"}"
|
2018-11-10 14:21:27 +00:00
|
|
|
];
|
|
|
|
|
2019-02-16 07:40:40 +00:00
|
|
|
preCheck = ''
|
|
|
|
export XDG_DATA_DIRS=$XDG_DATA_DIRS:${shared-mime-info}/share
|
|
|
|
'';
|
|
|
|
|
2018-11-10 14:21:27 +00:00
|
|
|
doCheck = true;
|
|
|
|
|
2019-08-22 23:34:48 +00:00
|
|
|
passthru = {
|
|
|
|
tests = {
|
2019-11-07 13:38:08 +00:00
|
|
|
installed-tests = nixosTests.installed-tests.libxmlb;
|
2019-08-22 23:34:48 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2021-01-21 17:00:13 +00:00
|
|
|
meta = with lib; {
|
2018-11-10 14:21:27 +00:00
|
|
|
description = "A library to help create and query binary XML blobs";
|
2020-03-06 20:23:24 +00:00
|
|
|
homepage = "https://github.com/hughsie/libxmlb";
|
2018-11-10 14:21:27 +00:00
|
|
|
license = licenses.lgpl21Plus;
|
|
|
|
maintainers = with maintainers; [ jtojnar ];
|
2022-02-25 14:51:08 +00:00
|
|
|
platforms = platforms.unix;
|
2018-11-10 14:21:27 +00:00
|
|
|
};
|
|
|
|
}
|