Your message dated Sun, 30 Jul 2006 13:54:49 +0200
with message-id <[EMAIL PROTECTED]>
and subject line I forgot to close this report
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--- Begin Message ---
Package: lirc
Version: 0.7.1pre2-6
Severity: normal
Tags: patch

Some variables in my /etc/lirc/hardware.conf (attached) are set in an
indented line. lirc's postinst fails to detect that these are
correctly set, and adds lines to set these. I simply deleted these
lines at first, but they are of course re-added on the next upgrade...

(Isn't modifying a conffile a policy violation as well? Anyway, I'd
prefer a debconf question: "Your hardware.conf seems broken? [Fix it
for me] [I will fix it myself] [Don't tell me again]")

I am attaching a simple-minded patch that at least handles indented
lines. Perhaps a better strategy would be to source hardware.conf and
check if the variables are then set.
# /etc/lirc/hardware.conf
#
# Arguments which will be used when launching lircd
LIRCD_ARGS=""

#Don't start lircmd even if there seems to be a good config file
START_LIRCMD=false

#Try to load appropriate kernel modules
LOAD_MODULES=true

# Run "lircd --driver=help" for a list of supported drivers.
# If DEVICE is set to /dev/lirc and devfs is in use /dev/lirc/0 will be
# automatically used instead
if [ $(uname -r | cut -d. -f2) -le 4 ]; then
  MODULES="lirc_dev lirc_i2c"
  DRIVER="default"
  DEVICE="/dev/lirc"
else
  MODULES="bttv ir-kbd-i2c"
  DRIVER="dev/input"
  DEVICE="/dev/input/event2"
fi

# Default configuration files for your hardware if any
LIRCD_CONF="hauppauge/lircd.conf.hauppauge"
LIRCMD_CONF="hauppauge/lircmd.conf.hauppauge"
--- /var/lib/dpkg/info/lirc.postinst    2005-03-28 23:11:49.000000000 +0200
+++ /var/lib/dpkg/info/lirc.postinst+   2005-04-04 20:01:19.608919424 +0200
@@ -51,7 +51,7 @@
        local VAR
        for VAR in DRIVER MODULES DEVICE LIRCD_CONF LIRCMD_CONF
        do
-               if ! grep -q "^$VAR\>" /etc/lirc/hardware.conf; then
+               if ! grep -q "^[        ]*$VAR\>" /etc/lirc/hardware.conf; then
                        echo "$VAR=\"UNCONFIGURED\"" >> /etc/lirc/hardware.conf
                fi
        done

--- End Message ---
--- Begin Message ---
Version: 0.7.1pre2-7

Hi there, Robert,

I applied your patch long ago, and it introduced no problems.
If you happen to still see this bug, feel free to reopen.


-- 
  ยท''`.          Policy is your friend. Trust the Policy.
 : :' :     Love the Policy. Obey the Policy. -- Lars Wirzenius
 `. `'           Proudly running unstable Debian GNU/Linux
   `-     www.amayita.com  www.malapecora.com  www.chicasduras.com

--- End Message ---

Reply via email to