List Info

Thread: Use executable target in an actions




Use executable target in an actions
user name
2006-09-21 15:07:52
On Sep 21, 2006, at 12:55 AM, Ilya Sokolov wrote:

> [snip]
>
>>> read
>>> http://www.crystalclearsoftware.com/cgi-bin/boost
_wiki/wiki.pl?
>>> Boost.Build_V2/UsingBuiltTool
>>
>>
>> Hi,
>>
>> This is an elegant solution if only I could make it
work.  The
>> COMMAND is not built before it's used in the
actions.  It may be that
>> the way I'm using it is the problem, not sure. 
This is what I've got
>> so far.
>>
>> # xmldb.jam
>> feature inline-binary : : free dependency ;
>> toolset.flags xmldb.concat.xml COMMAND
<inline-binary> ;
>>
>> type.register XML : xml ;
>> type.register XMLDB : xmldb ;
>> generators.register-composing xmldb.concat.xml :
XML : XMLDB ;
>>
>> actions xmldb.concat.xml bind COMMAND
>> {
>>    $(COMMAND) $(<) $(>)
>> }
>>
>> # xmlconcat.jam
>> exe xmlc : $(source-files) ;
>>
>> # parser.jam
>> import xmldb ;
>> xmldb foo.db : main.xml :
<inline-binary>/xmlconcat//xmlc ;
>>
>> When I build, the value of COMMAND is
bin/xmlconcat/gcc-3.4.3/debug/
>> xmlc but there is no executable in that directory,
so it doesn't
>> appear to be building it before using it.  Can you
see what I'm doing
>> wrong?
>
> i think it's a bbv2 bug, but you can try the
following:
>
> # parser.jam
> alias xmlc : /xmlconcat//xmlc ;
> import xmldb ;
> xmldb foo.db : main.xml : <inline-binary>xmlc ;

Yes, this works correctly.  Thanks for the help Ilya.

-- Noel


_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost-build
[1]

about | contact  Other archives ( Real Estate discussion Medical topics )