Release 0.80
[framework/connectivity/connman.git] / configure.ac
index 66bee66..fef831c 100644 (file)
@@ -1,7 +1,7 @@
 AC_PREREQ(2.60)
-AC_INIT(connman, 0.67)
+AC_INIT(connman, 0.80)
 
-AM_INIT_AUTOMAKE([foreign subdir-objects])
+AM_INIT_AUTOMAKE([foreign subdir-objects color-tests])
 AM_CONFIG_HEADER(config.h)
 
 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
@@ -104,6 +104,9 @@ AC_ARG_ENABLE(openconnect,
 if (test "${enable_openconnect}" != "no"); then
        if (test -z "${path_openconnect}"); then
                AC_PATH_PROG(OPENCONNECT, [openconnect], [], $PATH:/sbin:/usr/sbin)
+               if (test -z "${OPENCONNECT}"); then
+                       AC_MSG_ERROR(openconnect binary not found)
+               fi
        else
                OPENCONNECT="${path_openconnect}"
                AC_SUBST(OPENCONNECT)
@@ -112,12 +115,6 @@ fi
 AM_CONDITIONAL(OPENCONNECT, test "${enable_openconnect}" != "no")
 AM_CONDITIONAL(OPENCONNECT_BUILTIN, test "${enable_openconnect}" = "builtin")
 
-AC_ARG_ENABLE(portal,
-       AC_HELP_STRING([--enable-portal], [enable portal detection support]),
-                       [enable_portal=${enableval}], [enable_portal="no"])
-AM_CONDITIONAL(PORTAL, test "${enable_portal}" != "no")
-AM_CONDITIONAL(PORTAL_BUILTIN, test "${enable_portal}" = "builtin")
-
 AC_ARG_WITH(openvpn, AC_HELP_STRING([--with-openvpn=PROGRAM],
         [specify location of openvpn binary]), [path_openvpn=${withval}])
 
@@ -127,6 +124,9 @@ AC_ARG_ENABLE(openvpn,
 if (test "${enable_openvpn}" != "no"); then
        if (test -z "${path_openvpn}"); then
                AC_PATH_PROG(OPENVPN, [openvpn], [], $PATH:/sbin:/usr/sbin)
+               if (test -z "${OPENVPN}"); then
+                       AC_MSG_ERROR(openvpn binary not found)
+               fi
        else
                OPENVPN="${path_openvpn}"
                AC_SUBST(OPENVPN)
@@ -144,6 +144,9 @@ AC_ARG_ENABLE(vpnc,
 if (test "${enable_vpnc}" != "no"); then
        if (test -z "${path_vpnc}"); then
                AC_PATH_PROG(VPNC, [vpnc], [], $PATH:/sbin:/usr/sbin)
+               if (test -z "${VPNC}"); then
+                       AC_MSG_ERROR(vpnc binary not found)
+               fi
        else
                VPNC="${path_vpnc}"
                AC_SUBST(VPNC)
@@ -152,6 +155,50 @@ fi
 AM_CONDITIONAL(VPNC, test "${enable_vpnc}" != "no")
 AM_CONDITIONAL(VPNC_BUILTIN, test "${enable_vpnc}" = "builtin")
 
+AC_ARG_ENABLE(l2tp,
+       AC_HELP_STRING([--enable-l2tp], [enable l2tp support]),
+                       [enable_l2tp=${enableval}], [enable_l2tp="no"])
+if (test "${enable_l2tp}" != "no"); then
+       if (test -z "${path_pppd}"); then
+               AC_PATH_PROG(PPPD, [pppd], [/usr/sbin/pppd], $PATH:/sbin:/usr/sbin)
+       else
+               PPPD="${path_pppd}"
+               AC_SUBST(PPPD)
+       fi
+       AC_CHECK_HEADERS(pppd/pppd.h, dummy=yes,
+                       AC_MSG_ERROR(ppp header files are required))
+       if (test -z "${path_l2tp}"); then
+               AC_PATH_PROG(L2TP, [xl2tpd], [/usr/sbin/xl2tpd], $PATH:/sbin:/usr/sbin)
+       else
+               L2TP="${path_l2tp}"
+               AC_SUBST(L2TP)
+       fi
+fi
+AM_CONDITIONAL(L2TP, test "${enable_l2tp}" != "no")
+AM_CONDITIONAL(L2TP_BUILTIN, test "${enable_l2tp}" = "builtin")
+
+AC_ARG_ENABLE(pptp,
+       AC_HELP_STRING([--enable-pptp], [enable pptp support]),
+                       [enable_pptp=${enableval}], [enable_pptp="no"])
+if (test "${enable_pptp}" != "no"); then
+       if (test -z "${path_pppd}"); then
+               AC_PATH_PROG(PPPD, [pppd], [/usr/sbin/pppd], $PATH:/sbin:/usr/sbin)
+       else
+               PPPD="${path_pppd}"
+               AC_SUBST(PPPD)
+       fi
+       AC_CHECK_HEADERS(pppd/pppd.h, dummy=yes,
+                       AC_MSG_ERROR(ppp header files are required))
+       if (test -z "${path_pptp}"); then
+               AC_PATH_PROG(PPTP, [pptp], [/usr/sbin/pptp], $PATH:/sbin:/usr/sbin)
+       else
+               PPTP="${path_pptp}"
+               AC_SUBST(PPTP)
+       fi
+fi
+AM_CONDITIONAL(PPTP, test "${enable_pptp}" != "no")
+AM_CONDITIONAL(PPTP_BUILTIN, test "${enable_pptp}" = "builtin")
+
 AC_ARG_ENABLE(loopback,
        AC_HELP_STRING([--enable-loopback], [enable loopback support]),
                        [enable_loopback=${enableval}], [enable_loopback="no"])
@@ -172,18 +219,6 @@ AC_ARG_ENABLE(pacrunner,
 AM_CONDITIONAL(PACRUNNER, test "${enable_pacrunner}" != "no")
 AM_CONDITIONAL(PACRUNNER_BUILTIN, test "${enable_pacrunner}" = "builtin")
 
-AC_ARG_ENABLE(google,
-       AC_HELP_STRING([--enable-google], [enable Google Public DNS support]),
-                       [enable_google=${enableval}], [enable_google="no"])
-AM_CONDITIONAL(GOOGLE, test "${enable_google}" != "no")
-AM_CONDITIONAL(GOOGLE_BUILTIN, test "${enable_google}" = "builtin")
-
-AC_ARG_ENABLE(meego,
-       AC_HELP_STRING([--enable-meego], [enable MeeGo features support]),
-                       [enable_meego=${enableval}], [enable_meego="no"])
-AM_CONDITIONAL(MEEGO, test "${enable_meego}" != "no")
-AM_CONDITIONAL(MEEGO_BUILTIN, test "${enable_meego}" = "builtin")
-
 AC_CHECK_HEADERS(resolv.h, dummy=yes,
        AC_MSG_ERROR(resolver header files are required))
 AC_CHECK_LIB(resolv, ns_initparse, dummy=yes, [
@@ -191,6 +226,9 @@ AC_CHECK_LIB(resolv, ns_initparse, dummy=yes, [
                AC_MSG_ERROR(resolver library support is required))
 ])
 
+AC_CHECK_FUNC(signalfd, dummy=yes,
+                       AC_MSG_ERROR(signalfd support is required))
+
 AC_CHECK_LIB(dl, dlopen, dummy=yes,
                        AC_MSG_ERROR(dynamic linking loader is required))
 
@@ -256,23 +294,17 @@ AC_ARG_ENABLE(iospm, AC_HELP_STRING([--enable-iospm],
                [enable Intel OSPM support]), [enable_iospm=${enableval}])
 AM_CONDITIONAL(IOSPM, test "${enable_iospm}" = "yes")
 
-AC_ARG_WITH(ntpd, AC_HELP_STRING([--with-ntpd=PROGRAM],
-       [specify ntpd binary location]), [path_ntpd=${withval}])
-
-AC_ARG_ENABLE(ntpd,
-       AC_HELP_STRING([--enable-ntpd], [enable ntpd support]),
-                       [enable_ntpd=${enableval}], [enable_ntpd="no"])
+AC_ARG_ENABLE(nmcompat,
+       AC_HELP_STRING([--enable-nmcompat], [enable nmcompat support]),
+                       [enable_nmcompat=${enableval}], [enable_nmcompat="no"])
+AM_CONDITIONAL(NMCOMPAT, test "${enable_nmcompat}" != "no")
+AM_CONDITIONAL(NMCOMPAT_BUILTIN, test "${enable_nmcompat}" = "builtin")
 
-if (test "${enable_ntpd}" != "no"); then
-       if (test -z "${path_ntpd}"); then
-               AC_PATH_PROG(NTPD, [ntpd], [], $PATH:/sbin:/usr/sbin)
-       else
-               NTPD="${path_ntpd}"
-               AC_SUBST(NTPD)
-       fi
-fi
-AM_CONDITIONAL(NTPD, test "${enable_ntpd}" != "no")
-AM_CONDITIONAL(NTPD_BUILTIN, test "${enable_ntpd}" = "builtin")
+AC_ARG_ENABLE(tist,
+       AC_HELP_STRING([--enable-tist], [enable TI Shared Transport support]),
+                       [enable_tist=${enableval}], [enable_tist="no"])
+AM_CONDITIONAL(TIST, test "${enable_tist}" != "no")
+AM_CONDITIONAL(TIST_BUILTIN, test "${enable_tist}" = "builtin")
 
 AC_ARG_WITH(stats-max-file-size, AC_HELP_STRING([--with-stats-max-file-size=SIZE],
                        [Maximal size of a statistics round robin file]),
@@ -298,11 +330,8 @@ if (test "${enable_threads}" = "yes"); then
        GLIB_LIBS="$GLIB_LIBS $GTHREAD_LIBS"
 fi
 
-PKG_CHECK_MODULES(DBUS, dbus-1 >= 1.0, dummy=yes,
-                               AC_MSG_ERROR(D-Bus >= 1.0 is required))
-AC_CHECK_LIB(dbus-1, dbus_watch_get_unix_fd, dummy=yes,
-       AC_DEFINE(NEED_DBUS_WATCH_GET_UNIX_FD, 1,
-               [Define to 1 if you need the dbus_watch_get_unix_fd() function.]))
+PKG_CHECK_MODULES(DBUS, dbus-1 >= 1.4, dummy=yes,
+                               AC_MSG_ERROR(D-Bus >= 1.4 is required))
 AC_SUBST(DBUS_CFLAGS)
 AC_SUBST(DBUS_LIBS)
 
@@ -361,15 +390,13 @@ AM_CONDITIONAL(CLIENT, test "${enable_client}" = "yes")
 AC_ARG_ENABLE(tools, AC_HELP_STRING([--enable-tools],
                [enable testing tools]), [enable_tools=${enableval}])
 if (test "${enable_tools}" = "yes"); then
-       PKG_CHECK_MODULES(NETLINK, libnl-1, dummy=yes,
-                               AC_MSG_ERROR(Netlink library is required))
-       AC_SUBST(NETLINK_CFLAGS)
-       AC_SUBST(NETLINK_LIBS)
-
        PKG_CHECK_MODULES(GNUTLS, gnutls, dummy=yes,
                                AC_MSG_ERROR(GnuTLS library is required))
        AC_SUBST(GNUTLS_CFLAGS)
        AC_SUBST(GNUTLS_LIBS)
+
+       AC_CHECK_HEADERS(linux/if_alg.h, dummy=yes,
+               AC_MSG_ERROR(User-space algorithm header files are required))
 fi
 AM_CONDITIONAL(TOOLS, test "${enable_tools}" = "yes")