[GRASS-user] Compile grass6_devel with ffmpeg support?

Glynn Clements glynn at gclements.plus.com
Sun Nov 23 13:46:38 EST 2008


Nikos Alexandris wrote:

> > > Has anybody compiled recently grass6_devel (aka grass-6.4.svn) with
> > > ffmpeg support?
> > > 
> > > It does not work for me. Always complaining about missing "ffmpeg
> > > includes" but I am sure they exist on my system
> > > (under /usr/include/ffmpeg).
> > 
> > Look at the error messages in config.log.
> > 
> > Note that an error reporting a "missing" header means that it failed
> > to compile (more precisely, preprocess) a test program which
> > "#include"s that header. This can be caused by factors other than the
> > header actually being absent.
> > 
> > It works for me in 7.0 (with ffmpeg-0.4.9_p20070616-r3) and there are
> > no differences in the FFMPEG configure checks between 6.4 and 7.0.
> > 
> > However, the FFMPEG API is quite unstable, and we only attempt to
> > support the most common version (more precisely, the checks get
> > changed when the existing checks no longer work for at least one GRASS
> > developer who understands how to fix configure.in).
> 
> # after another failure
> # the bottom lines from config.log
> [...]
> configure:10745: checking whether to use FFMPEG
> configure:10765: checking for location of FFMPEG includes
> configure:10791: checking for avcodec.h
> configure:10799: gcc -E  -I/usr/include/ffmpeg/  conftest.c >/dev/null
> 2>conftest.out
> configure:10835: checking for avformat.h
> configure:10843: gcc -E  -I/usr/include/ffmpeg/  conftest.c >/dev/null
> 2>conftest.out
> configure:10839:22: error: avformat.h: No such file or directory
> configure: failed program was:
> #line 10838 "configure"
> #include "confdefs.h"
> #include <avformat.h>
> 
> So, there is one specific format which causes trouble. Right?

No. FFMPEG is split into several libraries, each with its own header
file(s). The actual libraries are named avcodec (audio and video
codecs: XviD, h.264, MP3, etc), avformat (file formats: AVI, MKV, MP4,
etc), and avutil (utility functions).

Depending upon how your distribution packages FFMPEG, you might have
to install multiple packages. Or it's possible that the headers are in
separate subdirectories, in which case you would need to specify
multiple directories with the --with-ffmpeg-includes= option.

-- 
Glynn Clements <glynn at gclements.plus.com>


More information about the grass-user mailing list