3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/os-specific/linux/bolt/default.nix

62 lines
1.5 KiB
Nix
Raw Normal View History

2019-02-18 21:58:30 +00:00
{ stdenv, meson, ninja, pkgconfig, fetchFromGitLab,
python3, umockdev, gobject-introspection, dbus,
asciidoc, libxml2, libxslt, docbook_xml_dtd_45, docbook_xsl,
glib, systemd, polkit
}:
stdenv.mkDerivation rec {
pname = "bolt";
2019-08-18 19:13:42 +01:00
version = "0.8";
2019-02-18 21:58:30 +00:00
src = fetchFromGitLab {
domain = "gitlab.freedesktop.org";
owner = "bolt";
repo = "bolt";
2019-09-09 00:38:31 +01:00
rev = version;
2019-08-18 19:13:42 +01:00
sha256 = "1qamls0fll0qc27lqavf56hv1yj6v6n4ry90g7bcnwpvccmd82yd";
2019-02-18 21:58:30 +00:00
};
nativeBuildInputs = [
meson ninja pkgconfig
asciidoc libxml2 libxslt docbook_xml_dtd_45 docbook_xsl
] ++ stdenv.lib.optional (!doCheck) python3;
buildInputs = [
glib systemd polkit
];
doCheck = true;
preCheck = ''
export LD_LIBRARY_PATH=${umockdev.out}/lib/
'';
checkInputs = [
dbus umockdev gobject-introspection
(python3.withPackages
(p: [ p.pygobject3 p.dbus-python p.python-dbusmock ]))
];
# meson install tries to create /var/lib/boltd
patches = [ ./0001-skip-mkdir.patch ];
postPatch = ''
2019-08-18 19:13:42 +01:00
patchShebangs scripts tests
2019-02-18 21:58:30 +00:00
'';
mesonFlags = [
"-Dlocalstatedir=/var"
];
PKG_CONFIG_SYSTEMD_SYSTEMDSYSTEMUNITDIR = "${placeholder "out"}/lib/systemd/system";
PKG_CONFIG_UDEV_UDEVDIR = "${placeholder "out"}/lib/udev";
meta = with stdenv.lib; {
description = "Thunderbolt 3 device management daemon";
homepage = "https://gitlab.freedesktop.org/bolt/bolt";
2019-02-18 21:58:30 +00:00
license = licenses.lgpl21Plus;
maintainers = [ maintainers.callahad ];
platforms = platforms.linux;
};
}