diff options
author | Masahiro Yamada <masahiroy@kernel.org> | 2020-04-29 05:45:22 +0200 |
---|---|---|
committer | Masahiro Yamada <masahiroy@kernel.org> | 2020-05-17 11:52:02 +0200 |
commit | 28949b84b2cb2473507ec2fed06728f995dd7942 (patch) | |
tree | 849d597e58bb9678e12f869a7cbc5cd97f87348b /samples/vfs/Makefile | |
parent | samples: connector: build sample program for target architecture (diff) | |
download | linux-28949b84b2cb2473507ec2fed06728f995dd7942.tar.xz linux-28949b84b2cb2473507ec2fed06728f995dd7942.zip |
samples: vfs: build sample programs for target architecture
These userspace programs include UAPI headers exported to usr/include/.
'make headers' always works for the target architecture (i.e. the same
architecture as the kernel), so the sample programs should be built for
the target as well. Kbuild now supports 'userprogs' for that.
I also guarded the CONFIG option by 'depends on CC_CAN_LINK' because
$(CC) may not provide libc.
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Diffstat (limited to '')
-rw-r--r-- | samples/vfs/Makefile | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/samples/vfs/Makefile b/samples/vfs/Makefile index 65acdde5c117..00b6824f9237 100644 --- a/samples/vfs/Makefile +++ b/samples/vfs/Makefile @@ -1,10 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -# List of programs to build -hostprogs := \ - test-fsmount \ - test-statx +userprogs := test-fsmount test-statx +always-y := $(userprogs) -always-y := $(hostprogs) - -HOSTCFLAGS_test-fsmount.o += -I$(objtree)/usr/include -HOSTCFLAGS_test-statx.o += -I$(objtree)/usr/include +userccflags += -I usr/include |