Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 142854 - gpac-0.4.2 and ffmpeg-0.4.9_p20060530 circular dependency
Summary: gpac-0.4.2 and ffmpeg-0.4.9_p20060530 circular dependency
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Media-video project
URL:
Whiteboard:
Keywords:
: 157081 (view as bug list)
Depends on: 157814
Blocks:
  Show dependency tree
 
Reported: 2006-08-04 22:07 UTC by Leonard Khoo
Modified: 2007-03-16 09:35 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Leonard Khoo 2006-08-04 22:07:57 UTC
I tried to emerge amarok and gpac dumps this error. This is due to ffmpeg being emerge after gpac. As you can see x264 depends on gpac with the "mp4" use flag turned on and ffmpeg depends on x264 with the use flag turned on and in return gpac with ffmpeg depends on ffmpeg. This looks like a cyclic dependency.


[ebuild  N    ] media-video/gpac-0.4.2  USE="aac amr ffmpeg ft jpeg mad ogg opengl oss png sdl ssl theora truetype vorbis xml xvid -debug -javascript -wxwindows" 0 kB
[ebuild  N    ] media-libs/x264-svn-20060612  USE="mp4 threads -debug" 296 kB
[ebuild  N    ] media-video/ffmpeg-0.4.9_p20060530  USE="a52 aac amr dts encode ieee1394 imlib mmx network ogg oss sdl theora threads truetype vorbis x264 xvid zlib -debug -doc -test -v4l" 2,290 kB


ffmpeg_decode.c:570: error: 'FFDec' has no member named 'ctx'
ffmpeg_decode.c:571: error: 'PIX_FMT_YUV420P' undeclared (first use in this function)
ffmpeg_decode.c:572: error: 'FFDec' has no member named 'frame'
ffmpeg_decode.c:573: warning: implicit declaration of function 'avpicture_deinterlace'
ffmpeg_decode.c:573: error: expected expression before ')' token
ffmpeg_decode.c:578: warning: implicit declaration of function 'img_convert'
ffmpeg_decode.c:578: error: expected expression before ')' token
ffmpeg_decode.c: In function 'FFDEC_CanHandleStream':
ffmpeg_decode.c:620: error: 'CODEC_ID_MP2' undeclared (first use in this function)
ffmpeg_decode.c:626: error: 'CODEC_ID_MPEG4' undeclared (first use in this function)
ffmpeg_decode.c:628: error: 'CODEC_ID_H264' undeclared (first use in this function)
ffmpeg_decode.c:638: error: 'CODEC_ID_MPEG2VIDEO' undeclared (first use in this function)
ffmpeg_decode.c:652: warning: comparison between pointer and integer
ffmpeg_decode.c:653: warning: comparison between pointer and integer
ffmpeg_decode.c: In function 'FFDEC_GetCodecName':
ffmpeg_decode.c:661: error: 'FFDec' has no member named 'codec'
ffmpeg_decode.c:662: error: 'FFDec' has no member named 'codec'
ffmpeg_decode.c:662: error: 'FFDec' has no member named 'codec'
ffmpeg_decode.c:662: error: 'FFMPEG_VERSION' undeclared (first use in this function)
ffmpeg_decode.c: In function 'FFDEC_Load':
ffmpeg_decode.c:674: warning: implicit declaration of function 'avcodec_init'
ffmpeg_decode.c:675: warning: implicit declaration of function 'avcodec_register_all'
ffmpeg_decode.c: In function 'FFDEC_Delete':
ffmpeg_decode.c:698: error: 'FFDec' has no member named 'ctx'
ffmpeg_decode.c:698: error: 'FFDec' has no member named 'ctx'
make[2]: *** [ffmpeg_decode.o] Error 1
make[2]: Leaving directory `/var/tmp/portage/gpac-0.4.2/work/gpac/modules/ffmpeg_in'
make[1]: *** [plugs] Error 2
make[1]: Leaving directory `/var/tmp/portage/gpac-0.4.2/work/gpac/modules'
make: *** [mods] Error 2

