kernel-defaults: Delete external source tree user_headers

When we use an external kernel tree which may not have been fully
cleaned, there may be user_headers left which do not match the target
architecture, leading to build failures for packages that do an explicit
inclusion of user_headers (such as iproute2 or iptables). Make sure we
delete them while preparing the directory.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
This commit is contained in:
Florian Fainelli 2020-09-12 17:09:53 -07:00 committed by CN_SZTL
parent 33e4a1c124
commit 4f494164cb
No known key found for this signature in database
GPG Key ID: 6850B6345C862176

View File

@ -46,6 +46,7 @@ else
rmdir $(LINUX_DIR); \
fi
ln -s $(CONFIG_EXTERNAL_KERNEL_TREE) $(LINUX_DIR)
$(_SINGLE) [ -d $(LINUX_DIR)/user_headers ] && rm -rf $(LINUX_DIR)/user_headers
endef
endif