diff options
Diffstat (limited to 'meta/recipes-kernel/lttng/babeltrace_1.5.11.bb')
-rw-r--r-- | meta/recipes-kernel/lttng/babeltrace_1.5.11.bb | 98 |
1 files changed, 98 insertions, 0 deletions
diff --git a/meta/recipes-kernel/lttng/babeltrace_1.5.11.bb b/meta/recipes-kernel/lttng/babeltrace_1.5.11.bb new file mode 100644 index 0000000000..f4d9b5e42a --- /dev/null +++ b/meta/recipes-kernel/lttng/babeltrace_1.5.11.bb | |||
@@ -0,0 +1,98 @@ | |||
1 | SUMMARY = "Babeltrace - Trace Format Babel Tower" | ||
2 | DESCRIPTION = "Babeltrace provides trace read and write libraries in host side, as well as a trace converter, which used to convert LTTng 2.0 traces into human-readable log." | ||
3 | HOMEPAGE = "http://babeltrace.org/" | ||
4 | BUGTRACKER = "https://bugs.lttng.org/projects/babeltrace" | ||
5 | LICENSE = "MIT & GPL-2.0-only & LGPL-2.1-only" | ||
6 | LIC_FILES_CHKSUM = "file://LICENSE;md5=76ba15dd76a248e1dd526bca0e2125fa" | ||
7 | |||
8 | DEPENDS = "glib-2.0 util-linux popt bison-native flex-native" | ||
9 | |||
10 | SRC_URI = "git://git.efficios.com/babeltrace.git;branch=stable-1.5;protocol=https \ | ||
11 | file://run-ptest \ | ||
12 | " | ||
13 | SRCREV = "91c00f70884887ff5c4849a8e3d47e311a22ba9d" | ||
14 | UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>1(\.\d+)+)$" | ||
15 | |||
16 | S = "${WORKDIR}/git" | ||
17 | |||
18 | inherit autotools pkgconfig ptest | ||
19 | |||
20 | EXTRA_OECONF = "--disable-debug-info" | ||
21 | |||
22 | ASNEEDED = "" | ||
23 | |||
24 | RDEPENDS:${PN}-ptest += "bash gawk make" | ||
25 | |||
26 | addtask do_patch_ptest_path after do_patch before do_configure | ||
27 | do_patch_ptest_path () { | ||
28 | for f in $(grep -l -r abs_top_srcdir ${S}/tests); do | ||
29 | sed -i 's:\@abs_top_srcdir\@:${PTEST_PATH}:' ${f} | ||
30 | done | ||
31 | |||
32 | for f in $(grep -l -r abs_top_builddir ${S}/tests); do | ||
33 | sed -i 's:\@abs_top_builddir\@:${PTEST_PATH}:' ${f} | ||
34 | done | ||
35 | for f in $(grep -l -r GREP ${S}/tests); do | ||
36 | sed -i 's:\@GREP\@:grep:' ${f} | ||
37 | done | ||
38 | |||
39 | for f in $(grep -l -r SED ${S}/tests); do | ||
40 | sed -i 's:\@SED\@:sed:' ${f} | ||
41 | done | ||
42 | } | ||
43 | |||
44 | do_compile_ptest () { | ||
45 | make -C tests all | ||
46 | } | ||
47 | |||
48 | do_install_ptest () { | ||
49 | # Copy required files from source directory | ||
50 | for f in config/tap-driver.sh config/test-driver; do | ||
51 | install -D "${S}/$f" "${D}${PTEST_PATH}/$f" | ||
52 | done | ||
53 | install -d "$f" "${D}${PTEST_PATH}/tests/ctf-traces/" | ||
54 | cp -a ${S}/tests/ctf-traces/* ${D}${PTEST_PATH}/tests/ctf-traces/ | ||
55 | |||
56 | # Copy the tests directory tree and the executables and | ||
57 | # Makefiles found within. | ||
58 | install -D "${B}/tests/Makefile" "${D}${PTEST_PATH}/tests/" | ||
59 | for d in $(find "${B}/tests" -type d -not -name .libs -printf '%P ') ; do | ||
60 | install -d "${D}${PTEST_PATH}/tests/$d" | ||
61 | find "${B}/tests/$d" -maxdepth 1 -executable -type f \ | ||
62 | -exec install -t "${D}${PTEST_PATH}/tests/$d" {} + | ||
63 | test -r "${B}/tests/$d/Makefile" && \ | ||
64 | install -t "${D}${PTEST_PATH}/tests/$d" "${B}/tests/$d/Makefile" | ||
65 | find "${B}/tests/$d" -maxdepth 1 -name *.sh \ | ||
66 | -exec install -t "${D}${PTEST_PATH}/tests/$d" {} \; | ||
67 | done | ||
68 | |||
69 | for d in $(find "${B}/tests" -type d -name .libs -printf '%P ') ; do | ||
70 | for f in $(find "${B}/tests/$d" -maxdepth 1 -executable -type f -printf '%P ') ; do | ||
71 | cp ${B}/tests/$d/$f ${D}${PTEST_PATH}/tests/`dirname $d`/$f | ||
72 | done | ||
73 | done | ||
74 | |||
75 | install -D ${B}/formats/ctf/metadata/.libs/ctf-parser-test \ | ||
76 | ${D}${PTEST_PATH}/formats/ctf/metadata/ctf-parser-test | ||
77 | |||
78 | # Prevent attempts to update Makefiles during test runs, and | ||
79 | # silence "Making check in $SUBDIR" messages. | ||
80 | find "${D}${PTEST_PATH}" -name Makefile -type f -exec \ | ||
81 | sed -i \ | ||
82 | -e '/Makefile:/,/^$/d' \ | ||
83 | -e '/$(check_SCRIPTS)/s/^/#/' \ | ||
84 | -e '/%: %.in/,/^$/d' \ | ||
85 | -e '/echo "Making $$target in $$subdir"; \\/d' \ | ||
86 | -e 's/^srcdir = \(.*\)/srcdir = ./' \ | ||
87 | -e 's/^builddir = \(.*\)/builddir = ./' \ | ||
88 | -e 's/^all-am:.*/all-am:/' \ | ||
89 | {} + | ||
90 | |||
91 | # Remove path to babeltrace. | ||
92 | for f in $(grep -l -r "^BABELTRACE_BIN" ${D}${PTEST_PATH}); do | ||
93 | sed -i 's:^BABELTRACE_BIN.*:BABELTRACE_BIN=/usr/bin/babeltrace:' ${f} | ||
94 | done | ||
95 | for f in $(grep -l -r "^BTBIN" ${D}${PTEST_PATH}); do | ||
96 | sed -i 's:^BTBIN.*:BTBIN=/usr/bin/babeltrace:' ${f} | ||
97 | done | ||
98 | } | ||