- if [ "$svn_ffmpeg" != "" ]
- then
- if [ "$gpl" = "true" ]
- then
- enable_gpl="--enable-gpl"
- if [ "$swscale" != "" ]
- then
- enable_swscale="--enable-swscaler"
- echo "SWSCALE=1" >> config.mak
- fi
- elif [ "$swscale" != "" ]
- then
- echo
- echo "ERROR ERROR ERROR ERROR ERROR ERROR"
- echo "--enable-gpl is required to use --avformat-swscale with --avformat-svn!"
- echo
- exit
- fi
- if [ ! -d "ffmpeg" ]
- then
- echo
- echo "Checking out ffmpeg/avformat - no password required"
- echo
- svn checkout svn://svn.mplayerhq.hu/ffmpeg/trunk ffmpeg
- fi
- [ -d "ffmpeg" ] && ( cd ffmpeg ; ./configure $enable_gpl $enable_swscale $svn_ffmpeg_extra )
- #[ ! -f "ffmpeg/ffmpeg.patch" ] && ( cd ffmpeg ; cp ../ffmpeg.patch . ; patch -p0 < ffmpeg.patch )
- echo "CFLAGS+=-I`pwd`/ffmpeg/libavformat -I`pwd`/ffmpeg/libavcodec -I`pwd`/ffmpeg/libavutil -I`pwd`/ffmpeg/libswscale" >> config.mak
- echo "LDFLAGS+=-L`pwd`/ffmpeg/libavformat -L`pwd`/ffmpeg/libavcodec -L`pwd`/ffmpeg/libavutil -L`pwd`/ffmpeg/libswscale" >> config.mak
- [ $targetos = "Darwin" ] &&
- echo "LDFLAGS+=-single_module" >> config.mak
- echo "LOCAL_FFMPEG=1" >> config.mak
- extra_libs="$extra_libs -lz"
- elif [ "$static_ffmpeg" != "" ]