lavu: Move preprocessor macros in a separate file

And remove all the circular inclusions of avutil.h while at it.
lavc/ffwavesynth: fix dependency sizeof(AVFrame).
ffprobe: check av_frame_alloc() failure.
lavc/utils: check av_frame_alloc() failure.
lavc/diracdec: check av_frame_alloc() failure.
lavc/libopenjpegenc: check av_frame_alloc() failure.
lavc/mjpegenc: check av_frame_alloc() failure.
lavc/mjpegenc: use proper error codes.
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  lavu: Move preprocessor macros in a separate file

Conflicts:
	libavutil/avutil.h
	libavutil/utils.c
	libavutil/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
compat: provide va_copy for old gcc versions.

Since we have this compat/va_copy.h header already we might just as well make
use of it for more than one compiler.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
configure: check that pthreads is compatible with compiler.

In particular the mutex initialization for example won't actually
compile with e.g. gcc 2.95.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
af_aresample: remove only use of array compound literals with non-const initializers in FFmpeg.

Some older compilers might have particular trouble with them,
and they do not really seem worth it to me.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Merge remote-tracking branch 'cigaes/master'

* cigaes/master:
  lavc/mjpegenc: use proper error codes.
  lavc/mjpegenc: check av_frame_alloc() failure.
  lavc/libopenjpegenc: check av_frame_alloc() failure.
  lavc/diracdec: check av_frame_alloc() failure.
  lavc/utils: check av_frame_alloc() failure.
  ffprobe: check av_frame_alloc() failure.
  lavc/ffwavesynth: fix dependency sizeof(AVFrame).

Merged-by: Michael Niedermayer <michaelni@gmx.at>