1 2 AC_INIT([testmixvideo], [0.1], [tao.q.tao (a] intel.com]) 3 4 dnl AC_CONFIG_MACRO_DIR([m4]) 5 6 AM_INIT_AUTOMAKE($PACKAGE, $VERSION) 7 AM_INIT_AUTOMAKE([-Wall -Werror foreign]) 8 9 AC_PROG_CC 10 AC_PROG_LIBTOOL 11 12 AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, yes , no) 13 14 dnl Give error and exit if we don't have pkgconfig 15 if test "x$HAVE_PKGCONFIG" = "xno"; then 16 AC_MSG_ERROR(you need to have pkgconfig installed !) 17 fi 18 19 GLIB_REQ=2.18 20 dnl Check for glib2 without extra fat, useful for the unversioned tool frontends 21 dnl PKG_CHECK_MODULES(GLIB_ONLY, glib-2.0 >= $GLIB_REQ,HAVE_GLIB=yes,HAVE_GLIB=no) 22 PKG_CHECK_MODULES(GLIB, glib-2.0 >= $GLIB_REQ,HAVE_GLIB=yes,HAVE_GLIB=no) 23 if test "x$HAVE_GLIB" = "xno"; then 24 AC_MSG_ERROR(You need glib development packages installed !) 25 fi 26 27 PKG_CHECK_MODULES(GOBJECT, gobject-2.0 >= $GLIB_REQ,HAVE_GOBJECT=yes,HAVE_GOBJECT=no) 28 if test "x$HAVE_GOBJECT" = "xno"; then 29 AC_MSG_ERROR(You need glib development packages installed !) 30 fi 31 32 MIXVIDEO_REQ=0.5 33 PKG_CHECK_MODULES(MIXVIDEO, mixvideo >= $MIXVIDEO_REQ,HAVE_MIXVIDEO=yes,HAVE_MIXVIDEO=no) 34 if test "x$HAVE_MIXVIDEO" = "xno"; then 35 AC_MSG_ERROR(You need mixvideo development packages installed !) 36 fi 37 38 AC_ARG_ENABLE(optimization, AC_HELP_STRING([ --disable-optimization], [Do not optimize the library for speed. Might be required for debugging.])) 39 AC_ARG_ENABLE(debuginfo, AC_HELP_STRING([ --enable-debuginfo ], [add -g to the compiler flags (to create debug information)])) 40 41 if test "$enable_optimization" = "no" ; then 42 DEBUG=true 43 else 44 DEBUG=false 45 fi 46 47 48 AC_CONFIG_HEADERS([config.h]) 49 AC_CONFIG_FILES([ 50 Makefile 51 src/Makefile 52 ]) 53 AC_OUTPUT 54