From c7d84e7ff5a651d186a6ec41361c4f07acc2fb9c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andr=C3=A9=20Almeida?= Date: Tue, 27 Apr 2021 10:53:27 -0300 Subject: [PATCH] selftests: futex: Correctly include headers dirs MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit When building selftests, the build system will install uapi linux headers at usr/include in kernel source's root directory. When building with a different output folder, the headers will be installed at kselftests/usr/include. Add both paths so we can build the tests using up-to-date headers. Currently, this is uncommon to happen since it's rare to find a build system with an outdated futex header, but it happens when testing new futex operations. Signed-off-by: André Almeida Signed-off-by: Ingo Molnar Link: https://lore.kernel.org/r/20210427135328.11013-2-andrealmeid@collabora.com --- tools/testing/selftests/futex/functional/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/testing/selftests/futex/functional/Makefile b/tools/testing/selftests/futex/functional/Makefile index 23207829ec752..1d2b3b2a5b86b 100644 --- a/tools/testing/selftests/futex/functional/Makefile +++ b/tools/testing/selftests/futex/functional/Makefile @@ -1,5 +1,6 @@ # SPDX-License-Identifier: GPL-2.0 -INCLUDES := -I../include -I../../ +INCLUDES := -I../include -I../../ -I../../../../../usr/include/ \ + -I$(KBUILD_OUTPUT)/kselftest/usr/include CFLAGS := $(CFLAGS) -g -O2 -Wall -D_GNU_SOURCE -pthread $(INCLUDES) LDLIBS := -lpthread -lrt -- 2.39.5