diff options
author | Andreas Müller <schnitzeltony@googlemail.com> | 2012-09-17 08:15:45 +0000 |
---|---|---|
committer | Koen Kooi <koen@dominion.thruhere.net> | 2012-09-17 10:42:32 +0200 |
commit | e527e152a2c051221ee137f0cc117f85941ead03 (patch) | |
tree | beed2d309c4e96faf1923a6fd6551124135e3351 | |
parent | a2d7dc4466b4cf207ad84544dcd43a4d8671337f (diff) | |
download | meta-openembedded-e527e152a2c051221ee137f0cc117f85941ead03.tar.gz |
networkmanager: unbreak build with latest kernel headers
| nm-ppp-manager.c: In function 'monitor_cb':
| nm-ppp-manager.c:307:23: error: storage size of 'req' isn't known
| make[5]: *** [libppp_manager_la-nm-ppp-manager.lo] Error 1
Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
2 files changed, 50 insertions, 1 deletions
diff --git a/meta-oe/recipes-connectivity/networkmanager/networkmanager/0002-ppp-don-t-use-struct-ifpppstatsreq-that-was-removed-.patch b/meta-oe/recipes-connectivity/networkmanager/networkmanager/0002-ppp-don-t-use-struct-ifpppstatsreq-that-was-removed-.patch new file mode 100644 index 000000000..e2f43f35b --- /dev/null +++ b/meta-oe/recipes-connectivity/networkmanager/networkmanager/0002-ppp-don-t-use-struct-ifpppstatsreq-that-was-removed-.patch | |||
@@ -0,0 +1,48 @@ | |||
1 | From 6b64e4db2f3c9cfc0e0e240cf0bc58f3b3e90c1f Mon Sep 17 00:00:00 2001 | ||
2 | From: =?UTF-8?q?Ji=C5=99=C3=AD=20Klime=C5=A1?= <jklimes@redhat.com> | ||
3 | Date: Wed, 28 Mar 2012 16:42:24 +0200 | ||
4 | Subject: [PATCH 7/9] ppp: don't use struct ifpppstatsreq that was removed | ||
5 | from linux/ip_ppp.h | ||
6 | |||
7 | in recent kernels. | ||
8 | |||
9 | We can use ifreq and ppp_stats structures separately. They needn't have to | ||
10 | to be packed in a structure. | ||
11 | --- | ||
12 | Upstream-Status: Backport [1] | ||
13 | [1] http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=6b64e4db2f3c9cfc0e0e240cf0bc58f3b3e90c1f | ||
14 | src/ppp-manager/nm-ppp-manager.c | 12 +++++++----- | ||
15 | 1 file changed, 7 insertions(+), 5 deletions(-) | ||
16 | |||
17 | diff --git a/src/ppp-manager/nm-ppp-manager.c b/src/ppp-manager/nm-ppp-manager.c | ||
18 | index 59698c3..243d2e1 100644 | ||
19 | --- a/src/ppp-manager/nm-ppp-manager.c | ||
20 | +++ b/src/ppp-manager/nm-ppp-manager.c | ||
21 | @@ -304,18 +304,20 @@ monitor_cb (gpointer user_data) | ||
22 | { | ||
23 | NMPPPManager *manager = NM_PPP_MANAGER (user_data); | ||
24 | NMPPPManagerPrivate *priv = NM_PPP_MANAGER_GET_PRIVATE (manager); | ||
25 | - struct ifpppstatsreq req; | ||
26 | + struct ifreq req; | ||
27 | + struct ppp_stats stats; | ||
28 | |||
29 | memset (&req, 0, sizeof (req)); | ||
30 | - req.stats_ptr = (caddr_t) &req.stats; | ||
31 | + memset (&stats, 0, sizeof (stats)); | ||
32 | + req.ifr_data = (caddr_t) &stats; | ||
33 | |||
34 | - strncpy (req.ifr__name, priv->ip_iface, sizeof (req.ifr__name)); | ||
35 | + strncpy (req.ifr_name, priv->ip_iface, sizeof (req.ifr_name)); | ||
36 | if (ioctl (priv->monitor_fd, SIOCGPPPSTATS, &req) < 0) { | ||
37 | nm_log_warn (LOGD_PPP, "could not read ppp stats: %s", strerror (errno)); | ||
38 | } else { | ||
39 | g_signal_emit (manager, signals[STATS], 0, | ||
40 | - req.stats.p.ppp_ibytes, | ||
41 | - req.stats.p.ppp_obytes); | ||
42 | + stats.p.ppp_ibytes, | ||
43 | + stats.p.ppp_obytes); | ||
44 | } | ||
45 | |||
46 | return TRUE; | ||
47 | -- | ||
48 | 1.7.9.4 | ||
diff --git a/meta-oe/recipes-connectivity/networkmanager/networkmanager_0.9.2.0.bb b/meta-oe/recipes-connectivity/networkmanager/networkmanager_0.9.2.0.bb index e774cb953..074e6650b 100644 --- a/meta-oe/recipes-connectivity/networkmanager/networkmanager_0.9.2.0.bb +++ b/meta-oe/recipes-connectivity/networkmanager/networkmanager_0.9.2.0.bb | |||
@@ -4,13 +4,14 @@ SECTION = "net/misc" | |||
4 | LICENSE = "GPLv2+" | 4 | LICENSE = "GPLv2+" |
5 | LIC_FILES_CHKSUM = "file://COPYING;md5=cbbffd568227ada506640fe950a4823b" | 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=cbbffd568227ada506640fe950a4823b" |
6 | 6 | ||
7 | PR = "r7" | 7 | PR = "r8" |
8 | 8 | ||
9 | DEPENDS = "libnl dbus dbus-glib udev wireless-tools polkit gnutls util-linux ppp" | 9 | DEPENDS = "libnl dbus dbus-glib udev wireless-tools polkit gnutls util-linux ppp" |
10 | inherit gnome gettext | 10 | inherit gnome gettext |
11 | 11 | ||
12 | SRC_URI = "${GNOME_MIRROR}/NetworkManager/${@gnome_verdir("${PV}")}/NetworkManager-${PV}.tar.bz2 \ | 12 | SRC_URI = "${GNOME_MIRROR}/NetworkManager/${@gnome_verdir("${PV}")}/NetworkManager-${PV}.tar.bz2 \ |
13 | file://0001-don-t-try-to-run-sbin-dhclient-to-get-the-version-nu.patch \ | 13 | file://0001-don-t-try-to-run-sbin-dhclient-to-get-the-version-nu.patch \ |
14 | file://0002-ppp-don-t-use-struct-ifpppstatsreq-that-was-removed-.patch \ | ||
14 | file://gtk-doc.make \ | 15 | file://gtk-doc.make \ |
15 | " | 16 | " |
16 | SRC_URI[md5sum] = "bc0b00b8a187762d93c50a9706b4c5c3" | 17 | SRC_URI[md5sum] = "bc0b00b8a187762d93c50a9706b4c5c3" |