1 DESCRIPTION = "Open Source multimedia player."
4 HOMEPAGE = "http://www.mplayerhq.hu/"
5 DEPENDS = "virtual/libsdl xsp libmad zlib libpng jpeg liba52 freetype fontconfig alsa-lib lzo ncurses lame libxv virtual/libx11"
6 DEPENDS_append_c7x0 = " libw100 "
7 DEPENDS_append_hx4700 = " libw100 "
9 DEFAULT_PREFERENCE_avr32 = "1"
11 RDEPENDS = "mplayer-common"
13 SRC_URI = "http://www1.mplayerhq.hu/MPlayer/releases/MPlayer-1.0rc2.tar.bz2 \
15 file://vo_w100_api.h \
19 file://simple_idct_armv5te.S \
20 file://Makefile-codec-cfg.patch;patch=1 \
21 file://w100-configure-svn.patch;patch=1 \
22 file://w100-video_out.patch;patch=1 \
23 file://w100-mplayer.patch;patch= \
24 file://pld-onlyarm5.patch;patch=1 \
25 file://makefile-nostrip-rc2.patch;patch=1 \
26 file://mplayer-imageon-svn.patch;patch=1 \
27 file://imageon-video_out.patch;patch=1 \
28 file://pxa_configure.patch;patch=1 \
29 file://pxa-video_out.patch;patch=1 \
30 file://motion-comp-pld.patch;patch=1 "
32 # This is required for the collie machine only as all stacks in that
33 # machine seem to be set to executable by the toolchain. If someone
34 # discovers this is more general than please make this more general
35 # ie. for all armv4 machines.
36 SRC_URI_append_collie = "file://disable-executable-stack-test.patch;patch=1"
38 PACKAGE_ARCH_collie = "collie"
39 PACKAGE_ARCH_c7x0 = "c7x0"
40 PACKAGE_ARCH_hx4700 = "hx4700"
42 RCONFLICTS_${PN} = "mplayer-atty"
43 RREPLACES_${PN} = "mplayer-atty"
49 S = "${WORKDIR}/MPlayer-1.0rc2"
51 PACKAGES =+ "mencoder"
53 FILES_${PN} = "${bindir}/mplayer ${libdir}"
54 FILES_mencoder = "${bindir}/mencoder"
56 inherit autotools pkgconfig
61 --target=${TARGET_SYS} \
66 --disable-linux-devfs \
71 --disable-xf86keysym \
75 --disable-tv-bsdbt848 \
83 --disable-libdvdcss-internal \
84 --disable-dvdread-internal \
85 --disable-cdparanoia \
93 --disable-macosx-finder-support \
94 --disable-macosx-bundle \
109 --disable-libavutil_so \
110 --disable-libavcodec_so \
111 --disable-libavformat_so \
112 --disable-libpostproc_so \
114 --enable-tremor-low \
172 --disable-win32waveout \
178 EXTRA_OECONF_append_arm = " --disable-decoder=vorbis_decoder \
179 --disable-encoder=vorbis_encoder"
180 EXTRA_OECONF_append_c7x0 = " --enable-imageon "
181 EXTRA_OECONF_append_hx4700 = " --enable-imageon "
183 EXTRA_OECONF_append_armv6 = " --enable-armv6 "
184 EXTRA_OECONF_append_armv7a = "--enable-armv6 "
186 #build with support for the iwmmxt instruction and pxa270fb overlay support (pxa270 and up)
187 #not every iwmmxt machine has the lcd connected to pxafb, but building the module doesn't hurt
188 MY_ARCH := "${PACKAGE_ARCH}"
189 PACKAGE_ARCH = "${@base_contains('MACHINE_FEATURES', 'iwmmxt', 'iwmmxt', '${MY_ARCH}',d)}"
191 MY_TARGET_CC_ARCH := "${TARGET_CC_ARCH}"
192 TARGET_CC_ARCH = "${@base_contains('MACHINE_FEATURES', 'iwmmxt', '-march=iwmmxt -mtune=iwmmxt', '${MY_TARGET_CC_ARCH}',d)}"
194 EXTRA_OECONF_append = " ${@base_contains('MACHINE_FEATURES', 'iwmmxt', '--enable-pxa --enable-iwmmxt', '',d)} "
195 EXTRA_OECONF_append = " ${@base_contains('MACHINE_FEATURES', 'x86', '--enable-runtime-cpudetection', '',d)} "
197 FULL_OPTIMIZATION = "-fexpensive-optimizations -fomit-frame-pointer -frename-registers -O4 -ffast-math"
198 FULL_OPTIMIZATION_armv7a = "-fexpensive-optimizations -ftree-vectorize -fomit-frame-pointer -O4 -ffast-math"
199 BUILD_OPTIMIZATION = "${FULL_OPTIMIZATION}"
203 cp ${WORKDIR}/vo_w100.c ${S}/libvo
204 cp ${WORKDIR}/vo_w100_api.h ${S}/libvo
205 cp ${WORKDIR}/vo_w100_fb.h ${S}/libvo
206 cp ${WORKDIR}/vo_pxa.c ${S}/libvo
207 cp ${WORKDIR}/vo_pxa.h ${S}/libvo
208 cp ${WORKDIR}/simple_idct_armv5te.S ${S}/libavcodec/armv4l/
210 sed -i 's|/usr/include|${STAGING_INCDIR}|g' ${S}/configure
211 sed -i 's|/usr/lib|${STAGING_LIBDIR}|g' ${S}/configure
212 sed -i 's|/usr/\S*include[\w/]*||g' ${S}/configure
213 sed -i 's|/usr/\S*lib[\w/]*||g' ${S}/configure
215 ./configure ${EXTRA_OECONF}