aboutsummaryrefslogtreecommitdiff
path: root/system/mjpg-streamer
diff options
context:
space:
mode:
Diffstat (limited to 'system/mjpg-streamer')
-rw-r--r--system/mjpg-streamer/README28
-rw-r--r--system/mjpg-streamer/mjpg-streamer.SlackBuild117
-rw-r--r--system/mjpg-streamer/mjpg-streamer.info10
-rw-r--r--system/mjpg-streamer/slack-desc19
4 files changed, 174 insertions, 0 deletions
diff --git a/system/mjpg-streamer/README b/system/mjpg-streamer/README
new file mode 100644
index 0000000000000..ff64743fac6cc
--- /dev/null
+++ b/system/mjpg-streamer/README
@@ -0,0 +1,28 @@
+MJPG-streamer is a very lightweight and resource friendly video
+streamer. It also comes with uvc_stream, which is a very basic
+streamer, and uvc_viewer, a simple gtk viewing application.
+
+MJPG-streamer takes JPGs from Linux-UVC compatible webcams,
+filesystem or other input plugins and streams them as M-JPEG via HTTP
+to webbrowsers, VLC and other software. It is the successor of
+uvc-streamer, a Linux-UVC streaming application with Pan/Tilt
+
+Homepage: https://sourceforge.net/projects/mjpg-streamer/
+
+Note:
+
+The included uvc_viewer is a 32bit binary and therefore will not
+work on other archs. You may use mplayer to watch the stream
+using a similar command to:
+
+mplayer -fps 30 -demuxer lavf -cache 256 \
+"http://192.168.1.2:8080/?action=stream&ignored.mjpg"
+
+You may find that mplayer is lighter on resources anyway. Also
+the viewer leaves a properties.ini file in the CWD.
+
+There is an included start.sh script which contains many
+examples for using the mjpg_streamer application. (The www directory
+mentioned should be replaced by /var/mjpg-www.)
+
+You can find it and more in /usr/doc/mjpg-streamer-$version
diff --git a/system/mjpg-streamer/mjpg-streamer.SlackBuild b/system/mjpg-streamer/mjpg-streamer.SlackBuild
new file mode 100644
index 0000000000000..7b9e4eb43e4df
--- /dev/null
+++ b/system/mjpg-streamer/mjpg-streamer.SlackBuild
@@ -0,0 +1,117 @@
+#!/bin/sh
+
+# Slackware build script for mjpg-streamer
+
+# Copyright 2011 David Woodfall <dave@dawoodfall.net>
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+PRGNAM=mjpg-streamer
+VERSION=${VERSION:-svn20111016}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/sbo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+cd $PRGNAM-$VERSION
+chown -R root:root .
+chmod -R u+w,go+r-w,a-s .
+
+# Add our flags to the Makefiles
+find . -name Makefile -exec \
+ sed -i "s/^CFLAGS += -O2/CFLAGS += $SLKCFLAGS/
+ s/^CFLAGS += -O1/CFLAGS += $SLKCFLAGS/
+ 0,/^CFLAGS +=/ {/^CFLAGS +=.*/a\
+ CXXFLAGS = $SLKCFLAGS
+ }" '{}' \;
+
+# Manual installation section
+cd uvc-streamer
+make
+install -m 755 -D uvc_stream $PKG/usr/bin/uvc_stream
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION/uvc-streamer
+cp -a README CHANGELOG LICENSE \
+ $PKG/usr/doc/$PRGNAM-$VERSION/uvc-streamer
+
+cd ../mjpg-streamer
+make
+install -m 755 -D mjpg_streamer $PKG/usr/bin/mjpg_streamer
+mkdir -p $PKG/usr/lib$LIBDIRSUFFIX
+install -m 644 *.so $PKG/usr/lib$LIBDIRSUFFIX/
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION/mjpg-streamer
+cp -a README CHANGELOG LICENSE TODO start.sh \
+ $PKG/usr/doc/$PRGNAM-$VERSION/mjpg-streamer
+mkdir -p $PKG/var/mjpg-www
+cp -r www/* $PKG/var/mjpg-www
+
+cd ../udp_client
+qmake
+make
+install -m 755 -D udp_client $PKG/usr/bin/udp_client
+
+find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF | \
+ cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+
+# This is already stripped.
+cd ../mjpeg-client/bin/linux_i386_upx
+install -m 755 -D viewer $PKG/usr/bin/uvc_viewer
+
+cd ../../../
+
+cp -a doc/* \
+ $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
diff --git a/system/mjpg-streamer/mjpg-streamer.info b/system/mjpg-streamer/mjpg-streamer.info
new file mode 100644
index 0000000000000..f58c4225bcc86
--- /dev/null
+++ b/system/mjpg-streamer/mjpg-streamer.info
@@ -0,0 +1,10 @@
+PRGNAM="mjpg-streamer"
+VERSION="svn20111016"
+HOMEPAGE="https://sourceforge.net/projects/mjpg-streamer/"
+DOWNLOAD="http://source.dawoodfall.net/mjpg-streamer-svn20111016.tar.gz"
+MD5SUM="1e251c2b8a76fe524d5901054ea5529b"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+MAINTAINER="Dave Woodfall"
+EMAIL="dave@dawoodfall.net"
+APPROVED="Erik Hanson"
diff --git a/system/mjpg-streamer/slack-desc b/system/mjpg-streamer/slack-desc
new file mode 100644
index 0000000000000..5a85bdb8a8e15
--- /dev/null
+++ b/system/mjpg-streamer/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+mjpg-streamer: mjpg-streamer (lightweight video streamer)
+mjpg-streamer:
+mjpg-streamer: MJPG-streamer takes JPGs from Linux-UVC compatible webcams,
+mjpg-streamer: filesystem or other input plugins and streams them as M-JPEG via HTTP
+mjpg-streamer: to webbrowsers, VLC and other software. It is the successor of
+mjpg-streamer: uvc-streamer, a Linux-UVC streaming application with Pan/Tilt
+mjpg-streamer:
+mjpg-streamer: Homepage: https://sourceforge.net/projects/mjpg-streamer/
+mjpg-streamer:
+mjpg-streamer:
+mjpg-streamer: