DUB: Sometimes generates .di file and sometimes do not.
BoQsc
vaidas.boqsc at gmail.com
Sun Nov 5 11:07:58 UTC 2023
On Sunday, 5 November 2023 at 10:54:35 UTC, Imperatorn wrote:
> On Sunday, 5 November 2023 at 10:53:33 UTC, BoQsc wrote:
>> I would like to know how to solve this problem with `dub`.
>>
>> **dub.sdl**
>>
>> ```
>> name "dheaders"
>> description "generates .di header file for a static library."
>> authors "public domain"
>> copyright "Public Domain. No rights reserved."
>> license "public domain"
>>
>> configuration "staticLibrary" {
>> dflags "-Hf=$PACKAGE_DIR/builds/library.di"
>> targetName "library"
>> targetType "library"
>> targetPath "builds"
>> sourceFiles "library.d"
>> }
>> ```
>>
>> **library.d**
>>
>> ```
>> module library;
>>
>> int func(int x)
>> {
>> return x+1;
>> }
>> ```
>>
>> **Command Line:**
>> ```
>> dub
>> ```
>>
>> **Problem:**
>> After running `dub` command: `library.di` file is
>> rarely/inconsistenly generated inside `builds` directory.
>
> Try add quotes to the Hf param
Didn't help.
More information about the Digitalmars-d-learn
mailing list