summaryrefslogtreecommitdiff
path: root/recipes/ffmpeg
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/ffmpeg')
-rw-r--r--recipes/ffmpeg/ffmpeg-0.4.9-pre1/Makefile-add-liblame.patch13
-rw-r--r--recipes/ffmpeg/ffmpeg-0.4.9-pre1/Makefile-avformat-use-LDFLAGS.patch13
-rw-r--r--recipes/ffmpeg/ffmpeg-0.4.9-pre1/configure.patch113
-rw-r--r--recipes/ffmpeg/ffmpeg-0.4.9-pre1/gcc4.patch146
-rw-r--r--recipes/ffmpeg/ffmpeg-0.4.9-pre1/install-must-not-strip.patch47
-rw-r--r--recipes/ffmpeg/ffmpeg-0.4.9-pre1/soname.patch84
-rw-r--r--recipes/ffmpeg/ffmpeg.inc113
-rw-r--r--recipes/ffmpeg/ffmpeg_0.4.9-pre1.bb68
-rw-r--r--recipes/ffmpeg/ffmpeg_0.5.bb59
-rw-r--r--recipes/ffmpeg/ffmpeg_git.bb73
-rw-r--r--recipes/ffmpeg/ffmpeg_svn.bb61
-rw-r--r--recipes/ffmpeg/omapfbplay/fbplay-static.diff21
-rw-r--r--recipes/ffmpeg/omapfbplay_git.bb29
13 files changed, 840 insertions, 0 deletions
diff --git a/recipes/ffmpeg/ffmpeg-0.4.9-pre1/Makefile-add-liblame.patch b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/Makefile-add-liblame.patch
new file mode 100644
index 0000000000..3c3969de43
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/Makefile-add-liblame.patch
@@ -0,0 +1,13 @@
+--- /orig-Makefile 2008-07-17 00:29:01.000000000 +0300
++++ /Makefile 2008-07-17 00:29:35.000000000 +0300
+@@ -58,6 +58,10 @@
+ EXTRALIBS+=-lfaac
+ endif
+
++ifeq ($(CONFIG_MP3LAME),yes)
++EXTRALIBS+=-lmp3lame
++endif
++
+ ifeq ($(BUILD_VHOOK),yes)
+ VHOOK=videohook
+ INSTALLVHOOK=install-vhook
diff --git a/recipes/ffmpeg/ffmpeg-0.4.9-pre1/Makefile-avformat-use-LDFLAGS.patch b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/Makefile-avformat-use-LDFLAGS.patch
new file mode 100644
index 0000000000..d78ada9b36
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/Makefile-avformat-use-LDFLAGS.patch
@@ -0,0 +1,13 @@
+Index: ffmpeg-0.4.9-pre1/libavformat/Makefile
+===================================================================
+--- ffmpeg-0.4.9-pre1.orig/libavformat/Makefile 2008-08-30 11:35:09.000000000 +0200
++++ ffmpeg-0.4.9-pre1/libavformat/Makefile 2008-08-30 11:35:34.000000000 +0200
+@@ -94,7 +94,7 @@
+ $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def) -o $@ $(OBJS) $(PPOBJS) $(EXTRALIBS) $(VPATH)/../libavcodec/avcodec.dll
+ -lib /machine:i386 /def:$(@:.dll=.def)
+ else
+- $(CC) $(SHFLAGS) -o $@ $(OBJS) $(PPOBJS) $(EXTRALIBS) -Wl,-soname -Wl,libavformat.so.0
++ $(CC) $(SHFLAGS) -o $@ $(OBJS) $(PPOBJS) $(EXTRALIBS) $(LDFLAGS) -Wl,-soname -Wl,libavformat.so.0
+ endif
+
+ depend: $(SRCS)
diff --git a/recipes/ffmpeg/ffmpeg-0.4.9-pre1/configure.patch b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/configure.patch
new file mode 100644
index 0000000000..10fa0ce6b2
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/configure.patch
@@ -0,0 +1,113 @@
+--- ./configure~configure.patch 2004-07-06 03:36:16.000000000 +0930
++++ ./configure 2004-09-27 00:07:23.000000000 +0930
+@@ -88,7 +88,7 @@
+ mandir=""
+ bindir=""
+ cross_prefix=""
+-cc="gcc"
++cc="$CC"
+ ar="ar"
+ ranlib="ranlib"
+ make="make"
+@@ -104,7 +104,7 @@
+ cpu="x86"
+ ;;
+ # armv4l is a subset of armv5tel
+- armv4l|armv5tel)
++ armv4l|armv5tel|arm|xscale)
+ cpu="armv4l"
+ ;;
+ alpha)
+@@ -434,6 +434,37 @@
+ esac
+ done
+
++case "$cpu" in
++ i386|i486|i586|i686|i86pc|BePC)
++ cpu="x86"
++ ;;
++ # armv4l is a subset of armv5tel
++ armv4l|armv5tel|arm|xscale)
++ cpu="armv4l"
++ ;;
++ alpha)
++ cpu="alpha"
++ ;;
++ "Power Macintosh"|ppc)
++ cpu="powerpc"
++ ;;
++ mips)
++ cpu="mips"
++ ;;
++ sun4u|sparc64)
++ cpu="sparc64"
++ ;;
++ sparc)
++ cpu="sparc"
++ ;;
++ sh4)
++ cpu="sh4"
++ ;;
++ *)
++ cpu="unknown"
++ ;;
++esac
++
+ if test "$gpl" != "yes"; then
+ if test "$pp" != "no" -o "$shared_pp" != "no"; then
+ echo "The Postprocessing code is under GPL and --enable-gpl is not specified"
+@@ -662,7 +693,6 @@
+ bindir="$prefix"
+ fi
+
+-cc="${cross_prefix}${cc}"
+ ar="${cross_prefix}${ar}"
+ ranlib="${cross_prefix}${ranlib}"
+ strip="${cross_prefix}${strip}"
+@@ -753,21 +783,6 @@
+ fi
+
+ if test "$zlib" = "yes"; then
+-# check for zlib - mmu_man
+-cat > $TMPC << EOF
+-#include <zlib.h>
+-int main ( void ) {
+-if (zlibVersion() != ZLIB_VERSION)
+- puts("zlib version differs !!!");
+- return 1;
+-return 0;
+-}
+-EOF
+-$cc $CFLAGS -o $TMPE $TMPC -lz 2> /dev/null || zlib="no"
+-# $TMPE 2> /dev/null > /dev/null || zlib="no"
+-# XXX: more tests needed - runtime test
+-fi
+-if test "$zlib" = "yes"; then
+ extralibs="$extralibs -lz"
+ fi
+
+@@ -881,24 +896,8 @@
+ ##########################################
+ # SDL probe
+
+-cat > $TMPC << EOF
+-#include <SDL.h>
+-#undef main /* We don't want SDL to override our main() */
+-int main( void ) { return SDL_Init (SDL_INIT_VIDEO); }
+-EOF
+-
+ sdl_too_old=no
+-sdl=no
+-if sdl-config --version >/dev/null 2>&1 ; then
+-if $cc -o $TMPE `sdl-config --cflags` $TMPC `sdl-config --libs` > /dev/null 2>&1 ; then
+-_sdlversion=`sdl-config --version | sed 's/[^0-9]//g'`
+-if test "$_sdlversion" -lt 121 ; then
+-sdl_too_old=yes
+-else
+ sdl=yes
+-fi
+-fi
+-fi
+
+ ##########################################
+ # texi2html probe
diff --git a/recipes/ffmpeg/ffmpeg-0.4.9-pre1/gcc4.patch b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/gcc4.patch
new file mode 100644
index 0000000000..e04fdab3e5
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/gcc4.patch
@@ -0,0 +1,146 @@
+--- ffmpeg-0.4.9-pre1/libavcodec/common.h.orig 2008-02-23 19:42:48.000000000 -0500
++++ ffmpeg-0.4.9-pre1/libavcodec/common.h 2008-02-23 19:08:09.000000000 -0500
+@@ -64,11 +64,11 @@
+
+ struct AVOption;
+ #ifdef HAVE_MMX
+-extern const struct AVOption avoptions_common[3 + 5];
++extern const struct AVOption *avoptions_common[2 + 5];
+ #else
+-extern const struct AVOption avoptions_common[3];
++extern const struct AVOption *avoptions_common[2];
+ #endif
+-extern const struct AVOption avoptions_workaround_bug[11];
++extern const struct AVOption *avoptions_workaround_bug[10];
+
+ #endif /* HAVE_AV_CONFIG_H */
+
+@@ -1292,10 +1292,6 @@ tend= rdtsc();\
+ #define time time_is_forbidden_due_to_security_issues
+ #define rand rand_is_forbidden_due_to_state_trashing
+ #define srand srand_is_forbidden_due_to_state_trashing
+-#if !(defined(LIBAVFORMAT_BUILD) || defined(_FRAMEHOOK_H))
+-#define printf please_use_av_log
+-#define fprintf please_use_av_log
+-#endif
+
+ #define CHECKED_ALLOCZ(p, size)\
+ {\
+--- ffmpeg-0.4.9-pre1/libavcodec/ac3tab.h.orig 2008-02-23 19:46:06.000000000 -0500
++++ ffmpeg-0.4.9-pre1/libavcodec/ac3tab.h 2008-02-23 19:08:09.000000000 -0500
+@@ -4,10 +4,10 @@
+ */
+
+ /* possible frequencies */
+-static const uint16_t ac3_freqs[3] = { 48000, 44100, 32000 };
++const uint16_t ac3_freqs[3] = { 48000, 44100, 32000 };
+
+ /* possible bitrates */
+-static const uint16_t ac3_bitratetab[19] = {
++const uint16_t ac3_bitratetab[19] = {
+ 32, 40, 48, 56, 64, 80, 96, 112, 128,
+ 160, 192, 224, 256, 320, 384, 448, 512, 576, 640
+ };
+@@ -15,7 +15,7 @@ static const uint16_t ac3_bitratetab[19]
+ /* AC3 MDCT window */
+
+ /* MDCT window */
+-static const int16_t ac3_window[256] = {
++const int16_t ac3_window[256] = {
+ 4, 7, 12, 16, 21, 28, 34, 42,
+ 51, 61, 72, 84, 97, 111, 127, 145,
+ 164, 184, 207, 231, 257, 285, 315, 347,
+@@ -144,27 +144,27 @@ static const uint8_t baptab[64]= {
+ 15, 15, 15, 15,
+ };
+
+-static const uint8_t sdecaytab[4]={
++const uint8_t sdecaytab[4]={
+ 0x0f, 0x11, 0x13, 0x15,
+ };
+
+-static const uint8_t fdecaytab[4]={
++const uint8_t fdecaytab[4]={
+ 0x3f, 0x53, 0x67, 0x7b,
+ };
+
+-static const uint16_t sgaintab[4]= {
++const uint16_t sgaintab[4]= {
+ 0x540, 0x4d8, 0x478, 0x410,
+ };
+
+-static const uint16_t dbkneetab[4]= {
++const uint16_t dbkneetab[4]= {
+ 0x000, 0x700, 0x900, 0xb00,
+ };
+
+-static const uint16_t floortab[8]= {
++const uint16_t floortab[8]= {
+ 0x2f0, 0x2b0, 0x270, 0x230, 0x1f0, 0x170, 0x0f0, 0xf800,
+ };
+
+-static const uint16_t fgaintab[8]= {
++const uint16_t fgaintab[8]= {
+ 0x080, 0x100, 0x180, 0x200, 0x280, 0x300, 0x380, 0x400,
+ };
+
+--- ffmpeg-0.4.9-pre1/libavcodec/dsputil.h.orig 2008-02-23 19:47:34.000000000 -0500
++++ ffmpeg-0.4.9-pre1/libavcodec/dsputil.h 2008-02-23 19:08:09.000000000 -0500
+@@ -558,15 +558,15 @@ static int name16(void /*MpegEncContext*
+ /* XXX: add ISOC specific test to avoid specific BSD testing. */
+ /* better than nothing implementation. */
+ /* btw, rintf() is existing on fbsd too -- alex */
+-static inline long int lrintf(float x)
+-{
+-#ifdef CONFIG_WIN32
+- /* XXX: incorrect, but make it compile */
+- return (int)(x);
+-#else
+- return (int)(rint(x));
+-#endif
+-}
++//static inline long int lrintf(float x)
++//{
++//#ifdef CONFIG_WIN32
++// /* XXX: incorrect, but make it compile */
++// return (int)(x);
++//#else
++// return (int)(rint(x));
++//#endif
++//}
+ #else
+ #ifndef _ISOC9X_SOURCE
+ #define _ISOC9X_SOURCE
+--- ffmpeg-0.4.9-pre1/libavcodec/opts.c.orig 2008-02-23 19:49:11.000000000 -0500
++++ ffmpeg-0.4.9-pre1/libavcodec/opts.c 2008-02-23 19:08:09.000000000 -0500
+@@ -12,7 +12,7 @@
+
+ #include "avcodec.h"
+
+-const AVOption avoptions_common[] = {
++const AVOption *avoptions_common[] = {
+ AVOPTION_CODEC_FLAG("bit_exact", "use only bit-exact stuff", flags, CODEC_FLAG_BITEXACT, 0),
+ AVOPTION_CODEC_FLAG("mm_force", "force mm flags", dsp_mask, FF_MM_FORCE, 0),
+ #ifdef HAVE_MMX
+@@ -22,10 +22,10 @@ const AVOption avoptions_common[] = {
+ AVOPTION_CODEC_FLAG("mm_sse", "mask SSE feature", dsp_mask, FF_MM_SSE, 0),
+ AVOPTION_CODEC_FLAG("mm_sse2", "mask SSE2 feature", dsp_mask, FF_MM_SSE2, 0),
+ #endif
+- AVOPTION_END()
++// AVOPTION_END()
+ };
+
+-const AVOption avoptions_workaround_bug[] = {
++const AVOption *avoptions_workaround_bug[] = {
+ AVOPTION_CODEC_FLAG("bug_autodetect", "workaround bug autodetection", workaround_bugs, FF_BUG_AUTODETECT, 1),
+ AVOPTION_CODEC_FLAG("bug_old_msmpeg4", "workaround old msmpeg4 bug", workaround_bugs, FF_BUG_OLD_MSMPEG4, 0),
+ AVOPTION_CODEC_FLAG("bug_xvid_ilace", "workaround XviD interlace bug", workaround_bugs, FF_BUG_XVID_ILACE, 0),
+@@ -36,7 +36,7 @@ const AVOption avoptions_workaround_bug[
+ AVOPTION_CODEC_FLAG("bug_std_qpel", "workaround std qpel bug", workaround_bugs, FF_BUG_STD_QPEL, 0),
+ AVOPTION_CODEC_FLAG("bug_qpel_chroma2", "workaround qpel chroma2 bug", workaround_bugs, FF_BUG_QPEL_CHROMA2, 0),
+ AVOPTION_CODEC_FLAG("bug_direct_blocksize", "workaround direct blocksize bug", workaround_bugs, FF_BUG_DIRECT_BLOCKSIZE, 0),
+- AVOPTION_END()
++// AVOPTION_END()
+ };
+
+ /* avoid compatibility problems by redefining it */
diff --git a/recipes/ffmpeg/ffmpeg-0.4.9-pre1/install-must-not-strip.patch b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/install-must-not-strip.patch
new file mode 100644
index 0000000000..6fbeb3eb88
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/install-must-not-strip.patch
@@ -0,0 +1,47 @@
+Index: ffmpeg-0.4.9-pre1/libavcodec/Makefile
+===================================================================
+--- ffmpeg-0.4.9-pre1.orig/libavcodec/Makefile 2008-08-30 11:13:14.000000000 +0200
++++ ffmpeg-0.4.9-pre1/libavcodec/Makefile 2008-08-30 11:13:34.000000000 +0200
+@@ -267,10 +267,10 @@
+ ifeq ($(BUILD_SHARED),yes)
+ install: all install-headers
+ ifeq ($(CONFIG_WIN32),yes)
+- install -s -m 755 $(SLIB) "$(prefix)"
++ install -m 755 $(SLIB) "$(prefix)"
+ else
+ install -d $(prefix)/lib
+- install -s -m 755 $(SLIB) $(prefix)/lib/libavcodec.so.0.4.9
++ install -m 755 $(SLIB) $(prefix)/lib/libavcodec.so.0.4.9
+ ln -sf libavcodec.so.0.4.9 $(prefix)/lib/libavcodec.so.0
+ ln -sf libavcodec.so.0.4.9 $(prefix)/lib/libavcodec.so
+ ldconfig || true
+Index: ffmpeg-0.4.9-pre1/libavcodec/libpostproc/Makefile
+===================================================================
+--- ffmpeg-0.4.9-pre1.orig/libavcodec/libpostproc/Makefile 2008-08-30 11:13:14.000000000 +0200
++++ ffmpeg-0.4.9-pre1/libavcodec/libpostproc/Makefile 2008-08-30 11:13:40.000000000 +0200
+@@ -50,7 +50,7 @@
+ install: all
+ ifeq ($(SHARED_PP),yes)
+ install -d $(prefix)/lib
+- install -s -m 755 $(SPPLIB) $(prefix)/lib/$(SPPLIB).$(SPPVERSION)
++ install -m 755 $(SPPLIB) $(prefix)/lib/$(SPPLIB).$(SPPVERSION)
+ ln -sf $(SPPLIB).$(SPPVERSION) $(prefix)/lib/$(SPPLIB)
+ ldconfig || true
+ mkdir -p $(prefix)/include/postproc
+Index: ffmpeg-0.4.9-pre1/libavformat/Makefile
+===================================================================
+--- ffmpeg-0.4.9-pre1.orig/libavformat/Makefile 2008-08-30 11:13:14.000000000 +0200
++++ ffmpeg-0.4.9-pre1/libavformat/Makefile 2008-08-30 11:13:46.000000000 +0200
+@@ -103,10 +103,10 @@
+ ifeq ($(BUILD_SHARED),yes)
+ install: all install-headers
+ ifeq ($(CONFIG_WIN32),yes)
+- install -s -m 755 $(SLIB) "$(prefix)"
++ install -m 755 $(SLIB) "$(prefix)"
+ else
+ install -d $(prefix)/lib
+- install -s -m 755 $(SLIB) $(prefix)/lib/libavformat.so.0.4.9
++ install -m 755 $(SLIB) $(prefix)/lib/libavformat.so.0.4.9
+ ln -sf libavformat.so.0.4.9 $(prefix)/lib/libavformat.so.0
+ ln -sf libavformat.so.0.4.9 $(prefix)/lib/libavformat.so
+ ldconfig || true
diff --git a/recipes/ffmpeg/ffmpeg-0.4.9-pre1/soname.patch b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/soname.patch
new file mode 100644
index 0000000000..80bf3937e4
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg-0.4.9-pre1/soname.patch
@@ -0,0 +1,84 @@
+--- ffmpeg-0.4.9-pre1/libavcodec/Makefile.orig 2008-02-23 19:34:18.000000000 -0500
++++ ffmpeg-0.4.9-pre1/libavcodec/Makefile 2008-02-23 19:24:55.000000000 -0500
+@@ -7,7 +7,7 @@ include ../config.mak
+ VPATH=$(SRC_PATH)/libavcodec
+
+ # NOTE: -I.. is needed to include config.h
+-CFLAGS=$(OPTFLAGS) -DHAVE_AV_CONFIG_H -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE
++CFLAGS=$(OPTFLAGS) -DHAVE_AV_CONFIG_H -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE -fPIC -DPIC
+
+ OBJS= common.o utils.o mem.o allcodecs.o \
+ mpegvideo.o jrevdct.o jfdctfst.o jfdctint.o\
+@@ -89,9 +89,10 @@ endif
+
+ ifeq ($(CONFIG_PP),yes)
+ ifeq ($(SHARED_PP),yes)
+-EXTRALIBS += -lpostproc
++LIBS += -lpostproc
+ else
+ # LIBS += libpostproc/libpostproc.a ... should be fixed
++LIBS += libpostproc/libpostproc.a
+ OBJS += libpostproc/postprocess.o
+ endif
+ endif
+@@ -197,7 +198,7 @@ ifeq ($(CONFIG_WIN32),yes)
+ $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS)
+ -lib /machine:i386 /def:$(@:.dll=.def)
+ else
+- $(CC) $(SHFLAGS) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS) $(LDFLAGS)
++ $(CC) $(SHFLAGS) -o $@ $(OBJS) $(EXTRALIBS) $(AMREXTRALIBS) $(LDFLAGS) -Wl,-soname -Wl,libavcodec.so.0
+ endif
+
+ dsputil.o: dsputil.c dsputil.h
+@@ -269,8 +270,9 @@ ifeq ($(CONFIG_WIN32),yes)
+ install -s -m 755 $(SLIB) "$(prefix)"
+ else
+ install -d $(prefix)/lib
+- install -s -m 755 $(SLIB) $(prefix)/lib/libavcodec-$(VERSION).so
+- ln -sf libavcodec-$(VERSION).so $(prefix)/lib/libavcodec.so
++ install -s -m 755 $(SLIB) $(prefix)/lib/libavcodec.so.0.4.9
++ ln -sf libavcodec.so.0.4.9 $(prefix)/lib/libavcodec.so.0
++ ln -sf libavcodec.so.0.4.9 $(prefix)/lib/libavcodec.so
+ ldconfig || true
+ endif
+ else
+--- ffmpeg-0.4.9-pre1/libavformat/Makefile.orig 2008-02-23 19:37:40.000000000 -0500
++++ ffmpeg-0.4.9-pre1/libavformat/Makefile 2008-02-23 19:06:56.000000000 -0500
+@@ -6,7 +6,7 @@ include ../config.mak
+
+ VPATH=$(SRC_PATH)/libavformat
+
+-CFLAGS=$(OPTFLAGS) -I.. -I$(SRC_PATH) -I$(SRC_PATH)/libavcodec -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE
++CFLAGS=$(OPTFLAGS) -I.. -I$(SRC_PATH) -I$(SRC_PATH)/libavcodec -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE -fPIC -DPIC
+
+ OBJS= utils.o cutils.o os_support.o allformats.o
+ PPOBJS=
+@@ -54,6 +54,7 @@ endif
+ ifeq ($(CONFIG_AUDIO_BEOS),yes)
+ PPOBJS+= beosaudio.o
+ EXTRALIBS+=-lbe -lmedia
++else
+ # this should be the default !
+ EXTRALIBS+=-lavcodec -L../libavcodec
+ endif
+@@ -93,7 +94,7 @@ ifeq ($(CONFIG_WIN32),yes)
+ $(CC) $(SHFLAGS) -Wl,--output-def,$(@:.dll=.def) -o $@ $(OBJS) $(PPOBJS) $(EXTRALIBS) $(VPATH)/../libavcodec/avcodec.dll
+ -lib /machine:i386 /def:$(@:.dll=.def)
+ else
+- $(CC) $(SHFLAGS) -o $@ $(OBJS) $(PPOBJS) $(EXTRALIBS)
++ $(CC) $(SHFLAGS) -o $@ $(OBJS) $(PPOBJS) $(EXTRALIBS) -Wl,-soname -Wl,libavformat.so.0
+ endif
+
+ depend: $(SRCS)
+@@ -105,8 +106,9 @@ ifeq ($(CONFIG_WIN32),yes)
+ install -s -m 755 $(SLIB) "$(prefix)"
+ else
+ install -d $(prefix)/lib
+- install -s -m 755 $(SLIB) $(prefix)/lib/libavformat-$(VERSION).so
+- ln -sf libavformat-$(VERSION).so $(prefix)/lib/libavformat.so
++ install -s -m 755 $(SLIB) $(prefix)/lib/libavformat.so.0.4.9
++ ln -sf libavformat.so.0.4.9 $(prefix)/lib/libavformat.so.0
++ ln -sf libavformat.so.0.4.9 $(prefix)/lib/libavformat.so
+ ldconfig || true
+ endif
+ else
diff --git a/recipes/ffmpeg/ffmpeg.inc b/recipes/ffmpeg/ffmpeg.inc
new file mode 100644
index 0000000000..33e7d7aaf7
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg.inc
@@ -0,0 +1,113 @@
+DESCRIPTION = "FFmpeg is a complete solution to record, convert and stream audio and video"
+HOMEPAGE = "http://ffmpeg.mplayerhq.hu/"
+AUTHOR = "Fabrice Bellard ffmpeg-devel@mplayerhq.hu"
+SECTION = "libs"
+PRIORITY = "optional"
+LICENSE = "LGPL"
+
+ARM_INSTRUCTION_SET = "arm"
+
+DEPENDS = "zlib libogg libvorbis libtheora faac faad2 ${@base_conditional('ENTERPRISE_DISTRO', '1', '', 'lame liba52', d)}"
+RSUGGESTS = "mplayer"
+
+inherit autotools pkgconfig
+
+LEAD_SONAME = "libavcodec.so"
+
+EXTRA_OECONF = "\
+ \
+ --enable-pp \
+ --enable-shared \
+ --enable-pthreads \
+ --enable-gpl \
+ \
+ --cross-prefix=${TARGET_PREFIX} \
+ --disable-debug \
+ --disable-ffserver \
+ --disable-ffplay \
+ \
+"
+
+do_stage() {
+ for lib in libavcodec libavdevice libavformat \
+ libavutil libpostproc libswscale
+ do
+ oe_libinstall -a -so -C $lib $lib ${STAGING_LIBDIR} || true
+ install -d ${STAGING_INCDIR}/$lib
+ done
+
+ install -d ${STAGING_INCDIR}/ffmpeg
+
+ install -m 0644 ${S}/libavcodec/avcodec.h ${STAGING_INCDIR}/ffmpeg/avcodec.h
+ install -m 0644 ${S}/libavcodec/opt.h ${STAGING_INCDIR}/ffmpeg/opt.h
+ install -m 0644 ${S}/libavcodec/avcodec.h ${STAGING_INCDIR}/libavcodec/avcodec.h
+ install -m 0644 ${S}/libavcodec/opt.h ${STAGING_INCDIR}/libavcodec/opt.h
+
+ install -m 0644 ${S}/libavdevice/avdevice.h ${STAGING_INCDIR}/ffmpeg/avdevice.h
+
+ for h in avformat.h avio.h rtp.h rtsp.h rtspcodes.h
+ do
+ install -m 0644 ${S}/libavformat/$h ${STAGING_INCDIR}/ffmpeg/$h
+ install -m 0644 ${S}/libavformat/$h ${STAGING_INCDIR}/libavformat/$h
+ done
+
+ for h in adler32.h avstring.h avutil.h base64.h bswap.h \
+ common.h crc.h fifo.h integer.h intfloat_readwrite.h \
+ log.h lzo.h mathematics.h md5.h mem.h random.h \
+ rational.h sha1.h
+ do
+ install -m 0644 ${S}/libavutil/$h ${STAGING_INCDIR}/ffmpeg/$h
+ install -m 0644 ${S}/libavutil/$h ${STAGING_INCDIR}/libavutil/$h
+ done
+
+ install -d ${STAGING_INCDIR}/libswscale/
+ install -m 0644 ${S}/libswscale/*.h ${STAGING_INCDIR}/ffmpeg/
+ install -m 0644 ${S}/libswscale/*.h ${STAGING_INCDIR}/libswscale/
+
+ install -d ${STAGING_INCDIR}/libpostproc
+ install -d ${STAGING_INCDIR}/postproc
+ install -m 0644 ${S}/libpostproc/postprocess.h ${STAGING_INCDIR}/libpostproc/postprocess.h
+ install -m 0644 ${S}/libpostproc/postprocess.h ${STAGING_INCDIR}/postproc/postprocess.h
+}
+
+
+PACKAGES += "${PN}-vhook-dbg ${PN}-vhook"
+
+FILES_${PN} = "${bindir}"
+FILES_${PN}-dev = "${includedir}/${PN}"
+
+FILES_${PN}-vhook = "${libdir}/vhook"
+FILES_${PN}-vhook-dbg += "${libdir}/vhook/.debug"
+
+
+PACKAGES += "libavcodec libavcodec-dev libavcodec-dbg \
+ libavdevice libavdevice-dev libavdevice-dbg \
+ libavformat libavformat-dev libavformat-dbg \
+ libavutil libavutil-dev libavutil-dbg \
+ libpostproc libpostproc-dev libpostproc-dbg \
+ libswscale libswscale-dev libswscale-dbg"
+
+FILES_${PN}-dev = "${includedir}"
+FILES_libavcodec = "${libdir}/libavcodec*.so.*"
+FILES_libavcodec-dev = "${libdir}/libavcodec*.so ${libdir}/pkgconfig/libavcodec.pc ${libdir}/libavcodec*.a"
+FILES_libavcodec-dbg += "${libdir}/.debug/libavcodec*"
+
+FILES_libavdevice = "${libdir}/libavdevice*.so.*"
+FILES_libavdevice-dev = "${libdir}/libavdevice*.so ${libdir}/pkgconfig/libavdevice.pc ${libdir}/libavdevice*.a"
+FILES_libavdevice-dbg += "${libdir}/.debug/libavdevice*"
+
+FILES_libavformat = "${libdir}/libavformat*.so.*"
+FILES_libavformat-dev = "${libdir}/libavformat*.so ${libdir}/pkgconfig/libavformat.pc ${libdir}/libavformat*.a"
+FILES_libavformat-dbg += "${libdir}/.debug/libavformat*"
+
+FILES_libavutil = "${libdir}/libavutil*.so.*"
+FILES_libavutil-dev = "${libdir}/libavutil*.so ${libdir}/pkgconfig/libavutil.pc ${libdir}/libavutil*.a"
+FILES_libavutil-dbg += "${libdir}/.debug/libavutil*"
+
+FILES_libpostproc = "${libdir}/libpostproc*.so.*"
+FILES_libpostproc-dev = "${libdir}/libpostproc*.so ${libdir}/pkgconfig/libpostproc.pc ${libdir}/libpostproc*.a ${includedir}/postproc"
+FILES_libpostproc-dbg += "${libdir}/.debug/libpostproc*"
+
+FILES_libswscale = "${libdir}/libswscale*.so.*"
+FILES_libswscale-dev = "${libdir}/libswscale*.so ${libdir}/pkgconfig/libswscale.pc ${libdir}/libswscale*.a"
+FILES_libswscale-dbg += "${libdir}/.debug/libswscale*"
diff --git a/recipes/ffmpeg/ffmpeg_0.4.9-pre1.bb b/recipes/ffmpeg/ffmpeg_0.4.9-pre1.bb
new file mode 100644
index 0000000000..6e347b16f1
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg_0.4.9-pre1.bb
@@ -0,0 +1,68 @@
+require ffmpeg.inc
+
+PR = "r9"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/ffmpeg/ffmpeg-${PV}.tar.gz \
+ file://configure.patch;patch=0 \
+ file://gcc4.patch;patch=1 \
+ file://soname.patch;patch=1 \
+ file://Makefile-avformat-use-LDFLAGS.patch;patch=1 \
+ file://Makefile-add-liblame.patch;patch=1 \
+ file://install-must-not-strip.patch;patch=1 \
+ "
+
+EXTRA_OECONF += " \
+ \
+ --prefix=${D}${prefix} \
+ --mandir=${D}${prefix}/share/man \
+ \
+ --enable-mp3lame \
+ --enable-vorbis \
+ --enable-faad \
+ --enable-faadbin \
+ --enable-faac \
+ --enable-a52 \
+ --enable-a52bin \
+ --enable-shared-pp \
+ --disable-amr_nb \
+ --enable-amr_nb-fixed \
+ --disable-amr_wb \
+ \
+ --cpu=${TARGET_ARCH} \
+ --tune=${PACKAGE_ARCH} \
+ --extra-libs="-la52" \
+ --extra-ldflags="-L${STAGING_LIBDIR}" \
+ \
+ --disable-audio-beos \
+ --disable-v4l \
+ --disable-dv1394 \
+"
+
+EXTRA_OECONF_append_x86 += " \
+ --disable-mmx \
+"
+
+do_stage() {
+ oe_libinstall -a -so -C libavcodec libavcodec ${STAGING_LIBDIR}
+ oe_libinstall -a -so -C libavformat libavformat ${STAGING_LIBDIR}
+
+ install -d ${STAGING_INCDIR}/ffmpeg
+
+ install -m 0644 ${S}/libavcodec/avcodec.h ${STAGING_INCDIR}/ffmpeg/avcodec.h
+ install -m 0644 ${S}/libavcodec/common.h ${STAGING_INCDIR}/ffmpeg/common.h
+ install -m 0644 ${S}/libavcodec/rational.h ${STAGING_INCDIR}/ffmpeg/rational.h
+
+ install -m 0644 ${S}/libavformat/avformat.h ${STAGING_INCDIR}/ffmpeg/avformat.h
+ install -m 0644 ${S}/libavformat/avio.h ${STAGING_INCDIR}/ffmpeg/avio.h
+ install -m 0644 ${S}/libavformat/rtp.h ${STAGING_INCDIR}/ffmpeg/rtp.h
+ install -m 0644 ${S}/libavformat/rtsp.h ${STAGING_INCDIR}/ffmpeg/rtsp.h
+ install -m 0644 ${S}/libavformat/rtspcodes.h ${STAGING_INCDIR}/ffmpeg/rtspcodes.h
+}
+
+PACKAGES += "libavcodec libavcodec-dev \
+ libavformat libavformat-dev"
+
+FILES_libavcodec = "${libdir}/libavcodec*.so.*"
+FILES_libavcodec-dev = "${libdir}/libavcodec*.so"
+FILES_libavformat = "${libdir}/libavformat*.so.*"
+FILES_libavformat-dev = "${libdir}/libavformat*.so"
diff --git a/recipes/ffmpeg/ffmpeg_0.5.bb b/recipes/ffmpeg/ffmpeg_0.5.bb
new file mode 100644
index 0000000000..e49478a215
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg_0.5.bb
@@ -0,0 +1,59 @@
+require ffmpeg.inc
+
+DEPENDS += "schroedinger libgsm"
+
+PE = "1"
+PR = "r0"
+
+DEFAULT_PREFERENCE = "1"
+
+SRCREV_libswscale = "b2e1c8222eeef74b0ca8053b400957dd69e18e4d"
+SRC_URI = "http://ffmpeg.org/releases/ffmpeg-${PV}.tar.bz2"
+
+#S = "${WORKDIR}/git"
+B = "${S}/build.${HOST_SYS}.${TARGET_SYS}"
+
+FULL_OPTIMIZATION_armv7a = "-fexpensive-optimizations -ftree-vectorize -fomit-frame-pointer -O4 -ffast-math"
+BUILD_OPTIMIZATION = "${FULL_OPTIMIZATION}"
+
+EXTRA_FFCONF_armv7a = "--cpu=cortex-a8"
+EXTRA_FFCONF ?= ""
+
+EXTRA_OECONF = " \
+ --enable-shared \
+ --enable-pthreads \
+ --disable-stripping \
+ --enable-gpl \
+ --enable-nonfree \
+ --enable-postproc \
+ \
+ --cross-prefix=${TARGET_PREFIX} \
+ --prefix=${prefix} \
+ \
+ --enable-x11grab \
+ --enable-libfaac \
+ --enable-libfaad \
+ --enable-libfaadbin \
+ --enable-libgsm \
+ --enable-libmp3lame \
+ --enable-libschroedinger \
+ --enable-libtheora \
+ --enable-libvorbis \
+ --enable-swscale \
+ --arch=${TARGET_ARCH} \
+ --enable-cross-compile \
+ --extra-cflags="${TARGET_CFLAGS} ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}" \
+ --extra-ldflags="${TARGET_LDFLAGS}" \
+ --enable-hardcoded-tables \
+ ${EXTRA_FFCONF} \
+"
+
+do_configure() {
+ sed -i -e s:'check_cflags -std=c99'::g ${S}/configure
+ cd ${S}
+ mkdir -p ${B}
+ cd ${B}
+ ${S}/configure ${EXTRA_OECONF}
+ sed -i -e s:Os:O4:g ${B}/config.h
+}
+
diff --git a/recipes/ffmpeg/ffmpeg_git.bb b/recipes/ffmpeg/ffmpeg_git.bb
new file mode 100644
index 0000000000..b2b854aed8
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg_git.bb
@@ -0,0 +1,73 @@
+require ffmpeg.inc
+
+DEPENDS += "schroedinger libgsm"
+
+PE = "1"
+PV = "0.4.9+${PR}+gitr${SRCREV}"
+PR = "r38"
+
+DEFAULT_PREFERENCE = "-1"
+DEFAULT_PREFERENCE_arm = "1"
+DEFAULT_PREFERENCE_avr32 = "1"
+
+FFBRANCH_arm = "arm"
+FFBRANCH ?= "master"
+
+# When bumping SRCREV make sure you bump PR here and in dependant recipes (gst-ffmpeg, gnash, omxil, etc) to account for SOVERSION changes
+SRCREV = "997df8779ce24088d0ebf77aa36f71280785a549"
+SRCREV_arm = "e4f37d7bc8ebd5e63ce57af157c2ebebfdf871fa"
+SRCREV_libswscale = "b2e1c8222eeef74b0ca8053b400957dd69e18e4d"
+SRC_URI = "git://git.mansr.com/ffmpeg.mru;protocol=git;branch=${FFBRANCH} \
+"
+
+S = "${WORKDIR}/git"
+B = "${S}/build.${HOST_SYS}.${TARGET_SYS}"
+
+FULL_OPTIMIZATION_armv7a = "-fexpensive-optimizations -ftree-vectorize -fomit-frame-pointer -O4 -ffast-math"
+BUILD_OPTIMIZATION = "${FULL_OPTIMIZATION}"
+
+EXTRA_FFCONF_armv7a = "--cpu=cortex-a8"
+EXTRA_FFCONF ?= ""
+
+EXTRA_OECONF = " \
+ --enable-shared \
+ --enable-pthreads \
+ --disable-stripping \
+ --enable-gpl \
+ --enable-nonfree \
+ --enable-postproc \
+ \
+ --cross-prefix=${TARGET_PREFIX} \
+ --prefix=${prefix} \
+ \
+ --enable-x11grab \
+ --enable-libfaac \
+ --enable-libfaad \
+ --enable-libfaadbin \
+ --enable-libgsm \
+ --enable-libmp3lame \
+ --enable-libschroedinger \
+ --enable-libtheora \
+ --enable-libvorbis \
+ --enable-swscale \
+ --arch=${TARGET_ARCH} \
+ --enable-cross-compile \
+ --extra-cflags="${TARGET_CFLAGS} ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}" \
+ --extra-ldflags="${TARGET_LDFLAGS}" \
+ --enable-hardcoded-tables \
+ ${EXTRA_FFCONF} \
+"
+
+do_configure() {
+ sed -i -e s:'check_cflags -std=c99'::g ${S}/configure
+ cd ${S}
+ git clone git://git.mplayerhq.hu/libswscale || true
+ cd libswscale
+ git checkout ${SRCREV_libswscale} || true
+ cd ${S}
+ mkdir -p ${B}
+ cd ${B}
+ ${S}/configure ${EXTRA_OECONF}
+ sed -i -e s:Os:O4:g ${B}/config.h
+}
+
diff --git a/recipes/ffmpeg/ffmpeg_svn.bb b/recipes/ffmpeg/ffmpeg_svn.bb
new file mode 100644
index 0000000000..5d8c775e93
--- /dev/null
+++ b/recipes/ffmpeg/ffmpeg_svn.bb
@@ -0,0 +1,61 @@
+require ffmpeg.inc
+
+DEPENDS += "schroedinger libgsm"
+
+SRCREV = "16396"
+
+PE = "1"
+PV = "0.4.9+svnr${SRCREV}"
+PR = "r1"
+
+DEFAULT_PREFERENCE = "-1"
+
+SRC_URI = "svn://svn.ffmpeg.org/ffmpeg/;module=trunk"
+
+S = "${WORKDIR}/trunk"
+
+DEFAULT_PREFERENCE = "-1"
+
+B = "${S}/build.${HOST_SYS}.${TARGET_SYS}"
+
+FULL_OPTIMIZATION_armv7a = "-fexpensive-optimizations -ftree-vectorize -fomit-frame-pointer -O4 -ffast-math"
+BUILD_OPTIMIZATION = "${FULL_OPTIMIZATION}"
+
+EXTRA_FFCONF_armv7a = "--cpu=cortex-a8"
+EXTRA_FFCONF ?= ""
+
+EXTRA_OECONF = " \
+ --enable-shared \
+ --enable-pthreads \
+ --disable-stripping \
+ --enable-gpl \
+ --enable-nonfree \
+ --enable-postproc \
+ \
+ --cross-prefix=${TARGET_PREFIX} \
+ --prefix=${prefix} \
+ \
+ --enable-x11grab \
+ --enable-libfaac \
+ --enable-libfaad \
+ --enable-libfaadbin \
+ --enable-libgsm \
+ --enable-libmp3lame \
+ --enable-libschroedinger \
+ --enable-swscale \
+ --arch=${TARGET_ARCH} \
+ --enable-cross-compile \
+ --extra-cflags="${TARGET_CFLAGS} ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}" \
+ --extra-ldflags="${TARGET_LDFLAGS}" \
+ --enable-hardcoded-tables \
+ ${EXTRA_FFCONF} \
+"
+
+do_configure() {
+ sed -i -e s:'check_cflags -std=c99'::g ${S}/configure
+ mkdir -p ${B}
+ cd ${B}
+ ${S}/configure ${EXTRA_OECONF}
+ sed -i -e s:Os:O4:g ${B}/config.h
+}
+
diff --git a/recipes/ffmpeg/omapfbplay/fbplay-static.diff b/recipes/ffmpeg/omapfbplay/fbplay-static.diff
new file mode 100644
index 0000000000..021194a5a1
--- /dev/null
+++ b/recipes/ffmpeg/omapfbplay/fbplay-static.diff
@@ -0,0 +1,21 @@
+--- /tmp/Makefile 2008-07-21 22:08:58.000000000 +0200
++++ git/Makefile 2008-07-21 22:10:08.023198000 +0200
+@@ -5,6 +5,6 @@
+ CFLAGS = -O3 -Wall -fomit-frame-pointer -mcpu=cortex-a8 -mfpu=neon \
+ -I$(LINUX)/include -I$(FFMPEG)
+ LDFLAGS = -L$(FFMPEG)/libavcodec -L$(FFMPEG)/libavformat -L$(FFMPEG)/libavutil
+-LDLIBS = -lavformat -lavcodec -lavutil -lm -lz -lpthread -lrt
++LDLIBS = -lavformat -lavcodec -lavutil -lz -ldl -lbz2 -lfaac -lgsm -lmp3lame -lm -lpthread -lrt
+
+ all: omapfbplay
+--- /tmp/omapfbplay.c 2008-11-28 10:28:21.000000000 +0100
++++ git/omapfbplay.c 2008-11-28 10:28:47.000000000 +0100
+@@ -37,7 +37,7 @@
+ #include <semaphore.h>
+
+ #include <linux/fb.h>
+-#include <mach/omapfb.h>
++#include "omapfb.h"
+
+ #include <libavformat/avformat.h>
+ #include <libavcodec/avcodec.h>
diff --git a/recipes/ffmpeg/omapfbplay_git.bb b/recipes/ffmpeg/omapfbplay_git.bb
new file mode 100644
index 0000000000..202c29f291
--- /dev/null
+++ b/recipes/ffmpeg/omapfbplay_git.bb
@@ -0,0 +1,29 @@
+DESCRIPTION = "Simple ffmpeg-based player that uses the omapfb overlays"
+DEPENDS = "bzip2 lame ffmpeg virtual/kernel"
+LICENSE = "MIT"
+
+PR = "r15"
+
+PV = "0.0+${PR}+gitr${SRCREV}"
+
+SRCREV = "f4765e699090872679d4fb2799e35fff5ed4c8df"
+SRC_URI = "git://git.mansr.com/${PN};protocol=git \
+ file://fbplay-static.diff;patch=1 "
+
+S = "${WORKDIR}/git"
+
+# We want a kernel header for armv7a, but we don't want to make mplayer machine specific for that
+STAGING_KERNEL_DIR = "${STAGING_DIR}/${MACHINE_ARCH}${TARGET_VENDOR}-${TARGET_OS}/kernel"
+
+CFLAGS += " -I. -I${STAGING_KERNEL_DIR}/include "
+
+do_compile() {
+ cp ${STAGING_KERNEL_DIR}/arch/arm/plat-omap/include/mach/omapfb.h ${S} || true
+ cp ${STAGING_KERNEL_DIR}/include/asm-arm/arch-omap/omapfb.h ${S} || true
+ oe_runmake -e
+}
+
+do_install() {
+ install -d ${D}/${bindir}
+ install -m 0755 ${S}/omapfbplay ${D}/${bindir}/
+}