mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-14 04:52:59 +02:00
sane configuration
git-svn-id: http://svn.ipfire.org/svn/ipfire/branches/2.1/trunk@1247 ea5c0bd1-69bd-2848-81d8-4f18e57aeed8
This commit is contained in:
@@ -1 +1 @@
|
||||
8
|
||||
9
|
||||
|
||||
@@ -566,3 +566,8 @@ usr/etc/sane.d/mustek_pp.conf
|
||||
usr/lib/sane/libsane-mustek_pp.so
|
||||
usr/lib/sane/libsane-mustek_pp.so.1
|
||||
usr/lib/sane/libsane-mustek_pp.so.1.0.19
|
||||
etc/rc.d/init.d/sane
|
||||
etc/rc.d/rc3.d/S95sane
|
||||
etc/rc.d/rc0.d/K10sane
|
||||
etc/rc.d/rc6.d/K10sane
|
||||
usr/local/bin/sanedloop
|
||||
|
||||
24
config/sane/saned.conf
Normal file
24
config/sane/saned.conf
Normal file
@@ -0,0 +1,24 @@
|
||||
#
|
||||
# saned.conf
|
||||
#
|
||||
# The contents of the saned.conf file is a list of host names, IP
|
||||
# addresses or IP subnets (CIDR notation) that are permitted to use local
|
||||
# SANE devices. IPv6 addresses must be enclosed in brackets, and should
|
||||
# always be specified in their compressed form.
|
||||
#
|
||||
# The hostname matching is not case-sensitive.
|
||||
#
|
||||
#scan-client.somedomain.firm
|
||||
#192.168.0.1
|
||||
#192.168.0.1/29
|
||||
#[2001:7a8:185e::42:12]
|
||||
#[2001:7a8:185e::42:12]/64
|
||||
#
|
||||
# NOTE: /etc/inetd.conf (or /etc/xinetd.conf) and
|
||||
# /etc/services must also be properly configured to start
|
||||
# the saned daemon as documented in saned(8), services(4)
|
||||
# and inetd.conf(4) (or xinetd.conf(5)).
|
||||
#
|
||||
# a singe "+" allow all hosts to connect.
|
||||
+
|
||||
|
||||
6
lfs/sane
6
lfs/sane
@@ -34,7 +34,7 @@ TARGET = $(DIR_INFO)/$(THISAPP)
|
||||
PROG = sane
|
||||
PAK_VER = 1
|
||||
|
||||
DEPS = ""
|
||||
DEPS = "libtiff"
|
||||
|
||||
###############################################################################
|
||||
# Top-level Rules
|
||||
@@ -81,5 +81,9 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
|
||||
--enable-parport-directio
|
||||
cd $(DIR_APP) && make $(MAKETUNING)
|
||||
cd $(DIR_APP) && make install
|
||||
cp -vf $(DIR_SRC)/config/sane/saned.conf /usr/etc/sane.d/
|
||||
ln -sf ../init.d/sane /etc/rc.d/rc3.d/S95sane
|
||||
ln -sf ../init.d/sane /etc/rc.d/rc0.d/K10sane
|
||||
ln -sf ../init.d/sane /etc/rc.d/rc6.d/K10sane
|
||||
@rm -rf $(DIR_APP)
|
||||
@$(POSTBUILD)
|
||||
|
||||
50
src/initscripts/init.d/sane
Normal file
50
src/initscripts/init.d/sane
Normal file
@@ -0,0 +1,50 @@
|
||||
#!/bin/sh
|
||||
########################################################################
|
||||
# Begin $rc_base/init.d/sane
|
||||
#
|
||||
# Description : Sane Network deamon
|
||||
#
|
||||
# Authors : Arne Fitzenreiter (arne_f@ipfire.org)
|
||||
#
|
||||
# Version : 01.00
|
||||
#
|
||||
# Notes : runs sanedloop ibecause saned is intended
|
||||
# for use with (x)inet.d
|
||||
#
|
||||
########################################################################
|
||||
|
||||
. /etc/sysconfig/rc
|
||||
. ${rc_functions}
|
||||
|
||||
case "${1}" in
|
||||
start)
|
||||
boot_mesg "Starting sane - network scanner deamon..."
|
||||
killall sanedloop > /dev/nul 2&>1
|
||||
killall saned > /dev/nul 2&>1
|
||||
/usr/local/bin/sanedloop &
|
||||
evaluate_retval
|
||||
;;
|
||||
|
||||
stop)
|
||||
boot_mesg "Stopping sane - network scanner deamon..."
|
||||
killall sanedloop > /dev/nul 2&>1
|
||||
killall saned > /dev/nul 2&>1
|
||||
echo_ok
|
||||
;;
|
||||
|
||||
restart)
|
||||
${0} start
|
||||
;;
|
||||
|
||||
status)
|
||||
statusproc /usr/bin/sanedloop
|
||||
statusproc /usr/sbin/saned
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "Usage: ${0} {start|stop|restart|status}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
# End $rc_base/init.d/sane
|
||||
8
src/scripts/sanedloop
Normal file
8
src/scripts/sanedloop
Normal file
@@ -0,0 +1,8 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# saned is intended for use with (x)inet.d so we have to recall it in a loop
|
||||
#
|
||||
while true;
|
||||
do
|
||||
/usr/sbin/saned -s0;
|
||||
done;
|
||||
Reference in New Issue
Block a user