linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] configure: allow usb.ids location to be specified
@ 2011-05-20 21:19 Scott James Remnant
  2011-05-20 22:05 ` Greg KH
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Scott James Remnant @ 2011-05-20 21:19 UTC (permalink / raw)
  To: linux-hotplug

We already allow the pci.ids location to be specified, so add a
patch doing the same for usb.ids. Please don't make me explain
why this is necessary, it will only make you cry.

Signed-off-by: Scott James Remnant <scott@netsplit.com>
---
 configure.ac |   14 ++++++++++++--
 1 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/configure.ac b/configure.ac
index 3646f93..11e5bc5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -93,8 +93,18 @@ if test "x$enable_hwdb" = xyes; then
 		AC_CHECK_FILES([/usr/share/misc/pci.ids], [pciids=/usr/share/misc/pci.ids])
 	fi
 
-	PKG_CHECK_MODULES(USBUTILS, usbutils >= 0.82)
-	AC_SUBST([USB_DATABASE], [$($PKG_CONFIG --variable=usbids usbutils)])
+	AC_ARG_WITH(usb-ids-path,
+		[AS_HELP_STRING([--with-usb-ids-path=DIR], [Path to usb.ids file])],
+		[USB_DATABASE=${withval}],
+		[if test -n "$usbids" ; then
+			PCI_DATABASE="$usbids"
+		else
+			PKG_CHECK_MODULES(USBUTILS, usbutils >= 0.82)
+			AC_SUBST([USB_DATABASE], [$($PKG_CONFIG --variable=usbids usbutils)])
+		fi])
+	AC_MSG_CHECKING([for USB database location])
+	AC_MSG_RESULT([$USB_DATABASE])
+	AC_SUBST(USB_DATABASE)
 
 	AC_ARG_WITH(pci-ids-path,
 		[AS_HELP_STRING([--with-pci-ids-path=DIR], [Path to pci.ids file])],
-- 
1.7.3.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2011-05-23 21:43 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-20 21:19 [PATCH] configure: allow usb.ids location to be specified Scott James Remnant
2011-05-20 22:05 ` Greg KH
2011-05-23  8:48 ` Kay Sievers
2011-05-23 19:37 ` Scott James Remnant
2011-05-23 21:13 ` Kay Sievers
2011-05-23 21:43 ` Scott James Remnant

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).