3 AC_INIT(Location, 0.1, [sena06.kim@samsung.com])
4 AC_CONFIG_AUX_DIR([build-aux])
5 AC_CONFIG_MACRO_DIR([m4])
6 AC_CONFIG_HEADER([config.h])
7 AC_CONFIG_SRCDIR([location])
8 AM_INIT_AUTOMAKE([1.10.2 foreign -Wall -Werror subdir-objects])
10 # Check programs for making executable
11 m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
16 # Check programs for making libraries.
18 AC_PATH_PROG(GLIB_GENMARSHAL, glib-genmarshal)
20 # Add default build options to CFLAGS, LDFLAGS
21 if test "x$GCC" = "xyes"; then
22 CFLAGS="$CFLAGS -Wall" # -Werror
23 LDFLAGS="$LDFLAGS -Wl,-z,defs -Wl,--as-needed -Wl,--hash-style=both"
26 # Add -g option to CFLAGS
27 AC_ARG_ENABLE([debug],
28 [AC_HELP_STRING([--enable-debug],[turn on debugging [default=no]])],
29 [case "${enableval}" in
30 yes) enable_dbg=yes ;;
32 *) AC_MSG_ERROR([Bad value ${enableval} for --enable-debug]) ;;
33 esac],[enable_dbg=no])
34 if ([test "x$enable_dbg" = xyes]); then
38 # Check GCC EFL visibility
39 AC_MSG_CHECKING(for ELF visibility)
42 __attribute__((visibility("default")))
46 AC_DEFINE([EXPORT_API], [__attribute__((visibility("default")))], [Symbol visibility prefix])
47 CFLAGS="$CFLAGS -fvisibility=hidden"],
49 AC_DEFINE([EXPORT_API], [], [Symbol visibility prefix]) ]
51 AC_MSG_RESULT($has_visibility)
54 PKG_CHECK_MODULES(LOCATION, [glib-2.0 gobject-2.0 dbus-glib-1 gmodule-2.0 vconf vconf-internal-keys])
55 AC_SUBST(LOCATION_LIBS)
56 AC_SUBST(LOCATION_CFLAGS)
58 #PKG_CHECK_MODULES(TEST, [glib-2.0 gconf-2.0 json-glib-1.0])
60 #AC_SUBST(TEST_CFLAGS)
62 # Check dlog libraries
64 [AC_HELP_STRING([--enable-dlog],[show dlog message [default=no]])],
65 [case "${enableval}" in
66 yes) enable_dlog=yes ;;
68 *) AC_MSG_ERROR([Bad value ${enableval} for --enable-dlog]) ;;
69 esac],[enable_dlog=no])
70 if ([test "x$enable_dlog" = xyes]); then
71 PKG_CHECK_MODULES(DLOG, [dlog], have_dlog="yes", have_dlog="no")
74 if test "x$have_dlog" = "xyes"; then
75 LOCATION_CFLAGS="$LOCATION_CFLAGS -DLOCATION_DLOG_DEBUG $DLOG_CFLAGS"
76 LOCATION_LIBS="$LOCATION_LIBS $DLOG_LIBS"
79 LOCATION_CFLAGS="$LOCATION_CFLAGS -DLIBPATH=\\\"$libdir\\\""
85 location/manager/Makefile
86 location/map-service/Makefile
87 location/module/Makefile