Check for kconfig.h presence, not just build dir (#3588)
This is a better check than just checking the presence of the build dir.
In Gentoo Linux, when you remove the kernel source package, the leftover
build directory is intentionally left in place. Which means the
/lib/modules/$(uname -r)/build symlink still remains valid, but there's
no kconfig.h there anymore[1]. This prevents bcc from using the kheaders
(/sys/kernel/kheaders.tar.xz) fallback, instead making it fail later on:
<built-in>:1:10: fatal error: './include/linux/kconfig.h' file not found
#include "./include/linux/kconfig.h"
^~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
[1] https://bugs.gentoo.org/809347
Signed-off-by: WGH <wgh@torlan.ru>