Bug 24611

Summary: Wrong paths for config and backends
Product: Mageia Reporter: Juan Magallon <jamagallon>
Component: RPM PackagesAssignee: Mageia Bug Squad <bugsquad>
Status: RESOLVED INVALID QA Contact:
Severity: major    
Priority: Normal CC: geiger.david68210, jamagallon
Version: Cauldron   
Target Milestone: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Source RPM: sane-1.0.27-3.mga7.src.rpm CVE:
Status comment:

Description Juan Magallon 2019-04-03 02:52:52 CEST
SANE looks for config files in /usr/etc/sane.d, but they are installed under /etc/sane.d:
werewolf:~# strace scanimage -L 2>&1 | grep dll.conf
openat(AT_FDCWD, "./dll.conf", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/etc/sane.d/dll.conf", O_RDONLY) = -1 ENOENT (No such file or directory)
werewolf:~# rpm -ql sane-backends | grep dll.conf
/etc/sane.d/dll.conf

Can be solved with a symlink, for the moment.
But then, same happens for lib backend modules, looks undet /usr/lib,
but they are in /usr/lib64:
werewolf:~# strace scanimage -L 2>&1 | grep hpaio
openat(AT_FDCWD, "/usr/lib/sane/libsane-hpaio.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
werewolf:/usr/etc# rpm -ql lib64sane-hpaio1 | grep hpaio
/usr/lib64/sane/libsane-hpaio.so.1
/usr/lib64/sane/libsane-hpaio.so.1.0.0
werewolf:~# strace scanimage -L 2>&1 | grep net
openat(AT_FDCWD, "/usr/lib/sane/libsane-net.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
werewolf:/usr/etc# rpm -ql lib64sane1 | grep sane-net
/usr/lib64/sane/libsane-net.so.1
/usr/lib64/sane/libsane-net.so.1.0.27

Is this a real bug, or something misconfigured in my box ?
Comment 1 David GEIGER 2019-04-03 07:26:53 CEST
Hmmm! here seems good on my Cauldron x86_64:

$ strace scanimage -L 2>&1 | grep dll.conf
openat(AT_FDCWD, "./dll.conf", O_RDONLY) = -1 ENOENT (Aucun fichier ou dossier de ce type)
openat(AT_FDCWD, "/etc/sane.d/dll.conf", O_RDONLY) = 3
read(3, "# dll.conf - Configuration file "..., 4096) = 1121
$


$ strace scanimage -L 2>&1 | grep hpaio
openat(AT_FDCWD, "/usr/lib64/sane/libsane-hpaio.so.1", O_RDONLY) = 9
openat(AT_FDCWD, "/usr/lib64/sane/libsane-hpaio.so.1", O_RDONLY|O_CLOEXEC) = 9
$


$ strace scanimage -L 2>&1 | grep net
openat(AT_FDCWD, "/lib64/libnetsnmp.so.35", O_RDONLY|O_CLOEXEC) = 9
openat(AT_FDCWD, "/lib64/libnettle.so.6", O_RDONLY|O_CLOEXEC) = 9
openat(AT_FDCWD, "/usr/lib64/sane/libsane-net.so.1", O_RDONLY) = 14
openat(AT_FDCWD, "/usr/lib64/sane/libsane-net.so.1", O_RDONLY|O_CLOEXEC) = 14
openat(AT_FDCWD, "/usr/lib64/sane/libsane-dell1600n_net.so.1", O_RDONLY) = 14
openat(AT_FDCWD, "/usr/lib64/sane/libsane-dell1600n_net.so.1", O_RDONLY|O_CLOEXEC) = 14
openat(AT_FDCWD, "./dell1600n_net.conf", O_RDONLY) = -1 ENOENT (Aucun fichier ou dossier de ce type)
openat(AT_FDCWD, "/etc/sane.d/dell1600n_net.conf", O_RDONLY) = 14
openat(AT_FDCWD, "./net.conf", O_RDONLY) = -1 ENOENT (Aucun fichier ou dossier de ce type)
openat(AT_FDCWD, "/etc/sane.d/net.conf", O_RDONLY) = 14
read(14, "# This is the net backend config"..., 4096) = 573
$

CC: (none) => geiger.david68210

Comment 2 Juan Magallon 2019-04-03 12:44:57 CEST
Found it. I don't know why, I had a libsane.so.1.0.27 in /usr/lib, apart
from /usr/lib64.

CC: (none) => jamagallon
Status: NEW => RESOLVED
Resolution: (none) => INVALID