2011-07-23 01:29:51 +00:00
|
|
|
{ stdenv, fetchurl, pkgconfig, sg3_utils, udev, glib, dbus, dbus_glib
|
|
|
|
, polkit, parted, lvm2, libatasmart, intltool, libuuid, mdadm
|
2012-03-01 15:09:53 +00:00
|
|
|
, libxslt, docbook_xsl, utillinux }:
|
2011-07-23 01:29:51 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2014-03-13 20:15:35 +00:00
|
|
|
name = "udisks-1.0.5";
|
2011-07-23 01:29:51 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://hal.freedesktop.org/releases/${name}.tar.gz";
|
2014-03-13 20:15:35 +00:00
|
|
|
sha256 = "0wbg3jrv8limdgvcygf4dqin3y6d30y9pcmmk711vq571vmq5v7j";
|
2011-07-23 01:29:51 +00:00
|
|
|
};
|
|
|
|
|
2012-12-13 12:14:58 +00:00
|
|
|
patches = [ ./purity.patch ./no-pci-db.patch ];
|
2011-08-18 12:53:07 +00:00
|
|
|
|
2012-03-01 15:09:53 +00:00
|
|
|
postPatch =
|
|
|
|
''
|
|
|
|
sed -e 's,/sbin/mdadm,${mdadm}&,g' -e "s,@slashlibdir@,$out/lib,g" -i data/80-udisks.rules
|
2011-08-18 12:53:07 +00:00
|
|
|
|
2012-03-01 15:09:53 +00:00
|
|
|
substituteInPlace src/main.c --replace \
|
|
|
|
"/sbin:/bin:/usr/sbin:/usr/bin" \
|
|
|
|
"${utillinux}/bin:${mdadm}/sbin:/var/run/current-system/sw/bin:/var/run/current-system/sw/sbin"
|
2014-03-25 15:48:19 +00:00
|
|
|
|
|
|
|
# For some reason @libexec@ is set to 'lib/' when building.
|
|
|
|
# Passing --libexecdir in configureFlags didn't help.
|
|
|
|
substituteInPlace data/systemd/udisks.service.in \
|
|
|
|
--replace "@libexecdir@" "$out/libexec"
|
2012-03-01 15:09:53 +00:00
|
|
|
'';
|
2011-08-18 12:53:07 +00:00
|
|
|
|
2011-07-23 01:29:51 +00:00
|
|
|
buildInputs =
|
2011-08-18 12:53:07 +00:00
|
|
|
[ sg3_utils udev glib dbus dbus_glib polkit parted
|
2011-07-23 01:29:51 +00:00
|
|
|
lvm2 libatasmart intltool libuuid libxslt docbook_xsl
|
|
|
|
];
|
|
|
|
|
2012-12-28 18:20:09 +00:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
2011-08-18 12:53:07 +00:00
|
|
|
|
2014-03-13 20:15:35 +00:00
|
|
|
configureFlags = [
|
|
|
|
"--localstatedir=/var"
|
|
|
|
"--enable-lvm2"
|
|
|
|
"--with-systemdsystemunitdir=$(out)/etc/systemd/system"
|
|
|
|
];
|
2011-07-23 01:29:51 +00:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = http://www.freedesktop.org/wiki/Software/udisks;
|
|
|
|
description = "A daemon and command-line utility for querying and manipulating storage devices";
|
2011-08-03 22:36:20 +00:00
|
|
|
platforms = stdenv.lib.platforms.linux;
|
2011-07-23 01:29:51 +00:00
|
|
|
};
|
|
|
|
}
|