Re: test10-pre7

From: Linus Torvalds (torvalds@transmeta.com)
Date: Tue Oct 31 2000 - 13:38:46 EST


Ok, how about this approach? It only works for the case where we do not
have the kind of multiple stuff that drivers/net has, but hey, we don't
actually need to handle all the cases right now.

We can leave that for the future, as the configuration process is likely
to change anyway during 2.5.x, and the multiple object case may go away
entirely (ie the case of slhc and 8390 will become just a normal
configuration dependency: you'd have a "CONFIG_SLHC" entry that is
computed by the dependency graph at configuration time, rather than by the
Makefile at build time).

This is the simplest rule base that I could come up with that should work
for both SCSI and USB:

        # Translate to Rules.make lists.
        multi-used := $(filter $(list-multi), $(obj-y) $(obj-m))
        multi-objs := $(foreach m, $(multi-used), $($(basename $(m))-objs))
        active-objs := $(sort $(multi-objs) $(obj-y) $(obj-m))

        O_OBJS := $(obj-y)
        M_OBJS := $(obj-m)
        MIX_OBJS := $(filter $(export-objs), $(active-objs))

Does anybody see any problems with it? Basically, we're sidestepping the
sorting, because neither SCSI nor USB need it. Making the problem simpler
is always good.

Now, the above won't work for drivers/net, but I think it will work for
just about anything else. So let's just leave drivers/net alone for now.
Simplicity is good.

                Linus

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



This archive was generated by hypermail 2b29 : Tue Oct 31 2000 - 21:00:30 EST