diff --git a/samples/Kconfig b/samples/Kconfig index 9d236c346de506dfcf65cba58dbec3507659bc18..205076cf234ee12a91fc86ffe9b12f718049fb81 100644 --- a/samples/Kconfig +++ b/samples/Kconfig @@ -171,7 +171,7 @@ config SAMPLE_VFIO_MDEV_MBOCHS config SAMPLE_ANDROID_BINDERFS bool "Build Android binderfs example" - depends on CONFIG_ANDROID_BINDERFS + depends on ANDROID_BINDERFS help Builds a sample program to illustrate the use of the Android binderfs filesystem. diff --git a/samples/binderfs/Makefile b/samples/binderfs/Makefile index ea4c93d362569e27b1ba194965bf39d892f42af4..a3ac5476338a47bbf54a467b0498a32b19574692 100644 --- a/samples/binderfs/Makefile +++ b/samples/binderfs/Makefile @@ -1,2 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only -obj-$(CONFIG_SAMPLE_ANDROID_BINDERFS) += binderfs_example.o +ifndef CROSS_COMPILE +ifdef CONFIG_SAMPLE_ANDROID_BINDERFS +hostprogs := binderfs_example +endif +endif