# Add group for UDEV rules
groupadd --system -f scanner
- groupadd --system -f saned
- hv_useradd --system -c saned -d /dev/null -g saned -s /bin/false saned
+ # Group for sane server
+ hv_useradd --system -c saned -d /dev/null -g scanner -s /bin/false saned
- CONFIGURE_OPTS+=" --with-x=${USE_X_OPTION}"
+ CONFIGURE_OPTS+=" \
+ --with-x=${USE_X_OPTION} \
+ --localstatedir=/var \
+ --with-group=scanner \
+ --enable-libusb_1_0"
}
hvbuild_post()
install -v -m 644 tools/udev/libsane.rules \
/etc/udev/rules.d/65-scanner.rules
+ chgrp -v scanner /var/lock/sane
+
# Addition to /etc/services (for both the client and server)
string_add "sane 6566/tcp saned # SANE Network Scanner Daemon" \
/etc/services
protocol = tcp
wait = no
user = saned
+ group = scanner
server = /usr/sbin/saned
log_type = SYSLOG local4 info
}
hv_useradd -g users -s /bin/bash -m ${REGUSER}
# Add user to these supplementary groups:
- usermod -a -G audio,video,cdrom,usb,shutdown,kvm,lpadmin ${REGUSER}
+ usermod -a -G audio,video,cdrom,usb,shutdown,kvm,lpadmin,scanner,plugdev \
+ ${REGUSER}
fi
if [ "x${INST_TYPE}" = "xserver" -o "x${INST_TYPE}" = "xltsp-server" ]; then