03ff509386391536ac619bf0d988ea0e61d63475
[archive/platform/core/multimedia/libmm-scmirroring-common.git] / configure.ac
1 #                                               -*- Autoconf -*-
2 # Process this file with autoconf to produce a configure script.
3
4 AC_PREREQ(2.61)
5 AC_INIT([libmm-scmirroring-common],[0.0.1])
6 AC_CONFIG_HEADER([config.h])
7 AM_INIT_AUTOMAKE([-Wall -Werror foreign])
8
9 # Checks for programs.
10 +m4_pattern_allow([AM_PROG_AR])
11 AM_PROG_AR
12 AC_PROG_CC
13 AC_PROG_LIBTOOL
14
15 AC_FUNC_MMAP
16 AC_FUNC_REALLOC
17 AC_FUNC_SELECT_ARGTYPES
18 AC_FUNC_STAT
19 AC_HEADER_STDBOOL
20 AC_HEADER_STDC
21 AC_HEADER_TIME
22 AC_PROG_GCC_TRADITIONAL
23
24 PKG_CHECK_MODULES(MMCOMMON,mm-common)
25 AC_SUBST(MMCOMMON_CFLAGS)
26 AC_SUBST(MMCOMMON_LIBS)
27
28 PKG_CHECK_MODULES(GLIB, glib-2.0)
29 AC_SUBST(GLIB_CFLAGS)
30 AC_SUBST(GLIB_LIBS)
31
32 # for testsuite
33
34 AC_ARG_ENABLE(context-manager, AC_HELP_STRING([--enable-context-manager], [context manager]),
35 [
36  case "${enableval}" in
37          yes) ENABLE_CONTEXT_MANAGER=yes ;;
38          no)  ENABLE_CONTEXT_MANAGER=no ;;
39          *)   AC_MSG_ERROR(bad value ${enableval} for --enable-context-manager) ;;
40  esac
41  ],
42  [ENABLE_CONTEXT_MANAGER=no])
43 AM_CONDITIONAL(ENABLE_CONTEXT_MANAGER, test "x$ENABLE_CONTEXT_MANAGER" = "xyes")
44
45 if [test "x$ENABLE_CONTEXT_MANAGER" = "xyes"]
46 then
47 PKG_CHECK_MODULES(CONTEXT_MANAGER, capi-context-manager)
48 AC_SUBST(CONTEXT_MANAGER_CFLAGS)
49 AC_SUBST(CONTEXT_MANAGER_LIBS)
50 fi
51
52 AC_CONFIG_FILES([Makefile
53          mm-scmirroring-common.pc
54          wfdconfig/Makefile
55 ])
56 AC_OUTPUT