nm: Check for libnm
authorLubomir Rintel <lkundrak@v3.sk>
Wed, 21 Oct 2015 08:56:23 +0000 (10:56 +0200)
committerTobias Brunner <tobias@strongswan.org>
Mon, 5 Sep 2016 13:39:43 +0000 (15:39 +0200)
libnm replaces libnm-glib. This will make sense with port to libnm and is done
to reduce line noise in that commit.

src/frontends/gnome/auth-dialog/Makefile.am
src/frontends/gnome/configure.ac
src/frontends/gnome/debian/control
src/frontends/gnome/properties/Makefile.am

index 9c9f7d6..ddfd7ee 100644 (file)
@@ -4,8 +4,7 @@ nm_strongswan_auth_dialog_CPPFLAGS = \
        $(GTK_CFLAGS) \
        $(LIBGNOMEUI_CFLAGS) \
        $(LIBSECRET_CFLAGS) \
-       $(NETWORK_MANAGER_CFLAGS) \
-       $(NM_UTILS_CFLAGS) \
+       $(LIBNM_GLIB_CFLAGS) \
        -DG_DISABLE_DEPRECATED \
        -DGNOME_DISABLE_DEPRECATED \
        -DGNOMELOCALEDIR=\"$(datadir)/locale\" \
@@ -18,4 +17,4 @@ nm_strongswan_auth_dialog_LDADD = \
        $(GTK_LIBS) \
        $(LIBGNOMEUI_LIBS) \
        $(LIBSECRET_LIBS) \
-       $(NM_UTILS_LIBS)
+       $(LIBNM_GLIB_LIBS)
index a2e3bee..41cd560 100644 (file)
@@ -46,10 +46,12 @@ AM_GLIB_GNU_GETTEXT
 PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 2.6)
 PKG_CHECK_MODULES(LIBGNOMEUI, libgnomeui-2.0)
 PKG_CHECK_MODULES(LIBSECRET, libsecret-1)
-PKG_CHECK_EXISTS([libnm-glib],
-       [PKG_CHECK_MODULES(NM_UTILS, NetworkManager >= 0.9.0 libnm-util libnm-glib libnm-glib-vpn)],
-       [PKG_CHECK_MODULES(NM_UTILS, NetworkManager >= 0.9.0 libnm-util libnm_glib libnm_glib_vpn)]
-)
+
+PKG_CHECK_MODULES(LIBNM_GLIB, NetworkManager >= 0.9.0 libnm-util libnm-glib libnm-glib-vpn)
+
+PKG_CHECK_MODULES(LIBNM, libnm >= 1.1.0)
+LIBNM_CFLAGS="$LIBNM_CFLAGS -DNM_VERSION_MIN_REQUIRED=NM_VERSION_1_2"
+LIBNM_CFLAGS="$LIBNM_CFLAGS -DNM_VERSION_MAX_ALLOWED=NM_VERSION_1_2"
 
 AC_ARG_WITH(
        [charon],
index be60bcf..c35bdf6 100644 (file)
@@ -4,6 +4,7 @@ Priority: extra
 Maintainer: Martin Willi <martin@strongswan.org>
 Build-Depends: cdbs,
        debhelper (>= 7),
+       libnm (>= 1.1.0),
        network-manager-dev (>= 0.9),
        libnm-util-dev (>= 0.9),
        libnm-glib-dev (>= 0.9),
index f98ce73..fe62f9e 100644 (file)
@@ -18,21 +18,21 @@ common_CFLAGS = \
        -DGDK_DISABLE_DEPRECATED
 
 libnm_vpn_plugin_strongswan_la_CFLAGS = \
-       $(NM_UTILS_CFLAGS) \
+       $(LIBNM_GLIB_CFLAGS) \
        $(common_CFLAGS)
 
 libnm_strongswan_properties_la_CFLAGS = \
        -DNM_STRONGSWAN_OLD \
-       $(NM_UTILS_CFLAGS) \
+       $(LIBNM_GLIB_CFLAGS) \
        $(common_CFLAGS)
 
 libnm_vpn_plugin_strongswan_la_LIBADD = \
        $(GTK_LIBS) \
-       $(NM_UTILS_LIBS)
+       $(LIBNM_GLIB_LIBS)
 
 libnm_strongswan_properties_la_LIBADD = \
        $(GTK_LIBS) \
-       $(NM_UTILS_LIBS)
+       $(LIBNM_GLIB_LIBS)
 
 libnm_vpn_plugin_strongswan_la_LDFLAGS = \
        -avoid-version