|
# --- ROCK-COPYRIGHT-NOTE-BEGIN ---
|
|
#
|
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
|
|
# Please add additional copyright information _after_ the line containing
|
|
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
|
|
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
|
|
#
|
|
# ROCK Linux: rock-src/package/jimmy/mplayer/mplayer.conf
|
|
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf
|
|
#
|
|
# This program is free software; you can redistribute it and/or modify
|
|
# it under the terms of the GNU General Public License as published by
|
|
# the Free Software Foundation; either version 2 of the License, or
|
|
# (at your option) any later version. A copy of the GNU General Public
|
|
# License can be found at Documentation/COPYING.
|
|
#
|
|
# Many people helped and are helping developing ROCK Linux. Please
|
|
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM
|
|
# file for details.
|
|
#
|
|
# --- ROCK-COPYRIGHT-NOTE-END ---
|
|
|
|
mplayer_premake() {
|
|
# disable all crappy altivec code the hard way (look into the configure
|
|
# to see why we need to do it this way. Hopefully at one day all
|
|
# the altivec crap code will compile ... -ReneR
|
|
sed -i 's/TARGET_ALTIVEC = yes/TARGET_ALTIVEC = /' config.mak
|
|
sed -i -e 's/#define HAVE_ALTIVEC 1/#undef HAVE_ALTIVEC/' \
|
|
-e 's/#define HAVE_ALTIVEC_H 1/#undef HAVE_ALTIVEC_H/' config.h
|
|
}
|
|
|
|
mplayer_postmake() {
|
|
if [ -f $root/var/adm/packages/gtk+12 ] ; then
|
|
echo "extracting the default GUI ..."
|
|
mkdir -p $datadir/$pkg/Skin
|
|
tar $taropt $archdir/default-1.7.tar.bz2 -C $datadir/$pkg/Skin
|
|
fi
|
|
|
|
echo "extracting the default font ..."
|
|
tar $taropt $archdir/font-arial-iso-8859-1.tar.bz2 -C $datadir/$pkg
|
|
rm -rf $datadir/$pkg/font
|
|
ln -sf font-arial-24-iso-8859-1 $datadir/$pkg/font
|
|
|
|
echo "copy/move some documentation ..."
|
|
cp -fR DOCS/HTML/en/*.{css,html} DOCS/tech $docdir
|
|
mv -f $datadir/$pkg/README* $docdir
|
|
|
|
echo "create a default configuration ..."
|
|
cat <<- 'EOT' > $sysconfdir/mplayer.conf
|
|
# Write your default config options here!
|
|
|
|
framedrop=yes
|
|
menu=yes
|
|
# vop=pp
|
|
# autoq=6
|
|
EOT
|
|
cp -f etc/{input,menu,codecs}.conf $sysconfdir
|
|
echo "TAB menu up" >> $sysconfdir/input.conf
|
|
rm -f $sysconfdir/*.older
|
|
|
|
echo "correcting permissions and ownership ..."
|
|
chown -R root:root $datadir/$pkg $docdir $sysconfdir
|
|
find $datadir/$pkg $docdir $sysconfdir -type d | xargs -r chmod 0755
|
|
find $datadir/$pkg $docdir $sysconfdir -type f | xargs -r chmod 0644
|
|
}
|
|
|
|
sysconfdir="$sysconfdir/mplayer"
|
|
confopt="--prefix=$root/$prefix --confdir=$sysconfdir"
|
|
|
|
var_append confopt " " "--enable-linux-devfs --enable-menu \
|
|
--with-extraincdir=/usr/include/libpng \
|
|
--enable-fbdev --enable-largefiles --enable-shared-pp"
|
|
|
|
if [ $arch = x86 ] ; then
|
|
var_append confopt " " "--with-win32libdir=$root/$prefix/lib/win32"
|
|
fi
|
|
|
|
if test "$ROCKCFG_PKG_MPLAYER_RUN_CPUDETECT" != 0 ; then
|
|
var_append confopt " " "--enable-runtime-cpudetection"
|
|
fi
|
|
|
|
if test "$ROCKCFG_PKG_MPLAYER_BLINKENLIGHTS" != 0 ; then
|
|
var_append confopt " " "--enable-bl"
|
|
fi
|
|
|
|
pkginstalled rtsp && var_append confopt " " "--enable-live"
|
|
pkginstalled xmms && var_append confopt " " "--enable-xmms"
|
|
pkginstalled gtk+12 && var_append confopt " " "--enable-gui"
|
|
test "$ROCKCFG_DISABLE_NLS" = 0 || var_append confopt " " "--disable-i18n"
|
|
|
|
hook_add premake 3 mplayer_premake
|
|
hook_add postmake 5 mplayer_postmake
|
|
|