kernel: prevent adding custom string to localversion

When the kernel build picks up a localversion file in the source tree,
that string is unconditionally appended to LOCALVERSION and affects the
uname string.
Make sure to delete any such file.

Signed-off-by: Josua Mayer <josua.mayer97@gmail.com>
This commit is contained in:
Josua Mayer 2016-08-17 16:18:04 +02:00 committed by John Crispin
parent 0df2c6563a
commit 57ef81d78f

View File

@ -111,6 +111,7 @@ define Kernel/SetNoInitramfs
endef endef
define Kernel/Configure/Default define Kernel/Configure/Default
rm -f $(LINUX_DIR)/localversion
$(LINUX_CONF_CMD) > $(LINUX_DIR)/.config.target $(LINUX_CONF_CMD) > $(LINUX_DIR)/.config.target
# copy CONFIG_KERNEL_* settings over to .config.target # copy CONFIG_KERNEL_* settings over to .config.target
awk '/^(#[[:space:]]+)?CONFIG_KERNEL/{sub("CONFIG_KERNEL_","CONFIG_");print}' $(TOPDIR)/.config >> $(LINUX_DIR)/.config.target awk '/^(#[[:space:]]+)?CONFIG_KERNEL/{sub("CONFIG_KERNEL_","CONFIG_");print}' $(TOPDIR)/.config >> $(LINUX_DIR)/.config.target