Adding flags to dub build
Jean-Louis Leroy via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Tue Jul 18 13:59:13 PDT 2017
On Tuesday, 18 July 2017 at 20:12:13 UTC, Jean-Louis Leroy wrote:
> On Tuesday, 18 July 2017 at 20:00:48 UTC, Guillaume Piolat
> wrote:
>> On Tuesday, 18 July 2017 at 19:49:35 UTC, Jean-Louis Leroy
>> wrote:
>>> Hi,
>>>
>>> I want to add a few flags while building with dub. I tried:
>>>
>>> DFLAGS='-d-version=explain' dub test ...
>>>
>>> ...but DFLAGS does not seem to be honored. In fact I wouldn't
>>> mind adding a builtType to my dub.sdl (but then will it be
>>> inherited by the subpackages) but I don't see how to specify
>>> flags there either...maybe because it tries to hide
>>> variations in compiler switches?
>>>
>>> J-L
>>
>> Use "dflags" or "lflags" (linker)
>
> It doesn't work either...
The Source holds all the answers ;-)
DFLAGS='-d-version=explain' dub test openmethods:benchmarks
--build '$DFLAGS'
...
Performing "$DFLAGS" build using ldc2 for x86_64.
...
More information about the Digitalmars-d-learn
mailing list