2022-01-01 15:58:55 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, autoreconfHook
|
|
|
|
, gperf
|
|
|
|
, kmod
|
|
|
|
, pkg-config
|
|
|
|
, util-linux
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "eudev";
|
|
|
|
version = "3.2.11";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "eudev-project";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
|
|
|
hash = "sha256-W5nL4hicQ4fxz5rqoP+hhkE1tVn8lJZjMq4UaiXH6jc=";
|
2014-11-17 06:44:26 +00:00
|
|
|
};
|
2017-09-14 19:24:37 +00:00
|
|
|
|
2022-01-01 15:58:55 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
autoreconfHook
|
|
|
|
gperf
|
|
|
|
pkg-config
|
2014-11-17 06:44:26 +00:00
|
|
|
];
|
2022-01-01 15:58:55 +00:00
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
kmod
|
|
|
|
util-linux
|
2017-01-21 07:55:17 +00:00
|
|
|
];
|
|
|
|
|
2014-12-12 11:48:14 +00:00
|
|
|
configureFlags = [
|
|
|
|
"--localstatedir=/var"
|
|
|
|
"--sysconfdir=/etc"
|
|
|
|
];
|
2022-01-01 15:58:55 +00:00
|
|
|
|
2014-12-13 09:55:11 +00:00
|
|
|
makeFlags = [
|
|
|
|
"hwdb_bin=/var/lib/udev/hwdb.bin"
|
|
|
|
"udevrulesdir=/etc/udev/rules.d"
|
|
|
|
];
|
2015-07-09 10:27:29 +00:00
|
|
|
|
|
|
|
preInstall = ''
|
2022-01-01 15:58:55 +00:00
|
|
|
# Disable install-exec-hook target,
|
|
|
|
# as it conflicts with our move-sbin setup-hook
|
|
|
|
|
2015-07-09 10:27:29 +00:00
|
|
|
sed -i 's;$(MAKE) $(AM_MAKEFLAGS) install-exec-hook;$(MAKE) $(AM_MAKEFLAGS);g' src/udev/Makefile
|
|
|
|
'';
|
|
|
|
|
2022-01-01 15:58:55 +00:00
|
|
|
installFlags = [
|
2014-12-12 11:48:14 +00:00
|
|
|
"localstatedir=$(TMPDIR)/var"
|
|
|
|
"sysconfdir=$(out)/etc"
|
|
|
|
"udevconfdir=$(out)/etc/udev"
|
|
|
|
"udevhwdbbin=$(out)/var/lib/udev/hwdb.bin"
|
|
|
|
"udevhwdbdir=$(out)/var/lib/udev/hwdb.d"
|
2014-12-13 09:55:11 +00:00
|
|
|
"udevrulesdir=$(out)/var/lib/udev/rules.d"
|
2022-01-01 15:58:55 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/eudev-project/eudev";
|
|
|
|
description = "A fork of udev with the aim of isolating it from init";
|
|
|
|
license = licenses.gpl2Plus ;
|
|
|
|
maintainers = with maintainers; [ raskin AndersonTorres ];
|
|
|
|
platforms = platforms.linux;
|
2014-11-17 06:44:26 +00:00
|
|
|
};
|
|
|
|
}
|