From effe3b68b666b2e242bbd53871cde8ad0792463f Mon Sep 17 00:00:00 2001
From: James Meyer <james.meyer@operamail.com>
Date: Thu, 25 Mar 2010 10:02:41 -0500
Subject: rrd-stats: update rrd programs to use correct path

closes #664
closes #586
---
 abs/extra-testing/rrd_stats/PKGBUILD      |   3 ++-
 abs/extra-testing/rrd_stats/rrd_stats.tgz | Bin 7454 -> 8444 bytes
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/abs/extra-testing/rrd_stats/PKGBUILD b/abs/extra-testing/rrd_stats/PKGBUILD
index 40f0536..1f987e4 100644
--- a/abs/extra-testing/rrd_stats/PKGBUILD
+++ b/abs/extra-testing/rrd_stats/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=rrd_stats
 pkgver=1
-pkgrel=16
+pkgrel=18
 pkgdesc="graph system stats"
 arch=('i686' 'x86_64')
 url=""
@@ -18,3 +18,4 @@ build() {
   chown -R http:users $startdir/pkg/data/srv/httpd
   chmod -R 755 $startdir/pkg/data/srv/httpd
 }
+md5sums=('e3d5f7d56fd1a3f26af0226ddcc53bfa')
diff --git a/abs/extra-testing/rrd_stats/rrd_stats.tgz b/abs/extra-testing/rrd_stats/rrd_stats.tgz
index c141ffa..4f1f3f5 100644
Binary files a/abs/extra-testing/rrd_stats/rrd_stats.tgz and b/abs/extra-testing/rrd_stats/rrd_stats.tgz differ
-- 
cgit v0.12


From c72e5b283fb8b8cb83158fa8b81c1557b6d4af40 Mon Sep 17 00:00:00 2001
From: James Meyer <james.meyer@operamail.com>
Date: Thu, 25 Mar 2010 11:35:20 -0500
Subject: recstat: initial include.   Does not have support for runit recstat
 will need to be modified

ref #632
---
 abs/extra-testing/recstat/PKGBUILD        | 17 ++++++++++
 abs/extra-testing/recstat/recstat         | 56 +++++++++++++++++++++++++++++++
 abs/extra-testing/recstat/recstat.install | 12 +++++++
 abs/extra-testing/recstat/recstat.py      | 38 +++++++++++++++++++++
 4 files changed, 123 insertions(+)
 create mode 100644 abs/extra-testing/recstat/PKGBUILD
 create mode 100644 abs/extra-testing/recstat/recstat
 create mode 100644 abs/extra-testing/recstat/recstat.install
 create mode 100644 abs/extra-testing/recstat/recstat.py

