diff options
author | Alexandre Rostovtsev <tetromino@gentoo.org> | 2011-11-07 18:27:29 +0000 |
---|---|---|
committer | Alexandre Rostovtsev <tetromino@gentoo.org> | 2011-11-07 18:27:29 +0000 |
commit | e82f1ed2ef5a4c8dc194d071ce19924e11e5e156 (patch) | |
tree | 9b7ff8e07c1c73e25ee9d9e8463989b484bac5ac /net-misc/networkmanager/files | |
parent | Punt ldap until fixed updstream, feature is nice but non-working with system ... (diff) | |
download | gentoo-2-e82f1ed2ef5a4c8dc194d071ce19924e11e5e156.tar.gz gentoo-2-e82f1ed2ef5a4c8dc194d071ce19924e11e5e156.tar.bz2 gentoo-2-e82f1ed2ef5a4c8dc194d071ce19924e11e5e156.zip |
Bump to 0.9.1.95; lots of bugfixes. Also, fix src_install so it doesn't try to chmod things in the live filesystem.
(Portage version: 2.2.0_alpha72/cvs/Linux x86_64)
Diffstat (limited to 'net-misc/networkmanager/files')
4 files changed, 303 insertions, 0 deletions
diff --git a/net-misc/networkmanager/files/networkmanager-0.9.1.95-dns-routing-unmanaged-devices.patch b/net-misc/networkmanager/files/networkmanager-0.9.1.95-dns-routing-unmanaged-devices.patch new file mode 100644 index 000000000000..7b244dfdc45c --- /dev/null +++ b/net-misc/networkmanager/files/networkmanager-0.9.1.95-dns-routing-unmanaged-devices.patch @@ -0,0 +1,69 @@ +From fc0739a5d4e714234e1d544db838e932219c5d4d Mon Sep 17 00:00:00 2001 +From: Mathieu Trudel-Lapierre <mathieu.tl@gmail.com> +Date: Wed, 2 Nov 2011 15:28:43 -0500 +Subject: [PATCH] dns: don't update routing and DNS if no devices were ever + managed (lp:862134) + +Avoids blowing away existing routes and resolv.conf if NM never +managed any devices. +--- + src/dns-manager/nm-dns-manager.c | 21 +++++++++++++-------- + src/nm-policy.c | 9 +++++++++ + 2 files changed, 22 insertions(+), 8 deletions(-) + +diff --git a/src/dns-manager/nm-dns-manager.c b/src/dns-manager/nm-dns-manager.c +index 0203f2b..ddfd47c 100644 +--- a/src/dns-manager/nm-dns-manager.c ++++ b/src/dns-manager/nm-dns-manager.c +@@ -1097,15 +1097,20 @@ dispose (GObject *object) + g_slist_free (priv->plugins); + priv->plugins = NULL; + +- /* If we're quitting leave a valid resolv.conf in place, not one +- * pointing to 127.0.0.1 if any plugins were active. Thus update +- * DNS after disposing of all plugins. ++ /* If last_iface is NULL, this means we haven't done a DNS update before, ++ * so no reason to try and take down entries from resolv.conf. + */ +- if (!update_dns (self, priv->last_iface, TRUE, &error)) { +- nm_log_warn (LOGD_DNS, "could not commit DNS changes on shutdown: (%d) %s", +- error ? error->code : -1, +- error && error->message ? error->message : "(unknown)"); +- g_clear_error (&error); ++ if (priv->last_iface != NULL) { ++ /* If we're quitting leave a valid resolv.conf in place, not one ++ * pointing to 127.0.0.1 if any plugins were active. Thus update ++ * DNS after disposing of all plugins. ++ */ ++ if (!update_dns (self, priv->last_iface, TRUE, &error)) { ++ nm_log_warn (LOGD_DNS, "could not commit DNS changes on shutdown: (%d) %s", ++ error ? error->code : -1, ++ error && error->message ? error->message : "(unknown)"); ++ g_clear_error (&error); ++ } + } + + g_slist_foreach (priv->configs, (GFunc) g_object_unref, NULL); +diff --git a/src/nm-policy.c b/src/nm-policy.c +index cd8245e..669db28 100644 +--- a/src/nm-policy.c ++++ b/src/nm-policy.c +@@ -1042,6 +1042,15 @@ device_state_changed (NMDevice *device, + update_routing_and_dns (policy, FALSE); + break; + case NM_DEVICE_STATE_UNMANAGED: ++ if ( old_state == NM_DEVICE_STATE_UNAVAILABLE ++ || old_state == NM_DEVICE_STATE_DISCONNECTED) { ++ /* If the device was never activated, there's no point in ++ * updating routing or DNS. This allows us to keep the previous ++ * resolv.conf or routes from before NM started if no device was ++ * ever managed by NM. ++ */ ++ break; ++ } + case NM_DEVICE_STATE_UNAVAILABLE: + update_routing_and_dns (policy, FALSE); + break; +-- +1.7.7.2 + diff --git a/net-misc/networkmanager/files/networkmanager-0.9.1.95-force-libnl1.1.patch b/net-misc/networkmanager/files/networkmanager-0.9.1.95-force-libnl1.1.patch new file mode 100644 index 000000000000..8eb66efe9eaf --- /dev/null +++ b/net-misc/networkmanager/files/networkmanager-0.9.1.95-force-libnl1.1.patch @@ -0,0 +1,47 @@ +Build against libnl:1.1 only. Otherwise, networkmanager will link to +libnl-3.so and to libiWmxSdk (from wimax-1.5.2) which links to libnl.so, +and then explode spectacularly at runtime due to symbol collisions. + +diff --git a/configure.ac b/configure.ac +index 75b9978..6761832 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -314,32 +314,13 @@ fi + AC_DEFINE_UNQUOTED(NO_CONSOLEKIT, $no_ck, [Define to disable use of ConsoleKit]) + + have_libnl="no" +-PKG_CHECK_MODULES(LIBNL3, libnl-3.0, [have_libnl3=yes], [have_libnl3=no]) +-PKG_CHECK_MODULES(LIBNL_ROUTE3, libnl-route-3.0, [have_libnl_route3=yes], [have_libnl_route3=no]) +-if (test "${have_libnl3}" = "yes" -a "${have_libnl_route3}" = "yes"); then +- AC_DEFINE(HAVE_LIBNL3, 1, [Define if you require specific libnl-3 support]) +- LIBNL_CFLAGS="$LIBNL3_CFLAGS $LIBNL_ROUTE3_CFLAGS" +- LIBNL_LIBS="$LIBNL3_LIBS $LIBNL_ROUTE3_LIBS" +- libnl_version="3" ++PKG_CHECK_MODULES(LIBNL1, libnl-1 >= 1.0-pre8, [have_libnl1=yes], [have_libnl1=no]) ++if (test "${have_libnl1}" = "yes"); then ++ AC_DEFINE(HAVE_LIBNL1, 1, [Define if you require libnl-1 legacy support]) ++ LIBNL_CFLAGS="$LIBNL1_CFLAGS" ++ LIBNL_LIBS="$LIBNL1_LIBS" ++ libnl_version="1" + have_libnl="yes" +-else +- PKG_CHECK_MODULES(LIBNL2, libnl-2.0, [have_libnl2=yes], [have_libnl2=no]) +- if (test "${have_libnl2}" = "yes"); then +- AC_DEFINE(HAVE_LIBNL2, 1, [Define if you require specific libnl-2 support]) +- LIBNL_CFLAGS="$LIBNL2_CFLAGS" +- LIBNL_LIBS="$LIBNL2_LIBS" +- libnl_version="2" +- have_libnl="yes" +- else +- PKG_CHECK_MODULES(LIBNL1, libnl-1 >= 1.0-pre8, [have_libnl1=yes], [have_libnl1=no]) +- if (test "${have_libnl1}" = "yes"); then +- AC_DEFINE(HAVE_LIBNL1, 1, [Define if you require libnl-1 legacy support]) +- LIBNL_CFLAGS="$LIBNL1_CFLAGS" +- LIBNL_LIBS="$LIBNL1_LIBS" +- libnl_version="1" +- have_libnl="yes" +- fi +- fi + fi + + if (test "${have_libnl}" = "no"); then diff --git a/net-misc/networkmanager/files/networkmanager-0.9.1.95-glib-2.31.patch b/net-misc/networkmanager/files/networkmanager-0.9.1.95-glib-2.31.patch new file mode 100644 index 000000000000..be90d5c8e155 --- /dev/null +++ b/net-misc/networkmanager/files/networkmanager-0.9.1.95-glib-2.31.patch @@ -0,0 +1,161 @@ +From 4d1d3b9935fca45ff98e1e705ce74540d234c41b Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Ji=C5=99=C3=AD=20Klime=C5=A1?= <jklimes@redhat.com> +Date: Mon, 31 Oct 2011 11:50:28 +0100 +Subject: [PATCH] core: fix building for GLib thread API changes (GLib >= + 2.31.0) (bgo #662695) + +--- + src/main.c | 9 +++++++++ + src/nm-policy-hostname.c | 45 ++++++++++++++++++++++++++++++++++----------- + 2 files changed, 43 insertions(+), 11 deletions(-) + +diff --git a/src/main.c b/src/main.c +index b7c0fd5..12a0b89 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -563,9 +563,18 @@ main (int argc, char *argv[]) + umask (022); + + g_type_init (); ++ ++/* ++ * Threading is always enabled starting from GLib 2.31.0. ++ * See also http://developer.gnome.org/glib/2.31/glib-Deprecated-Thread-APIs.html. ++ */ ++#if !GLIB_CHECK_VERSION (2,31,0) + if (!g_thread_supported ()) + g_thread_init (NULL); + dbus_g_thread_init (); ++#else ++ dbus_threads_init_default (); ++#endif + + #ifndef HAVE_DBUS_GLIB_DISABLE_LEGACY_PROP_ACCESS + #error HAVE_DBUS_GLIB_DISABLE_LEGACY_PROP_ACCESS not defined +diff --git a/src/nm-policy-hostname.c b/src/nm-policy-hostname.c +index 4fe69c5..f98aa9c 100644 +--- a/src/nm-policy-hostname.c ++++ b/src/nm-policy-hostname.c +@@ -15,7 +15,7 @@ + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + * +- * Copyright (C) 2004 - 2010 Red Hat, Inc. ++ * Copyright (C) 2004 - 2011 Red Hat, Inc. + * Copyright (C) 2007 - 2008 Novell, Inc. + */ + +@@ -36,7 +36,11 @@ + struct HostnameThread { + GThread *thread; + ++#if GLIB_CHECK_VERSION (2,31,0) ++ GMutex lock; ++#else + GMutex *lock; ++#endif + gboolean dead; + int ret; + +@@ -50,6 +54,25 @@ struct HostnameThread { + gpointer user_data; + }; + ++/* ++ * GMutex API has changed: ++ * http://developer.gnome.org/glib/2.31/glib-Threads.html#GMutex ++ * http://developer.gnome.org/glib/2.31/glib-Deprecated-Thread-APIs.html ++*/ ++#if GLIB_CHECK_VERSION (2,31,0) ++#define X_MUTEX_LOCK(mutex) g_mutex_lock (&(mutex)) ++#define X_MUTEX_UNLOCK(mutex) g_mutex_unlock (&(mutex)) ++#define X_MUTEX_INIT(mutex) g_mutex_init (&(mutex)) ++#define X_MUTEX_CLEAR(mutex) g_mutex_clear (&(mutex)) ++#define X_THREAD_CREATE(func,data) g_thread_try_new ("hostname-thread", func, data, NULL); ++#else ++#define X_MUTEX_LOCK(mutex) g_mutex_lock (mutex) ++#define X_MUTEX_UNLOCK(mutex) g_mutex_unlock (mutex) ++#define X_MUTEX_INIT(mutex) mutex = g_mutex_new () ++#define X_MUTEX_CLEAR(mutex) g_mutex_free (mutex) ++#define X_THREAD_CREATE(func,data) g_thread_create (func, data, FALSE, NULL); ++#endif ++ + static gboolean + hostname_thread_run_cb (gpointer user_data) + { +@@ -72,12 +95,12 @@ hostname_thread_worker (gpointer data) + + nm_log_dbg (LOGD_DNS, "(%p) starting address reverse-lookup", ht); + +- g_mutex_lock (ht->lock); ++ X_MUTEX_LOCK (ht->lock); + if (ht->dead) { +- g_mutex_unlock (ht->lock); ++ X_MUTEX_UNLOCK (ht->lock); + return (gpointer) NULL; + } +- g_mutex_unlock (ht->lock); ++ X_MUTEX_UNLOCK (ht->lock); + + ht->ret = getnameinfo (ht->addr, ht->addr_size, ht->hostname, NI_MAXHOST, NULL, 0, NI_NAMEREQD); + if (ht->ret == 0) { +@@ -106,7 +129,7 @@ hostname_thread_free (HostnameThread *ht) + + nm_log_dbg (LOGD_DNS, "(%p) freeing reverse-lookup thread", ht); + +- g_mutex_free (ht->lock); ++ X_MUTEX_CLEAR (ht->lock); + memset (ht, 0, sizeof (HostnameThread)); + g_free (ht); + } +@@ -123,7 +146,7 @@ hostname4_thread_new (guint32 ip4_addr, + ht = g_malloc0 (sizeof (HostnameThread)); + g_assert (ht); + +- ht->lock = g_mutex_new (); ++ X_MUTEX_INIT (ht->lock); + ht->callback = callback; + ht->user_data = user_data; + +@@ -132,7 +155,7 @@ hostname4_thread_new (guint32 ip4_addr, + ht->addr = (struct sockaddr *) &ht->addr4; + ht->addr_size = sizeof (ht->addr4); + +- ht->thread = g_thread_create (hostname_thread_worker, ht, FALSE, NULL); ++ ht->thread = X_THREAD_CREATE (hostname_thread_worker, ht); + if (!ht->thread) { + hostname_thread_free (ht); + return NULL; +@@ -158,7 +181,7 @@ hostname6_thread_new (const struct in6_addr *ip6_addr, + ht = g_malloc0 (sizeof (HostnameThread)); + g_assert (ht); + +- ht->lock = g_mutex_new (); ++ X_MUTEX_INIT (ht->lock); + ht->callback = callback; + ht->user_data = user_data; + +@@ -167,7 +190,7 @@ hostname6_thread_new (const struct in6_addr *ip6_addr, + ht->addr = (struct sockaddr *) &ht->addr6; + ht->addr_size = sizeof (ht->addr6); + +- ht->thread = g_thread_create (hostname_thread_worker, ht, FALSE, NULL); ++ ht->thread = X_THREAD_CREATE (hostname_thread_worker, ht); + if (!ht->thread) { + hostname_thread_free (ht); + return NULL; +@@ -189,9 +212,9 @@ hostname_thread_kill (HostnameThread *ht) + + nm_log_dbg (LOGD_DNS, "(%p) stopping reverse-lookup thread", ht); + +- g_mutex_lock (ht->lock); ++ X_MUTEX_LOCK (ht->lock); + ht->dead = TRUE; +- g_mutex_unlock (ht->lock); ++ X_MUTEX_UNLOCK (ht->lock); + } + + gboolean +-- +1.7.7.2 + diff --git a/net-misc/networkmanager/files/networkmanager-0.9.1.95-keyfile-scheme.patch b/net-misc/networkmanager/files/networkmanager-0.9.1.95-keyfile-scheme.patch new file mode 100644 index 000000000000..2248830a0895 --- /dev/null +++ b/net-misc/networkmanager/files/networkmanager-0.9.1.95-keyfile-scheme.patch @@ -0,0 +1,26 @@ +From 2938243e251dc10b22fecc4fd50c675f9c2ca1c4 Mon Sep 17 00:00:00 2001 +From: Florian Echtler <floe@butterbrot.org> +Date: Tue, 1 Nov 2011 16:32:51 +0100 +Subject: [PATCH] keyfile: call correct scheme function when writing + certificates (bgo #662836) + +--- + src/settings/plugins/keyfile/writer.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/src/settings/plugins/keyfile/writer.c b/src/settings/plugins/keyfile/writer.c +index db43b23..2babe26 100644 +--- a/src/settings/plugins/keyfile/writer.c ++++ b/src/settings/plugins/keyfile/writer.c +@@ -679,7 +679,7 @@ cert_writer (GKeyFile *file, + } + g_return_if_fail (objtype != NULL); + +- scheme = objtypes->scheme_func (NM_SETTING_802_1X (setting)); ++ scheme = objtype->scheme_func (NM_SETTING_802_1X (setting)); + if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) { + path = objtype->path_func (NM_SETTING_802_1X (setting)); + g_assert (path); +-- +1.7.7.2 + |