Re: 2.6.25-rc1, weird build error

From: Sam Ravnborg
Date: Wed Feb 13 2008 - 16:07:32 EST


On Tue, Feb 12, 2008 at 08:04:48AM +0100, Ingo Molnar wrote:
>
> i've got a build log from a weird build error below:
>
> LD init/built-in.o
> distcc[12023] ERROR: compile (null) on localhost failed
> make: *** [vmlinux.o] Error 1
> make: *** Waiting for unfinished jobs....
> LD .tmp_vmlinux1
>
> but there's no actual error visible in the logs. On a second attempt, it
> built just fine. (unfortunately erasing most evidence of the previous
> failure.) This happened after a rather long randconfig build series so i
> doubt it's readily reprodicible.
>
> any ideas? Is this something benign? Or should i start doing all builds
> with V=1, in the hope of catching more information?

building vmlinux.o were moved up in the dependency chain so we started
to build it before the kallsym stuff. This was done to let modpost
report section mismatch bugs even when the final link failed.

Originally I had expected the dependency of $(kallsyms.o) to
cover this but it turns out that we need to be even more explicit.
With attached patch this is addressed and I now get the desired
behaviour.
The drawback is that the final steps are serialized and we seems
to be pretty CPU bound doing all the linking stuff.

I assume the patch is safe but a bit testing from your side
is appreciated.
That randconfig qa thing is excellent to find these subtle things.

Sam

diff --git a/Makefile b/Makefile
index c162370..bec8da3 100644
--- a/Makefile
+++ b/Makefile
@@ -810,7 +810,9 @@ endif
$(Q)rm -f .old_version

# build vmlinux.o first to catch section mismatch errors early
-$(kallsyms.o): vmlinux.o
+ifdef CONFIG_KALLSYMS
+.tmp_vmlinux1: vmlinux.o
+endif
vmlinux.o: $(vmlinux-lds) $(vmlinux-init) $(vmlinux-main) FORCE
$(call if_changed_rule,vmlinux-modpost)

--
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/