diff --git a/abs/extra-testing/recstat/PKGBUILD b/abs/extra-testing/recstat/PKGBUILD
new file mode 100644
index 0000000..84a0943
--- /dev/null
+++ b/abs/extra-testing/recstat/PKGBUILD
@@ -0,0 +1,17 @@
+pkgname=recstat
+pkgver=1
+pkgrel=7
+pkgdesc="pkg to help use the  System LEDs for Recording Status"
+arch=('i686' 'x86_64')
+url=""
+depends=('python')
+license=('GPL')
+source=(recstat recstat.py)
+md5sums=('626acb8cdd9e5cdb3a502bc12b828067')
+install=recstat.install
+build () {
+  install -D $startdir/src/recstat $startdir/pkg/etc/rc.d/recstat
+  install -D $startdir/src/recstat.py $startdir/pkg/usr/bin/recstat.py
+}
+md5sums=('7f4ba41b65ed4d693d60d5ea00e8411b'
+         '9477fe77a716c308125eab521cf59f20')
diff --git a/abs/extra-testing/recstat/recstat b/abs/extra-testing/recstat/recstat
new file mode 100644
index 0000000..2d72c61
--- /dev/null
+++ b/abs/extra-testing/recstat/recstat
@@ -0,0 +1,56 @@
+#! /bin/sh
+
+set -e
+
+PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
+DESC="serial port encoder status script"
+NAME=recstat
+DAEMON=/usr/bin/$NAME.py
+PIDFILE=/var/run/$NAME.pid
+SCRIPTNAME=/etc/init.d/$NAME
+
+# Gracefully exit if the package has been removed.
+test -x $DAEMON || exit 0
+
+#
+#       Function that starts the daemon/service.
+#
+d_start() {
+        start-stop-daemon --start --quiet --make-pidfile --pidfile $PIDFILE \
+                --exec $DAEMON &
+}
+
+#
+#       Function that stops the daemon/service.
+#
+d_stop() {
+        kill -9 `cat $PIDFILE`
+}
+
+case "$1" in
+  start)
+        echo -n "Starting $DESC: $NAME"
+        d_start
+        echo "."
+        ;;
+  stop)
+        echo -n "Stopping $DESC: $NAME"
+        d_stop
+        echo "."
+        ;;
+  restart|force-reload)
+        echo -n "Stopping $DESC: $NAME"
+        d_stop
+        sleep 1
+        echo "."
+        echo -n "Starting $DESC: $NAME"
+        d_start
+        echo "."
+        ;;
+  *)
+        echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2
+        exit 1
+        ;;
+esac
+
+exit 0 
\ No newline at end of file
diff --git a/abs/extra-testing/recstat/recstat.install b/abs/extra-testing/recstat/recstat.install
new file mode 100644
index 0000000..c45cc1b
--- /dev/null
+++ b/abs/extra-testing/recstat/recstat.install
@@ -0,0 +1,12 @@
+# arg 1:  the new package version
+post_install() {
+    echo ""
+    echo ""
+    echo ""
+    echo " Edit /usr/bin/recstat.py  to fit your tuner setup"
+    echo " http://linhes.org/bugs/projects/lin-hes/wiki/_Using_System_LEDs_for_Recording_Status_"
+}
+
+op=$1
+shift
+$op $*
diff --git a/abs/extra-testing/recstat/recstat.py b/abs/extra-testing/recstat/recstat.py
new file mode 100644
index 0000000..ff1b11e
--- /dev/null
+++ b/abs/extra-testing/recstat/recstat.py
@@ -0,0 +1,38 @@
+#!/usr/bin/python 
+
+import httplib 
+import serial,time 
+
+mythStatus = "localhost:6544" 
+encoder1 = "Encoder 1 " 
+encoder2 = "Encoder 2 " 
+recording = "is local on mythtv and is recording" 
+watching = "is local on mythtv and is watching" 
+
+#Open COM2 
+s = serial.Serial(1) 
+#Turn off all lights 
+s.setDTR(0) 
+s.setRTS(0) 
+
+while(True): 
+   conn = httplib.HTTPConnection(mythStatus) 
+   conn.request("GET", "/") 
+   r1 = conn.getresponse() 
+   results = r1.read() 
+
+   if(results.find(encoder1+recording)!=-1): 
+      s.setDTR(1) 
+   elif (results.find(encoder1+watching) !=-1): 
+      s.setDTR(1) 
+   else: 
+      s.setDTR(0) 
+
+   if(results.find(encoder2+recording)!=-1): 
+      s.setRTS(1) 
+   elif (results.find(encoder2+watching) !=-1): 
+      s.setRTS(1) 
+   else: 
+      s.setRTS(0) 
+
+   time.sleep(1)
\ No newline at end of file
-- 
cgit v0.12


From b0529d6eaf69405fb2ca0faa2a97c5ffb756c2ad Mon Sep 17 00:00:00 2001
From: James Meyer <james.meyer@operamail.com>
Date: Thu, 25 Mar 2010 11:43:53 -0500
Subject: python-pyserial: initial import needed for recstat

---
 abs/extra-testing/python-pyserial/PKGBUILD | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)
 create mode 100644 abs/extra-testing/python-pyserial/PKGBUILD

