[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Directory targets: specifics
From: |
Gary Oberbrunner |
Subject: |
Re: Directory targets: specifics |
Date: |
Fri, 1 Dec 2000 15:55:53 -0500 (EST) |
>>>>> "ZD" == Zachary Deretsky <address@hidden> writes:
ZD> 3. Which brings me to the main issue here: which targets are
ZD> attributed to a directory? I belive, consistent definition is:
ZD> All the targets of all the Conscripts residing in this directory.
ZD> This handles the case, for example, when files are copied from a
ZD> repository to the install area, not touching the directory,
ZD> where the Conscript with this Command resides in any way.
Hmm. I was rather thinking that all targets which are built *into* a
particular directory become the dependencies of that directory. So if
A/Conscript does Install $env ($EXPORT, "foo") and B/Conscript does
Install $env ($EXPORT, "bar"), then those two files become
dependencies of $EXPORT. (Same for any command, not just Install.)
Your model would say that $EXPORT/foo is a dependency of A and same
for bar and B. These are pretty different cases.
In your case, what if a Library is built by two different dirs'
Conscripts? I guess both dirs would depend on the library?
ZD> 4. The above implies that if Conscript in directory A has
ZD> Build("B/Conscript");
ZD> then directory A target would depend on directory B.
Do you mean by this that *no* targets in A should be built until B is
complete? If you do, I think you would have to add explicit Depends
here for each target in A: I don't think Build's current meaning
should be changed like that. In A/Conscript you could have something
like:
Build("B/Conscript");
Depends $env ($some-A-target, "B")
Depends $env ($other-A-target, "B")
Without the individual Depends, it would be hard for cons to figure
out that B has to be built first when some third Conscript requires
$some-A-target.
If I misinterpreted you and you just mean that the A directory target
isn't considered up-to-date until B is also up-to-date, then I'm fine
with that, though adding an explicit Depends $env, "A", "B" is so easy
I'd suggest leaving Build the way it is. The only effect it would
have, anyway, is on an AfterBuild on A: it would wait til after all of
B was built, even if nothing else in A depends on anything in B. Is
that your intention?
ZD> 6. Question: in Link "BuildDir" => "SourceDir" situation which
ZD> directory is the target?
If you accept my modification, this is no longer an issue. The real
dir of a target is the one that gets the dependency.
--
. . . . . . . . . . . . . . . . . . . . . . . . .
Gary Oberbrunner address@hidden
GenArts, Inc. Tel: 617-492-2888
8 Clinton Street Fax: 617-492-2852
Cambridge, MA 02139 USA http://web.genarts.com