X-Git-Url: http://git.maemo.org/git/?p=connman;a=blobdiff_plain;f=configure.ac;h=39dbced2d6ff6154d189d51fe37f45aaebd8c2d2;hp=564f7c0fbd36c62cfb7704c5de4b7b67e58328a2;hb=18a1d464eceb21cfb1956f4991fa6d5ddc7b31c2;hpb=28be89368b487e1d524a1aec78c892e2dbc857ad diff --git a/configure.ac b/configure.ac index 564f7c0..39dbced 100644 --- a/configure.ac +++ b/configure.ac @@ -24,8 +24,6 @@ AC_PROG_LIBTOOL GTK_DOC_CHECK -AC_PATH_PROG([XSLTPROC], [xsltproc]) - AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug], [enable compiling with debugging information]), [ if (test "${enableval}" = "yes" && @@ -46,10 +44,6 @@ AC_ARG_ENABLE(pie, AC_HELP_STRING([--enable-pie], AC_ARG_ENABLE(threads, AC_HELP_STRING([--enable-threads], [enable threading support]), [enable_threads=${enableval}]) -AC_PATH_PROG(UDHCPC, [udhcpc], [], $PATH:/sbin:/usr/sbin) -AC_PATH_PROG(DHCLIENT, [dhclient], [], $PATH:/sbin:/usr/sbin) -AC_PATH_PROG(RESOLVCONF, [resolvconf], [], $PATH:/sbin:/usr/sbin) - AC_ARG_ENABLE(loopback, AC_HELP_STRING([--enable-loopback], [enable loopback support]), [enable_loopback=${enableval}]) AM_CONDITIONAL(LOOPBACK, test "${enable_loopback}" = "yes") @@ -62,14 +56,76 @@ if (test "${enable_wifi}" = "yes"); then fi AM_CONDITIONAL(WIFI, test "${enable_wifi}" = "yes") +AC_ARG_WITH(udhcpc, AC_HELP_STRING([--with-udhcpc=PROGRAM], + [specify location of udhcpc binary]), [path_udhcpc=${withval}]) + +AC_ARG_ENABLE(UDHCP, AC_HELP_STRING([--enable-udhcp], + [enable uDHCP support]), [enable_udhcp=${enableval}]) +if (test "${enable_udhcp}" = "yes"); then + if (test -z "${path_udhcpc}"); then + AC_PATH_PROG(UDHCPC, [udhcpc], [], $PATH:/sbin:/usr/sbin) + else + UDHCPC="${path_udhcpc}" + AC_SUBST(UDHCPC) + fi +fi +AM_CONDITIONAL(UDHCP, test "${enable_udhcp}" = "yes") + +AC_ARG_WITH(dhclient, AC_HELP_STRING([--with-dhclient=PROGRAM], + [specify location of dhclient binary]), [path_dhclient=${withval}]) + +AC_ARG_ENABLE(DHCLIENT, AC_HELP_STRING([--enable-dhclient], + [enable dhclient support]), [enable_dhclient=${enableval}]) +if (test "${enable_dhclient}" = "yes"); then + if (test -z "${path_dhclient}"); then + AC_PATH_PROG(DHCLIENT, [dhclient], [], $PATH:/sbin:/usr/sbin) + else + UDHCPC="${path_dhclient}" + AC_SUBST(DHCLIENT) + fi +fi +AM_CONDITIONAL(DHCLIENT, test "${enable_dhclient}" = "yes") + +AC_ARG_WITH(resolvconf, AC_HELP_STRING([--with-resolvconf=PROGRAM], + [specify location of resolvconf binary]), [path_resolvconf=${withval}]) + +AC_ARG_ENABLE(RESOLVCONF, AC_HELP_STRING([--enable-resolvconf], + [enable resolvconf support]), [enable_resolvconf=${enableval}]) +if (test "${enable_resolvconf}" = "yes"); then + if (test -z "${path_resolvconf}"); then + AC_PATH_PROG(RESOLVCONF, [resolvconf], [], $PATH:/sbin:/usr/sbin) + else + UDHCPC="${path_resolvconf}" + AC_SUBST(RESOLVCONF) + fi +fi +AM_CONDITIONAL(RESOLVCONF, test "${enable_resolvconf}" = "yes") + +AC_ARG_ENABLE(novatel, AC_HELP_STRING([--enable-novatel], + [enable Novatel support]), [enable_novatel=${enableval}]) +AM_CONDITIONAL(NOVATEL, test "${enable_novatel}" = "yes") + +AC_ARG_ENABLE(huawei, AC_HELP_STRING([--enable-huawei], + [enable HUAWEI support]), [enable_huawei=${enableval}]) +AM_CONDITIONAL(HUAWEI, test "${enable_huawei}" = "yes") + AC_ARG_ENABLE(hso, AC_HELP_STRING([--enable-hso], [enable HSO support]), [enable_hso=${enableval}]) AM_CONDITIONAL(HSO, test "${enable_hso}" = "yes") +AC_ARG_WITH(pppd, AC_HELP_STRING([--with-pppd=PROGRAM], + [specify location of pppd binary]), [path_pppd=${withval}]) + AC_ARG_ENABLE(ppp, AC_HELP_STRING([--enable-ppp], [enable PPP support]), [enable_ppp=${enableval}]) -if (test "${enable_ppp}" = "yes"); then - AC_PATH_PROG(PPPD, [pppd], [], $PATH:/sbin:/usr/sbin) +if (test "${enable_ppp}" = "yes" || test "${enable_novatel}" = "yes" || + test "${enable_huawei}" = "yes"); then + if (test -z "${path_pppd}"); then + AC_PATH_PROG(PPPD, [pppd], [], $PATH:/sbin:/usr/sbin) + else + PPPD="${path_pppd}" + AC_SUBST(PPPD) + fi AC_CHECK_HEADERS(pppd/pppd.h, enable_ppp=yes, AC_MSG_ERROR(PPP development files are required)) fi @@ -103,20 +159,17 @@ AC_ARG_ENABLE(udev, AC_HELP_STRING([--enable-udev], [enable udev support]), [enable_udev=${enableval}]) if (test "${enable_udev}" = "yes"); then AC_DEFINE(HAVE_UDEV, 1, [Define if udev support is available]) - AC_CHECK_LIB(udev, udev_monitor_enable_receiving, dummy=yes, - AC_DEFINE(NEED_UDEV_MONITOR_ENABLE_RECEIVING, 1, - [Define to 1 if you need the - udev_monitor_enable_receiving() function.])) - AC_CHECK_LIB(udev, udev_monitor_receive_device, dummy=yes, - AC_DEFINE(NEED_UDEV_MONITOR_RECEIVE_DEVICE, 1, + PKG_CHECK_MODULES(UDEV, libudev >= 129, enable_udev=yes, + AC_MSG_ERROR(udev >= 129 is required)) + AC_CHECK_LIB(udev, udev_enumerate_add_match_property, dummy=yes, + AC_DEFINE(NEED_UDEV_ENUMERATE_ADD_MATCH_PROPERTY, 1, [Define to 1 if you need the - udev_monitor_receive_device() function.])) - AC_CHECK_LIB(udev, udev_device_get_action, dummy=yes, - AC_DEFINE(NEED_UDEV_DEVICE_GET_ACTION, 1, + udev_enumerate_add_match_property() function.])) + AC_CHECK_LIB(udev, udev_device_get_parent_with_subsystem_devtype, dummy=yes, + AC_DEFINE(NEED_UDEV_DEVICE_GET_PARENT_WITH_SUBSYSTEM_DEVTYPE, 1, [Define to 1 if you need the - udev_device_get_action() function.])) - PKG_CHECK_MODULES(UDEV, libudev >= 127, enable_udev=yes, - AC_MSG_ERROR(udev >= 127 is required)) + udev_device_get_parent_with_subsystem_devtype() + function.])) fi AC_SUBST(UDEV_CFLAGS) AC_SUBST(UDEV_LIBS)