Re: Linux 2.6.28-rc1

From: Sam Ravnborg
Date: Fri Oct 24 2008 - 19:15:56 EST


On Fri, Oct 24, 2008 at 12:24:38PM +0100, Alistair John Strachan wrote:
> On Friday 24 October 2008 05:10:29 Linus Torvalds wrote:
> > It's been two weeks, so it's time to close the merge window. A 2.6.28-rc1
> > is out there, and it's hopefully all good.
>
> It seems if you have a broken asm/ symlink in include/ (which happened as a
> result of the x86 header moves, for me) the kernel won't try to update it
> appropriately, and this breaks "make prepare".
>
> $ make ARCH=x86_64 prepare
> CHK include/linux/version.h
> CHK include/linux/utsrelease.h
> GEN include/asm/asm-offsets.h
> /bin/sh: include/asm/asm-offsets.h: No such file or directory
> make[1]: *** [include/asm/asm-offsets.h] Error 1
> make: *** [prepare0] Error 2
>
> rm -f include/asm fixes it
>
> This was just from taking a 2.6.27 tree, git clean -d -f, git pull, make
> oldconfig. Might be a nice thing to fix?

The following patch add another special case hwre we delete stale symlinks.
In my limited testing it fixes the issue - can you try to give it a spin.

Sam

diff --git a/Makefile b/Makefile
index f6703f1..9dc7427 100644
--- a/Makefile
+++ b/Makefile
@@ -961,6 +961,7 @@ export CPPFLAGS_vmlinux.lds += -P -C -U$(ARCH)

# The asm symlink changes when $(ARCH) changes.
# Detect this and ask user to run make mrproper
+# If asm is a stale symlink (point to dir that does not exist) remove it
define check-symlink
set -e; \
if [ -L include/asm ]; then \
@@ -970,6 +971,7 @@ define check-symlink
echo " set ARCH or save .config and run 'make mrproper' to fix it"; \
exit 1; \
fi; \
+ test -e $$asmlink || rm include/asm; \
fi
endef

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/