Compile and link C/C++ libs automatically
RSY
rsy_881 at gmail.com
Thu Dec 3 20:01:33 UTC 2020
On Thursday, 3 December 2020 at 09:10:53 UTC, Robert M. Münch
wrote:
> On 3 Dec 2020 at 06:08:55 CET, "RSY" <rsy_881 at gmail.com> wrote:
>
>> However, one feature that is making me very jealous was the
>> ability to compile c/c++ code and automatically link the lib,
>> and cache all that
>>
>> This made working with C libraries MUCH easier ...
>> Now imagine such feature, with DUB
>
> Go make it even simpler and IMO that's the way to go:
>
> // <myinclude.>
> Import "C"
>
> And now use all your C functions and structs, etc.
>
> That's the way to go. No extra tool, no pre-step conversion, no
> fiddling around with separate files.
>
> Just simple, straight import and you are done.
I still prefer to have it separate, so you can add specific
compilation flags or defines
But yes, making such feature easily accessible is the goal
More information about the Digitalmars-d
mailing list