aboutsummaryrefslogtreecommitdiffstats
path: root/testing/td-agent-bit/0001-lib-flb_libco-Fix-ppc64-function-arguments.patch
diff options
context:
space:
mode:
authorBreno Leitao <breno.leitao@gmail.com>2017-05-08 19:44:22 +0000
committerBreno Leitao <breno.leitao@gmail.com>2017-05-08 19:46:35 +0000
commit1780a0dfdf57871c83f7104703ace40a1833675b (patch)
treec06b18e644d0498a9dd2dcc2074f140ee95914f9 /testing/td-agent-bit/0001-lib-flb_libco-Fix-ppc64-function-arguments.patch
parent7635e82b0a56e10ff90402cbc4fae0e25c505fe7 (diff)
downloadaports-1780a0dfdf57871c83f7104703ace40a1833675b.tar.bz2
aports-1780a0dfdf57871c83f7104703ace40a1833675b.tar.xz
testing/td-agent-bit: Fix build on ppc64le
There was a regression td-agent-bit that broke a function on ppc64le. This patch fixes it. This patch was also sent uptream, as: https://github.com/fluent/fluent-bit/pull/253
Diffstat (limited to 'testing/td-agent-bit/0001-lib-flb_libco-Fix-ppc64-function-arguments.patch')
-rw-r--r--testing/td-agent-bit/0001-lib-flb_libco-Fix-ppc64-function-arguments.patch48
1 files changed, 48 insertions, 0 deletions
diff --git a/testing/td-agent-bit/0001-lib-flb_libco-Fix-ppc64-function-arguments.patch b/testing/td-agent-bit/0001-lib-flb_libco-Fix-ppc64-function-arguments.patch
new file mode 100644
index 0000000000..fd0578a054
--- /dev/null
+++ b/testing/td-agent-bit/0001-lib-flb_libco-Fix-ppc64-function-arguments.patch
@@ -0,0 +1,48 @@
+From a0dfda11ab576da7b3c931f7512fa77b86d95209 Mon Sep 17 00:00:00 2001
+From: Breno Leitao <breno.leitao@gmail.com>
+Date: Mon, 8 May 2017 19:36:43 +0000
+Subject: [PATCH] lib: flb_libco: Fix ppc64 function arguments
+
+This software currently does not built on Power due to duplicated
+function.
+
+ lib/flb_libco/ppc.c:282:12: error: conflicting types for 'co_create'
+ cothread_t co_create(unsigned int size, void (*entry_)(void)) {
+
+ lib/flb_libco/libco.h:19:12: note: previous declaration of 'co_create' was here
+ cothread_t co_create(unsigned int, void (*)(void), size_t *);
+
+This is happening because commit
+b2bb2227cd2712df1946c438ec733b5956e9ecd8 forgot to change the function
+name on ppc source code.
+
+Signed-off-by: Breno Leitao <breno.leitao@gmail.com>
+---
+ lib/flb_libco/ppc.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/lib/flb_libco/ppc.c b/lib/flb_libco/ppc.c
+index e6536d56..8b70ad77 100755
+--- a/lib/flb_libco/ppc.c
++++ b/lib/flb_libco/ppc.c
+@@ -279,7 +279,8 @@ static uint32_t* co_create_(unsigned size, uintptr_t entry) {
+ return t;
+ }
+
+-cothread_t co_create(unsigned int size, void (*entry_)(void)) {
++cothread_t co_create(unsigned int size, void (*entry_)(void),
++ size_t *out_size) {
+ uintptr_t entry = (uintptr_t)entry_;
+ uint32_t* t = 0;
+
+@@ -289,6 +290,7 @@ cothread_t co_create(unsigned int size, void (*entry_)(void)) {
+ t = co_create_(size, entry);
+ }
+
++ *out_size = size;
+ if(t) {
+ uintptr_t sp;
+ int shift;
+--
+2.12.2
+