[lkml]   [2014]   [Jul]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
Subject[PATCH] kbuild: Fix packaging targets with relative $(srctree)
All other users of set $(obj) to the name of the
subdirectory to build. Do the same for the packaging targets, otherwise
the build fails if $(srctree) is a relative directory:

$ make O=build tar-pkg
make[1]: Entering directory `/home/mmarek/linux-2.6/build'
CHK include/config/kernel.release
../scripts/ ../../scripts/package/Makefile: No such file or directory
make[2]: *** No rule to make target `../../scripts/package/Makefile'. Stop.

Fixes: 9da0763b ("kbuild: Use relative path when building in a subdir of the source tree")
Signed-off-by: Michal Marek <>
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 1a5f9f3..347d6c7 100644
--- a/Makefile
+++ b/Makefile
@@ -1176,7 +1176,7 @@ distclean: mrproper
# Packaging of the kernel to various formats
# ---------------------------------------------------------------------------
# rpm target kept for backward compatibility
-package-dir := $(srctree)/scripts/package
+package-dir := scripts/package

%src-pkg: FORCE
$(Q)$(MAKE) $(build)=$(package-dir) $@

 \ /
  Last update: 2014-07-04 23:41    [W:0.037 / U:3.736 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site