/[gentoo-x86]/net-misc/networkmanager/files/networkmanager-0.8.1-dhcp-configure.patch
Gentoo

Contents of /net-misc/networkmanager/files/networkmanager-0.8.1-dhcp-configure.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Tue Aug 23 23:17:09 2011 UTC (3 years, 3 months ago) by nirbheek
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +0 -0 lines
FILE REMOVED
Bump for the 0.9.0 release, go forth and test. Also, remove old ebuilds and unused patches.

(Portage version: 2.2.0_alpha51/cvs/Linux x86_64)

1 From c050e036c3d748970945195ed0fe6c914c439481 Mon Sep 17 00:00:00 2001
2 From: Dan Williams <dcbw@redhat.com>
3 Date: Thu, 05 Aug 2010 20:25:42 +0000
4 Subject: dhcp: make sure disabled DHCP clients aren't used (gentoo #330319)
5
6 If the client was disabled with --with-dhclient=no or
7 --with-dhcpcd=no, then it's corresponding _PATH will be an empty
8 string. In that case we want to ignore that client completely
9 since it was disabled at build time.
10 ---
11 diff --git a/src/dhcp-manager/nm-dhcp-manager.c b/src/dhcp-manager/nm-dhcp-manager.c
12 index bde874f..a1e3e5e 100644
13 --- a/src/dhcp-manager/nm-dhcp-manager.c
14 +++ b/src/dhcp-manager/nm-dhcp-manager.c
15 @@ -265,8 +265,13 @@ get_client_type (const char *client, GError **error)
16 const char *dhclient_path = NULL;
17 const char *dhcpcd_path = NULL;
18
19 - dhclient_path = nm_dhcp_dhclient_get_path (DHCLIENT_PATH);
20 - dhcpcd_path = nm_dhcp_dhcpcd_get_path (DHCPCD_PATH);
21 + /* If a client was disabled at build-time, its *_PATH define will be
22 + * an empty string.
23 + */
24 + if (DHCLIENT_PATH && strlen (DHCLIENT_PATH))
25 + dhclient_path = nm_dhcp_dhclient_get_path (DHCLIENT_PATH);
26 + if (DHCPCD_PATH && strlen (DHCPCD_PATH))
27 + dhcpcd_path = nm_dhcp_dhcpcd_get_path (DHCPCD_PATH);
28
29 if (!client) {
30 if (dhclient_path)
31 --
32 From 91e90d9d5412223e0252ccff0e3732afae201af6 Mon Sep 17 00:00:00 2001
33 From: Mike Auty <ikelos@gentoo.org>
34 Date: Thu, 05 Aug 2010 20:25:12 +0000
35 Subject: build: fix dhcpcd client detection
36
37 ---
38 diff --git a/configure.ac b/configure.ac
39 index 9c260fb..b1d16f2 100644
40 --- a/configure.ac
41 +++ b/configure.ac
42 @@ -344,10 +344,10 @@ case "${with_dhcpcd}" in
43 AC_MSG_CHECKING(for dhcpcd)
44 # We fully work with upstream dhcpcd-4
45 for path in /sbin /usr/sbin /usr/pkg/sbin /usr/local/sbin; do
46 - test -x "${path}/dhclient" || continue
47 + test -x "${path}/dhcpcd" || continue
48 case `"$path/dhcpcd" --version 2>/dev/null` in
49 "dhcpcd "[123]*);;
50 - "dhcpcd "*) DHCP_CLIENT_PATH="$path/dhcpcd"; break;;
51 + "dhcpcd "*) DHCPCD_PATH="$path/dhcpcd"; break;;
52 esac
53 done
54 if test -n "${DHCPCD_PATH}"; then
55 @@ -364,7 +364,7 @@ if test -z "$DHCPCD_PATH" -a -z "$DHCLIENT_PATH"; then
56 # in most distros, so use it.
57 AC_MSG_WARN([Could not find a suitable DHCP client])
58 DHCLIENT_PATH=/sbin/dhclient
59 - AC_MSG_WARN([Falling back to ISC dhclient, ${DHCP_CLIENT_PATH}])
60 + AC_MSG_WARN([Falling back to ISC dhclient, ${DHCLIENT_PATH}])
61 fi
62 AC_SUBST(DHCLIENT_PATH)
63 AC_SUBST(DHCPCD_PATH)
64 --

  ViewVC Help
Powered by ViewVC 1.1.20