History

kbuild: fix mismatch between .version and include/generated/compile.h

Since commit 56d589361572 ("kbuild: do not create orphan built-in.a or obj-y objects"), scripts/link-vmlinux.sh does nothing when descending into init/. Once the version number becomes out of sync between .version and include/generated/compile.h, it is not self-healing. [How to reproduce] $ echo 100 > .version $ make You will see the number in the .version is always bigger than that in compile.h by one. After this, every time you run 'make', the vmlinux is re-linked even when none of source files is updated.

Masahiro Yamada committed 6 years ago

Commit 083bc0e1 parent 9d1b3891 file · +1 −1Browse files

Showing the changes to scripts (1 of 1 file). Show all

Unified · Split

scripts/link-vmlinux.sh+1−1
@@ -239,7 +239,7 @@ else · 238 unmodified lines
239239 fi;
240240
241241 # final build of init/
242−${MAKE} -f "${srctree}/scripts/Makefile.build" obj=init
242+${MAKE} -f "${srctree}/scripts/Makefile.build" obj=init need-builtin=1
243243
244244 #link vmlinux.o
245245 info LD vmlinux.o