CRUX-ARM : Home

Home :: Documentation :: Download :: Development :: Community :: Ports :: Packages :: Bugs :: Links :: About :: Donors
mplayer: fixed build avoiding thumb instructions.
[ports/opt-arm.git] / mplayer / Pkgfile
1 # Description: Versatile media player and encoder/converter
2 # URL: http://www.mplayerhq.hu/
3 # Packager: Matt Housh, jaeger at morpheus dot net
4 # Maintainer: Thomas Penteker, tek at serverop dot de
5 # Arch Maintainer: CRUX-ARM System Team, devel at crux-arm dot nu
6 # Depends on: expat freetype xorg-libxinerama xorg-libxv xorg-libxxf86dga xorg-libxxf86vm yasm
7 # Nice to have: libsdl libjpeg libpng lame zlib libogg libvorbis cdparanoia win32-essential-codecs faac x264 libdvdnav libdca
8
9 name=mplayer
10 version=export-2011-08-16
11 release=1
12 source=(http://crux.nu/~tek/$name-$version.tar.bz2
13 http://www1.mplayerhq.hu/MPlayer/releases/fonts/font-arial-iso-8859-1.tar.bz2
14 mplayer.conf)
15
16 build() {
17 cd $name-$version
18 # We avoid thumb instructions over CFLAGS
19 export CFLAGS="$(echo $CFLAGS | sed -e 's/\-mthumb//')"
20 # Keep in line with mplayer CFLAGS, but allow people to set their own march/mtune values.
21 export CFLAGS="$(echo $CFLAGS | sed -e 's/-O[s0-3]/-O3/') -ffast-math -fomit-frame-pointer -fno-strict-aliasing"
22
23 rm -f ffmpeg/mp_auto_pull
24
25 ./configure --prefix=/usr \
26 --mandir=/usr/man \
27 --codecsdir=/usr/share/codecs \
28 --confdir=/etc/mplayer
29 make
30 make DESTDIR=$PKG install
31
32 (cd $PKG/usr/man/man1; rm mencoder.1; ln -s mplayer.1.gz mencoder.1.gz)
33
34 # fonts
35 mkdir -p $PKG/usr/share/mplayer
36 cp -a $SRC/font-arial-iso-8859-1/font-arial-??-iso-8859-1 \
37 $PKG/usr/share/mplayer
38 ln -s font-arial-14-iso-8859-1 $PKG/usr/share/mplayer/font
39
40 # config
41 mkdir -p $PKG/etc/mplayer
42 install -m 644 $SRC/mplayer.conf $PKG/etc/mplayer/
43 install -m 644 etc/input.conf $PKG/etc/mplayer/
44
45 # finish up
46 rmdir $PKG/usr/lib
47 find $PKG -name '*.desc' | xargs chmod g-w
48 }