summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoerg Bornkessel <hd_brummy@gentoo.org>2008-11-17 17:56:13 +0000
committerJoerg Bornkessel <hd_brummy@gentoo.org>2008-11-17 17:56:13 +0000
commit5c2d8703468ec235f706113eebdb672efb689b44 (patch)
treeace034d523d518319bbc2efe7ca7a07052960417 /media-plugins
parentnew package (diff)
downloadhistorical-5c2d8703468ec235f706113eebdb672efb689b44.tar.gz
historical-5c2d8703468ec235f706113eebdb672efb689b44.tar.bz2
historical-5c2d8703468ec235f706113eebdb672efb689b44.zip
initial ebuild
Package-Manager: portage-2.1.4.5
Diffstat (limited to 'media-plugins')
-rw-r--r--media-plugins/vdr-systeminfo/ChangeLog11
-rw-r--r--media-plugins/vdr-systeminfo/Manifest18
-rw-r--r--media-plugins/vdr-systeminfo/files/confd20
-rw-r--r--media-plugins/vdr-systeminfo/files/rc-addon.sh13
-rw-r--r--media-plugins/vdr-systeminfo/files/systeminfo.sh116
-rw-r--r--media-plugins/vdr-systeminfo/metadata.xml10
-rw-r--r--media-plugins/vdr-systeminfo/vdr-systeminfo-0.1.1.ebuild27
7 files changed, 215 insertions, 0 deletions
diff --git a/media-plugins/vdr-systeminfo/ChangeLog b/media-plugins/vdr-systeminfo/ChangeLog
new file mode 100644
index 000000000000..bc3939529ccc
--- /dev/null
+++ b/media-plugins/vdr-systeminfo/ChangeLog
@@ -0,0 +1,11 @@
+# ChangeLog for media-plugins/vdr-systeminfo
+# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/media-plugins/vdr-systeminfo/ChangeLog,v 1.1 2008/11/17 17:56:13 hd_brummy Exp $
+
+*vdr-systeminfo-0.1.1 (17 Nov 2008)
+
+ 17 Nov 2008; Joerg Bornkessel <hd_brummy@gentoo.org> +files/confd,
+ +files/rc-addon.sh, +files/systeminfo.sh, +metadata.xml,
+ +vdr-systeminfo-0.1.1.ebuild:
+ initial ebuild
+
diff --git a/media-plugins/vdr-systeminfo/Manifest b/media-plugins/vdr-systeminfo/Manifest
new file mode 100644
index 000000000000..ae8a99d9ba0f
--- /dev/null
+++ b/media-plugins/vdr-systeminfo/Manifest
@@ -0,0 +1,18 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+AUX confd 471 RMD160 6ae384cd921242721dcb19852cc9d4fe5375189c SHA1 4365d075f3be985a7a43499812c58eb879e5cd01 SHA256 3150c608b36b0af09291857532e1ab0abf2fc356dd19e873eeb99cedf9c9fc53
+AUX rc-addon.sh 347 RMD160 4ac4dec347ced863483b63e7dab2b1520e30f5a4 SHA1 edc258d538353dab7c41b63b2ea8b407ec1b7901 SHA256 d902e1d564db0d2d0524200d3fff7dbbfec9e4fb9ebffff233aed631158b4687
+AUX systeminfo.sh 3173 RMD160 0513f51eb0e688f3600dcc36ad0d60003ff8970c SHA1 3db15605d46f62d911cdce3310e0f54239158270 SHA256 d5c80cbf1cdd78f9b97798f5929ef410f453da16a3dea69561e03bb5eb6cf884
+DIST vdr-systeminfo-0.1.1.tar.bz2 16816 RMD160 8e0c6aa070a008faccea6b4f10f696833eb7a6da SHA1 cfe7bbb05402d94a88f4eb389db76d1b7df58330 SHA256 2764e88c07a84e4d42ab318e0cd7ad186b549c9843c6fed8e6aa964658685cc1
+EBUILD vdr-systeminfo-0.1.1.ebuild 695 RMD160 b2bb8a55b33eaae26559e8b1e9baaab06d674c5b SHA1 c24b233174e799c6f860c97151109f42ff6c24d9 SHA256 b030f8b54065bf6da65fd465930d011e772b4d11d63204e588962a67d042e043
+MISC ChangeLog 447 RMD160 463a3a4739d0cce5b6ea3c05e8c95b217327a8ae SHA1 48a715f046604d53db0630819e8cff7d4505a64d SHA256 e63f331b73e0536ad81e011dd82f6edf344665e83d20df95a12cea5936b885b1
+MISC metadata.xml 251 RMD160 b4bdfc1a9e947ad1d1f76c1942f02057d5cbc993 SHA1 6e174f6e4395999a9dafd53f523e079766c0b094 SHA256 b426b6e6d679a63de74d2c1a21e4da2381fb1b580b0180b041307471d67ab54f
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.5 (GNU/Linux)
+Comment: added by hd_brummy@gentoo.org
+
+iD8DBQFJIbBJdn07HTTCgIoRAjFrAJ9bEFXZMfZFH+T8a35lMPAo3oOATwCdGmmh
+PAChXFOBhoqNebp0SFQPBbs=
+=vyyB
+-----END PGP SIGNATURE-----
diff --git a/media-plugins/vdr-systeminfo/files/confd b/media-plugins/vdr-systeminfo/files/confd
new file mode 100644
index 000000000000..4a7022d79de3
--- /dev/null
+++ b/media-plugins/vdr-systeminfo/files/confd
@@ -0,0 +1,20 @@
+# Global config file for VDR systeminfo plugin
+# $Header: /var/cvsroot/gentoo-x86/media-plugins/vdr-systeminfo/files/confd,v 1.1 2008/11/17 17:56:13 hd_brummy Exp $
+
+# I most cases here is no user activity needed
+# Yust if you get wrong or no output in OSD of plugin
+# you have something to change on next parameter
+# Get right parameter by run 'sensors' on Konsole
+
+CPU_TEMP="temp2"
+
+MOBO_TEMP="temp1"
+
+FAN_1="fan2"
+
+FAN_2="fan1"
+
+DISK_1="/dev/hda"
+
+#DISK_2="/dev/hdc"
+
diff --git a/media-plugins/vdr-systeminfo/files/rc-addon.sh b/media-plugins/vdr-systeminfo/files/rc-addon.sh
new file mode 100644
index 000000000000..411ef0cc6e85
--- /dev/null
+++ b/media-plugins/vdr-systeminfo/files/rc-addon.sh
@@ -0,0 +1,13 @@
+# $Header: /var/cvsroot/gentoo-x86/media-plugins/vdr-systeminfo/files/rc-addon.sh,v 1.1 2008/11/17 17:56:13 hd_brummy Exp $
+#
+# rc-addon-script for plugin systeminfo
+#
+# Joerg Bornkessel <hd_brummy@gentoo.org>
+
+: ${SYSTEMINFO_SCRIPT:=/usr/share/vdr/systeminfo/systeminfo.sh}
+
+plugin_pre_vdr_start() {
+
+add_plugin_param "-s ${SYSTEMINFO_SCRIPT}"
+
+} \ No newline at end of file
diff --git a/media-plugins/vdr-systeminfo/files/systeminfo.sh b/media-plugins/vdr-systeminfo/files/systeminfo.sh
new file mode 100644
index 000000000000..47dd1f564b42
--- /dev/null
+++ b/media-plugins/vdr-systeminfo/files/systeminfo.sh
@@ -0,0 +1,116 @@
+#!/bin/bash
+# systeminfo.sh: external data collection script
+# This file belongs to the VDR plugin systeminfo
+#
+# See the main source file 'systeminfo.c' for copyright information and
+# how to reach the author.
+#
+# $Id: systeminfo.sh,v 1.1 2008/11/17 17:56:13 hd_brummy Exp $
+#
+# possible output formats:
+# (blanks around tabs only for better reading)
+# 1) Name \t Value displays Name and Value
+# 2) Name \t Value1 \t Value2 displays Name, Value1 and Value2
+# 3) Name \t total used displays an additional progress bar (percentage) after the values
+# 4) s \t Name \t ... defines a static value, this line is only requested during the first cycle
+#
+# special keywords (they are replaced by the plugin with the actual value):
+# CPU% CPU usage in percent
+#
+# test with: for i in $(seq 1 16); do systeminfo.sh $i;echo;done
+#
+
+PATH=/usr/bin:/bin:/sbin:/usr/sbin
+
+source /etc/conf.d/vdr.systeminfo
+
+case "$1" in
+ 1) # kernel version (static)
+ KERNEL=$(uname -rm)
+ echo -ne "s\tLinux Kernel:\t"$KERNEL
+ ;;
+
+ 2) # distribution release (static)
+ if test -f /etc/gentoo-release; then
+ DISTRI="Gentoo"
+ RELEASE=$(head -n 1 /etc/gentoo-release)
+ fi
+ echo -ne "s\tDistribution:\t"$RELEASE
+ exit
+ ;;
+
+ 3) # CPU type (static)
+ CPUTYPE=$(grep 'model name' /proc/cpuinfo | cut -d':' -f 2 | cut -d' ' -f2- | uniq)
+ echo -ne "s\tCPU Type:\t"$CPUTYPE
+ ;;
+
+ 4) # current CPU speed
+ VAR=$(grep 'cpu MHz' /proc/cpuinfo | sed 's/.*: *\([0-9]*\)\.[0-9]*/\1 MHz/')
+ echo -ne "CPU speed:\t"$VAR
+ exit
+ ;;
+
+ 5) # hostname and IP (static)
+ hostname=$(hostname)
+ dnsname=$(dnsdomainname)
+ IP=$(ifconfig eth0 | grep inet | cut -d: -f2 | cut -d' ' -f1)
+ echo -ne "s\tHostname:\t"${hostname:-<unknown>}"."${dnsname:-<unknown>}"\tIP: "${IP:-N/A}
+ exit
+ ;;
+
+ 6) # fan speeds
+ CPU=$( sensors | grep -i ${FAN_1:=FAN1} | tr -s ' ' | cut -d' ' -f 2)
+ CASE=$(sensors | grep -i ${FAN_2:=Fan2} | tr -s ' ' | cut -d' ' -f 2)
+ echo -ne "Fans:\tCPU: "$CPU" rpm\tCase: "$CASE" rpm"
+ exit
+ ;;
+
+ 7) # temperature of CPU and mainboard
+ CPU=$(sensors | grep -i ${CPU_TEMP:=CPU Temp} | tr -s ' ' | cut -d' ' -f 2)
+ MB=$( sensors | grep -i ${MOBO_TEMP:=M/B Temp} | tr -s ' ' | cut -d' ' -f 2)
+ echo -ne "Temperatures:\tCPU: "$CPU"\tMB: "$MB
+ exit
+ ;;
+
+ 8) # temperature of hard disks
+ DISK1=$(hddtemp ${DISK_1:=/dev/sda} | cut -d: -f1,3)
+ DISK2=$(hddtemp ${DISK_2} | cut -d: -f1,3)
+ echo -ne "\t"$DISK1"\t"$DISK2
+ exit
+ ;;
+
+ 9) # CPU usage
+ echo -e "CPU time:\tCPU%"
+ exit
+ ;;
+
+ 10) # header (static)
+ echo -ne "s\t\ttotal / free"
+ exit
+ ;;
+
+ 11) # video disk usage
+ VAR=$(df -h | grep hd | grep video | tail -n 1 | tr -s ' ' | cut -d' ' -f 2,4)
+ echo -ne "Video Disk:\t"$VAR
+ exit
+ ;;
+
+ 12) # memory usage
+ VAR=$( grep -E 'MemTotal|MemFree' /proc/meminfo | cut -d: -f2 | tr -d ' ')
+ echo -ne "Memory:\t"$VAR
+ exit
+ ;;
+
+ 13) # swap usage
+ VAR=$(grep -E 'SwapTotal|SwapFree' /proc/meminfo | cut -d: -f2 | tr -d ' ')
+ echo -ne "Swap:\t"$VAR
+ exit
+ ;;
+ test)
+ echo ""
+ echo "Usage: systeminfo.sh {1|2|3|4|...}"
+ echo ""
+ exit 1
+ ;;
+esac
+exit
diff --git a/media-plugins/vdr-systeminfo/metadata.xml b/media-plugins/vdr-systeminfo/metadata.xml
new file mode 100644
index 000000000000..5f9f14619db8
--- /dev/null
+++ b/media-plugins/vdr-systeminfo/metadata.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>media-tv</herd>
+<maintainer>
+<email>vdr@gentoo.org</email>
+<name>Gentoo VDR Project</name>
+</maintainer>
+</pkgmetadata>
+
diff --git a/media-plugins/vdr-systeminfo/vdr-systeminfo-0.1.1.ebuild b/media-plugins/vdr-systeminfo/vdr-systeminfo-0.1.1.ebuild
new file mode 100644
index 000000000000..13088631c1ff
--- /dev/null
+++ b/media-plugins/vdr-systeminfo/vdr-systeminfo-0.1.1.ebuild
@@ -0,0 +1,27 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-plugins/vdr-systeminfo/vdr-systeminfo-0.1.1.ebuild,v 1.1 2008/11/17 17:56:13 hd_brummy Exp $
+
+inherit vdr-plugin
+
+DESCRIPTION="VDR Plugin: systeminfo"
+HOMEPAGE="http://firefly.vdr-developer.org/systeminfo/"
+SRC_URI="http://firefly.vdr-developer.org/systeminfo/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~x86 ~amd64"
+IUSE=""
+
+DEPEND=">=media-video/vdr-1.4.7"
+
+RDEPEND="sys-apps/lm_sensors
+ app-admin/hddtemp"
+
+src_install() {
+ vdr-plugin_src_install
+
+ insinto /usr/share/vdr/systeminfo/
+ insopts -m0755
+ doins "${FILESDIR}"/systeminfo.sh
+}