Boost logo

Boost-Build :

Subject: Re: [Boost-build] Problem with notfile target
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2008-11-29 13:05:45


AMDG

Ian Emmons wrote:
>> Probably, instead of adding the target to sources, you can use
>>
>> <dependency>JniHeaders
>>
>> in requirements?
>>
>> - Volodya
>
> Thanks for the quick reply.
>
> Your suggestion does indeed cause the JniHeaders target to run before
> the library is built, but it has two undesirable side effects:
>
> * It causes the library is completely rebuilt every time, as if I did
> a bjam --clean beforehand.

notfile targets are always built. You can try something like:

make JniHeaders.txt : : @BuildJniHeaders ;
alias JniHeaders : JniHeaders.txt ;
actions BuildJniHeaders
{
    ant jniHeaders
    echo Updated >$(<)
}

so that bjam has something to check the timestamp of.

> * It causes the JniHeaders target to run after the library is built as
> well (i.e., it runs twice).

explicit JniHeaders ;

> It would be nice if the lib rule could just ignore source dependency
> targets of unknown type.

How would that help?

In Christ,
Steven Watanabe


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk