wok-current view mplayer/receipt @ rev 25586

Fix linux build with gcc > 6 again
author Stanislas Leduc <shann@slitaz.org>
date Mon May 29 12:23:26 2023 +0000 (17 months ago)
parents f5616184eba2
children
line source
1 # SliTaz package receipt.
3 PACKAGE="mplayer"
4 VERSION="1.4"
5 CATEGORY="multimedia"
6 SHORT_DESC="The Ultimate Movie Player For Linux."
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="GPL2"
9 WEB_SITE="http://www.mplayerhq.hu/design7/news.html"
11 SOURCE="MPlayer"
12 TARBALL="$SOURCE-$VERSION.tar.xz"
13 WGET_URL="http://www1.mplayerhq.hu/MPlayer/releases/$TARBALL"
15 HOST_ARCH="i486 arm"
17 # Dont forget to update all related pkgs
18 RELATED="mplayer-codecs mencoder"
19 DEPENDS="alsa-lib audiofile enca esound ncurses cdparanoia-III ffmpeg gcc83-lib-base
20 giflib gtk+ lame libdvdnav libdvdread libmad libmng libogg libtheora libvorbis
21 lirc x264 xorg-libXdamage xorg-libXss xorg-libXv xorg-libXxf86vm xvidcore zlib"
22 BUILD_DEPENDS="alsa-lib-dev audiofile-dev esound-dev ffmpeg-dev gcc83 giflib-dev
23 gtk+-dev lame-dev libdvdnav-dev libdvdread-dev libmad-dev libogg-dev
24 libtheora-dev libvorbis-dev ncurses-dev pkg-config xorg-libXdamage-dev
25 xorg-libXv-dev xorg-libXxf86vm-dev xorg-xextproto xvidcore-dev yasm zlib-dev"
27 # Handle arch package install. Less deps and no GTK gui for ARM
28 case "$SLITAZ_ARCH" in
29 arm*)
30 DEPENDS="alsa-lib zlib libmad xorg-libXv xorg-libXxf86vm libogg \
31 libvorbis libtheora libsdl xvidcore lame esound gtk+" ;;
32 esac
34 # Handle cross compilation. Host coreutils-file-* are used
35 case "$ARCH" in
36 i?86)
37 ARCH_ARGS="--target=i386-linux --disable-sdl --enable-runtime-cpudetection"
38 BUILD_DEPENDS="$BUILD_DEPENDS cdparanoia-III-dev x264-dev enca-dev \
39 libmng-dev lirc-dev" ;;
40 arm*)
41 export PATH=/cross/arm/tools/arm-slitaz-linux-gnueabi/bin:$PATH
42 BUILD_DEPENDS="$BUILD_DEPENDS libsdl-dev"
43 ARCH_ARGS="--target=arm-linux --enable-cross-compile --enable-sdl" ;;
44 esac
46 # What is the latest version available today?
47 current_version()
48 {
49 wget -O - ${WGET_URL%/*}/ 2>/dev/null | \
50 sed "/latest/d;/$SOURCE-[0-9]/!d;/tar/!d;s|.*$SOURCE-\\(.*\\).tar.*|\\1|" | sort -Vr | sed q
51 }
53 # Rules to configure and make the package.
54 compile_rules()
55 {
56 export CC=gcc-83
57 export CXX=g++-83
58 ./configure \
59 --prefix=/usr \
60 --confdir=/etc/mplayer \
61 --libdir=/usr/lib/mplayer \
62 --enable-gui \
63 --language="en de es fr it ru" \
64 --disable-ffmpeg_a \
65 --disable-gl \
66 --disable-jack \
67 --disable-liblzo \
68 --disable-libdv \
69 --disable-fribidi \
70 --disable-ivtv \
71 --disable-smb \
72 --disable-ftp \
73 --disable-openal \
74 --disable-faac \
75 --disable-speex \
76 ${ARCH_ARGS} &&
77 make $MAKEFLAGS &&
78 make install DESTDIR=$DESTDIR | sed '/install: strip: .*/'d
79 }
81 # Rules to gen a SliTaz package suitable for Tazpkg.
82 genpkg_rules()
83 {
84 mkdir -p $fs/usr/share/mplayer/skins
85 cp -a $install/usr/bin $fs/usr
86 # Mencoder goes in a splitted package.
87 rm $fs/usr/bin/mencoder
88 [ -d "$install/usr/share/mplayer" ] &&
89 cp -a $install/usr/share/mplayer $fs/usr/share
90 cp -a $install/etc $fs
91 cp $src/etc/example.conf $fs/etc/mplayer
92 # Configuration to use Xv by default.
93 cp $stuff/mplayer.conf $fs/etc/mplayer
94 # default skin
95 tar xjf $stuff/productive-1.0.tar.bz2 -C $fs/usr/share/mplayer/skins
96 cd $fs/usr/share/mplayer/skins && ln -s productive default
97 # Font
98 cd .. && ln -s ../fonts/truetype/ttf-dejavu/DejaVuSans.ttf subfont.ttf
99 # Xv support dont work for ARM and gmplayer symlink not created
100 case "$ARCH" in
101 arm*)
102 cp -f $stuff/mplayer-arm.conf $fs/etc/mplayer/mplayer.conf
103 cd $fs/usr/bin && ln -s mplayer gmplayer ;;
104 esac
105 }