xbmc: add patch to add udev cdrom support

Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
Stephan Raue 2013-08-22 22:55:04 +02:00
parent 3fbf2f82ef
commit 21d1ea08af
2 changed files with 17 additions and 0 deletions

View File

@ -0,0 +1,17 @@
diff -Naur xbmc-12.2-5ba69b6/xbmc/storage/linux/UDevProvider.cpp xbmc-12.2-5ba69b6.patch/xbmc/storage/linux/UDevProvider.cpp
--- xbmc-12.2-5ba69b6/xbmc/storage/linux/UDevProvider.cpp 2013-08-22 21:37:41.543830684 +0200
+++ xbmc-12.2-5ba69b6.patch/xbmc/storage/linux/UDevProvider.cpp 2013-08-22 21:37:34.557825148 +0200
@@ -145,10 +145,12 @@
continue;
}
- // look for usb devices on the usb bus or mounted on /media/usbX (sdcards)
+ // look for usb devices on the usb bus, or mounted on /media/usbX (sdcards) or cdroms
const char *bus = udev_device_get_property_value(device, "ID_BUS");
+ const char *cdrom = udev_device_get_property_value(device, "ID_CDROM");
if (removable &&
((bus && strstr(bus, "usb")) ||
+ (cdrom && strstr(cdrom,"1")) ||
(mountpoint && strstr(mountpoint, "usb"))))
{
const char *label = udev_device_get_property_value(device, "ID_FS_LABEL");