aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/owfs/files
diff options
context:
space:
mode:
authorDirk Opfer <dirk@do13.de>2009-04-22 10:31:52 +0200
committerDirk Opfer <dirk@do13.de>2009-04-22 10:31:52 +0200
commitb2bbfbf9df3fce104eba8e34121610f4c56a4625 (patch)
treeae2748db187b23a349ca0f94dd44dcb73d84e8d4 /recipes/owfs/files
parentb2c58f438d407186f3f6c4eb86e6fc070e71b42e (diff)
downloadopenembedded-b2bbfbf9df3fce104eba8e34121610f4c56a4625.tar.gz
owfs: new recipe, version 2.7p21
OWFS is an easy way to use the powerful 1-wire system of Dallas/Maxim
Diffstat (limited to 'recipes/owfs/files')
-rwxr-xr-xrecipes/owfs/files/owhttpd60
-rwxr-xr-xrecipes/owfs/files/owserver59
2 files changed, 119 insertions, 0 deletions
diff --git a/recipes/owfs/files/owhttpd b/recipes/owfs/files/owhttpd
new file mode 100755
index 0000000000..5d74d13d9d
--- /dev/null
+++ b/recipes/owfs/files/owhttpd
@@ -0,0 +1,60 @@
+#!/bin/sh
+
+PATH=/sbin:/bin:/usr/bin
+
+DAEMON="owhttpd"
+
+test -f /usr/bin/${DAEMON} || exit 0
+
+if test -f /etc/default/${DAEMON} ; then
+. /etc/default/${DAEMON}
+else
+:
+fi
+
+if [ "$START_OWHTTPD" != "yes" ]
+then
+ exit 0
+fi
+
+
+startdaemon(){
+ echo -n "Starting ${DAEMON}: "
+ start-stop-daemon --start -x /usr/bin/${DAEMON} -- ${CMDLINE} --pid_file /var/run/${DAEMON}.pid
+ echo "done"
+}
+
+stopdaemon(){
+ echo -n "Stopping ${DAEMON}: "
+ start-stop-daemon --stop -p /var/run/${DAEMON}.pid
+ echo "done"
+}
+
+
+
+case "$1" in
+ start)
+ startdaemon
+ ;;
+ stop)
+ stopdaemon
+ ;;
+ force-reload)
+ stopdaemon
+ startdaemon
+ ;;
+ restart)
+ stopdaemon
+ startdaemon
+ ;;
+ reload)
+ stopdaemon
+ startdaemon
+ ;;
+ *)
+ echo "Usage: ${DAEMON} { start | stop | restart | reload }" >&2
+ exit 1
+ ;;
+esac
+
+exit 0
diff --git a/recipes/owfs/files/owserver b/recipes/owfs/files/owserver
new file mode 100755
index 0000000000..b69ea53e37
--- /dev/null
+++ b/recipes/owfs/files/owserver
@@ -0,0 +1,59 @@
+#!/bin/sh
+
+PATH=/sbin:/bin:/usr/bin
+
+DAEMON="owserver"
+
+test -f /usr/bin/${DAEMON} || exit 0
+
+if test -f /etc/default/${DAEMON} ; then
+. /etc/default/${DAEMON}
+else
+:
+fi
+
+if [ "$START_OWSERVER" != "yes" ]
+then
+ exit 0
+fi
+
+startdaemon(){
+ echo -n "Starting ${DAEMON}: "
+ start-stop-daemon --start -x /usr/bin/${DAEMON} -- ${CMDLINE} --pid_file /var/run/${DAEMON}.pid
+ echo "done"
+}
+
+stopdaemon(){
+ echo -n "Stopping ${DAEMON}: "
+ start-stop-daemon --stop -p /var/run/${DAEMON}.pid
+ echo "done"
+}
+
+
+
+case "$1" in
+ start)
+ startdaemon
+ ;;
+ stop)
+ stopdaemon
+ ;;
+ force-reload)
+ stopdaemon
+ startdaemon
+ ;;
+ restart)
+ stopdaemon
+ startdaemon
+ ;;
+ reload)
+ stopdaemon
+ startdaemon
+ ;;
+ *)
+ echo "Usage: ${DAEMON} { start | stop | restart | reload }" >&2
+ exit 1
+ ;;
+esac
+
+exit 0