Boost logo

Boost-Build :

Subject: [Boost-build] A last minute link inclusion.
From: william.crocker_at_[hidden]
Date: 2009-01-01 18:49:43


If my application needs to be relinked, I need
to sneak in a specially created/compiled source file.
I include the build date into my application with a
link action which looks like this (using
good old Jam (I removed some boiler plate)) :

actions Link bind {
    echo 'const char *link_date() { return("'`date`'"); }' >
    $(C++) $(C++FLAGS) -c -o link_date.o
    $(LINK) $(LINKFLAGS) -o $(<) $(>) link_date.o $(LINKLIBS)
    $(RM) link_date.o

Note that this is a NOT a dependency which causes the app to be relinked.

What is the cool way of doing this using BBV2?


Boost-Build list run by bdawes at, david.abrahams at, gregod at, cpdaniel at, john at