[FFmpeg-devel] [PATCH] Fix compilation when only MPEG-1encoder is enabled

Aurelien Jacobs aurel
Thu May 10 15:11:41 CEST 2007

On Thu, 10 May 2007 14:00:26 +0200
Panagiotis Issaris <takis.issaris at uhasselt.be> wrote:

> Hi Aurelien,
> Aurelien Jacobs wrote:
> > On Thu, 10 May 2007 13:34:53 +0200
> > Panagiotis Issaris <takis.issaris at uhasselt.be> wrote:
> > 
> >> Hi,
> >>
> >> The mpegvideo.c file unconditionally refers to code in the wmv2.c file.
> >> As mpegvideo.c is compiled unconditionally, the attached patch removes
> >> these references if wmv2 encoder support is not being compiled.
> >>
> >> When compiling ffmpeg code configured with the following options:
> >> ./configure --disable-encoders --enable-encoder=mpeg1video
> >>
> >> Compilation was currently broken, and fixed with this patch.
> > 
> > I'm currently in the process of fixing this. I might do it a different
> > way. 
> I'm curiously awaiting it :)

So just have a look ;-)

> I could only think of compiling it all in,
> or making sure mpegvideo.c doesn't reference it when it isn't available.
> Unless of course your making bigger changes in mpegvideo.c, making the
> ff_wmv_* code generic and adding it to some commonly compiled code, I
> can't see a quick solution...

Well, in fact it's almost the same solution as you used, just without
the ugly ifdef jungle. But the result is the same.

> > Note that there are much more references to mpeg4/wmv2 which needs
> > to be disabled.
> Weird, the patch worked fine here. For other configurations, such as
> with all decoders disabled there seems to be one other reference to a
> wmv2 decoding related function (line 4080 in mpegvideo.c) which would
> cause problems.

I mean with a different config. Try to only disable msmpeg4* and wmv2.
There are reference to those files also in h263dec.c. Well just have a
look at my commit and you will see.

> > I should be able to fix it today.
> Excellent :-)



More information about the ffmpeg-devel mailing list