www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - Using external libraries the correct way

reply solidstate1991 <laszloszeremi outlook.com> writes:
Up to this day, I have to use them by dragging the source into my 
project. When I tried to import imageformats, the compiler looks 
up for the file imageformats.d and fails to finish the program.

I'm not using command line for compiling, I use Xamarin with 
mono-D instead.
Jul 17 2016
next sibling parent Edwin van Leeuwen <edder tkwsping.nl> writes:
On Sunday, 17 July 2016 at 17:52:59 UTC, solidstate1991 wrote:
 Up to this day, I have to use them by dragging the source into 
 my project. When I tried to import imageformats, the compiler 
 looks up for the file imageformats.d and fails to finish the 
 program.

 I'm not using command line for compiling, I use Xamarin with 
 mono-D instead.
I tend to use dub for all my external libraries: http://code.dlang.org Not sure how that ties in with mono-D though.
Jul 17 2016
prev sibling parent NX <nightmarex1337 hotmail.com> writes:
On Sunday, 17 July 2016 at 17:52:59 UTC, solidstate1991 wrote:
 Up to this day, I have to use them by dragging the source into 
 my project. When I tried to import imageformats, the compiler 
 looks up for the file imageformats.d and fails to finish the 
 program.

 I'm not using command line for compiling, I use Xamarin with 
 mono-D instead.
Menu > Project > Project Options > Compiling > Libraries Something like this: http://i51.photobucket.com/albums/f358/NightmareX1337/project-options_zpsbmvgtr3b.png Or you can choose the pragma(lib) way: http://dlang.org/spec/pragma.html#lib
Jul 17 2016