Re: test10-pre7

From: Peter Samuelson (peter@cadcamlab.org)
Date: Tue Oct 31 2000 - 09:16:08 EST


  [rmk]
> > Take the instance where we need to link a.o first, z.o second, f.o
> > third and p.o fourth. How does LINK_FIRST / LINK_LAST guarantee
> > this?

It does. Read the patch. LINK_FIRST *itself* is not sorted.

> > LINK_FIRST = a.o z.o
> > LINK_LAST = f.o p.o
> >
> > But then what guarantees that 'a.o' will be linked before 'z.o'?

[kaos]
> LINK_FIRST is processed in the order it is specified, so a.o will be
> linked before z.o when both are present. See the patch.

Indeed, the right solution is

  LINK_FIRST := a.o z.o f.o p.o

which is self-documenting, as Keith has said: by looking at that line,
the intended behavior is obvious. You should still accompany this with
a comment explaining *why* the ordering is needed, but even if you
don't, you are giving us much more information than the status quo
(which is "this link order works, any other order is quite possibly
sane but who knows for sure").

Peter
-
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:29 EST