diff options
Diffstat (limited to 'abs/core/lirc/lirc.install')
-rw-r--r-- | abs/core/lirc/lirc.install | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/abs/core/lirc/lirc.install b/abs/core/lirc/lirc.install index 814312e..1f8fd7c 100644 --- a/abs/core/lirc/lirc.install +++ b/abs/core/lirc/lirc.install @@ -8,6 +8,24 @@ post_install() { post_upgrade() { post_install + + . /etc/systemconfig + + # Fix LircSocket in mythtv database + SOCKET=`mysql -u mythtv -pmythtv -B --skip-column-names -h "${dbhost}" -D mythconverg -e \ + "SELECT data FROM settings WHERE value = 'LircSocket' AND hostname = '${hostname}';"` + if [ "${SOCKET}" != "/var/run/lirc/lircd" ]; then + mysql -u mythtv -pmythtv -B --skip-column-names -h "${dbhost}" -D mythconverg -e \ + "UPDATE settings SET data = '/var/run/lirc/lircd' WHERE hostname = '${hostname}';" + else + echo ">>>" + echo ">>> ATTENTION! ATTENTION! ATTENTION!" + echo ">>> Unable to connect the the MySQL database to make needed" + echo ">>> changes to the LIRC socket." + echo ">>> LIRC now uses /var/run/lirc/lircd and /dev/lirc is now" + echo ">>> obsolete. Update your MythTV settings to reflect this." + echo ">>>" + fi } # arg 1: the old package version |