Easier way to add libraries to visual d?

Basile B. via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Thu May 26 08:21:40 PDT 2016


On Thursday, 26 May 2016 at 15:11:05 UTC, TheDGuy wrote:
> Hi,
> i use Visual D as a plugin for visual studio to create D 
> applications. But what bothers me a bit is that i have to tell 
> visual D the exact link to the .lib file for every lib i want 
> to use in the project (!).
> So these are the steps i have to make to get an external lib 
> working:
>
> 1. create a new folder in D:\dmd2\src\ with the name of the 
> library
> 2. edit the 'sc.ini' file in D:\dmd2\windows\bin\ and add 
> "-I%@P%\..\..\src\[foldername]" under '[Environment]' for every 
> lib i want to use
> 3. add the .lib file to D:\dmd2\windows\lib
> 4. add the path to the lib in visual studio (project properties 
> -> Linker -> General -> Library Files)
>
> Why do i have to do that? Why can i not just use one folder for 
> the library files in visual d and the compiler searches the 
> .lib files for each library which was imported into the project 
> on its own?
>
> Is there an easier way to use libraries?

Use Coedit: the widget "library manager" allow to register 
libraries in a single click and then they are usable on the fly, 
in the projects or in a runnable modules, without specifying 
anything (except a (*) in a project setting called 
"libraryAliases".

https://github.com/BBasile/Coedit/wiki#library-manager-widget

It was especially designed because the other IDE suck a bit with 
static libraries.



More information about the Digitalmars-d-learn mailing list