summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMu Qiao <qiaomuf@gentoo.org>2010-11-30 09:35:18 +0000
committerMu Qiao <qiaomuf@gentoo.org>2010-11-30 09:35:18 +0000
commit6a5d439d036ab1463ec1db05b5e1329e37526736 (patch)
treebc2bd02cc12efa8b5dc4707d86f337e416671b07 /net-misc
parentFixing libmemcached minimum version (diff)
downloadhistorical-6a5d439d036ab1463ec1db05b5e1329e37526736.tar.gz
historical-6a5d439d036ab1463ec1db05b5e1329e37526736.tar.bz2
historical-6a5d439d036ab1463ec1db05b5e1329e37526736.zip
Accept "gw" by the plugin. That should fix bug #339215
Package-Manager: portage-2.1.9.25/cvs/Linux x86_64
Diffstat (limited to 'net-misc')
-rw-r--r--net-misc/networkmanager/ChangeLog8
-rw-r--r--net-misc/networkmanager/Manifest19
-rw-r--r--net-misc/networkmanager/files/networkmanager-0.8.2-accept-gw.patch135
-rw-r--r--net-misc/networkmanager/networkmanager-0.8.2-r1.ebuild (renamed from net-misc/networkmanager/networkmanager-0.8.2.ebuild)7
4 files changed, 165 insertions, 4 deletions
diff --git a/net-misc/networkmanager/ChangeLog b/net-misc/networkmanager/ChangeLog
index 272215163abb..f24feb0a7991 100644
--- a/net-misc/networkmanager/ChangeLog
+++ b/net-misc/networkmanager/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for net-misc/networkmanager
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/networkmanager/ChangeLog,v 1.88 2010/11/10 12:57:16 dagger Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/networkmanager/ChangeLog,v 1.89 2010/11/30 09:35:18 qiaomuf Exp $
+
+*networkmanager-0.8.2-r1 (30 Nov 2010)
+
+ 30 Nov 2010; <gentoo@gentoo.org> +networkmanager-0.8.2-r1.ebuild,
+ +files/networkmanager-0.8.2-accept-gw.patch:
+ Accept "gw" by ifnet plugin for bug #339215
28 Oct 2010; Samuli Suominen <ssuominen@gentoo.org>
networkmanager-0.8-r1.ebuild:
diff --git a/net-misc/networkmanager/Manifest b/net-misc/networkmanager/Manifest
index e6604f9279b2..3c79304d6f98 100644
--- a/net-misc/networkmanager/Manifest
+++ b/net-misc/networkmanager/Manifest
@@ -1,3 +1,6 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
AUX NetworkManagerDispatcher 1198 RMD160 4345870ab40607b9aed80c8da383b604f032b98e SHA1 1dd2250c746b25566fceaab551f4ef8335fe4f55 SHA256 f8cb5d0470619cf1f0812fffcf1bf2091e3c44a757899c07164f80ddd6a2641e
AUX networkmanager-0.8-confchanges.patch 1063 RMD160 25a0d45410fa5590098386556e9947dd15507eda SHA1 ba6eaa63188f97f93bbbb327676d8104bbf7e8c8 SHA256 9fcbe0b9ab4cc38c9057a0dde2f5153efc12515ed4d28920a455dad7fc2b1e09
AUX networkmanager-0.8-nscd-clear-cache.patch 1214 RMD160 2381f455593202a740e634601c0ba8245ecb8fac SHA1 b4a0cec446b6f8fa81c06d5992db61b296f17057 SHA256 2d981bafa96607acb06740d78b8e33afdc675c52b0cf3ce5b098c67566362c99
@@ -8,6 +11,7 @@ AUX networkmanager-0.8.1-dhclient3-fix.patch 295 RMD160 986359b62d5cb7d4ca34b015
AUX networkmanager-0.8.1-dhclient3.patch 4658 RMD160 d229c87a41f882a6162520ee3f2afdc5650c283a SHA1 06ca671ba76cd1591556cdcc96a88060ca89e727 SHA256 45b1c302cea8605cc489a77250404e4457d0747ca3cab9ed993eb51551da3290
AUX networkmanager-0.8.1-dhcp-configure.patch 2447 RMD160 1c222ce867a7f92167b2ffcbc401f8ea83b24193 SHA1 f17b676ad65788b5b665c16b29d01a88e3cdd041 SHA256 7bda5db2d937b2562c98435620774bba487bf8b53da5c035422b2bc2ed21a400
AUX networkmanager-0.8.1-glib-2.25.12-workaround.patch 663 RMD160 b4397b17a6148244dedd341b35185c07ca267f06 SHA1 926acbd76076750ab4ec48ac34fe73679693a4ca SHA256 a00523ad7d6bdced76be82b980788af4c313fc59aff8b9d258343e17ad6bf969
+AUX networkmanager-0.8.2-accept-gw.patch 3679 RMD160 b163afa5215f0eb52ba2562d22c65ec5e0bd3380 SHA1 a71f25413abf0c359439add74a73545790604ac9 SHA256 631ccad5bc4c2d880b5235bc8e6ace494467bad1734023ded9d8bcd52b9177af
AUX nm-system-settings.conf 23 RMD160 6d66c702b345bde668a420a15716feea6005fbd1 SHA1 49ba558d20f5ca5a201e027e13b878dd5ac3569c SHA256 44b048804c7c0b8b3b0c29b8632b6ad613c397d0a1635ec918e10c0fbcdadf21
AUX nm-system-settings.conf-ifnet 70 RMD160 c0d2be147383999b62cead86ab4333169e4ef277 SHA1 679ec8052b610969c148a2d34cd4da7a41484a76 SHA256 34f53d9ac1ad65eda6942dc3059117f60f6321059ca23f4fbfcc2f2edcae151f
DIST NetworkManager-0.8.1.tar.bz2 1505134 RMD160 82f5ad1a641fa49acf34604f89154c865f3d5fbc SHA1 778989ed73cfd7ec05714f77121fa8bfc1bf0981 SHA256 dc126fbe3199d47899c4781e4fff32cee404dc7c728c6ade9eaa899bd80f19fa
@@ -16,6 +20,17 @@ DIST NetworkManager-0.8.tar.bz2 1376044 RMD160 40074f52a79965510de816c0e94d1b9ac
DIST networkmanager-ifnet-540e40f.patch 268068 RMD160 954ffb9915fdd8ae650963b66aba7e185ddfe0c6 SHA1 0bd0cfcb02a0511d17179d2994e40a663b49dd6f SHA256 8a870fb5ed708eea5523b954e23be05471c5b6783cd2d0a19071a1d253fcab51
EBUILD networkmanager-0.8-r1.ebuild 3516 RMD160 8722fcf8330e8f11a1e3dd83f2e2b53c8f34be5b SHA1 ebb761da259e1e76abe6645f35ff654fc5385984 SHA256 6142178a7ee9177a978c451eb9e02ccdf11de09b2f5b13ca0be79382d07883aa
EBUILD networkmanager-0.8.1-r6.ebuild 4632 RMD160 15481e54c0f3e9502c8357fd6a6b772a53c7ceab SHA1 b656512bcd456c4b621cff0876e846954a6545df SHA256 ec4be6303fd338df4efc0e4c51bce67985b295a14a9b6eea0e0a46460fffe557
-EBUILD networkmanager-0.8.2.ebuild 4018 RMD160 78d0726dafa4d3e768f17ad1938909bf0e76aa1f SHA1 d2bffb3bfbae6bcf07a04a54157c68463f7c84fc SHA256 47bef482328648fbd39d933b9e5aa4f277a3bcd0c1b7f7594fe61f77ced0ac4d
-MISC ChangeLog 18452 RMD160 9a279bf01b286ebba0b260fe357f9dd2487b044e SHA1 f786c6a69db49e34dc64d670650771210acf7a90 SHA256 b0ce0b1f82119bc274eb0d9a69b03cb8127ef682bf1274bbaadbcdc385291dce
+EBUILD networkmanager-0.8.2-r1.ebuild 4132 RMD160 1261ce2f0e499ece5e2ea4c010c8627ede1fa754 SHA1 96f9ac6b0ecaf0656386e82458453a97dfb8be61 SHA256 d247e094c0e22b885b78efa2cc8a6c8b32bbb5967f95a46439985d9a9da7362e
+MISC ChangeLog 18655 RMD160 9ddd481dac4f22042472af2120d71cf46a4a93a0 SHA1 589e842769483065d8bb65f8282fa99cead8da1e SHA256 6222777d697232eb069bb545da2475e38fb40945c102987dbaa0b07b20b067c2
MISC metadata.xml 975 RMD160 7f7f8f54c53fe2098dae8ed0a4cd177900289d3f SHA1 11de32f78915bbc01c6b0665b45233d004d75c25 SHA256 e0ce95394f82f5631ecec62c6595dc4dad9afc52cf5e1bb0f30618edfb79becc
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v2.0.16 (GNU/Linux)
+
+iQEcBAEBAgAGBQJM9MVtAAoJEDCzDeQXsVfpWyYH/j9cyWGQFt6IFuVc4DvwabXf
+JTHXpFnV4D3sMb7e5OkTtnpRUumtfgR4uE6/WYe/po2JJXgcC1oDBFm1DO6Vd1DF
+29vWLSxhCQi5v0iVP6SVqdBUhuQe96aDNwj3lkvaw4OFvILdyJv8s3CSui/OIfyr
+rqmQzyF2Y4GSVfCE0+qN+ik/h0sHeq4RxujshcZ02fG1rsz7o0h25k1Tkme+S6u/
+mYrLNcu0kznPNA34Ljr0Pi3iAKHtgl6imlyhwISc7C12AL8OoABQ5Q2d4yexZyG6
+ICEcwKuP3KY7H85ycLRO5IbQnzdvijY34VQy6YxW26GjzfN0+mhggtGJwZXMnoU=
+=t2RA
+-----END PGP SIGNATURE-----
diff --git a/net-misc/networkmanager/files/networkmanager-0.8.2-accept-gw.patch b/net-misc/networkmanager/files/networkmanager-0.8.2-accept-gw.patch
new file mode 100644
index 000000000000..b2911db71a9a
--- /dev/null
+++ b/net-misc/networkmanager/files/networkmanager-0.8.2-accept-gw.patch
@@ -0,0 +1,135 @@
+--- NetworkManager_Patched/system-settings/plugins/ifnet/net_utils.c 2010-11-04 04:10:52.000000000 +0800
++++ NetworkManager-0.8.2/system-settings/plugins/ifnet/net_utils.c 2010-11-23 15:11:08.024000011 +0800
+@@ -19,7 +19,6 @@
+ * Copyright (C) 1999-2010 Gentoo Foundation, Inc.
+ */
+
+-#include <config.h>
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <string.h>
+@@ -194,6 +193,32 @@
+ return error_quark;
+ }
+
++static char *
++find_default_gateway_str (char *str)
++{
++ char *tmp;
++
++ if ((tmp = strstr (str, "default via ")) != NULL) {
++ return tmp + strlen ("default via ");
++ } else if ((tmp = strstr (str, "default gw ")) != NULL) {
++ return tmp + strlen ("default gw ");
++ }
++ return NULL;
++}
++
++static char *
++find_gateway_str (char *str)
++{
++ char *tmp;
++
++ if ((tmp = strstr (str, "via ")) != NULL) {
++ return tmp + strlen ("via ");
++ } else if ((tmp = strstr (str, "gw ")) != NULL) {
++ return tmp + strlen ("gw ");
++ }
++ return NULL;
++}
++
+ gboolean
+ reload_parsers ()
+ {
+@@ -362,11 +387,10 @@
+ if (!tmp)
+ return FALSE;
+ routes = g_strdup (tmp);
+- tmp = strstr (routes, "default via ");
++ tmp = find_default_gateway_str (routes);
+ if (!tmp) {
+ goto error;
+ }
+- tmp += strlen ("default via ");
+ g_strstrip (tmp);
+ if ((end = strstr (tmp, "\"")) != NULL)
+ *end = '\0';
+@@ -483,8 +507,13 @@
+
+ if (!gateway)
+ return 0;
+- tmp = strstr (gateway, "via ");
+- tmp = g_strdup (tmp + strlen ("via "));
++ tmp = find_gateway_str(gateway);
++ if (!tmp) {
++ PLUGIN_WARN (IFNET_PLUGIN_NAME,
++ "Couldn't obtain gateway in \"%s\"", gateway);
++ return 0;
++ }
++ tmp = g_strdup (tmp);
+ strip_string (tmp, ' ');
+ strip_string (tmp, '"');
+ if ((split = strstr (tmp, "\"")) != NULL)
+@@ -509,8 +538,13 @@
+
+ if (!next_hop)
+ return 0;
+- tmp = strstr (next_hop, "via ");
+- tmp = g_strdup (tmp + strlen ("via "));
++ tmp = find_gateway_str(next_hop);
++ if (!tmp) {
++ PLUGIN_WARN (IFNET_PLUGIN_NAME,
++ "Couldn't obtain next_hop in \"%s\"", next_hop);
++ return 0;
++ }
++ tmp = g_strdup (tmp);
+ strip_string (tmp, ' ');
+ strip_string (tmp, '"');
+ g_strstrip (tmp);
+@@ -671,8 +705,8 @@
+ length = g_strv_length (ipset);
+ for (i = 0; i < length; i++) {
+ ip = ipset[i];
+- if (strstr (ip, "default via ") || strstr (ip, "::")
+- || !strstr (ip, "via"))
++ if (find_default_gateway_str (ip) || strstr (ip, "::")
++ || !find_gateway_str (ip))
+ continue;
+ ip = strip_string (ip, '"');
+ iblock = create_ip4_block (ip);
+@@ -712,9 +746,7 @@
+ ip = strip_string (ip, '"');
+ if (ip[0] == '\0')
+ continue;
+- printf ("ip:%s\n", ip);
+- if ((tmp_addr = strstr (ip, "default via ")) != NULL) {
+- tmp_addr += strlen ("default via ");
++ if ((tmp_addr = find_default_gateway_str (ip)) != NULL) {
+ if (!is_ip6_address (tmp_addr))
+ continue;
+ else {
+@@ -855,7 +887,7 @@
+ void
+ get_dhcp_hostname_and_client_id (char **hostname, char **client_id)
+ {
+- gchar *dhcp_client = ifnet_get_global_setting ("main", "dhcp");
++ gchar *dhcp_client = NULL;
+ const gchar *dhcpcd_conf = "/etc/dhcpcd.conf";
+ const gchar *dhclient_conf = "/etc/dhcp/dhclient.conf";
+ gchar *line = NULL, *tmp = NULL, *contents = NULL;
+@@ -864,6 +896,7 @@
+
+ *hostname = NULL;
+ *client_id = NULL;
++ dhcp_client = ifnet_get_global_setting ("main", "dhcp");
+ if (dhcp_client) {
+ if (!strcmp (dhcp_client, "dhclient"))
+ g_file_get_contents (dhclient_conf, &contents, NULL,
+@@ -871,6 +904,7 @@
+ else if (!strcmp (dhcp_client, "dhcpcd"))
+ g_file_get_contents (dhcpcd_conf, &contents, NULL,
+ NULL);
++ g_free (dhcp_client);
+ } else {
+ if (g_file_test (dhclient_conf, G_FILE_TEST_IS_REGULAR))
+ g_file_get_contents (dhclient_conf, &contents, NULL,
diff --git a/net-misc/networkmanager/networkmanager-0.8.2.ebuild b/net-misc/networkmanager/networkmanager-0.8.2-r1.ebuild
index 44efc14f827c..f39e3320da2f 100644
--- a/net-misc/networkmanager/networkmanager-0.8.2.ebuild
+++ b/net-misc/networkmanager/networkmanager-0.8.2-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/networkmanager/networkmanager-0.8.2.ebuild,v 1.1 2010/11/10 12:57:16 dagger Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/networkmanager/networkmanager-0.8.2-r1.ebuild,v 1.1 2010/11/30 09:35:18 qiaomuf Exp $
EAPI="2"
@@ -80,6 +80,11 @@ pkg_setup() {
fi
}
+src_prepare() {
+ # accept "gw" in /etc/conf.d/net (bug #339215)
+ epatch "${FILESDIR}/${P}-accept-gw.patch"
+}
+
src_configure() {
ECONF="--disable-more-warnings
--localstatedir=/var