!!! ERROR: media-video/gpac-0.4.2 failed.
Call stack:
  ebuild.sh, line 1543:   Called dyn_compile
  ebuild.sh, line 938:   Called src_compile
  gpac-0.4.2.ebuild, line 135:   Called die
Comment 1 Evan Tait 2006-08-25 17:02:47 UTC
This is a workaround.  "USE="-ffmpeg" emerge gpac"  Once that's done, emerge ffmpeg as normal, then re-merge gpac with ffmpeg.

(In reply to comment #0)
> I tried to emerge amarok and gpac dumps this error. This is due to ffmpeg being
> emerge after gpac. As you can see x264 depends on gpac with the "mp4" use flag
> turned on and ffmpeg depends on x264 with the use flag turned on and in return
> gpac with ffmpeg depends on ffmpeg. This looks like a cyclic dependency.
> 
> 
> [ebuild  N    ] media-video/gpac-0.4.2  USE="aac amr ffmpeg ft jpeg mad ogg
> opengl oss png sdl ssl theora truetype vorbis xml xvid -debug -javascript
> -wxwindows" 0 kB
> [ebuild  N    ] media-libs/x264-svn-20060612  USE="mp4 threads -debug" 296 kB
> [ebuild  N    ] media-video/ffmpeg-0.4.9_p20060530  USE="a52 aac amr dts encode
> ieee1394 imlib mmx network ogg oss sdl theora threads truetype vorbis x264 xvid
> zlib -debug -doc -test -v4l" 2,290 kB
> 
> 
> ffmpeg_decode.c:570: error: 'FFDec' has no member named 'ctx'
> ffmpeg_decode.c:571: error: 'PIX_FMT_YUV420P' undeclared (first use in this
> function)
> ffmpeg_decode.c:572: error: 'FFDec' has no member named 'frame'
> ffmpeg_decode.c:573: warning: implicit declaration of function
> 'avpicture_deinterlace'
> ffmpeg_decode.c:573: error: expected expression before ')' token
> ffmpeg_decode.c:578: warning: implicit declaration of function 'img_convert'
> ffmpeg_decode.c:578: error: expected expression before ')' token
> ffmpeg_decode.c: In function 'FFDEC_CanHandleStream':
> ffmpeg_decode.c:620: error: 'CODEC_ID_MP2' undeclared (first use in this
> function)
> ffmpeg_decode.c:626: error: 'CODEC_ID_MPEG4' undeclared (first use in this
> function)
> ffmpeg_decode.c:628: error: 'CODEC_ID_H264' undeclared (first use in this
> function)
> ffmpeg_decode.c:638: error: 'CODEC_ID_MPEG2VIDEO' undeclared (first use in this
> function)
> ffmpeg_decode.c:652: warning: comparison between pointer and integer
> ffmpeg_decode.c:653: warning: comparison between pointer and integer
> ffmpeg_decode.c: In function 'FFDEC_GetCodecName':
> ffmpeg_decode.c:661: error: 'FFDec' has no member named 'codec'
> ffmpeg_decode.c:662: error: 'FFDec' has no member named 'codec'
> ffmpeg_decode.c:662: error: 'FFDec' has no member named 'codec'
> ffmpeg_decode.c:662: error: 'FFMPEG_VERSION' undeclared (first use in this
> function)
> ffmpeg_decode.c: In function 'FFDEC_Load':
> ffmpeg_decode.c:674: warning: implicit declaration of function 'avcodec_init'
> ffmpeg_decode.c:675: warning: implicit declaration of function
> 'avcodec_register_all'
> ffmpeg_decode.c: In function 'FFDEC_Delete':
> ffmpeg_decode.c:698: error: 'FFDec' has no member named 'ctx'
> ffmpeg_decode.c:698: error: 'FFDec' has no member named 'ctx'
> make[2]: *** [ffmpeg_decode.o] Error 1
> make[2]: Leaving directory
> `/var/tmp/portage/gpac-0.4.2/work/gpac/modules/ffmpeg_in'
> make[1]: *** [plugs] Error 2
> make[1]: Leaving directory `/var/tmp/portage/gpac-0.4.2/work/gpac/modules'
> make: *** [mods] Error 2
> 
> !!! ERROR: media-video/gpac-0.4.2 failed.
> Call stack:
>   ebuild.sh, line 1543:   Called dyn_compile
>   ebuild.sh, line 938:   Called src_compile
>   gpac-0.4.2.ebuild, line 135:   Called die
> 

Comment 2 Michael Gisbers 2006-08-30 01:35:49 UTC
This workaround works for me.
Comment 3 Rafał Mużyło 2006-09-04 06:24:31 UTC
I'm not sure which package is important so I'll list all:
media-video/gpac-0.4.2
media-video/ffmpeg-0.4.9_p20060816
media-libs/x264-svn-20060810
With this set workaround does not work, to successfully emerge
gpac with USE="ffmpeg" you have to add following line to the ebuild:
sed -i -e 's:FFMPEG_VERSION:"LIBAVCODEC_VERSION":' "${S}/modules/ffmpeg_in/ffmpeg_decode.c"
then it emerges fine as long as ffmpeg is already emerged.
Comment 4 Yangtse Su 2006-09-22 09:09:28 UTC
The same problem with me.
Comment 5 Alexis Ballier gentoo-dev 2006-09-24 07:33:12 UTC
Hi, 

the problem with FFMPEG_VERSION is a different one and is independant of the circular dependency problem, I've submitted a patch for it, see bug #148939


And, unless there is some behaviors of the C preprocessor that I'm not aware of, using "LIBAVCODEC_VERSION" instead of FFMPEG_VERSION will only produce a string containing "LIBAVCODEC_VERSION" instead of a string where the version has been replaced by the correct version number when the source is compiled.
Comment 6 Jakub Moc (RETIRED) gentoo-dev 2006-12-04 05:23:57 UTC
*** Bug 157081 has been marked as a duplicate of this bug. ***
Comment 7 Lee 2006-12-04 05:31:24 UTC
(In reply to comment #3)
> I'm not sure which package is important so I'll list all:
> media-video/gpac-0.4.2
> media-video/ffmpeg-0.4.9_p20060816
> media-libs/x264-svn-20060810
> With this set workaround does not work, to successfully emerge
> gpac with USE="ffmpeg" you have to add following line to the ebuild:
> sed -i -e 's:FFMPEG_VERSION:"LIBAVCODEC_VERSION":'
> "${S}/modules/ffmpeg_in/ffmpeg_decode.c"
> then it emerges fine as long as ffmpeg is already emerged.
> 

I used 
USE="-*" emerge x264-svn
as a workaround for me
Comment 8 Alexis Ballier gentoo-dev 2006-12-07 05:13:51 UTC
x264-svn ebuilds have been splitted in ~arch, media-libs/x264-svn now install only the x264 libraries and media-video/x264-svn-encoder the encoder part that needs gpac. This solves the circular dependencies problem.


Now, we have to wait a little bit and then I'll backport this to the stable x264-svn and we'll get rid of this bug.
Comment 9 Alexis Ballier gentoo-dev 2007-02-13 21:14:26 UTC
x264-svn-20060612[0]:
x264-svn-20061014[0]:
x264-svn-20061014-r1[0]: alpha amd64 ppc ppc64 sparc x86


ffmpeg-0.4.9_p20050226-r3[0]: ~mips
ffmpeg-0.4.9_p20051216[0]: -* arm
ffmpeg-0.4.9_p20060302[0]: ~arm ~ppc-macos
ffmpeg-0.4.9_p20060530[0]: -*
ffmpeg-0.4.9_p20060816[0]: -*
ffmpeg-0.4.9_p20061016[0]: -* alpha amd64 hppa ia64 ppc ppc64 sparc x86
ffmpeg-0.4.9_p20070129[0]: -* ~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd


gpac-0.4.0[0]: (M) ~x86 ~ppc
gpac-0.4.1_pre20060122[0]:
gpac-0.4.1_pre20060122-r1[0]:
gpac-0.4.2[0]:
gpac-0.4.2-r1[0]: ~alpha amd64 ppc ppc64 x86 ~x86-fbsd



this should be fine now, thus closing.