On Wed, 16 Mar 2005, Mattia Dongili wrote:
> On Wed, 16 Mar 2005 14:56:33 +0100, maximilian attems
> <[EMAIL PROTECTED]> wrote:
> > On Wed, 16 Mar 2005, Mattia Dongili wrote:
> [...]
> > i tend to disagree,
> > once the new X automaticaly detects the touchpads
> > (newer kernel > 2.6.10 is pretty good in detecting them)
> > and enables them. you'll want to have the syndaemon running.
>
> no. there is nothing in debian that automagically configures touchpads
> and there is nothing that automagically installs the package if a
> synaptics touchpad is detected either.
i know the sad state of current xfree86 autodetection,
and those the complaints of current debian installs.
it even got worse with that strange pci screen asking the device id.
i guess post-sarge with the help of ubuntu patches that will be
heavily worked on.
> > the current default desktop install includes a display manager,
> > gdm afair. so it would help newbies.
>
> hmmm... I'm not that convinced about that. Running syndaemon without
> being aware might actually be percieved as a slow responding touchpad
> (think: you touch the pad and it does nothing for 1 second. hmmmm...)
as i said above i agree that in current state an default init
makes no sense.
> > the syndaemon upstream maintainer said to incorporate
> > for the next release an overworked patch of mine, where
> > syndaemon has a new switch for the pid-file to create.
> > as soon as it is released, i'll send you an update init script.
>
> it is already, 0.14.1 has been released yesterday
cool, you are better in watching that page. great. :-)
> > but i guess yes it should not be running as root.
>
> So, having an init script is a bad idea. You need an user for the
> deamon that needs the necessary permissions to connect to the local
> DISPLAY... no good.
>
> Again, I'm not against providing necessary hints/scripts for users,
> but setting up an init script is not a good idea, I'd still prefer
> suggesting how to setup your own .xinitrc or the clicking procedure to
> setup the same in gnome.
> And this is what I will do wrt to this wishlist bug :)
it would be great if you provided that and the init script in
/usr/share/doc/$packagename/examples
i attache my init script that i wrote against the prerelease
of 0.14.1, untested against the new version currently.
thanks for your quick feedback!!
--
maks
#! /bin/sh
#
# based on:
# Version: @(#)skeleton 2.85-23 28-Jul-2004 [EMAIL PROTECTED]
#
# adapted for syndaemon usage by Maximilian Attems <[EMAIL PROTECTED]>
set -e
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
DESC="keyboard monitor"
NAME=syndaemon
DAEMON=/usr/bin/$NAME
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
# Gracefully exit if the package has been removed.
test -x $DAEMON || exit 0
# Read config file if it is present.
# FIXME: no config yet, therefor OPTIONS variable
#if [ -r /etc/default/$NAME ]
#then
# . /etc/default/$NAME
#fi
OPTIONS="-d -i 0.9 -p $PIDFILE"
#
# function that starts syndaemon
#
syndaemon_start()
{
start-stop-daemon --start --quiet --pidfile $PIDFILE \
--exec $DAEMON -- $OPTIONS \
|| echo -n " already running"
}
#
# function that stops syndaemon
#
syndaemon_stop()
{
start-stop-daemon --stop --quiet --pidfile $PIDFILE --name $NAME \
|| echo -n " not running"
}
case "$1" in
start)
echo -n "Starting $DESC: $NAME"
syndaemon_start
echo "."
;;
stop)
echo -n "Stopping $DESC: $NAME"
syndaemon_stop
echo "."
;;
restart|force-reload)
echo -n "Restarting $DESC: $NAME"
syndaemon_stop
sleep 1
syndaemon_start
echo "."
;;
*)
echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2
exit 1
;;
esac
exit 0