lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241219085803.1145606-3-lizhijian@fujitsu.com>
Date: Thu, 19 Dec 2024 16:58:03 +0800
From: Li Zhijian <lizhijian@...itsu.com>
To: linux-kselftest@...r.kernel.org,
	netdev@...r.kernel.org
Cc: linux-kernel@...r.kernel.org,
	davem@...emloft.net,
	Eric Dumazet <edumazet@...gle.com>,
	Paolo Abeni <pabeni@...hat.com>,
	Simon Horman <horms@...nel.org>,
	Shuah Khan <shuah@...nel.org>,
	Li Zhijian <lizhijian@...itsu.com>
Subject: [PATCH for-next 2/2] selftests/Makefile: add INSTALL_DEP_TARGETS to run_tests

Similar to the installation process, run_tests out-of-tree requires
copying TEST_FILES and TEST_INCLUDES to the OUTPUT directory.

The `net/lib` directory is a special case because it is a dependency for
`net`. Therefore, it should be processed before `net`.

This patch fixes the following error:
 $ make O=$build/ TARGETS=net kselftest V=1
  # selftests: net: rtnetlink.sh
  # lib.sh: line 5: $O/kselftest/net/lib/sh/defer.sh: No such file or directory
  # FAIL: cannot add dummy interface
  not ok 20 selftests: net: rtnetlink.sh # exit=1
  # timeout set to 3600
  # selftests: net: xfrm_policy.sh
  # lib.sh: line 5: $O/kselftest/net/lib/sh/defer.sh: No such file or directory

Signed-off-by: Li Zhijian <lizhijian@...itsu.com>
---
 tools/testing/selftests/Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/testing/selftests/Makefile b/tools/testing/selftests/Makefile
index fcaebd122d64..326dfd6ec497 100644
--- a/tools/testing/selftests/Makefile
+++ b/tools/testing/selftests/Makefile
@@ -206,8 +206,9 @@ all:
 	done; exit $$ret;
 
 run_tests: all
-	@for TARGET in $(TARGETS); do \
+	@for TARGET in $(INSTALL_DEP_TARGETS) $(TARGETS); do \
 		BUILD_TARGET=$$BUILD/$$TARGET;	\
+		mkdir -p $$BUILD_TARGET;	\
 		$(MAKE) OUTPUT=$$BUILD_TARGET -C $$TARGET run_tests \
 				SRC_PATH=$(shell readlink -e $$(pwd)) \
 				OBJ_PATH=$(BUILD)                   \
-- 
2.44.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