Fix kselftest builds when specifying an output dir
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest2 patches 1 replyIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | selftests: Fix kselftest O=objdir build from cluttering top level objdirtools/ | +2 | 0 replies | |
| 2/2 | selftests: set the BUILD variable to absolute pathtools/ | +17 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 5.4 0/2] Fix kselftest builds when specifying an output dir
From: "Tyler Hicks" <[email protected]>
When attempting to build kselftests with a separate output directory, a number of the tests fail to build.
For example,
$ rm -rf build && \ make INSTALL_HDR_PATH=build/usr headers_install > /dev/null && \ make O=build FORCE_TARGETS=1 TARGETS=breakpoints -C tools/testing/selftests > /dev/null /usr/bin/ld: cannot open output file build/kselftest/breakpoints/step_after_suspend_test: No such file or directory collect2: error: ld returned 1 exit status make[1]: *** [../lib.mk:146: build/kselftest/breakpoints/step_after_suspend_test] Error 1 make: *** [Makefile:163: all] Error 2
This has already been addressed upstream with v5.18 commit 5ad51ab618de ("selftests: set the BUILD variable to absolute path"). It does not cleanly cherry pick to the linux-5.4.y branch without v5.7 commit 29e911ef7b70 ("selftests: Fix kselftest O=objdir build from cluttering top level objdir"). Commit 5ad51ab618de was written in a way that assumes that the kselftests aren't build in the top level objdir so it makes sense to bring the pre-req commit back but it does represent a slight change in behavior since the kselftests will now be built in a subdir of the specified objdir (O=).
Tyler
Muhammad Usama Anjum (1):
selftests: set the BUILD variable to absolute path
Shuah Khan (1):
selftests: Fix kselftest O=objdir build from cluttering top level
objdir
tools/testing/selftests/Makefile | 28 ++++++++++++++++++---------- 1 file changed, 18 insertions(+), 10 deletions(-)
Signature · 1 line
2.34.1