diff --git a/abs/extra-testing/python-pyserial/PKGBUILD b/abs/extra-testing/python-pyserial/PKGBUILD
new file mode 100644
index 0000000..d90ee2d
--- /dev/null
+++ b/abs/extra-testing/python-pyserial/PKGBUILD
@@ -0,0 +1,20 @@
+# $Id: PKGBUILD 82 2009-07-17 19:56:55Z aaron $
+# Maintainer: Douglas Soares de Andrade <dsandrade@gmail.com>
+# Contributor: Douglas Soares de Andrade <dsandrade@gmail.com>
+
+pkgname=python-pyserial
+pkgver=2.4
+pkgrel=1
+pkgdesc="Multiplatform Serial Port Module for Python"
+arch=('i686' 'x86_64')
+url="http://pyserial.sf.net"
+license=('custom:PYTHON')
+depends=('python')
+source=(http://downloads.sourceforge.net/sourceforge/pyserial/pyserial-$pkgver.tar.gz)
+
+build() {
+	cd $startdir/src/pyserial-$pkgver
+    python setup.py install --root=$startdir/pkg
+	install -D -m644 LICENSE.txt $startdir/pkg/usr/share/licenses/$pkgname/LICENSE.txt
+}
+md5sums=('eec19df59fd75ba5a136992897f8e468')
-- 
cgit v0.12


From 1b80c6bf68b69f9b7befe14f975a079efc9d3811 Mon Sep 17 00:00:00 2001
From: James Meyer <james.meyer@operamail.com>
Date: Thu, 25 Mar 2010 11:44:22 -0500
Subject: recstat: update pkgbuild to include python-pyserial as a dep cleaned
 up recstat.py.

---
 abs/extra-testing/recstat/PKGBUILD   |  6 ++++--
 abs/extra-testing/recstat/recstat.py | 35 +++++++++++++++++------------------
 2 files changed, 21 insertions(+), 20 deletions(-)

diff --git a/abs/extra-testing/recstat/PKGBUILD b/abs/extra-testing/recstat/PKGBUILD
index 84a0943..ba67bd5 100644
--- a/abs/extra-testing/recstat/PKGBUILD
+++ b/abs/extra-testing/recstat/PKGBUILD
@@ -1,10 +1,10 @@
 pkgname=recstat
 pkgver=1
-pkgrel=7
+pkgrel=13
 pkgdesc="pkg to help use the  System LEDs for Recording Status"
 arch=('i686' 'x86_64')
 url=""
-depends=('python')
+depends=('python' 'python-pyserial')
 license=('GPL')
 source=(recstat recstat.py)
 md5sums=('626acb8cdd9e5cdb3a502bc12b828067')
@@ -15,3 +15,5 @@ build () {
 }
 md5sums=('7f4ba41b65ed4d693d60d5ea00e8411b'
          '9477fe77a716c308125eab521cf59f20')
+md5sums=('7f4ba41b65ed4d693d60d5ea00e8411b'
+         '810ee7a073e8f417ab18e146ebf3b900')
diff --git a/abs/extra-testing/recstat/recstat.py b/abs/extra-testing/recstat/recstat.py
index ff1b11e..6e09da9 100644
--- a/abs/extra-testing/recstat/recstat.py
+++ b/abs/extra-testing/recstat/recstat.py
@@ -16,23 +16,22 @@ s.setDTR(0)
 s.setRTS(0) 
 
 while(True): 
-   conn = httplib.HTTPConnection(mythStatus) 
-   conn.request("GET", "/") 
-   r1 = conn.getresponse() 
-   results = r1.read() 
+    conn = httplib.HTTPConnection(mythStatus) 
+    conn.request("GET", "/") 
+    r1 = conn.getresponse() 
+    results = r1.read() 
 
-   if(results.find(encoder1+recording)!=-1): 
-      s.setDTR(1) 
-   elif (results.find(encoder1+watching) !=-1): 
-      s.setDTR(1) 
-   else: 
-      s.setDTR(0) 
+    if(results.find(encoder1+recording)!=-1): 
+        s.setDTR(1) 
+    elif (results.find(encoder1+watching) !=-1): 
+        s.setDTR(1) 
+    else: 
+        s.setDTR(0) 
+        if(results.find(encoder2+recording)!=-1): 
+            s.setRTS(1) 
+        elif (results.find(encoder2+watching) !=-1): 
+            s.setRTS(1) 
+        else: 
+            s.setRTS(0) 
 
-   if(results.find(encoder2+recording)!=-1): 
-      s.setRTS(1) 
-   elif (results.find(encoder2+watching) !=-1): 
-      s.setRTS(1) 
-   else: 
-      s.setRTS(0) 
-
-   time.sleep(1)
\ No newline at end of file
+        time.sleep(1)
-- 
cgit v0.12


From 08532d47763dea9985faa9ad996a31df87400fb7 Mon Sep 17 00:00:00 2001
From: James Meyer <james.meyer@operamail.com>
Date: Thu, 25 Mar 2010 12:02:36 -0500
Subject: recstat: added run file. -More cleanup for recstat.py. -removed
 recstat which is used for init

closes #632
---
 abs/extra-testing/recstat/PKGBUILD        | 12 ++++++------
 abs/extra-testing/recstat/recstat.install |  1 +
 abs/extra-testing/recstat/recstat.py      | 17 +++++++++--------
 abs/extra-testing/recstat/run             |  7 +++++++
 4 files changed, 23 insertions(+), 14 deletions(-)
 create mode 100755 abs/extra-testing/recstat/run

diff --git a/abs/extra-testing/recstat/PKGBUILD b/abs/extra-testing/recstat/PKGBUILD
index ba67bd5..023a0ed 100644
--- a/abs/extra-testing/recstat/PKGBUILD
+++ b/abs/extra-testing/recstat/PKGBUILD
@@ -1,19 +1,19 @@
 pkgname=recstat
 pkgver=1
-pkgrel=13
+pkgrel=20
 pkgdesc="pkg to help use the  System LEDs for Recording Status"
 arch=('i686' 'x86_64')
 url=""
 depends=('python' 'python-pyserial')
 license=('GPL')
-source=(recstat recstat.py)
+source=(recstat recstat.py run)
 md5sums=('626acb8cdd9e5cdb3a502bc12b828067')
 install=recstat.install
 build () {
-  install -D $startdir/src/recstat $startdir/pkg/etc/rc.d/recstat
+#  install -D $startdir/src/recstat $startdir/pkg/etc/rc.d/recstat
   install -D $startdir/src/recstat.py $startdir/pkg/usr/bin/recstat.py
+  install -D $startdir/src/run $startdir/pkg/etc/sv/recstat/run
 }
 md5sums=('7f4ba41b65ed4d693d60d5ea00e8411b'
-         '9477fe77a716c308125eab521cf59f20')
-md5sums=('7f4ba41b65ed4d693d60d5ea00e8411b'
-         '810ee7a073e8f417ab18e146ebf3b900')
+         '7bc206d78a096e6ee80b9bb346619ed4'
+         '3a7cd3382212650e9233b910ed28d046')
diff --git a/abs/extra-testing/recstat/recstat.install b/abs/extra-testing/recstat/recstat.install
index c45cc1b..ecd58f0 100644
--- a/abs/extra-testing/recstat/recstat.install
+++ b/abs/extra-testing/recstat/recstat.install
@@ -5,6 +5,7 @@ post_install() {
     echo ""
     echo " Edit /usr/bin/recstat.py  to fit your tuner setup"
     echo " http://linhes.org/bugs/projects/lin-hes/wiki/_Using_System_LEDs_for_Recording_Status_"
+    echo " To start this program at boot run  add_service.sh recstat    "
 }
 
 op=$1
