Irrlicht.dll doesn't exist on this computer?

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
Dr_Asik
Posts: 18
Joined: Wed Jun 02, 2010 2:15 am

Irrlicht.dll doesn't exist on this computer?

Post by Dr_Asik »

Hello everyone, just trying out Irrlicht.

I'm on Visual Studio 2010 on Windows 7 x64. I unzipped Irrlicht 1.7.1 somewhere and added its include and lib directories to my project configuration options. I am able to compile a tutorial example fine, but when I try to run it, I get something like "Irrlicht.dll doesn't exist on this computer".

I've used the Win32-visualstudio lib directory, when I use Win64 it doesn't link (seems like VS defaults to producing a 32-bit executable). Not sure what I'm supposed to do. If I copy Irrlicht.dll to the directory where my exe is built, it works fine, but surely I'm not supposed to do that all the time.

Thanks for your help.
Last edited by Dr_Asik on Wed Jun 02, 2010 2:22 am, edited 1 time in total.
Nalin
Posts: 194
Joined: Thu Mar 30, 2006 12:34 am
Location: Lacey, WA, USA
Contact:

Post by Nalin »

If this error occurs when you try to run the example, you most likely forgot to put the Irrlicht.dll file in the same folder as the example executables.
Dr_Asik
Posts: 18
Joined: Wed Jun 02, 2010 2:15 am

Post by Dr_Asik »

Nalin wrote:If this error occurs when you try to run the example, you most likely forgot to put the Irrlicht.dll file in the same folder as the example executables.
So I need to do this manually for any new Irrlicht project? Strange that wasn't mentioned in any of the tutorials.
slavik262
Posts: 753
Joined: Sun Nov 22, 2009 9:25 pm
Location: Wisconsin, USA

Post by slavik262 »

Irrlicht.dll either needs to go in every folder you run an Irrlicht project from. Alternatively, you can cheat and put it in the system folder (SysWOW64 for you 64-bit boys).
Nalin
Posts: 194
Joined: Thu Mar 30, 2006 12:34 am
Location: Lacey, WA, USA
Contact:

Post by Nalin »

Dr_Asik wrote:
Nalin wrote:If this error occurs when you try to run the example, you most likely forgot to put the Irrlicht.dll file in the same folder as the example executables.
So I need to do this manually for any new Irrlicht project? Strange that wasn't mentioned in any of the tutorials.
Let me try to explain in simplified terms what is going on:

The pre-compiled Irrlicht that you can download was compiled for "dynamic" loading. That means all the Irrlicht code was compiled into a .dll file. The .lib file, which you link to, tells the program where all the Irrlicht functions are inside the .dll file. So, if you don't have the Irrlicht.dll somewhere where your program can find it, it fails to load, complaining about the missing file.

If you manually compile Irrlicht, you can do what is called a "static" compile. This means that no .dll file is created. All the code is compiled into the .lib file. When you link to the .lib file, it provides all the Irrlicht code. You can think of it as merging the .dll file inside your .exe file.
Virion
Competition winner
Posts: 2148
Joined: Mon Dec 18, 2006 5:04 am

Post by Virion »

Dr_Asik wrote:
Nalin wrote:If this error occurs when you try to run the example, you most likely forgot to put the Irrlicht.dll file in the same folder as the example executables.
So I need to do this manually for any new Irrlicht project? Strange that wasn't mentioned in any of the tutorials.
every programmer should know this. programming 101.
Dr_Asik
Posts: 18
Joined: Wed Jun 02, 2010 2:15 am

Post by Dr_Asik »

All right, just wasn't sure if I was doing the right thing since no tutorial made mention of the dll. I know what a dll is, just wondered if the irrlicht version I downloaded was for dynamic or static linking.
DtD
Posts: 264
Joined: Mon Aug 11, 2008 7:05 am
Location: Kansas
Contact:

Post by DtD »

If there is a .dll (or .so on Linux) it is dynamic. If there is only a .lib (or .a) then it is static.

(With dlls there is also usually an accompanying .lib)
RollieMe
Posts: 4
Joined: Tue Jun 01, 2010 6:04 am

Post by RollieMe »

Virion wrote:
Dr_Asik wrote:
Nalin wrote:If this error occurs when you try to run the example, you most likely forgot to put the Irrlicht.dll file in the same folder as the example executables.
So I need to do this manually for any new Irrlicht project? Strange that wasn't mentioned in any of the tutorials.
every programmer should know this. programming 101.
"Beginners Help
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."
w3rd
Posts: 3
Joined: Mon Sep 20, 2010 2:23 pm

Post by w3rd »

did you solve this? I have the same problem on Windows 7 with Visual Studio 2010 professional.
no matter where I copy the dll. I cant start the .exe.
serengeor
Posts: 1712
Joined: Tue Jan 13, 2009 7:34 pm
Location: Lithuania

Post by serengeor »

If I remember correctly if you run debug version from visual studio your dll has to be in the same folder as the sources, not sure tough, haven't seen Visual Studio in a long time :)
Working on game: Marrbles (Currently stopped).
w3rd
Posts: 3
Joined: Mon Sep 20, 2010 2:23 pm

Post by w3rd »

i was stupid.. sorry. already solved it. or rather never had it :)
Post Reply