[source] kernel: prevent adding custom string to localversion

LEDE Commits lede-commits at lists.infradead.org
Thu Aug 18 00:49:34 PDT 2016


blogic pushed a commit to source.git, branch master:
https://git.lede-project.org/?p=source.git;a=commitdiff;h=57ef81d78f590c86aaebeb41c14528b33b73db94

commit 57ef81d78f590c86aaebeb41c14528b33b73db94
Author: Josua Mayer <josua.mayer97 at gmail.com>
AuthorDate: Wed Aug 17 16:18:04 2016 +0200

    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 at gmail.com>
---
 include/kernel-defaults.mk | 1 +
 1 file changed, 1 insertion(+)

diff --git a/include/kernel-defaults.mk b/include/kernel-defaults.mk
index 47befba..bae8cd0 100644
--- a/include/kernel-defaults.mk
+++ b/include/kernel-defaults.mk
@@ -111,6 +111,7 @@ define Kernel/SetNoInitramfs
 endef
 
 define Kernel/Configure/Default
+	rm -f $(LINUX_DIR)/localversion
 	$(LINUX_CONF_CMD) > $(LINUX_DIR)/.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



More information about the lede-commits mailing list