diff --git a/abs/extra-testing/recstat/recstat.py b/abs/extra-testing/recstat/recstat.py
index 6e09da9..8def041 100644
--- a/abs/extra-testing/recstat/recstat.py
+++ b/abs/extra-testing/recstat/recstat.py
@@ -3,7 +3,7 @@
 import httplib 
 import serial,time 
 
-mythStatus = "localhost:6544" 
+mythStatus = "127.0.0.1:6544" 
 encoder1 = "Encoder 1 " 
 encoder2 = "Encoder 2 " 
 recording = "is local on mythtv and is recording" 
@@ -27,11 +27,12 @@ while(True):
         s.setDTR(1) 
     else: 
         s.setDTR(0) 
-        if(results.find(encoder2+recording)!=-1): 
-            s.setRTS(1) 
-        elif (results.find(encoder2+watching) !=-1): 
-            s.setRTS(1) 
-        else: 
-            s.setRTS(0) 
+       
+    if(results.find(encoder2+recording)!=-1): 
+        s.setRTS(1) 
+    elif (results.find(encoder2+watching) !=-1): 
+        s.setRTS(1) 
+    else: 
+        s.setRTS(0) 
 
-        time.sleep(1)
+    time.sleep(1)
diff --git a/abs/extra-testing/recstat/run b/abs/extra-testing/recstat/run
new file mode 100755
index 0000000..150fdb4
--- /dev/null
+++ b/abs/extra-testing/recstat/run
@@ -0,0 +1,7 @@
+#!/bin/sh
+exec 2>&1
+export TERM=linux
+. /etc/rc.conf
+. /etc/rc.d/functions
+stat_runit "Starting recstat"
+exec /usr/bin/recstat.py
-- 
cgit v0.12


From 0818619a55d0aa584ee30dfef1c99c4ffed8dcdb Mon Sep 17 00:00:00 2001
From: James Meyer <james.meyer@operamail.com>
Date: Thu, 25 Mar 2010 13:35:43 -0500
Subject: mythinstall: new mythvantage Reworked warning msg closes #496

---
 abs/core-testing/mythinstall/PKGBUILD | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/abs/core-testing/mythinstall/PKGBUILD b/abs/core-testing/mythinstall/PKGBUILD
index f97541b..b651479 100644
--- a/abs/core-testing/mythinstall/PKGBUILD
+++ b/abs/core-testing/mythinstall/PKGBUILD
@@ -1,7 +1,7 @@
 # Maintainer: Jams
 pkgname=mythinstall
 pkgver=2
-pkgrel=28
+pkgrel=29
 pkgdesc="LinHES installer/systemconfig GUI."
 arch=i686
 depends=()
-- 
cgit v0.12

