build error; missing dependencies on *every* new applet

Denys Vlasenko vda.linux at googlemail.com
Wed Nov 25 03:42:45 UTC 2009


On Wednesday 25 November 2009 01:14, Bernhard Reutner-Fischer wrote:
> On Wed, Nov 25, 2009 at 12:55:14AM +0100, Bernhard Reutner-Fischer wrote:
> >On Wed, Nov 25, 2009 at 01:43:58AM +0100, Denys Vlasenko wrote:
> 
> >>AWWW you too Brutus!!
> >>I just acquired at least one more gray hair looking
> >>at makefiles, can at least you be nicer to me and post
> >>a *smaller*, *less cryptic* testcase?
> >
> >smaller.. erm it's 377 bytes
> >
> >$ (make distclean ; make allnoconfig ; sed -i -e "/CONFIG_TRUE/s/.*/CONFIG_TRUE=y/" .config ; make -j) > /dev/null;./busybox true || echo broken
> >that's 142b and arguably simpler.
> >
> >less cryptic, let me try to expand on my findings:
> >- clean it.
> >- disable everything
> >- turn on one/several random applet(s)
> >- build
> >- run the random applet(s) we previously enabled
> >- curse (since it's broken)
> 
> still broken with 18221506e5ae

What do you mean by "still"?
I already fixed one bug: "make clean; make -j<N>"
wasn't working. Now it works. So something *was* fixed.

The bug with modified .config not always being detected
with make -j is another bug. And I am working on it.

> If you have more than 32MB of free RAM, make sure you have /dev/shm
> mounted (with exec), and (for your convenience):
> $ cd /dev/shm/ && git clone --depth=1 git://git.busybox.net/busybox
> $ cd /dev/shm/busybox
> the above () with "-j", not some cowardly chosen -j2

It's not good enough for you that I am trying to help you *at 03:35am*?

Anyway. I can easily reproduce it with:

make distclean
make allnoconfig
#sleep 1.2
sed -i -e "/CONFIG_TRUE/s/.*/CONFIG_TRUE=y/" .config
make -j<N>

make without -j works. Even make -j2 fails quite often.

I see that it basically amounts to this rule not triggering:

include/autoconf.h: .kconfig.d .config
        echo making include/autoconf.h  #debug
        $(Q)$(MAKE) -f $(srctree)/Makefile silentoldconfig
        echo made include/autoconf.h  #debug

Strange thing is that if I add a delay before sed (see "sleep 1.2"),
it starts to build reliably. I am totally confused.
What does this tell us? That "make allnoconfig" places timestamps
a bit in the future, and therefore sed does not make .config newer
than include/autoconf.h unless we have a pause??!?
--
vda



More information about the busybox mailing list