Boost logo

Boost-Build :

Subject: Re: [Boost-build] embed manifest file
From: tr1gun (tr1gun_at_[hidden])
Date: 2014-03-28 16:49:50


On 28.03.2014 21:13, Steven Watanabe wrote:
> AMDG
>
> On 03/28/2014 12:32 PM, tr1gun wrote:
>> Hello,
>>
>> i want to embed a user-defined manifest in the build dll.
>> i tried to extend the msvc-linking-generator and it seems now it
>> correctly builds and embeds a user supplied manifest file.
>> Can someone comment on the attached patch?
>> I extended the msvc-linking-generator to create an extra target for
>> embedding the manifest file. The extra target (MANIFESTLOG) is a dummy
>> file as embedding the manifest file only modifies the dll without
>> creating a new file.
>> Is this the correct way?
>>
>
> Creating a new target is wrong. The action updates
> the dll, so it should have the dll as its target.
> It would be much simpler and more reliable if
> you simply adjusted the check for <embed-manifest>on
> in link and link.dll so that it first checks
> whether a manifest file has been explicitly specified
> and uses that instead of the default.
>
> In Christ,
> Steven Watanabe
>

The problem i faced that the properties variable in the link / link.dll
rule is only a raw string and the file target for embed-manifest-file is
lost.
I tried it with a variable like DEF_FILE but i faced some problems with
labels in the action. Are actions executed like batch files? I also
noticed that boost build doesn't recognize the failure on the next run
and you would need to delete the target dll or rebuild everything.
Therefore i introduced a new target so it can detect the failure on the
next run.


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