summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2015-09-14 15:53:02 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-09-23 09:53:03 +0100
commit7d166a6d0621e0b811d41cd3b1377850a88092f0 (patch)
treeaa840ffe786fa0656c2f870bf3469a027e6d2be6
parentd36384e61d538fbf3f0434a0ae4e5fd3b361e27a (diff)
downloadpoky-7d166a6d0621e0b811d41cd3b1377850a88092f0.tar.gz
sysstat: Include needed headers explicitly
It depends on defines from .h files that are not includes as part of source file, on glibc it works because they get included indirectly but that can change any time since its internal glibc behaviour, at user level the header needed should be explicitly included. (From OE-Core rev: 2a19b13bdd5ab1505464c4c4bc0129a9a8ee0c7c) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-extended/sysstat/sysstat/0001-Include-needed-headers-explicitly.patch62
-rw-r--r--meta/recipes-extended/sysstat/sysstat_11.1.5.bb2
2 files changed, 64 insertions, 0 deletions
diff --git a/meta/recipes-extended/sysstat/sysstat/0001-Include-needed-headers-explicitly.patch b/meta/recipes-extended/sysstat/sysstat/0001-Include-needed-headers-explicitly.patch
new file mode 100644
index 0000000000..c12652307c
--- /dev/null
+++ b/meta/recipes-extended/sysstat/sysstat/0001-Include-needed-headers-explicitly.patch
@@ -0,0 +1,62 @@
1From 42325faa88d64cce799977d611b2792beb154643 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Mon, 14 Sep 2015 08:36:59 +0000
4Subject: [PATCH] Include needed headers explicitly
5
6on glibc these headers get pulled in indirectly via other .h files
7but right fix is to include them directly when used
8
9fixes
10
11error: use of undeclared identifier 'PATH_MAX'
12error: called object type 'unsigned int' is not a function or function pointer
13dm_major = major(aux.st_rdev);
14
15Signed-off-by: Khem Raj <raj.khem@gmail.com>
16---
17Upstream-Status: Pending
18
19 common.c | 1 +
20 ioconf.c | 1 +
21 sa_common.c | 1 +
22 3 files changed, 3 insertions(+)
23
24diff --git a/common.c b/common.c
25index a23155b..ad86446 100644
26--- a/common.c
27+++ b/common.c
28@@ -20,6 +20,7 @@
29 */
30
31 #include <stdio.h>
32+#include <limits.h>
33 #include <string.h>
34 #include <stdlib.h>
35 #include <time.h>
36diff --git a/ioconf.c b/ioconf.c
37index 7d88c5d..6d67691 100644
38--- a/ioconf.c
39+++ b/ioconf.c
40@@ -27,6 +27,7 @@
41 #include <errno.h>
42 #include <dirent.h>
43 #include <sys/stat.h>
44+#include <sys/types.h>
45
46 #include "ioconf.h"
47 #include "common.h"
48diff --git a/sa_common.c b/sa_common.c
49index b7351d9..c9e3299 100644
50--- a/sa_common.c
51+++ b/sa_common.c
52@@ -20,6 +20,7 @@
53 */
54
55 #include <stdio.h>
56+#include <limits.h>
57 #include <string.h>
58 #include <stdlib.h>
59 #include <time.h>
60--
612.5.2
62
diff --git a/meta/recipes-extended/sysstat/sysstat_11.1.5.bb b/meta/recipes-extended/sysstat/sysstat_11.1.5.bb
index 69d2ec26bf..bff861617a 100644
--- a/meta/recipes-extended/sysstat/sysstat_11.1.5.bb
+++ b/meta/recipes-extended/sysstat/sysstat_11.1.5.bb
@@ -2,6 +2,8 @@ require sysstat.inc
2 2
3LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b" 3LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b"
4 4
5SRC_URI += "file://0001-Include-needed-headers-explicitly.patch"
6
5SRC_URI[md5sum] = "4d8e6e72d057189a1660462a678d9ada" 7SRC_URI[md5sum] = "4d8e6e72d057189a1660462a678d9ada"
6SRC_URI[sha256sum] = "feb3a90d86ffd69cf5b88144a8876ae05bd42384f559676f08100671589fa2bb" 8SRC_URI[sha256sum] = "feb3a90d86ffd69cf5b88144a8876ae05bd42384f559676f08100671589fa2bb"
7 9