No rule to make target `/mnt/md0/devel/linux-git/include/linux/version.h
Hi,
"make O=/dir" is brooken.
make[4]: *** No rule to make target /mnt/md0/devel/linux-git/include/linux/version.h', needed by /mnt/md0/devel/linux-git-obj/usr/include/linux/version.h'. Stop. make[3]: *** [linux] Error 2
make[2]: *** [headers_install] Error 2
make[1]: *** [vmlinux] Error 2
make: *** [_all] Error 2
Regards,
Michal
Signature · 3 lines
Michal K. K. Piotrowski LTG - Linux Testers Group (http://www.stardust.webpages.pl/ltg/)
RFC PATCH 1/1 kbuild: more headers_check fix for non-in-tree builds (was [BUG 2.6.19-rc2-g51018b0a] No rule to make target /mnt/md0/devel/linux-git/include/linux/version.h)
"'objhdr-y' are generated files", thus they are not in $(srctree). Kbuild.include already included in root Makefile.
--- scripts/Makefile.headersinst | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
scripts/Makefile.headersinst +1 -3
@@ -39,8 +39,6 @@ include $(KBUILDFILES) -include scripts/Kbuild.include - # If this is include/asm-$(ARCH) and there's no $(ALTARCH), then # override $(_dst) so that we install to include/asm directly. # Unless $(BIASMDIR) is set, in which case we're probably doing
@@ -168,7 +166,7 @@ $(call cmd,gen) else -$(objhdr-y) : $(INSTALL_HDR_PATH)/$(_dst)/%.h: $(srctree)/$(obj)/%.h $(KBUILDFILES) +$(objhdr-y) : $(INSTALL_HDR_PATH)/$(_dst)/%.h: $(obj)/%.h $(KBUILDFILES) $(call cmd,o_hdr_install) $(header-y) : $(INSTALL_HDR_PATH)/$(_dst)/%.h: $(srctree)/$(obj)/%.h $(KBUILDFILES)
PATCH 1/1 kbuild: Another 'headers*' fix for non in-tree build
In reply to Michal Piotrowski While it mostly work, version.h header *is* generated, thus resides in $(objtree), not $(srctree).
This broke headers_install, thus headers_check.
---
was [BUG 2.6.19-rc2-g51018b0a] No rule to make target
/mnt/md0/devel/linux-git/include/linux/version.h
by Michal Piotrowski <[email protected]>
Test it, please, Michal. I think this, non-rfc version, is OK for 2.6.19.
scripts/Makefile.headersinst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/Makefile.headersinst +1 -1
@@ -168,7 +168,7 @@ $(call cmd,gen) else -$(objhdr-y) : $(INSTALL_HDR_PATH)/$(_dst)/%.h: $(srctree)/$(obj)/%.h $(KBUILDFILES) +$(objhdr-y) : $(INSTALL_HDR_PATH)/$(_dst)/%.h: $(objtree)/$(obj)/%.h $(KBUILDFILES) $(call cmd,o_hdr_install) $(header-y) : $(INSTALL_HDR_PATH)/$(_dst)/%.h: $(srctree)/$(obj)/%.h $(KBUILDFILES)