backports: Keep kconf/zconf.{lex,tab}.c during "make clean"
diff mbox series

Message ID 20190622085053.6709-1-yp@anthonywong.net
State New
Headers show
Series
  • backports: Keep kconf/zconf.{lex,tab}.c during "make clean"
Related show

Commit Message

Anthony Wong June 22, 2019, 8:50 a.m. UTC
From: Anthony Wong <yp@anthonywong.net>

On recent kernel versions, build fails after "make clean" is run
because "make clean" removes kconf/zconf.{lex,tab}.c, so presesrve
them during "make clean".

Signed-off-by: Anthony Wong <yp@anthonywong.net>
---
 backport/Makefile.real | 3 +++
 1 file changed, 3 insertions(+)

Patch
diff mbox series

diff --git a/backport/Makefile.real b/backport/Makefile.real
index 65508028..e772a9cf 100644
--- a/backport/Makefile.real
+++ b/backport/Makefile.real
@@ -115,7 +115,10 @@  uninstall:
 	@echo Reboot.
 	@echo
 
+EXCLUDE_CLEAN := kconf/zconf.lex.c kconf/zconf.tab.c
 .PHONY: clean
 clean:
+	@$(foreach f, $(EXCLUDE_CLEAN), mv $(f) $(f).orig;)
 	@$(MAKE) -f Makefile.build clean
 	@$(MAKE) -C kconf clean
+	@$(foreach f, $(EXCLUDE_CLEAN), mv $(f).orig $(f);)