--- /usr/portage/media-video/ffmpeg/ffmpeg-9999.ebuild 2011-03-21 15:01:18.000000000 +0300 +++ ffmpeg-9999.ebuild 2011-03-22 10:15:49.000000000 +0300 @@ -28,7 +28,7 @@ if [ "${PV#9999}" = "${PV}" ] ; then KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" fi -IUSE="+3dnow +3dnowext alsa altivec amr bindist +bzip2 cpudetection custom-cflags debug dirac doc +encode faac frei0r gsm +hardcoded-tables ieee1394 jack jpeg2k +mmx +mmxext mp3 network oss pic qt-faststart rtmp schroedinger sdl speex +ssse3 static-libs test theora threads v4l v4l2 vaapi vdpau vorbis vpx X x264 xvid +zlib" +IUSE="+3dnow +3dnowext alsa altivec amr bindist +bzip2 cpudetection custom-cflags debug dirac doc +encode faac ffmpeg-mt frei0r gsm +hardcoded-tables ieee1394 jack jpeg2k +mmx +mmxext mp3 network oss pic qt-faststart rtmp schroedinger sdl speex +ssse3 static-libs test theora threads v4l v4l2 vaapi vdpau vorbis vpx X x264 xvid +zlib" VIDEO_CARDS="nvidia" @@ -78,9 +78,31 @@ v4l2? ( sys-kernel/linux-headers ) " +src_unpack() { + if [ "${PV#9999}" != "${PV}" ] ; then + if use ffmpeg-mt; then + EGIT_REPO_URI="git://gitorious.org/ffmpeg/ffmpeg-mt" + EGIT_PROJECT="ffmpeg-mt" + fi + git_src_unpack + + S="${WORKDIR}/${P}" + + cd "${WORKDIR}" + else + unpack ${A} + fi +} + src_prepare() { - if [ "${PV%_p*}" != "${PV}" ] ; then # Snapshot - sed -i -e "s/UNKNOWN/SVN-r${FFMPEG_REVISION}/" "${S}/version.sh" || die + # Snapshot + if [ "${PV%_p*}" != "${PV}" ] ; then + sed -e "s/UNKNOWN/git-r${FFMPEG_REVISION}/" \ + -i version.sh || die + fi + + if [ "${PV#9999}" = "${PV}" ] && use ffmpeg-mt ; then + epatch "${DISTDIR}/${P}-ffmpeg-mt.patch" fi }