From: Gabriel Krisman Bertazi Date: Thu, 28 Oct 2021 18:56:28 +0000 (-0300) Subject: samples: Make fs-monitor depend on libc and headers X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=8fc70b3a142f97f7859bf052151df896933d2586;p=linux.git samples: Make fs-monitor depend on libc and headers Prevent build errors when headers or libc are not available, such as on kernel build bots, like the below: samples/fanotify/fs-monitor.c:7:10: fatal error: errno.h: No such file or directory 7 | #include | ^~~~~~~~~ Link: https://lore.kernel.org/r/87fsslasgz.fsf@collabora.com Suggested-by: Guenter Roeck Tested-by: Guenter Roeck Signed-off-by: Gabriel Krisman Bertazi Signed-off-by: Jan Kara --- diff --git a/samples/Kconfig b/samples/Kconfig index 88353b8eac0b4..56539b21f2c73 100644 --- a/samples/Kconfig +++ b/samples/Kconfig @@ -122,7 +122,7 @@ config SAMPLE_CONNECTOR config SAMPLE_FANOTIFY_ERROR bool "Build fanotify error monitoring sample" - depends on FANOTIFY + depends on FANOTIFY && CC_CAN_LINK && HEADERS_INSTALL help When enabled, this builds an example code that uses the FAN_FS_ERROR fanotify mechanism to monitor filesystem