DIP11: Automatic downloading of libraries

Graham Fawcett fawcett at uwindsor.ca
Tue Jun 14 10:31:21 PDT 2011


On Tue, 14 Jun 2011 12:20:33 -0500, Andrei Alexandrescu wrote:

> On 6/14/11 12:21 PM, Adam D. Ruppe wrote:
>> bearophile:
>>> Isn't this also an argument for the (ancient request of) inclusion of
>>> a normal build feature into the D compiler?
>>
>> I think if the compiler is going to be downloading files, it is
>> necessarily looking for those files... thus it'd become a bit of a
>> smarter build tool as a side effect of this change.
>>
>> It'd be silly if it said "this module is missing, and I'll download it,
>> but I refuse to actually look at it once it's downloaded!"
> 
> Agreed. I think we should have a pragma that mentions "add this file to
> the build" (possibly by adapting the existing pragma(lib, ...)), and
> that pragma(liburl, ...) should imply that other pragma.

pragma(resolve_all_dependencies_just_like_rdmd_does)?

As a data point: the Glasgow Haskell Compiler has a "--make" option which 
discovers and includes all dependent libraries, in the "rdmd" style. Only 
recently (ghc 7?), they made it the default behaviour for the compiler. 

I'd *really* like to see "dmd --make". Even better, "dmd --disable-make", 
because "--make" is the default.

Graham


More information about the Digitalmars-d mailing list