[network-manager-applet/lr/team: 1/6] build: enable wwan by default



commit 4dde5edd1dbf5395a68ea6dac23c96b2f5898673
Author: Lubomir Rintel <lkundrak v3 sk>
Date:   Mon Jul 18 11:50:40 2016 +0200

    build: enable wwan by default
    
    If someone doesn't explicitely disable it it's likely needed. Make sure
    it's not disabled in build by accidental ommision of the dependency.

 configure.ac |   26 +++++++-------------------
 1 files changed, 7 insertions(+), 19 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 17d870e..3f0693f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -111,28 +111,16 @@ fi
 AM_CONDITIONAL(HAVE_GBT, test x"$have_gbt" = "xyes")
 
 dnl ModemManager1 with libmm-glib for WWAN support
-AC_ARG_WITH(wwan, AS_HELP_STRING([--with-wwan], [Enable WWAN support]),,[with_wwan=auto])
-if (test "${with_wwan}" != "no"); then
+AC_ARG_WITH(wwan, AS_HELP_STRING([--with-wwan], [Enable WWAN support (default: yes)]))
+if (test "${with_wwan}" == "no"); then
+    AC_DEFINE(WITH_WWAN, 0, [Define if you have ModemManager/WWAN support])
+else
     PKG_CHECK_MODULES(MM_GLIB,
-                      [mm-glib],
-                      [have_libmm_glib=yes],
-                      [have_libmm_glib=no])
-
-    if (test "${have_libmm_glib}" = "no"); then
-        if (test "${with_wwan}" = "yes"); then
-            AC_MSG_ERROR([Couldn't find libmm-glib])
-        fi
-    else
-        with_wwan="yes"
-    fi
-fi
-
-if (test "${with_wwan}" = "yes"); then
+                      [mm-glib],,
+                      AC_MSG_ERROR([libmm-glib is needed for WWAN support. Use --without-wwan to build 
without it.]))
     AC_DEFINE(WITH_WWAN, 1, [Define if you have ModemManager/WWAN support])
-else
-       AC_DEFINE(WITH_WWAN, 0, [Define if you have ModemManager/WWAN support])
 fi
-AM_CONDITIONAL(WITH_WWAN, test "${with_wwan}" = "yes")
+AM_CONDITIONAL(WITH_WWAN, test "${with_wwan}" != "no")
 
 dnl Check for gudev
 PKG_CHECK_MODULES(GUDEV, gudev-1.0 >= 147)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]