diff options
author | Fan Xin <fan.xin@jp.fujitsu.com> | 2015-12-14 17:29:24 +0900 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-12-16 12:11:23 +0000 |
commit | 8e40d9d79bfffa8bc4b1dfd20e78e1554f6c9b00 (patch) | |
tree | 6fa774513658000b26e4ee20319d3c7cebce9802 /meta/recipes-extended/ltp/ltp/0001-Fix-compilation-for-gcc-5.x.patch | |
parent | 0196bc0d466758f634f52f8dff298ca9157c96c4 (diff) | |
download | openembedded-core-contrib-8e40d9d79bfffa8bc4b1dfd20e78e1554f6c9b00.tar.gz |
ltp: Upgrade 20150420 -> 20150903
1. Upgrade from 20150420 to 20150903
https://github.com/linux-test-project/ltp/releases/tag/20150903
2. Replace the patch file 0001-replace-inline-with-static-inline-for-gcc-5.x.patch due to the ltp original source code is changed.
Signed-off-by: Fan Xin <fan.xin@jp.fujitsu.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/recipes-extended/ltp/ltp/0001-Fix-compilation-for-gcc-5.x.patch')
-rw-r--r-- | meta/recipes-extended/ltp/ltp/0001-Fix-compilation-for-gcc-5.x.patch | 79 |
1 files changed, 79 insertions, 0 deletions
diff --git a/meta/recipes-extended/ltp/ltp/0001-Fix-compilation-for-gcc-5.x.patch b/meta/recipes-extended/ltp/ltp/0001-Fix-compilation-for-gcc-5.x.patch new file mode 100644 index 0000000000..9407a34584 --- /dev/null +++ b/meta/recipes-extended/ltp/ltp/0001-Fix-compilation-for-gcc-5.x.patch @@ -0,0 +1,79 @@ +From 40a2457cb8ec42a05a2f96b0810057efdb2a55f5 Mon Sep 17 00:00:00 2001 +From: Kai Kang <kai.kang@windriver.com> +Date: Wed, 16 Sep 2015 13:23:43 +0200 +Subject: [PATCH] Fix compilation for gcc-5.x + +The gcc-5.x defaults to -std=gnu11 instead of -std=gnu89 which causes +semantics for inline functions changes. + +GNU89 inline: Same as C99 extern inline. + +So the standalone 'inline' causes error such as: + +git/testcases/kernel/syscalls/kill/kill10.c:355: undefined reference to `k_sigaction' + +Replace inline with static inline to fix this issue. + +Ref: +https://gcc.gnu.org/gcc-5/porting_to.html + +Upstream-Status: Backport +Signed-off-by: Kai Kang <kai.kang@windriver.com> +Acked-by: Cyril Hrubis <chrubis@suse.cz> +--- + testcases/kernel/controllers/libcontrollers/libcontrollers.c | 2 +- + testcases/kernel/controllers/libcontrollers/libcontrollers.h | 2 +- + testcases/kernel/syscalls/kill/kill10.c | 4 ++-- + 3 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/testcases/kernel/controllers/libcontrollers/libcontrollers.c b/testcases/kernel/controllers/libcontrollers/libcontrollers.c +index 844c5bc..75766fc 100644 +--- a/testcases/kernel/controllers/libcontrollers/libcontrollers.c ++++ b/testcases/kernel/controllers/libcontrollers/libcontrollers.c +@@ -158,7 +158,7 @@ int read_file(char *filepath, int action, unsigned int *value) + * Prints error message and returns -1 + */ + +-inline void error_function(char *msg1, char *msg2) ++static inline void error_function(char *msg1, char *msg2) + { + fprintf(stdout, "ERROR: %s ", msg1); + fprintf(stdout, "%s\n", msg2); +diff --git a/testcases/kernel/controllers/libcontrollers/libcontrollers.h b/testcases/kernel/controllers/libcontrollers/libcontrollers.h +index bd8e2d8..cdde9f9 100644 +--- a/testcases/kernel/controllers/libcontrollers/libcontrollers.h ++++ b/testcases/kernel/controllers/libcontrollers/libcontrollers.h +@@ -70,7 +70,7 @@ enum{ + GET_TASKS + }; + +-inline void error_function(char *msg1, char *msg2); ++static inline void error_function(char *msg1, char *msg2); + + int read_shares_file(char *filepath); + +diff --git a/testcases/kernel/syscalls/kill/kill10.c b/testcases/kernel/syscalls/kill/kill10.c +index 982d9da..33dbcd3 100644 +--- a/testcases/kernel/syscalls/kill/kill10.c ++++ b/testcases/kernel/syscalls/kill/kill10.c +@@ -185,7 +185,7 @@ int child_checklist_total = 0; + int checklist_cmp(const void *a, const void *b); + void checklist_reset(int bit); + +-inline int k_sigaction(int sig, struct sigaction *sa, struct sigaction *osa); ++static inline int k_sigaction(int sig, struct sigaction *sa, struct sigaction *osa); + + char *TCID = "kill10"; + int TST_TOTAL = 1; +@@ -756,7 +756,7 @@ void checklist_reset(int bit) + + } + +-inline int k_sigaction(int sig, struct sigaction *sa, struct sigaction *osa) ++static inline int k_sigaction(int sig, struct sigaction *sa, struct sigaction *osa) + { + int ret; + if ((ret = sigaction(sig, sa, osa)) == -1) { +-- +1.9.1 + |