Is there a way to mark a dub package as linux only?

Christian Köstlin christian.koestlin at gmail.com
Tue Sep 27 12:50:39 UTC 2022


On 27.09.22 13:07, Ahmet Sait wrote:
> On Monday, 26 September 2022 at 20:57:06 UTC, Christian Köstlin wrote:
>> Or posix only? Or not windows?
>>
>> Kind regards,
>> Christian
> 
> Not necessarily a dub solution but you can do something like this:
> ```d
> version(Posix) { }
> else
>      static assert(0, "Unsupported platform.");
> ```
> This will result in a compiler error while targetting a non-posix platform.
Thanks a lot ... but thats a little late for me :) as someone already 
might have added my library and was looking forward on using it.



More information about the Digitalmars-d-learn mailing list