diff options
| author | Yi Zhao <yi.zhao@windriver.com> | 2026-01-10 21:38:08 +0800 |
|---|---|---|
| committer | Khem Raj <raj.khem@gmail.com> | 2026-01-12 10:25:55 -0800 |
| commit | 60e60fed31dbef0f494f8f10ab6fbb10c447ce0a (patch) | |
| tree | 9823d5d4364f870369aa50f0f0063ec4237ad8d3 | |
| parent | fea43ed974e97dc2c678106595e2970ad795626c (diff) | |
| download | meta-openembedded-60e60fed31dbef0f494f8f10ab6fbb10c447ce0a.tar.gz | |
nanomsg: add ptest
Ptest results:
$ run-ptest
PASS: async_shutdown
PASS: block
PASS: bug328
PASS: bug777
PASS: bus
PASS: cmsg
PASS: device
PASS: device4
PASS: device5
PASS: device6
PASS: device7
PASS: domain
PASS: emfile
PASS: hash
PASS: inproc
PASS: inproc_shutdown
PASS: iovec
PASS: ipc
PASS: ipc_shutdown
PASS: ipc_stress
PASS: list
PASS: msg
PASS: pair
PASS: pipeline
PASS: poll
PASS: prio
PASS: pubsub
PASS: reqrep
PASS: reqttl
PASS: separation
PASS: shutdown
PASS: stats
PASS: survey
PASS: surveyttl
PASS: symbol
PASS: tcp
PASS: tcp_shutdown
PASS: term
PASS: timeo
PASS: trie
PASS: ws
PASS: ws_async_shutdown
PASS: zerocopy
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
| -rw-r--r-- | meta-networking/recipes-connectivity/nanomsg/nanomsg/run-ptest | 16 | ||||
| -rw-r--r-- | meta-networking/recipes-connectivity/nanomsg/nanomsg_1.2.2.bb | 17 |
2 files changed, 31 insertions, 2 deletions
diff --git a/meta-networking/recipes-connectivity/nanomsg/nanomsg/run-ptest b/meta-networking/recipes-connectivity/nanomsg/nanomsg/run-ptest new file mode 100644 index 0000000000..447867aedb --- /dev/null +++ b/meta-networking/recipes-connectivity/nanomsg/nanomsg/run-ptest | |||
| @@ -0,0 +1,16 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | |||
| 3 | RET=0 | ||
| 4 | cd tests | ||
| 5 | |||
| 6 | for t in $(ls *); do | ||
| 7 | ./$t | ||
| 8 | if [ $? -eq 0 ]; then | ||
| 9 | echo PASS: $t | ||
| 10 | else | ||
| 11 | echo FAIL: $t | ||
| 12 | RET=1 | ||
| 13 | fi | ||
| 14 | done | ||
| 15 | |||
| 16 | exit $RET | ||
diff --git a/meta-networking/recipes-connectivity/nanomsg/nanomsg_1.2.2.bb b/meta-networking/recipes-connectivity/nanomsg/nanomsg_1.2.2.bb index 10ae7a61d7..f291326c80 100644 --- a/meta-networking/recipes-connectivity/nanomsg/nanomsg_1.2.2.bb +++ b/meta-networking/recipes-connectivity/nanomsg/nanomsg_1.2.2.bb | |||
| @@ -10,19 +10,32 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=587b3fd7fd291e418ff4d2b8f3904755" | |||
| 10 | SECTION = "libs/networking" | 10 | SECTION = "libs/networking" |
| 11 | 11 | ||
| 12 | SRC_URI = "git://github.com/nanomsg/nanomsg.git;protocol=https;branch=master \ | 12 | SRC_URI = "git://github.com/nanomsg/nanomsg.git;protocol=https;branch=master \ |
| 13 | file://run-ptest \ | ||
| 13 | " | 14 | " |
| 14 | 15 | ||
| 15 | SRCREV = "ccd7f20c1b756f7041598383baffcdc326246db7" | 16 | SRCREV = "ccd7f20c1b756f7041598383baffcdc326246db7" |
| 16 | 17 | ||
| 17 | inherit cmake pkgconfig | 18 | inherit cmake pkgconfig ptest |
| 18 | 19 | ||
| 19 | # nanomsg documentation generation requires asciidoctor, | 20 | # nanomsg documentation generation requires asciidoctor, |
| 20 | # not asciidoc, and currently there's no asciidoctor-native | 21 | # not asciidoc, and currently there's no asciidoctor-native |
| 21 | # recipe anywhere in openembedded-core or meta-openembedded | 22 | # recipe anywhere in openembedded-core or meta-openembedded |
| 22 | EXTRA_OECMAKE = " -DNN_ENABLE_DOC=OFF " | 23 | EXTRA_OECMAKE = " -DNN_ENABLE_DOC=OFF \ |
| 24 | ${@bb.utils.contains('PTEST_ENABLED', '1', '-DNN_TESTS=ON', '', d)} \ | ||
| 25 | " | ||
| 23 | 26 | ||
| 24 | # we don't want nanomsg-tools to be renamed to libnanomsg-tools | 27 | # we don't want nanomsg-tools to be renamed to libnanomsg-tools |
| 25 | DEBIAN_NOAUTONAME:${PN}-tools = "1" | 28 | DEBIAN_NOAUTONAME:${PN}-tools = "1" |
| 26 | 29 | ||
| 30 | do_install_ptest(){ | ||
| 31 | install -d ${D}/${PTEST_PATH}/tests | ||
| 32 | find ${B} -maxdepth 1 -type f -executable \ | ||
| 33 | ! -name "*_lat" \ | ||
| 34 | ! -name "*_thr" \ | ||
| 35 | ! -name "nanocat" \ | ||
| 36 | ! -name "libnanomsg.so*" \ | ||
| 37 | -exec install {} ${D}${PTEST_PATH}/tests/ \; | ||
| 38 | } | ||
| 39 | |||
| 27 | PACKAGES =+ "${PN}-tools" | 40 | PACKAGES =+ "${PN}-tools" |
| 28 | FILES:${PN}-tools = "${bindir}/*" | 41 | FILES:${PN}-tools = "${bindir}/*" |
