summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Schwarzott <zzam@gentoo.org>2007-10-05 07:32:03 +0000
committerMatthias Schwarzott <zzam@gentoo.org>2007-10-05 07:32:03 +0000
commit66527998ba71e72abccb6bbe0522c082e1fda5a2 (patch)
treec0c92a068079933ce38b877ec48a85e5ad668335 /media-gfx/sane-backends/files
parentstable on ppc64 (diff)
downloadgentoo-2-66527998ba71e72abccb6bbe0522c082e1fda5a2.tar.gz
gentoo-2-66527998ba71e72abccb6bbe0522c082e1fda5a2.tar.bz2
gentoo-2-66527998ba71e72abccb6bbe0522c082e1fda5a2.zip
Fixed file mode for libusb device nodes (664 as default rules do). Let the udev rules ignore printer devices, Bug #193266. Renamed rules file to 70-libsane.rules.
(Portage version: 2.1.3.11)
Diffstat (limited to 'media-gfx/sane-backends/files')
-rw-r--r--media-gfx/sane-backends/files/digest-sane-backends-1.0.18-r56
-rw-r--r--media-gfx/sane-backends/files/udev-rule-4.patch53
2 files changed, 59 insertions, 0 deletions
diff --git a/media-gfx/sane-backends/files/digest-sane-backends-1.0.18-r5 b/media-gfx/sane-backends/files/digest-sane-backends-1.0.18-r5
new file mode 100644
index 000000000000..5242a0c5bacf
--- /dev/null
+++ b/media-gfx/sane-backends/files/digest-sane-backends-1.0.18-r5
@@ -0,0 +1,6 @@
+MD5 69b18ea038b8cd0e289c04c512b43b8e sane-1.0.18-brother-driver.diff.bz2 8335
+RMD160 8d86dccca4054699e367412c25d80d8641de42ca sane-1.0.18-brother-driver.diff.bz2 8335
+SHA256 4a2eceb222f6cd55979fd150c4a7c365a9a83f2beab15045852f8859404de23b sane-1.0.18-brother-driver.diff.bz2 8335
+MD5 7ca7e2908e24721471de92cf40c75e60 sane-backends-1.0.18.tar.gz 3789493
+RMD160 aa863adff417d7c33cbb85c193878aa54a056100 sane-backends-1.0.18.tar.gz 3789493
+SHA256 d7876a78c5676b0c4bc29091c7a7e1287b5c0be5ff5bb61ef033fbffc73d66f3 sane-backends-1.0.18.tar.gz 3789493
diff --git a/media-gfx/sane-backends/files/udev-rule-4.patch b/media-gfx/sane-backends/files/udev-rule-4.patch
new file mode 100644
index 000000000000..3d824d162cb6
--- /dev/null
+++ b/media-gfx/sane-backends/files/udev-rule-4.patch
@@ -0,0 +1,53 @@
+Index: tools/sane-desc.c
+===================================================================
+--- tools/sane-desc.c.orig
++++ tools/sane-desc.c
+@@ -3151,7 +3151,7 @@ print_udev_header (void)
+
+ printf
+ ("#\n"
+- "# udev rules file for supported USB devices\n"
++ "# udev rules file for supported USB and SCSI devices\n"
+ "#\n"
+ "# To add a USB device, add a rule to the list below between the SUBSYSTEM...\n"
+ "# and LABEL... lines.\n"
+@@ -3169,25 +3169,33 @@ print_udev_header (void)
+ static void
+ print_udev (void)
+ {
++ int commentlen;
+ usbid_type *usbid = create_usbids_table ();
+
+ print_udev_header ();
+ printf ("\nACTION!=\"add\", GOTO=\"libsane_rules_end\"\n");
+- printf ("SUBSYSTEM!=\"usb_device\", GOTO=\"libsane_rules_end\"\n\n");
++ puts("SUBSYSTEMS==\"scsi\", ATTRS{type}==\"6\", MODE=\"660\", GROUP=\"scanner\"");
++ printf ("SUBSYSTEM!=\"usb|usb_device\", GOTO=\"libsane_rules_end\"\n");
++ printf ("SUBSYSTEM==\"usb\", ENV{DEVTYPE}!=\"usb_device\" ,GOTO=\"libsane_rules_end\"\n\n");
+ while (usbid)
+ {
+ manufacturer_model_type * name = usbid->name;
+
+- printf ("# ");
++ commentlen = printf ("# ");
+ while (name)
+ {
+- if (name != usbid->name)
+- printf (" | ");
+- printf ("%s", name->name);
++ if (name != usbid->name) {
++ commentlen += printf (" | ");
++ }
++ if(commentlen + strlen(name->name) > 480) {
++ printf(" (line too long, names omitted)");
++ break;
++ }
++ commentlen += printf ("%s", name->name);
+ name = name->next;
+ }
+ printf ("\n");
+- printf ("SYSFS{idVendor}==\"%s\", SYSFS{idProduct}==\"%s\", MODE=\"660\", GROUP=\"scanner\"\n",
++ printf ("ATTRS{idVendor}==\"%s\", ATTRS{idProduct}==\"%s\", MODE=\"664\", GROUP=\"scanner\"\n",
+ usbid->usb_vendor_id + 2, usbid->usb_product_id + 2);
+ usbid = usbid->next;
+ }