aboutsummaryrefslogtreecommitdiff
path: root/multimedia/mplayer
diff options
context:
space:
mode:
authorHeinz Wiesinger <pprkut@slackbuilds.org>2010-05-11 20:30:41 +0200
committerHeinz Wiesinger <pprkut@slackbuilds.org>2010-05-11 20:30:41 +0200
commit884e8a19ff309fe8ccf1f7914909ba80a0e65202 (patch)
treef7e92a9f69a56d2877249e97fe69b9c7e834280b /multimedia/mplayer
parent61c96b150ad2872fa57da35e5c232d48eecfb706 (diff)
multimedia/mplayer: Renamed from MPlayer
Diffstat (limited to 'multimedia/mplayer')
-rw-r--r--multimedia/mplayer/Blue-1.7.tar.bz2bin0 -> 222567 bytes
-rw-r--r--multimedia/mplayer/README30
-rw-r--r--multimedia/mplayer/doinst.sh19
-rw-r--r--multimedia/mplayer/mplayer.SlackBuild193
-rw-r--r--multimedia/mplayer/mplayer.info8
-rw-r--r--multimedia/mplayer/slack-desc19
6 files changed, 269 insertions, 0 deletions
diff --git a/multimedia/mplayer/Blue-1.7.tar.bz2 b/multimedia/mplayer/Blue-1.7.tar.bz2
new file mode 100644
index 0000000000000..993bde3cb3a63
--- /dev/null
+++ b/multimedia/mplayer/Blue-1.7.tar.bz2
Binary files differ
diff --git a/multimedia/mplayer/README b/multimedia/mplayer/README
new file mode 100644
index 0000000000000..b261eef7b3833
--- /dev/null
+++ b/multimedia/mplayer/README
@@ -0,0 +1,30 @@
+MPlayer plays most MPEG, VOB, AVI, OGG/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4,
+FLI, RM, NuppelVideo, YUV4MPEG, FILM, RoQ, PVA files, supported by many
+native, XAnim, and Win32 DLL codecs. You can watch VideoCD, SVCD, DVD, 3ivx,
+DivX 3/4/5 and even WMV movies, too (without the avifile library).
+
+The required codecs are available from the MPlayer site, and we have a
+SlackBuild script for them as well. If you have already installed the
+codecs on your own, then make sure the CODECSDIR variable in the script
+is defined correctly (or pass the correct value on the command line when
+running the SlackBuild script).
+
+This script is written to install the default "Blue" theme for MPlayer, and
+it will print an error (but allow you to continue) if you don't have the
+theme tarball in the build directory. You can obtain the Blue theme here:
+ http://www.mplayerhq.hu/MPlayer/skins/Blue-1.7.tar.bz2
+If you want to install some other theme, the script is written to support
+that, but other themes have not been tested with it. The best option for
+using additional themes/skins is to install them in $HOME/.mplayer by
+following the directions on the MPlayer homepage.
+
+You can speed-up decoding and encoding by passing RUNTIME_CPU=no to the build
+script.
+
+MPlayer supports DVD-Menu-Navigation; for it to work as expected, you will
+need the run the script with DVDNAV=yes and have the external libdvdnav
+package installed. This will disable MPlayer's internal libdvdread and
+rely on the libdvdread version installed by libdvdnav. Only with this option
+set will you be able to navigate through the menus. Additionally, you need
+to either write "mouse-movements=yes" into your mplayer.conf or start mplayer
+as "mplayer dvdnav:// -mouse-movements"
diff --git a/multimedia/mplayer/doinst.sh b/multimedia/mplayer/doinst.sh
new file mode 100644
index 0000000000000..7896df199e1dc
--- /dev/null
+++ b/multimedia/mplayer/doinst.sh
@@ -0,0 +1,19 @@
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD|md5sum)" = "$(cat $NEW|md5sum)" ]; then
+ # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+
+config etc/mplayer/mplayer.conf.new
+
+if [ -x /usr/bin/update-desktop-database ]; then
+ /usr/bin/update-desktop-database -q usr/share/applications
+fi
+
diff --git a/multimedia/mplayer/mplayer.SlackBuild b/multimedia/mplayer/mplayer.SlackBuild
new file mode 100644
index 0000000000000..80d71ce8d2570
--- /dev/null
+++ b/multimedia/mplayer/mplayer.SlackBuild
@@ -0,0 +1,193 @@
+#!/bin/sh
+
+# Slackware build script for MPlayer
+
+# Copyright 2006-2008 Robby Workman, Northport, AL, USA
+# Copyright 2007-2008 Eric Hameleers <alien@slackware.com>
+# 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.
+
+# Thanks to Heinz Wiesinger and Niki Kovacs for suggestions and code
+
+PRGNAM=mplayer
+VERSION=${VERSION:-svn_r27865}
+ARCH=${ARCH:-i486}
+BUILD=${BUILD:-2}
+TAG=${TAG:-_SBo}
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+# If you installed the codecs package according to the instructions at
+# the MPlayer website, you'll probably want to change this variable
+# to /usr/local/lib/codecs. Otherwise, you'll want to leave it alone
+# (if you installed the codecs using our SlackBuild script for them)
+# unless you placed the codecs in a non-standard location.
+CODECSDIR=${CODECSDIR:-/usr/lib/codecs}
+
+# This will activate runtime cpu-detection. This is a good choice,
+# if you build a package you want to use on different machines.
+# However, this does have a performance issue, so if that affects
+# you, you can turn it off here
+RUNTIME_CPU=${RUNTIME_CPU:-yes}
+
+if [ "$RUNTIME_CPU" = "yes" ]; then
+ do_cpu="en"
+else
+ do_cpu="dis"
+fi
+
+# This will configure MPlayer with correct support for DVD Menus.
+# MPlayer will normally find libdvdnav automatically if the correct version
+# is installed. However, only with this option set to "yes" (and the external
+# libdvdnav installed) will you be able to navigate through the menus.
+DVDNAV=${DVDNAV:-no}
+
+if [ "$DVDNAV" = "yes" ]; then
+ do_dvdnav="--disable-dvdread-internal"
+else
+ do_dvdnav=""
+fi
+
+# The default MPlayer theme is Blue
+# http://www.mplayerhq.hu/MPlayer/skins/Blue-1.7.tar.bz2
+# Others may work fine here, but the script has not been tested with them
+# Even so, it's probably better to leave this alone and install additional
+# themes to $HOME/.mplayer/skins/
+THEME=Blue
+THEME_VERSION=1.7
+
+# The fonts listed below should exist on a stock Slackware system.
+# If you want to change the default font after installation, that is probably
+# best done by making a link to your preferred font in $HOME/.mplayer/ by:
+# cd $HOME/.mplayer
+# ln -s /path/to/preferred/font subfont.ttf
+OSDFONTS="LiberationSans-Regular.ttf DejaVuSans.ttf Arialuni.ttf arial.ttf Vera.ttf"
+
+# Change this with something like: LANGUAGES=cs ./MPlayer.SlackBuild
+# Choices are: bg cs de dk el en es fr hu it ja ko mk nb
+# nl pl ro ru sk sv tr uk pt_BR zh_CN zh_TW
+# If you need more than one, they should be comma-separated -- e.g. "en,es,pt_BR"
+LANGUAGES=${LANGUAGES:-"en"}
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
+cd $PRGNAM-$VERSION
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \;
+
+# The MPlayer developers will not support and/or deal with bug reports
+# using custom CFLAGS, and the intent here is not to build a redistributable
+# package anyway, we won't :-)
+./configure \
+ --prefix=/usr \
+ --mandir=/usr/man \
+ --confdir=/etc/mplayer \
+ --disable-arts \
+ --enable-gui \
+ --enable-menu \
+ --${do_cpu}able-runtime-cpudetection \
+ --codecsdir="$CODECSDIR" \
+ --language="$LANGUAGES" \
+ $do_dvdnav
+
+make
+make install DESTDIR=$PKG
+
+# Now let's build the html docs
+( cd DOCS/xml
+ for i in $(echo $LANGUAGES | tr , ' ') ; do
+ make html-single-$i ;
+ done
+)
+
+( find $PKG | xargs file | grep -e "executable" -e "shared object" \
+ | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null )
+
+( cd $PKG/usr/man
+ find . -type f -exec gzip -9 {} \;
+ for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
+)
+
+mkdir -p $PKG/usr/share/mplayer/skins
+if [ -r $CWD/$THEME-$THEME_VERSION.tar.bz2 ]; then
+ cd $PKG/usr/share/mplayer/skins
+ tar xf $CWD/$THEME-$THEME_VERSION.tar.bz2
+ ln -s $THEME default
+ cd -
+else
+ echo A usable theme tarball does not appear to exist in $CWD,
+ echo or you did not edit the script to reflect it, or something
+ echo else is broken.
+ echo The script will continue to build a package, but some manual
+ echo setup may be required after installation.
+ echo
+ echo Type \"exit\" to quit or any other key to continue the script.
+ read _continue
+ if [ "$_continue" = "exit" ]; then
+ exit 1
+ fi
+fi
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a AUTHORS Changelog Copyright LICENSE README DOCS/tech \
+ $PKG/usr/doc/$PRGNAM-$VERSION
+# This isn't exactly ideal, but it's better than having the entire
+# script fail simply because the docs wouldn't build
+( cp -a DOCS/HTML-single $PKG/usr/doc/$PRGNAM-$VERSION/html 2>/dev/null )
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+# Don't clobber an existing config file
+cat etc/example.conf > $PKG/etc/mplayer/mplayer.conf.new
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+cat $CWD/doinst.sh > $PKG/install/doinst.sh
+
+# We'll link to one of the standard ttf fonts defined above.
+# Thanks to Eric Hameleers for this code snippet and permission to use it.
+cat << EOF >> $PKG/install/doinst.sh
+# Symlink a default TrueType font for OSD:
+if [ ! -f usr/share/mplayer/subfont.ttf ]; then
+ for font in $OSDFONTS ; do
+ if [ -f usr/share/fonts/TTF/\$font ]; then
+ ( cd usr/share/mplayer
+ rm -f subfont.ttf
+ ln -fs /usr/share/fonts/TTF/\$font subfont.ttf
+ )
+ break
+ fi
+ done
+fi
+EOF
+
+cd $PKG
+chown -R root:root . # Just in case
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
diff --git a/multimedia/mplayer/mplayer.info b/multimedia/mplayer/mplayer.info
new file mode 100644
index 0000000000000..b24c367312e23
--- /dev/null
+++ b/multimedia/mplayer/mplayer.info
@@ -0,0 +1,8 @@
+PRGNAM="mplayer"
+VERSION="svn_r27865"
+HOMEPAGE="http://www.mplayerhq.hu/"
+DOWNLOAD="http://slackbuilds.org/sources/12.1/mplayer-svn_r27865.tar.bz2"
+MD5SUM="b2d1bc8e297e39243e242119901240b8"
+MAINTAINER="Robby Workman"
+EMAIL="rw@rlworkman.net"
+APPROVED="dsomero"
diff --git a/multimedia/mplayer/slack-desc b/multimedia/mplayer/slack-desc
new file mode 100644
index 0000000000000..ef043df631c87
--- /dev/null
+++ b/multimedia/mplayer/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----------------------------------------------------|
+mplayer: mplayer (media player for *nix)
+mplayer:
+mplayer: Media player for linux (runs on many other Unices and non-x86
+mplayer: CPUs; see the documentation) plays most MPEG, VOB, AVI, OGG/OGM,
+mplayer: VIVO, ASF/WMA/WMV, QT/MOV/MP4, FLI, RM, NuppelVideo, YUV4MPEG,
+mplayer: FILM, RoQ, PVA files, supported by many native, XAnim, and Win32
+mplayer: DLL codecs. You can watch VideoCD, SVCD, DVD, 3ivx, DivX 3/4/5,
+mplayer: and even WMV movies, too (without the avifile library).
+mplayer:
+mplayer: Homepage: http://www.mplayerhq.hu
+mplayer: