Visual C++ quick question...

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Grumpy
Posts: 77
Joined: Wed Dec 30, 2009 7:17 pm
Location: Montana, Usa

Visual C++ quick question...

Post by Grumpy »

When directing Microsoft Visual C++ to include Irrlict.dll in its directory structure, between the two Irrlict dll I am trying to link the one ...\bin\win32-gcc\win32-visualstudios\
However, in Tools->options->Projects and Solutions->VC ++ Directories I am stumped in wich directory type to associate it to since the only dll files on my comp is Irrlicht...
I have already tried 'include files' and it still says the dll was not found.

Thanks in advanced...
code happens
CuteAlien
Admin
Posts: 9933
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Grumpy
Posts: 77
Joined: Wed Dec 30, 2009 7:17 pm
Location: Montana, Usa

Post by Grumpy »

After reading the article and moving Irrlict.dll to windows->system32->

I still get the same error that Irrlict.dll is not found after rebuilding and recompiling...


Help !!!
code happens
Sylence
Posts: 725
Joined: Sat Mar 03, 2007 9:01 pm
Location: Germany
Contact:

Post by Sylence »

Moving the Irrlicht DLL to the system32 folder is the wrongest way of all possible ones...
Software documentation is like sex. If it's good you want more. If it's bad it's better than nothing.
bitplane
Admin
Posts: 3204
Joined: Mon Mar 28, 2005 3:45 am
Location: England
Contact:

Post by bitplane »

Uh, help the guy?

It's been a long time since I last booted into Windows, but I would guess you need to either change your output dir so it saves to the directory containing irrlicht.dll, or copy irrlicht.dll to wherever your exe is built. If that doesn't work then it could be your working directory.
Submit bugs/patches to the tracker!
Need help right now? Visit the chat room
Sundar
Posts: 84
Joined: Mon Jun 05, 2006 11:05 am

Post by Sundar »

bitplane wrote:Uh, help the guy?

It's been a long time since I last booted into Windows, but I would guess you need to either change your output dir so it saves to the directory containing irrlicht.dll, or copy irrlicht.dll to wherever your exe is built. If that doesn't work then it could be your working directory.
adding to that,
generally your current working directory will be the directory where your vcproj/sln file resides. copy the dll there and it should run fine.
CuteAlien
Admin
Posts: 9933
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

I suppose you get this error when starting to run the application, right?

I do generally set the working directory to the output directory and make sure to copy the Irrlicht dll automatically beside the .exe in the post-build step. In c::b I do that with:
cmd /c xcopy ..\libs\irrlicht\bin\Win32-gcc\Irrlicht.dll .. /D /Y
What it does is that it copies the .dll only when it's date has changed.
But in VS it will be slightly different (probably without cmd /c and certainly not with Win32-gcc version and maybe with another target folder).

Also as general info: "include files" are only for headers.
Last edited by CuteAlien on Wed Jan 19, 2011 5:13 pm, edited 1 time in total.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

I'd have expected that dlls found in the 'binaries directories' of the MSVC setup would also be available. What would these directories be else good for? But it does not seem to work. At least I did not find a proper setup for the ogl-es branch, where I have the egl and ogl-es dlls in some configurable directory. For now I also copied them over to the Irrlicht bin directory, but that is not a real option for me. So any other suggestion is welcome.
Grumpy
Posts: 77
Joined: Wed Dec 30, 2009 7:17 pm
Location: Montana, Usa

Post by Grumpy »

but I would guess you need to either change your output dir so it saves to the directory containing irrlicht.dll, or copy irrlicht.dll to wherever your exe is built. If that doesn't work then it could be your working directory.


As it turned out the the directory where my .exe is built to is my debug folder... and what do you know... it worked fine.

The biggist problem I can see with this is I can only work on 1 irrlicht project at a time if I am restricted to leaving that dll file in that one directory at that time.

Perhaps on the next tutorial update you can add that info in.

Thank you again
code happens
Sylence
Posts: 725
Joined: Sat Mar 03, 2007 9:01 pm
Location: Germany
Contact:

Post by Sylence »

Grumpy wrote:The biggist problem I can see with this is I can only work on 1 irrlicht project at a time if I am restricted to leaving that dll file in that one directory at that time.
No you can work on as many irrlicht projects as you want at a time. Simply use a seperate DLL for all projects
Grumpy wrote:Perhaps on the next tutorial update you can add that info in.
That's nothing irrlicht specific. You always need to have every dll somewhere in the system's DLL search folders if an executable refers to them.
Software documentation is like sex. If it's good you want more. If it's bad it's better than nothing.
serengeor
Posts: 1712
Joined: Tue Jan 13, 2009 7:34 pm
Location: Lithuania

Post by serengeor »

You could build static lib and link it to your project, than there would be no need for irrlicht.dll 8)
Working on game: Marrbles (Currently stopped).
Post Reply