diff options
author | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 14:36:22 +0200 |
---|---|---|
committer | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 15:32:53 +0200 |
commit | f4cf9fe05bb3f32fabea4e54dd92d368967a80da (patch) | |
tree | 487180fa9866985ea7b28e625651765d86f515c3 /meta/recipes-kernel/trace-cmd | |
download | poky-f4cf9fe05bb3f32fabea4e54dd92d368967a80da.tar.gz |
initial commit for Enea Linux 4.0
Migrated from the internal git server on the daisy-enea branch
Signed-off-by: Adrian Dudau <adrian.dudau@enea.com>
Diffstat (limited to 'meta/recipes-kernel/trace-cmd')
10 files changed, 432 insertions, 0 deletions
diff --git a/meta/recipes-kernel/trace-cmd/kernelshark_1.2.bb b/meta/recipes-kernel/trace-cmd/kernelshark_1.2.bb new file mode 100644 index 0000000000..d61097df91 --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/kernelshark_1.2.bb | |||
@@ -0,0 +1,30 @@ | |||
1 | SUMMARY = "Graphical trace viewer for Ftrace" | ||
2 | LICENSE = "GPLv2" | ||
3 | LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \ | ||
4 | file://kernel-shark.c;beginline=6;endline=8;md5=2c22c965a649ddd7973d7913c5634a5e" | ||
5 | |||
6 | SRCREV = "7055ffd37beeb44714e86a4abc703f7e175a0db5" | ||
7 | PR = "r3" | ||
8 | PV = "1.2+git${SRCPV}" | ||
9 | |||
10 | DEPENDS = "gtk+" | ||
11 | RDEPENDS_${PN} = "trace-cmd" | ||
12 | |||
13 | inherit pkgconfig pythonnative | ||
14 | |||
15 | SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git \ | ||
16 | file://addldflags.patch \ | ||
17 | file://make-docs-optional.patch \ | ||
18 | file://blktrace-api-compatibility.patch \ | ||
19 | file://kernelshark-fix-syntax-error-of-shell.patch" | ||
20 | S = "${WORKDIR}/git" | ||
21 | |||
22 | EXTRA_OEMAKE = "'CC=${CC}' 'AR=${AR}' 'prefix=${prefix}' gui" | ||
23 | |||
24 | FILESPATH = "${FILE_DIRNAME}/trace-cmd" | ||
25 | |||
26 | do_install() { | ||
27 | oe_runmake CC="${CC}" AR="${AR}" prefix="${prefix}" DESTDIR="${D}" install_gui | ||
28 | rm -rf ${D}${datadir}/trace-cmd | ||
29 | rmdir ${D}${datadir} | ||
30 | } | ||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/addldflags.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/addldflags.patch new file mode 100644 index 0000000000..14730db905 --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd/addldflags.patch | |||
@@ -0,0 +1,51 @@ | |||
1 | trace-cmd: Cross-compile fixes for LDFLAGS and include path | ||
2 | |||
3 | Add ability for the Makefile to respect LDFLAGS. | ||
4 | Also remove hardcoded /usr/local/include include path. | ||
5 | |||
6 | Upstream-Status: Accepted [Post 1.2: 5f576e9af7ad706774d9764a9ae3989376797c0e] | ||
7 | |||
8 | Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> | ||
9 | Signed-off-by: Darren Hart <dvhart@linux.intel.com> | ||
10 | |||
11 | --- | ||
12 | Makefile | 7 ++++--- | ||
13 | 1 file changed, 4 insertions(+), 3 deletions(-) | ||
14 | |||
15 | Index: git/Makefile | ||
16 | =================================================================== | ||
17 | --- git.orig/Makefile | ||
18 | +++ git/Makefile | ||
19 | @@ -202,12 +202,13 @@ export Q VERBOSE | ||
20 | TRACECMD_VERSION = $(TC_VERSION).$(TC_PATCHLEVEL).$(TC_EXTRAVERSION) | ||
21 | KERNELSHARK_VERSION = $(KS_VERSION).$(KS_PATCHLEVEL).$(KS_EXTRAVERSION) | ||
22 | |||
23 | -INCLUDES = -I. -I/usr/local/include $(CONFIG_INCLUDES) | ||
24 | +INCLUDES = -I. $(CONFIG_INCLUDES) | ||
25 | |||
26 | include features.mk | ||
27 | |||
28 | # Set compile option CFLAGS if not set elsewhere | ||
29 | CFLAGS ?= -g -Wall | ||
30 | +LDFLAGS ?= | ||
31 | |||
32 | ifndef NO_PTRACE | ||
33 | ifneq ($(call try-cc,$(SOURCE_PTRACE),),y) | ||
34 | @@ -251,7 +252,7 @@ do_fpic_compile = \ | ||
35 | |||
36 | do_app_build = \ | ||
37 | ($(print_app_build) \ | ||
38 | - $(CC) $^ -rdynamic -o $@ $(CONFIG_LIBS) $(LIBS)) | ||
39 | + $(CC) $^ -rdynamic -o $@ $(LDFLAGS) $(CONFIG_LIBS) $(LIBS)) | ||
40 | |||
41 | do_compile_shared_library = \ | ||
42 | ($(print_shared_lib_compile) \ | ||
43 | @@ -263,7 +264,7 @@ do_compile_plugin_obj = \ | ||
44 | |||
45 | do_plugin_build = \ | ||
46 | ($(print_plugin_build) \ | ||
47 | - $(CC) $(CFLAGS) -shared -nostartfiles -o $@ $<) | ||
48 | + $(CC) $(CFLAGS) $(LDFLAGS) -shared -nostartfiles -o $@ $<) | ||
49 | |||
50 | do_build_static_lib = \ | ||
51 | ($(print_static_lib_build) \ | ||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch new file mode 100644 index 0000000000..0789e9fdf7 --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch | |||
@@ -0,0 +1,29 @@ | |||
1 | trace-cmd: Add blktrace_api compatibility for TC_BARRIER | ||
2 | |||
3 | Newer kernels replace TC_BARRIER with TC_FLUSH. Ensure trace-cmd | ||
4 | can build regardless of the linux-kernel-headers version. | ||
5 | |||
6 | Upstream-Status: Innapropriate [Stop gap] | ||
7 | |||
8 | Signed-off-by: Darren Hart <dvhart@linux.intel.com> | ||
9 | |||
10 | diff --git a/plugin_blk.c b/plugin_blk.c | ||
11 | index 9327b17..c8e5e1c 100644 | ||
12 | --- a/plugin_blk.c | ||
13 | +++ b/plugin_blk.c | ||
14 | @@ -44,6 +44,15 @@ struct blk_data { | ||
15 | unsigned short pdu_len; | ||
16 | }; | ||
17 | |||
18 | +/* | ||
19 | + * Newer kernels don't define BLK_TC_BARRIER and have replaced it with | ||
20 | + * BLK_TC_FLUSH. In this case, define it here and report FLUSHES as BARRIERS as | ||
21 | + * a workaround, as described in: | ||
22 | + * http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commit;h=c09c47caedc9854d59378d6e34c989e51cfdd2b4 | ||
23 | + */ | ||
24 | +#ifndef BLK_TC_BARRIER | ||
25 | +#define BLK_TC_BARRIER 1<<2 | ||
26 | +#endif | ||
27 | static void fill_rwbs(char *rwbs, int action, unsigned int bytes) | ||
28 | { | ||
29 | int i = 0; | ||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/kernelshark-fix-syntax-error-of-shell.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/kernelshark-fix-syntax-error-of-shell.patch new file mode 100644 index 0000000000..351b24b82f --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd/kernelshark-fix-syntax-error-of-shell.patch | |||
@@ -0,0 +1,30 @@ | |||
1 | kernelshark: fix syntax error of shell | ||
2 | |||
3 | Delete "<<<" syntax of bash in Makefile, else we would get following error: | ||
4 | |||
5 | Syntax error: redirection unexpected | ||
6 | |||
7 | Upstream-status: Pending | ||
8 | |||
9 | Signed-off-by: Chong Lu <Chong.Lu@windriver.com> | ||
10 | --- | ||
11 | Makefile | 3 +-- | ||
12 | 1 file changed, 1 insertion(+), 2 deletions(-) | ||
13 | |||
14 | diff --git a/Makefile b/Makefile | ||
15 | index c1fa906..be84415 100644 | ||
16 | --- a/Makefile | ||
17 | +++ b/Makefile | ||
18 | @@ -89,8 +89,7 @@ endif | ||
19 | |||
20 | # $(call test-build, snippet, ret) -> ret if snippet compiles | ||
21 | # -> empty otherwise | ||
22 | -test-build = $(if $(shell $(CC) -o /dev/null -c -x c - > /dev/null 2>&1 \ | ||
23 | - <<<'$1' && echo y), $2) | ||
24 | +test-build = $(if $(shell echo '$1' |$(CC) -o /dev/null -c -x c - > /dev/null 2>&1 && echo y), $2) | ||
25 | |||
26 | # have udis86 disassembler library? | ||
27 | udis86-flags := $(call test-build,\#include <udis86.h>,-DHAVE_UDIS86 -ludis86) | ||
28 | -- | ||
29 | 1.7.9.5 | ||
30 | |||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/make-docs-optional.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/make-docs-optional.patch new file mode 100644 index 0000000000..8402426c5f --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd/make-docs-optional.patch | |||
@@ -0,0 +1,36 @@ | |||
1 | Disable building docs until we have asciidocs available as a recipe. | ||
2 | |||
3 | Upstream-Status: Inappropriate [Account for missing dependency, the lazy way] | ||
4 | |||
5 | Signed-off-by: Darren Hart <dvhart@linux.intel.com> | ||
6 | |||
7 | --- | ||
8 | Makefile | 8 ++++++-- | ||
9 | 1 file changed, 6 insertions(+), 2 deletions(-) | ||
10 | |||
11 | Index: git/Makefile | ||
12 | =================================================================== | ||
13 | --- git.orig/Makefile | ||
14 | +++ git/Makefile | ||
15 | @@ -327,7 +327,9 @@ TARGETS = $(CMD_TARGETS) $(GUI_TARGETS) | ||
16 | # If you want kernelshark, then do: make gui | ||
17 | ### | ||
18 | |||
19 | -all: all_cmd doc show_gui_make | ||
20 | +# Make doc optional | ||
21 | +#all: all_cmd doc show_gui_make | ||
22 | +all: all_cmd show_gui_make | ||
23 | |||
24 | all_cmd: $(CMD_TARGETS) | ||
25 | |||
26 | @@ -503,7 +505,9 @@ install_python: $(PYTHON_SO_INSTALL) $(P | ||
27 | install_cmd: all_cmd install_plugins install_python | ||
28 | $(Q)$(call do_install,trace-cmd,$(bindir_SQ)) | ||
29 | |||
30 | -install: install_cmd install_doc | ||
31 | +# Make doc optional | ||
32 | +#install: install_cmd install_doc | ||
33 | +install: install_cmd | ||
34 | @echo "Note: to install the gui, type \"make install_gui\"" | ||
35 | |||
36 | install_gui: install_cmd gui | ||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch new file mode 100644 index 0000000000..8fdeedb008 --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch | |||
@@ -0,0 +1,61 @@ | |||
1 | From a6e259b2cd43db3c0f69441f627a8cf214f88506 Mon Sep 17 00:00:00 2001 | ||
2 | From: Mark Asselstine <mark.asselstine@windriver.com> | ||
3 | Date: Thu, 5 Apr 2012 15:19:44 -0400 | ||
4 | Subject: [PATCH] trace-cmd: Add checks for invalid pointers to fix segfaults | ||
5 | |||
6 | Upstream-Status: Backport | ||
7 | |||
8 | Running 'trace-cmd report' after running latency tracers will cause a | ||
9 | segfault due to invalid pointers. Adding checks to ensure | ||
10 | pointers/lists are initialized before attempting to use them prevents | ||
11 | these segfaults. | ||
12 | |||
13 | Link: http://lkml.kernel.org/r/1333653586-3379-2-git-send-email-mark.asselstine@windriver.com | ||
14 | |||
15 | Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com> | ||
16 | Signed-off-by: Steven Rostedt <rostedt@goodmis.org> | ||
17 | --- | ||
18 | trace-input.c | 12 +++++++++--- | ||
19 | 1 file changed, 9 insertions(+), 3 deletions(-) | ||
20 | |||
21 | diff --git a/trace-input.c b/trace-input.c | ||
22 | index b6af1e6..5151c1e 100644 | ||
23 | --- a/trace-input.c | ||
24 | +++ b/trace-input.c | ||
25 | @@ -695,7 +695,8 @@ static void __free_page(struct tracecmd_input *handle, struct page *page) | ||
26 | |||
27 | static void free_page(struct tracecmd_input *handle, int cpu) | ||
28 | { | ||
29 | - if (!handle->cpu_data[cpu].page) | ||
30 | + if (!handle->cpu_data || cpu >= handle->cpus || | ||
31 | + !handle->cpu_data[cpu].page) | ||
32 | return; | ||
33 | |||
34 | __free_page(handle, handle->cpu_data[cpu].page); | ||
35 | @@ -746,8 +747,12 @@ void tracecmd_record_ref(struct record *record) | ||
36 | |||
37 | static void free_next(struct tracecmd_input *handle, int cpu) | ||
38 | { | ||
39 | - struct record *record = handle->cpu_data[cpu].next; | ||
40 | + struct record *record; | ||
41 | + | ||
42 | + if (!handle->cpu_data || cpu >= handle->cpus) | ||
43 | + return; | ||
44 | |||
45 | + record = handle->cpu_data[cpu].next; | ||
46 | if (!record) | ||
47 | return; | ||
48 | |||
49 | @@ -2337,7 +2342,8 @@ void tracecmd_close(struct tracecmd_input *handle) | ||
50 | /* The tracecmd_peek_data may have cached a record */ | ||
51 | free_next(handle, cpu); | ||
52 | free_page(handle, cpu); | ||
53 | - if (!list_empty(&handle->cpu_data[cpu].pages)) | ||
54 | + if (handle->cpu_data && | ||
55 | + !list_empty(&handle->cpu_data[cpu].pages)) | ||
56 | warning("pages still allocated on cpu %d%s", | ||
57 | cpu, show_records(&handle->cpu_data[cpu].pages)); | ||
58 | } | ||
59 | -- | ||
60 | 1.7.10.4 | ||
61 | |||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch new file mode 100644 index 0000000000..4c00c512bb --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch | |||
@@ -0,0 +1,38 @@ | |||
1 | From 356dee73d9ced3e019dea2883a7f357fd4664b3e Mon Sep 17 00:00:00 2001 | ||
2 | From: Mark Asselstine <mark.asselstine@windriver.com> | ||
3 | Date: Thu, 5 Apr 2012 15:19:45 -0400 | ||
4 | Subject: [PATCH] trace-cmd: Do not call stop_threads() if doing latency | ||
5 | tracing | ||
6 | |||
7 | Upstream-Status: Backport | ||
8 | |||
9 | If we are using a latency tracer we do not call start_threads() we | ||
10 | should therefore not call stop_threads() if 'latency'. Attempting | ||
11 | to call stop_threads() without first calling start_threads() will | ||
12 | cause a segfault since pids will be uninitialized. | ||
13 | |||
14 | Link: http://lkml.kernel.org/r/1333653586-3379-3-git-send-email-mark.asselstine@windriver.com | ||
15 | |||
16 | Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com> | ||
17 | Signed-off-by: Steven Rostedt <rostedt@goodmis.org> | ||
18 | --- | ||
19 | trace-record.c | 3 ++- | ||
20 | 1 file changed, 2 insertions(+), 1 deletion(-) | ||
21 | |||
22 | diff --git a/trace-record.c b/trace-record.c | ||
23 | index fcec28b..1c56fa9 100644 | ||
24 | --- a/trace-record.c | ||
25 | +++ b/trace-record.c | ||
26 | @@ -2216,7 +2216,8 @@ void trace_record (int argc, char **argv) | ||
27 | } | ||
28 | |||
29 | disable_tracing(); | ||
30 | - stop_threads(); | ||
31 | + if (!latency) | ||
32 | + stop_threads(); | ||
33 | } | ||
34 | |||
35 | for (cpu = 0; cpu < cpu_count; cpu++) { | ||
36 | -- | ||
37 | 1.7.10.4 | ||
38 | |||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch new file mode 100644 index 0000000000..724e1e80b1 --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch | |||
@@ -0,0 +1,96 @@ | |||
1 | From d65740d61e7a4ea6d8d77237954b33dd18e3276c Mon Sep 17 00:00:00 2001 | ||
2 | From: Mark Asselstine <mark.asselstine@windriver.com> | ||
3 | Date: Sun, 8 Apr 2012 11:38:45 -0400 | ||
4 | Subject: [PATCH] trace-cmd: Setting plugin to 'nop' clears data before it's | ||
5 | recorded | ||
6 | |||
7 | Upstream-Status: Backport | ||
8 | |||
9 | commit e09a5db1a929ab668c273b87c4f0a32b81e1c21a | ||
10 | [trace-cmd: Add trace-cmd record --date option] | ||
11 | |||
12 | moved the call to disable_all() in trace_record() from after record_data() | ||
13 | to before it. Unfortunately disable_all() sets 'nop' in 'current_tracer' | ||
14 | which has the side affect of clearing 'trace', thus all the latency tracer | ||
15 | reports are empty/useless. Here we make disable_all() optionally call | ||
16 | set_plugin() thus, where we need to, we can delay the disabling of the tracer | ||
17 | until we have had a chance to capture 'trace'. We have added this delayed | ||
18 | behavior to trace_record() to fix the latency reports, for all other calls to | ||
19 | disable_all() we continue to have set_plugin() called. | ||
20 | |||
21 | Link: http://lkml.kernel.org/r/1333899525-6436-1-git-send-email-mark.asselstine@windriver.com | ||
22 | |||
23 | Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com> | ||
24 | Signed-off-by: Steven Rostedt <rostedt@goodmis.org> | ||
25 | --- | ||
26 | trace-record.c | 16 ++++++++++------ | ||
27 | 1 file changed, 10 insertions(+), 6 deletions(-) | ||
28 | |||
29 | diff --git a/trace-record.c b/trace-record.c | ||
30 | index 1c56fa9..95d4a2a 100644 | ||
31 | --- a/trace-record.c | ||
32 | +++ b/trace-record.c | ||
33 | @@ -897,11 +897,13 @@ static void disable_tracing(void) | ||
34 | write_tracing_on(0); | ||
35 | } | ||
36 | |||
37 | -static void disable_all(void) | ||
38 | +static void disable_all(int disable_tracer) | ||
39 | { | ||
40 | disable_tracing(); | ||
41 | |||
42 | - set_plugin("nop"); | ||
43 | + if (disable_tracer) | ||
44 | + set_plugin("nop"); | ||
45 | + | ||
46 | reset_events(); | ||
47 | |||
48 | /* Force close and reset of ftrace pid file */ | ||
49 | @@ -1573,7 +1575,7 @@ static void set_funcs(void) | ||
50 | /* make sure we are filtering functions */ | ||
51 | if (func_stack) { | ||
52 | if (!functions_filtered()) { | ||
53 | - disable_all(); | ||
54 | + disable_all(1); | ||
55 | die("Function stack trace set, but functions not filtered"); | ||
56 | } | ||
57 | save_option(FUNC_STACK_TRACE); | ||
58 | @@ -1938,7 +1940,7 @@ void trace_record (int argc, char **argv) | ||
59 | break; | ||
60 | } | ||
61 | } | ||
62 | - disable_all(); | ||
63 | + disable_all(1); | ||
64 | set_buffer_size(); | ||
65 | exit(0); | ||
66 | } else | ||
67 | @@ -2147,7 +2149,7 @@ void trace_record (int argc, char **argv) | ||
68 | |||
69 | if (!extract) { | ||
70 | fset = set_ftrace(!disable); | ||
71 | - disable_all(); | ||
72 | + disable_all(1); | ||
73 | |||
74 | /* Record records the date first */ | ||
75 | if (record && date) | ||
76 | @@ -2227,7 +2229,7 @@ void trace_record (int argc, char **argv) | ||
77 | } | ||
78 | |||
79 | if (!keep) | ||
80 | - disable_all(); | ||
81 | + disable_all(0); | ||
82 | |||
83 | printf("Kernel buffer statistics:\n" | ||
84 | " Note: \"entries\" are the entries left in the kernel ring buffer and are not\n" | ||
85 | @@ -2249,6 +2251,8 @@ void trace_record (int argc, char **argv) | ||
86 | if (keep) | ||
87 | exit(0); | ||
88 | |||
89 | + set_plugin("nop"); | ||
90 | + | ||
91 | /* If tracing_on was enabled before we started, set it on now */ | ||
92 | if (tracing_on_init_val) | ||
93 | write_tracing_on(tracing_on_init_val); | ||
94 | -- | ||
95 | 1.7.10.4 | ||
96 | |||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-fix-syntax-error-of-shell.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-fix-syntax-error-of-shell.patch new file mode 100644 index 0000000000..b1ebf49830 --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-fix-syntax-error-of-shell.patch | |||
@@ -0,0 +1,30 @@ | |||
1 | trace-cmd: fix syntax error of shell | ||
2 | |||
3 | Delete "<<<" syntax of bash in Makefile, else we would get following error: | ||
4 | |||
5 | Syntax error: redirection unexpected | ||
6 | |||
7 | Upstream-status: Pending | ||
8 | |||
9 | Signed-off-by: Chong Lu <Chong.Lu@windriver.com> | ||
10 | --- | ||
11 | Makefile | 3 +-- | ||
12 | 1 file changed, 1 insertion(+), 2 deletions(-) | ||
13 | |||
14 | diff --git a/Makefile b/Makefile | ||
15 | index c1fa906..7973c53 100644 | ||
16 | --- a/Makefile | ||
17 | +++ b/Makefile | ||
18 | @@ -89,8 +89,7 @@ endif | ||
19 | |||
20 | # $(call test-build, snippet, ret) -> ret if snippet compiles | ||
21 | # -> empty otherwise | ||
22 | -test-build = $(if $(shell $(CC) -o /dev/null -c -x c - > /dev/null 2>&1 \ | ||
23 | - <<<'$1' && echo y), $2) | ||
24 | +test-build = $(if $(shell echo '$1' |$(CC) -o /dev/null -c -x c - > /dev/null 2>&1 && echo y), $2) | ||
25 | |||
26 | # have udis86 disassembler library? | ||
27 | udis86-flags := $(call test-build,\#include <udis86.h>,-DHAVE_UDIS86 -ludis86) | ||
28 | -- | ||
29 | 1.7.9.5 | ||
30 | |||
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd_1.2.bb b/meta/recipes-kernel/trace-cmd/trace-cmd_1.2.bb new file mode 100644 index 0000000000..a0c823bf62 --- /dev/null +++ b/meta/recipes-kernel/trace-cmd/trace-cmd_1.2.bb | |||
@@ -0,0 +1,31 @@ | |||
1 | SUMMARY = "User interface to Ftrace" | ||
2 | LICENSE = "GPLv2 & LGPLv2.1" | ||
3 | LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \ | ||
4 | file://trace-cmd.c;beginline=6;endline=8;md5=2c22c965a649ddd7973d7913c5634a5e \ | ||
5 | file://COPYING.LIB;md5=bbb461211a33b134d42ed5ee802b37ff \ | ||
6 | file://trace-input.c;beginline=5;endine=8;md5=6ad47cc2b03385d8456771eec5eeea0b" | ||
7 | |||
8 | SRCREV = "7055ffd37beeb44714e86a4abc703f7e175a0db5" | ||
9 | PR = "r3" | ||
10 | PV = "1.2+git${SRCPV}" | ||
11 | |||
12 | inherit pkgconfig pythonnative | ||
13 | |||
14 | SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git \ | ||
15 | file://addldflags.patch \ | ||
16 | file://make-docs-optional.patch \ | ||
17 | file://blktrace-api-compatibility.patch \ | ||
18 | file://trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch \ | ||
19 | file://trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch \ | ||
20 | file://trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch \ | ||
21 | file://trace-cmd-fix-syntax-error-of-shell.patch \ | ||
22 | " | ||
23 | S = "${WORKDIR}/git" | ||
24 | |||
25 | EXTRA_OEMAKE = "'prefix=${prefix}'" | ||
26 | |||
27 | FILES_${PN}-dbg += "${datadir}/trace-cmd/plugins/.debug/" | ||
28 | |||
29 | do_install() { | ||
30 | oe_runmake prefix="${prefix}" DESTDIR="${D}" install | ||
31 | } | ||