Using libraries in VisualD

Zaggy1024 Zaggy1024 at gmail.com
Thu Apr 3 16:45:09 PDT 2014


On Friday, 7 March 2014 at 08:09:54 UTC, Rainer Schuetze wrote:
>
>
> On 07.03.2014 00:24, Nikos wrote:
>> I can't find how to use other libraries than Phobos in 
>> VisualD. How to
>> reference them?
>
> If you are building the library yourself in another project in 
> Visual Studio, just add a project dependency and it will be 
> added to the linker command line.
>
> Otherwise you should add it to the "Library Files" option on 
> the linker page of the project configuration.
>
> If you mean to replace the default phobos library, you might 
> have to add -L/NODEFAULTLIB:phobos to the command line.

Just thought I'd post this in a related existing thread. I've 
tried numerous ways to include DSFML (a D binding for SFML), but 
I can't seem to get it to work. I expect I'm doing something 
stupid somewhere along the way, but I haven't been able to figure 
out what.

I tried putting this in the Library Files field in the linker 
settings:

"C:\DSFML\prebuilt\dsfml-system.lib;C:\DSFML\prebuilt\dsfml-window.lib;C:\DSFML\prebuilt\dsfml-network.lib;C:\DSFML\prebuilt\dsfml-graphics.lib;C:\DSFML\prebuilt\dsfml-audio.lib"

But when I try using "import dsfml.system.sleep;" to import a 
part of the library, it spouts this:

"main.d(3): Error: module sleep is in file 'dsfml\system\sleep.d' 
which cannot be read"

If anyone knows what I'm doing wrong, I'd appreciate the help. :)


More information about the Digitalmars-d-ide mailing list