diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac index 002d050..b47529b 100644 --- a/configure.ac +++ b/configure.ac @@ -20,6 +20,11 @@ AC_SUBST([AM_CFLAGS]) # Checks for libraries. AC_CHECK_LIB([pthread], [pthread_self]) +AS_VAR_SET([has_ffmpeg], [yes]) +AC_CHECK_LIB([avcodec], [avcodec_version], [AS_VAR_SET([has_avcodec], [yes])], [AS_VAR_SET([has_avcodec], [no])]) +AC_CHECK_LIB([avformat], [avformat_version], [AS_VAR_SET([has_avformat], [yes])], [AS_VAR_SET([has_avformat], [no])]) +AC_CHECK_LIB([avutil], [avutil_version], [AS_VAR_SET([has_avutil], [yes])], [AS_VAR_SET([has_avutil], [no])]) +AC_CHECK_LIB([swscale], [swscale_version], [AS_VAR_SET([has_swscale], [yes])], [AS_VAR_SET([has_swscale], [no])]) # Checks for header files. AC_CHECK_HEADERS([stdlib.h sys/time.h]) @@ -32,13 +37,19 @@ AC_CHECK_FUNCS([gettimeofday]) AC_CHECK_PROG([has_valgrind], [valgrind], [yes], [no]) -AC_ARG_ENABLE([valgrind], AS_HELP_STRING([--disable-valgrind], [Disable the use of valgrind in tests]), [], [enable_valgrind="yes"]) +AC_ARG_ENABLE([examples], AS_HELP_STRING([--disable-examples], [Disable all examples]), [], [enable_examples="yes"]) AC_ARG_ENABLE([tests], AS_HELP_STRING([--disable-tests], [Disable all tests]), [], [enable_tests="yes"]) AC_ARG_ENABLE([itc-test], AS_HELP_STRING([--disable-itc-test], [Disable ITC test]), [], [enable_itc_test="yes"]) AC_ARG_ENABLE([tuberia-test], AS_HELP_STRING([--disable-tuberia-test], [Disable Tuberia test]), [], [enable_tuberia_test="yes"]) +AC_ARG_ENABLE([valgrind], AS_HELP_STRING([--disable-valgrind], [Disable the use of valgrind in tests]), [], [enable_valgrind="yes"]) AS_VAR_IF([has_valgrind], [yes], [], [AS_VAR_SET([enable_valgrind], [no])]) +AS_VAR_IF([has_avcodec], [no], [AS_VAR_SET([enable_examples], [no])], []) +AS_VAR_IF([has_avformat], [no], [AS_VAR_SET([enable_examples], [no])], []) +AS_VAR_IF([has_avutil], [no], [AS_VAR_SET([enable_examples], [no])], []) +AS_VAR_IF([has_swscale], [no], [AS_VAR_SET([enable_examples], [no])], []) +AM_CONDITIONAL([EXAMPLES], [test x$enable_examples = xyes]) AM_CONDITIONAL([TESTS], [test x$enable_tests = xyes]) AM_CONDITIONAL([ITCTEST], [test x$enable_itc_test = xyes]) AM_CONDITIONAL([TUBERIATEST], [test x$enable_tuberia_test = xyes]) @@ -47,16 +58,22 @@ AM_CONDITIONAL([VALGRIND], [test x$enable_valgrind = xyes]) AC_CONFIG_FILES([Makefile src/Makefile test/Makefile + example/Makefile tuberia.pc]) AC_OUTPUT AC_MSG_NOTICE([has valgrind: $has_valgrind]) -AC_MSG_NOTICE([enable valgrind: $enable_valgrind]) +AC_MSG_NOTICE([has avcodec: $has_avcodec]) +AC_MSG_NOTICE([has avformat: $has_avformat]) +AC_MSG_NOTICE([has avutil: $has_avutil]) +AC_MSG_NOTICE([has swscale: $has_swscale]) +AC_MSG_NOTICE([enable examples: $enable_examples]) AC_MSG_NOTICE([enable tests: $enable_tests]) AC_MSG_NOTICE([enable itc tests: $enable_itc_test]) AC_MSG_NOTICE([enable tuberia tests: $enable_tuberia_test]) +AC_MSG_NOTICE([enable valgrind: $enable_valgrind]) AC_MSG_NOTICE([prefix: $prefix]) -AC_MSG_NOTICE([exec_prefix: $execprefix]) +AC_MSG_NOTICE([exec_prefix: $exec_prefix]) AC_MSG_NOTICE([libdir: $libdir]) AC_MSG_NOTICE([includedir: $includedir]) |