dominicm00 / ham

A meaty Jam build tool replacement

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Warn about targets not transitively dependent on their sources

dominicm00 opened this issue · comments

The current independent target check warns if a target is used in an action while completely unprocessed, but targets can be processed and still have correct dependencies:

actions EchoSources
{
    echo "Building $(1) with sources $(2) "
}

NOTFILE source2 ;
EchoSources target : source1 source2 ;
EchoSources source1 : source2 ;
Depends all : target source1 ;
-
$ jam
EchoSources target 
Building target with sources source1 source2 
EchoSources source1 
Building source1 with sources source2 

It might be useful to warn about targets not depending on their sources. The caveats are that:

  • Checking this is expensive
  • It enforces the notion that $(1) is built from $(2), which may not be true; someone might just be passing two arguments to an action. That said, $(1) really should be built from $(2).

See #49 and #54 for more context/discussion.