[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
01/02: gnu: eudev: Add 'eudev-with-hwdb' variant that contains 'hwdb.bin
From: |
Ludovic Courtès |
Subject: |
01/02: gnu: eudev: Add 'eudev-with-hwdb' variant that contains 'hwdb.bin'. |
Date: |
Thu, 12 Jan 2017 09:22:07 +0000 (UTC) |
civodul pushed a commit to branch master
in repository guix.
commit e5d861f30568ec0265565af551289fc2033743c7
Author: Ludovic Courtès <address@hidden>
Date: Thu Jan 12 10:10:02 2017 +0100
gnu: eudev: Add 'eudev-with-hwdb' variant that contains 'hwdb.bin'.
* gnu/packages/linux.scm (eudev-with-hwdb): New variable.
(usbutils)[inputs]: Use it instead of EUDEV.
---
gnu/packages/linux.scm | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index 716845d..dc0fc07 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -597,7 +597,7 @@ slabtop, and skill.")
(build-system gnu-build-system)
(inputs
`(("libusb" ,libusb)
- ("eudev" ,eudev)))
+ ("eudev" ,eudev-with-hwdb)))
(native-inputs
`(("pkg-config" ,pkg-config)))
(home-page "http://www.linux-usb.org/")
@@ -1740,6 +1740,21 @@ device nodes from /dev/, handles hotplug events and
loads drivers at boot
time.")
(license license:gpl2+)))
+(define-public eudev-with-hwdb
+ ;; TODO: Merge with 'eudev'.
+ (package
+ (inherit eudev)
+ (name "eudev-with-hwdb")
+ (arguments
+ '(#:phases (modify-phases %standard-phases
+ (add-after 'install 'build-hwdb
+ (lambda* (#:key outputs #:allow-other-keys)
+ ;; Build OUT/etc/udev/hwdb.bin. This allows 'lsusb' and
+ ;; similar tools to display product names.
+ (let ((out (assoc-ref outputs "out")))
+ (zero? (system* (string-append out "/bin/udevadm")
+ "hwdb" "--update"))))))))))
+
(define-public lvm2
(package
(name "lvm2")