[sane-devel] Problem with mixed up backend device id

Jan Bruns ebay at abnuto.de
Sun Dec 15 19:18:39 GMT 2019


Hallo,

after fresh-installing Debian10 a few weeks ago, I decided to install 
proprietary printer/scanner drivers to be able to continue using my old 
hardware.

After some investigation

root at rechner2a:/home/jan# export SANE_DEBUG_DLL=255

revealed that (the installed) sane (version) somehow seems to use 
explicit path-prefixes for dynloading backend drivers.

So I created the missing link as

root at rechner2a:/home/jan# ln /lib64/sane/libsane-brother2.so.1.0.7 
/usr/lib/x86_64-linux-gnu/sane/libsane-brother2.so.1

but something's still wrong: It looks like sane passes a totally wrong 
device id to the backend, but I haven't looked into the sources, so I 
can't tell for sure. Did sane probably undergo any binary 
Interface-changes that might be causing this problem?

Gruss

Jan Bruns


root at rechner2a:/home/jan# lsusb
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 006: ID 24ae:1813
Bus 001 Device 010: ID 04f9:0193 Brother Industries, Ltd MFC-215C
Bus 001 Device 005: ID 1a40:0101 Terminus Technology Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

root at rechner2a:/home/jan# scanimage
[sanei_debug] Setting debug level of dll to 255.
[dll] sane_init: SANE dll backend version 1.0.13 from sane-backends 1.0.27
[dll] sane_init/read_dlld: attempting to open directory `./dll.d'
[dll] sane_init/read_dlld: attempting to open directory `/etc/sane.d/dll.d'
[dll] sane_init/read_dlld: using config directory `/etc/sane.d/dll.d'
[dll] sane_init/read_dlld: considering /etc/sane.d/dll.d/hplip
[dll] sane_init/read_config: reading dll.d/hplip
[dll] add_backend: adding backend `hpaio'
[dll] sane_init/read_dlld: done.
[dll] sane_init/read_config: reading dll.conf
[dll] add_backend: adding backend `net'
[dll] add_backend: adding backend `brother2'
[dll] sane_get_devices
[dll] load: searching backend `brother2' in 
`/usr/lib/x86_64-linux-gnu/sane:/usr/lib/sane'
[dll] load: trying to load 
`/usr/lib/x86_64-linux-gnu/sane/libsane-brother2.so.1'
[dll] load: dlopen()ing 
`/usr/lib/x86_64-linux-gnu/sane/libsane-brother2.so.1'
[dll] init: initializing backend `brother2'
[dll] init: backend `brother2' is version 1.0.1
[dll] load: searching backend `net' in 
`/usr/lib/x86_64-linux-gnu/sane:/usr/lib/sane'
[dll] load: trying to load `/usr/lib/x86_64-linux-gnu/sane/libsane-net.so.1'
[dll] load: dlopen()ing `/usr/lib/x86_64-linux-gnu/sane/libsane-net.so.1'
...
[dll] sane_get_devices: found 1 devices
[dll] sane_open: trying to open `brother2:bus7;dev1'
scanimage: open of device brother2:bus7;dev1 failed: Invalid argument
[dll] sane_exit: exiting

<plug/>

root at rechner2a:/home/jan# lsusb
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 006: ID 24ae:1813
Bus 001 Device 005: ID 1a40:0101 Terminus Technology Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 002: ID 04f9:0193 Brother Industries, Ltd MFC-215C
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

root at rechner2a:/home/jan# scanimage
...
[dll] sane_open: trying to open `brother2:bus4;dev1'
scanimage: open of device brother2:bus4;dev1 failed: Invalid argument
[dll] sane_exit: exiting

<plug/>

root at rechner2a:/home/jan# lsusb
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 014: ID 24ae:1813
Bus 001 Device 013: ID 1a40:0101 Terminus Technology Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 004: ID 04f9:0193 Brother Industries, Ltd MFC-215C
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

root at rechner2a:/home/jan# scanimage
...
[dll] sane_open: trying to open `brother2:bus4;dev1'
scanimage: open of device brother2:bus4;dev1 failed: Invalid argument
[dll] sane_exit: exiting





More information about the sane-devel mailing list