mbox series

[v2,0/3] selftests/nolibc: add misc improvments

Message ID cover.1691215074.git.falcon@tinylab.org (mailing list archive)
Headers show
Series selftests/nolibc: add misc improvments | expand

Message

Zhangjin Wu Aug. 5, 2023, 6:09 a.m. UTC
Hi, Willy, Hi Thomas

Based on Thomas' suggestion, V2 comes here with relative path support
for O= option, v1 is [1].

    // subdir
    $ pwd
    /labs/linux-lab/src/linux-stable/tools/testing/selftests/nolibc
    $ mkdir -p out
    $ make run-user O=out -C /labs/linux-lab/src/linux-stable/tools/testing/selftests/nolibc/ -j4 | grep status
    Makefile:122: srctree=/labs/linux-lab/src/linux-stable
    Makefile:123: objtree: out
    Makefile:124: COMMAND_O: O=/labs/linux-lab/src/linux-stable/tools/testing/selftests/nolibc/out
    Makefile:125: OUTPUT=/labs/linux-lab/src/linux-stable/tools/testing/selftests/nolibc/out/
    166 test(s): 158 passed,   8 skipped,   0 failed => status: warning

    // topdir
    $ pwd
    /labs/linux-lab/src/linux-stable
    $ mkdir -p out
    $ make run-user O=out -C /labs/linux-lab/src/linux-stable/tools/testing/selftests/nolibc/ -j4 | grep status
    Makefile:122: srctree=/labs/linux-lab/src/linux-stable
    Makefile:123: objtree: out
    Makefile:124: COMMAND_O: O=/labs/linux-lab/src/linux-stable/out
    Makefile:125: OUTPUT=/labs/linux-lab/src/linux-stable/out/
    166 test(s): 158 passed,   8 skipped,   0 failed => status: warning

    // outside
    $ pwd
    /labs/linux-lab/build
    $ mkdir -p out
    $ make run-user O=out -C /labs/linux-lab/src/linux-stable/tools/testing/selftests/nolibc/ -j4 | grep status
    Makefile:122: srctree=/labs/linux-lab/src/linux-stable
    Makefile:123: objtree: out
    Makefile:124: COMMAND_O: O=/labs/linux-lab/build/out
    Makefile:125: OUTPUT=/labs/linux-lab/build/out/
    166 test(s): 158 passed,   8 skipped,   0 failed => status: warning

Changes from v1 --> v2:

* selftests/nolibc: allow report with existing test log
  tools/nolibc: stackprotector.h: make __stack_chk_init static

    Add Reviewed-by line from Thomas

* selftests/nolibc: fix up O= option support

    Now with relative path support with the help of $(COMMAND_O).

    Suggested by Thomas.

Thanks!
Zhangjin
---
[1]: https://lore.kernel.org/lkml/cover.1691073180.git.falcon@tinylab.org/

Zhangjin Wu (3):
  selftests/nolibc: allow report with existing test log
  tools/nolibc: stackprotector.h: make __stack_chk_init static
  selftests/nolibc: fix up O= option support

 tools/include/nolibc/crt.h              |  2 +-
 tools/include/nolibc/stackprotector.h   |  5 ++---
 tools/testing/selftests/nolibc/Makefile | 19 +++++++++++++------
 3 files changed, 16 insertions(+), 10 deletions(-)