Code Blocks with Irrlicht
-
Alpha Omega
- Posts: 288
- Joined: Wed Oct 29, 2008 12:07 pm
Code Blocks with Irrlicht
I have been using code blocks for a few days making applications but today when trying to create a project I get a strange error. Im am using the GNC compiler but I get errors saying that the crtdefs.h (which is a VC++ header file right?) error: `__int641 does not name a type and follows 60+ errors after that. It all started when I tried compiling a Irrlicht.dll file which code blocks couldn't do. I am using the VC++ 2008 include/lib and have the DX and Windows SDK. Could it be a problem with code blocks?
-
SwitchCase
- Posts: 170
- Joined: Sun Jul 01, 2007 11:41 pm
- Location: Manchester, UK
+Im am using the GNC compiler
I am using the VC++ 2008 include/lib
There's your problem. You're trying to link to a library compiled with VC++ with a compiler other than VC++. C++ standards do not clarify exactly the definition of various types - therefore different compilers implement different ways of doing things.
Use the GCC lib. By "GNC compiler" I assume your on about the GCC compiler from GNU.
-
Alpha Omega
- Posts: 288
- Joined: Wed Oct 29, 2008 12:07 pm
Oh I see what I did wrong. But I got back to the problem I had before. I am trying to compile the Irrlicht.dll file but to gets an error at
Thats why I linked the VC++ lib to it in the first place. Can anyone help me with this please?[/code]
Code: Select all
#ifdef _IRR_WINDOWS_
#include <windows.h>
#if defined(_DEBUG) && !defined(__GNUWIN32__)
#include <crtdbg.h>
#endif-
SwitchCase
- Posts: 170
- Joined: Sun Jul 01, 2007 11:41 pm
- Location: Manchester, UK
-
Frank Dodd
- Posts: 208
- Joined: Sun Apr 02, 2006 9:20 pm
-
Alpha Omega
- Posts: 288
- Joined: Wed Oct 29, 2008 12:07 pm
Yes I was and thank you for your help.Are you missing the __GNUWIN32__ under project build options, compiler settings #defines.
I have built some of the tutorials that come with the engine but they all say "DIRECT3D9 is not supported with the current .dll file" or something close to that so I thought maybe I needed to compile a more updated Irrlicht.dll file?Have you successfully built a project that links to the irrlicht.dll already compiled for you?
*******
I compiled the new Irrlicht.dll file but it did not solve the "Direct3D9 is not supported with the current .dll file".
Irrlicht.dll issue and Linking Problems???
I am having an issue linking using code blocks I have just switched over to this ide and I want to define the library locations.
I can compile examples if I relocate the precompiled irrlicht.dll found in the bin. But I couldn't compile the demo using IrrKlang. How can i set up the ide to find my libs and includes. And other libraries i choose to use in the future?
PS> I compiled irrlicht from the source and I am getting the same issue as Alpha Omega of not being able to use directx. I believe I have directX 10? Any ideas? or can i link to the precompiled dll instead?
I can compile examples if I relocate the precompiled irrlicht.dll found in the bin. But I couldn't compile the demo using IrrKlang. How can i set up the ide to find my libs and includes. And other libraries i choose to use in the future?
PS> I compiled irrlicht from the source and I am getting the same issue as Alpha Omega of not being able to use directx. I believe I have directX 10? Any ideas? or can i link to the precompiled dll instead?
Code Blocks linking
so I found out how to link using the build options in code blocks. Rt click on the project and select build options then I can add libraries in the Linker Settings tab and other search directories in the next tab.
After compiling the Irrlicht source i can no longer use directX in the examples... I used to be able to. So I can no clue what version of Irrlicht.dll is linked =/ How do I find the linker is looking?
Also after linking IrrKlang and compiling I no longer have sound in the Demo project. I used to have sound everytime I clicked or pressed space. No build errors and I made sure to use IrrKlang the CDemo.h file.
I would like to get the linking part down so i can move on to deciphering the demos. Any help is appreciated. Thanks.
After compiling the Irrlicht source i can no longer use directX in the examples... I used to be able to. So I can no clue what version of Irrlicht.dll is linked =/ How do I find the linker is looking?
Also after linking IrrKlang and compiling I no longer have sound in the Demo project. I used to have sound everytime I clicked or pressed space. No build errors and I made sure to use IrrKlang the CDemo.h file.
I would like to get the linking part down so i can move on to deciphering the demos. Any help is appreciated. Thanks.
link for other newbs.
So i found this link... maybe it will help others:
http://irrlicht.sourceforge.net/tut_codeblocks.html
NOTE: many of the links to libs don't work.
I didn't know I need so many other dependencies...
I am still having issues but I am going to take a break and then come back later.
http://irrlicht.sourceforge.net/tut_codeblocks.html
NOTE: many of the links to libs don't work.
I didn't know I need so many other dependencies...
I am still having issues but I am going to take a break and then come back later.
the tutorial you found seems to use C::B with the MSVC libs, but as far as you're using C::B with gcc you can also check my tutorial at http://abusoft.g0dsoft.com, it's realy simple to use... 
while(!asleep) sheep++;
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
IrrExtensions:

http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
Its a good tutorial expect for one part didn't work for me. When you type "Irrlicht" for the lib. My compiler doesn't work like that. I had to actually find the lib file. "Irrlicht.a"Acki wrote:the tutorial you found seems to use C::B with the MSVC libs, but as far as you're using C::B with gcc you can also check my tutorial at http://abusoft.g0dsoft.com, it's realy simple to use...
that's because libs for gcc usually named libMyLib.a,magfuse wrote:When you type "Irrlicht" for the lib. My compiler doesn't work like that. I had to actually find the lib file. "Irrlicht.a"
so the Irrlicht lib should be named "libIrrlicht.a" and not just "Irrlicht.a" !!!
if you rename it you'll see it works like I discribed !!!
but that doesn't affect any usability though...
while(!asleep) sheep++;
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
IrrExtensions:

http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
It works!!! Thank You! I was using $(IrrKlangLIB)\libirrKlang.a and $(IrrLIB)\libirrKlang.a -- Custom variables. This is much more efficient.Acki wrote:that's because libs for gcc usually named libMyLib.a,magfuse wrote:When you type "Irrlicht" for the lib. My compiler doesn't work like that. I had to actually find the lib file. "Irrlicht.a"
so the Irrlicht lib should be named "libIrrlicht.a" and not just "Irrlicht.a" !!!
if you rename it you'll see it works like I discribed !!!![]()
but that doesn't affect any usability though...
I am not getting the "-1Irrlicht not found" error since I updated the search directories. Thanks for your tutorial!