diff options
| author | Dmitry Eremin-Solenikov <dmitry_eremin@mentor.com> | 2015-05-11 22:52:29 +0300 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-05-14 11:44:00 +0100 |
| commit | 13fb8554b739914bbb8055091212431c470267dd (patch) | |
| tree | 07d46e9be41d969f193b33dba97a43b21b754888 | |
| parent | 942ec74bad7c796363f334f031a927b76cfee420 (diff) | |
| download | poky-13fb8554b739914bbb8055091212431c470267dd.tar.gz | |
libevent: add ptest
Use provided regression testing as a ptest for libevent package.
(From OE-Core rev: d32fb4c50f73d169d7b9a238801aa72d77560135)
Signed-off-by: Dmitry Eremin-Solenikov <dmitry_eremin@mentor.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/recipes-support/libevent/libevent/run-ptest | 18 | ||||
| -rw-r--r-- | meta/recipes-support/libevent/libevent_2.0.22.bb | 17 |
2 files changed, 34 insertions, 1 deletions
diff --git a/meta/recipes-support/libevent/libevent/run-ptest b/meta/recipes-support/libevent/libevent/run-ptest new file mode 100644 index 0000000000..d521688e77 --- /dev/null +++ b/meta/recipes-support/libevent/libevent/run-ptest | |||
| @@ -0,0 +1,18 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | |||
| 3 | fail=0 | ||
| 4 | for test in ./test/* | ||
| 5 | do | ||
| 6 | $test | ||
| 7 | if [ $? -eq 0 ] | ||
| 8 | then | ||
| 9 | fail=1 | ||
| 10 | fi | ||
| 11 | done | ||
| 12 | |||
| 13 | if [ $fail -eq 0 ] | ||
| 14 | then | ||
| 15 | echo "PASS: libevent" | ||
| 16 | else | ||
| 17 | echo "FAIL: libevent" | ||
| 18 | fi | ||
diff --git a/meta/recipes-support/libevent/libevent_2.0.22.bb b/meta/recipes-support/libevent/libevent_2.0.22.bb index 3f9475ed75..2f492930d4 100644 --- a/meta/recipes-support/libevent/libevent_2.0.22.bb +++ b/meta/recipes-support/libevent/libevent_2.0.22.bb | |||
| @@ -6,7 +6,10 @@ SECTION = "libs" | |||
| 6 | LICENSE = "BSD" | 6 | LICENSE = "BSD" |
| 7 | LIC_FILES_CHKSUM = "file://LICENSE;md5=45c5316ff684bcfe2f9f86d8b1279559" | 7 | LIC_FILES_CHKSUM = "file://LICENSE;md5=45c5316ff684bcfe2f9f86d8b1279559" |
| 8 | 8 | ||
| 9 | SRC_URI = "${SOURCEFORGE_MIRROR}/levent/${BP}-stable.tar.gz" | 9 | SRC_URI = " \ |
| 10 | ${SOURCEFORGE_MIRROR}/levent/${BP}-stable.tar.gz \ | ||
| 11 | file://run-ptest \ | ||
| 12 | " | ||
| 10 | 13 | ||
| 11 | SRC_URI[md5sum] = "c4c56f986aa985677ca1db89630a2e11" | 14 | SRC_URI[md5sum] = "c4c56f986aa985677ca1db89630a2e11" |
| 12 | SRC_URI[sha256sum] = "71c2c49f0adadacfdbe6332a372c38cf9c8b7895bb73dabeaa53cdcc1d4e1fa3" | 15 | SRC_URI[sha256sum] = "71c2c49f0adadacfdbe6332a372c38cf9c8b7895bb73dabeaa53cdcc1d4e1fa3" |
| @@ -20,3 +23,15 @@ inherit autotools | |||
| 20 | 23 | ||
| 21 | # Needed for Debian packaging | 24 | # Needed for Debian packaging |
| 22 | LEAD_SONAME = "libevent-2.0.so" | 25 | LEAD_SONAME = "libevent-2.0.so" |
| 26 | |||
| 27 | inherit ptest | ||
| 28 | |||
| 29 | DEPENDS = "zlib" | ||
| 30 | |||
| 31 | do_install_ptest() { | ||
| 32 | install -d ${D}${PTEST_PATH}/test | ||
| 33 | for file in ${B}/test/.libs/regress ${B}/test/.libs/test* | ||
| 34 | do | ||
| 35 | install -m 0755 $file ${D}${PTEST_PATH}/test | ||
| 36 | done | ||
| 37 | } | ||
