--- configure.in.orig 2010-06-01 10:48:23.000000000 +0400 +++ configure.in 2013-12-01 13:32:23.000000000 +0400 @@ -316,7 +316,7 @@ # else if test "${FFMPEG_DIR}" = "yes"; then # AUTODETECT STATIC/SHARED LIB - AC_MSG_CHECKING(for ffmpeg autodetecting) + AC_MSG_CHECKING(for ffmpeg autodetecting libraries) if test -f /usr/lib64/libavcodec.a -o -f /usr/lib64/libavcodec.so && test -f /usr/lib64/libavformat.a -o -f /usr/lib64/libavformat.so ; then AC_MSG_RESULT(found in /usr/lib64) @@ -347,11 +347,11 @@ echo "" fi else - AC_MSG_CHECKING(for ffmpeg in -> [${FFMPEG_DIR}] <-) - if test -f ${FFMPEG_DIR}/lib/libavcodec.a -o -f ${FFMPEG_DIR}/lib/libavcodec.so && test -f ${FFMPEG_DIR}/lib/libavformat.a -o -f ${FFMPEG_DIR}/lib/libavformat.so ; then + AC_MSG_CHECKING(for ffmpeg libraries in -> [${FFMPEG_DIR}] <-) + if test -f ${FFMPEG_DIR}/lib/ffmpeg0/libavcodec0.a -o -f ${FFMPEG_DIR}/lib/ffmpeg0/libavcodec0.so && test -f ${FFMPEG_DIR}/lib/ffmpeg0/libavformat0.a -o -f ${FFMPEG_DIR}/lib/ffmpeg0/libavformat0.so ; then AC_MSG_RESULT(found) FFMPEG_OK="found" - FFMPEG_LIB="${FFMPEG_DIR}/lib" + FFMPEG_LIB="${FFMPEG_DIR}/lib/ffmpeg0" elif test -f ${FFMPEG_DIR}/libavcodec.a -o -f ${FFMPEG_DIR}/libavcodec.so && test -f ${FFMPEG_DIR}/libavformat.a -o -f ${FFMPEG_DIR}/libavformat.so ; then AC_MSG_RESULT(found) FFMPEG_LIB="${FFMPEG_DIR}" @@ -389,12 +389,12 @@ elif test -f ${FFMPEG_DIR}/include/ffmpeg/avformat.h; then AC_MSG_RESULT(found ${FFMPEG_DIR}/include/ffmpeg/avformat.h) FFMPEG_CFLAGS="-I${FFMPEG_DIR}/include/ffmpeg" - elif test -f ${FFMPEG_DIR}/include/libavformat/avformat.h; then - AC_MSG_RESULT(found ${FFMPEG_DIR}/include/libavformat/avformat.h) - FFMPEG_CFLAGS="-I${FFMPEG_DIR}/include -DFFMPEG_NEW_INCLUDES" - elif test -f ${FFMPEG_DIR}/include/ffmpeg/libavformat/avformat.h; then - AC_MSG_RESULT(found ${FFMPEG_DIR}/include/ffmpeg/libavformat/avformat.h) - FFMPEG_CFLAGS="-I${FFMPEG_DIR}/include/ffmpeg -DFFMPEG_NEW_INCLUDES" +# elif test -f ${FFMPEG_DIR}/include/libavformat/avformat.h; then +# AC_MSG_RESULT(found ${FFMPEG_DIR}/include/libavformat/avformat.h) +# FFMPEG_CFLAGS="-I${FFMPEG_DIR}/include -DFFMPEG_NEW_INCLUDES" + elif test -f ${FFMPEG_DIR}/include/ffmpeg0/libavformat/avformat.h; then + AC_MSG_RESULT(found ${FFMPEG_DIR}/include/ffmpeg0/libavformat/avformat.h) + FFMPEG_CFLAGS="-I${FFMPEG_DIR}/include/ffmpeg0 -DFFMPEG_NEW_INCLUDES" else AC_MSG_RESULT(not found) FFMPEG_OK="no_found" @@ -413,9 +413,9 @@ # if test "${FFMPEG_OK}" = "found"; then - TEMP_LIBS="$TEMP_LIBS -L${FFMPEG_LIB} -lavformat -lavcodec -lavutil -lm -lz" + TEMP_LIBS="$TEMP_LIBS -L${FFMPEG_LIB} -lavformat0 -lavcodec0 -lavutil0 -lm -lz" TEMP_LDFLAGS="${TEMP_LDFLAGS} -L${FFMPEG_LIB}" - TEMP_CFLAGS="${TEMP_CFLAGS} -DHAVE_FFMPEG ${FFMPEG_CFLAGS}" + TEMP_CFLAGS="-DHAVE_FFMPEG ${FFMPEG_CFLAGS} ${TEMP_CFLAGS}" FFMPEG_OBJ="ffmpeg.o" AC_SUBST(FFMPEG_OBJ) @@ -751,7 +751,7 @@ if test "${V4L}" = "no"; then AC_MSG_CHECKING(for V42L support) AC_MSG_RESULT(skipping) -else +elif test "${BKTR}" = "no"; then AC_CHECK_TYPE([struct v4l2_buffer], [SUPPORTED_V4L2=true], [SUPPORTED_V4L2=false], @@ -1067,6 +1067,11 @@ LIBS="${TEMP_LIBS}" LDFLAGS="${TEMP_LDFLAGS}" +AC_CHECK_FUNC(avformat_alloc_context, AC_DEFINE([have_avformat_alloc_context],1,[Define to 1 if you have avformat_alloc_context support])) +AC_CHECK_FUNC(av_avformat_alloc_context, AC_DEFINE([have_av_avformat_alloc_context],1,[Define to 1 if you have av_avformat_alloc_context support])) +AC_CHECK_FUNC(av_register_protocol2, AC_DEFINE([have_av_register_protocol2],1,[Define to 1 if you have av_register_protocol2 support])) +AC_CHECK_FUNC(av_register_protocol, AC_DEFINE([have_av_register_protocol],1,[Define to 1 if you have av_register_protocol support])) + # # Add the right exec path for rc scripts #