diff options
Diffstat (limited to 'meta/classes/ptest.bbclass')
-rw-r--r-- | meta/classes/ptest.bbclass | 35 |
1 files changed, 29 insertions, 6 deletions
diff --git a/meta/classes/ptest.bbclass b/meta/classes/ptest.bbclass index 131af7b0ef..6ab5ee411f 100644 --- a/meta/classes/ptest.bbclass +++ b/meta/classes/ptest.bbclass | |||
@@ -23,13 +23,36 @@ FILES_${PN}-dbg += "${PTEST_PATH}/.debug \ | |||
23 | ${PTEST_PATH}/*/*/*/*/.debug \ | 23 | ${PTEST_PATH}/*/*/*/*/.debug \ |
24 | " | 24 | " |
25 | 25 | ||
26 | ptest_do_install() { | 26 | do_configure_ptest_base() { |
27 | if [ "${PN}" = "${BPN}" -a ${PTEST_ENABLED} = "1" ]; then | 27 | if [ ${PTEST_ENABLED} = 1 ]; then |
28 | install -D ${WORKDIR}/run-ptest ${D}${PTEST_PATH}/run-ptest | 28 | if [ type -t do_configure_ptest = function ]; then |
29 | if grep -q install-ptest: Makefile; then | 29 | do_configure_ptest |
30 | oe_runmake DESTDIR=${D}${PTEST_PATH} install-ptest | ||
31 | fi | 30 | fi |
32 | fi | 31 | fi |
33 | } | 32 | } |
34 | 33 | ||
35 | EXPORT_FUNCTIONS ptest_do_install | 34 | do_compile_ptest_base() { |
35 | if [ ${PTEST_ENABLED} = 1 ]; then | ||
36 | if [ type -t do_compile_ptest = function ]; then | ||
37 | do_compile_ptest | ||
38 | fi | ||
39 | fi | ||
40 | } | ||
41 | |||
42 | do_install_ptest_base() { | ||
43 | if [ ${PTEST_ENABLED} = 1 ]; then | ||
44 | if [ -f ${WORKDIR}/run-ptest ]; then | ||
45 | install -D ${WORKDIR}/run-ptest ${D}${PTEST_PATH}/run-ptest | ||
46 | if grep -q install-ptest: Makefile; then | ||
47 | oe_runmake DESTDIR=${D}${PTEST_PATH} install-ptest | ||
48 | fi | ||
49 | if [ type -t do_install_ptest = function ]; then | ||
50 | do_install_ptest | ||
51 | fi | ||
52 | fi | ||
53 | fi | ||
54 | } | ||
55 | |||
56 | addtask configure_ptest_base after do_configure before do_compile | ||
57 | addtask compile_ptest_base after do_compile before do_install | ||
58 | addtask install_ptest_base after do_install before do_package | ||