Help compiling irrlicht

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
nathanf534
Posts: 199
Joined: Tue Dec 09, 2008 2:55 am

Help compiling irrlicht

Post by nathanf534 »

I have made a slight modification to Irrlicht and need to recompile the dll's, but I can't figure out how. I am using Eclipse with Windows 7, with MinGW GCC toolchain.

I tried creating a new c++ Shared Library project, and copying all the files from the source folder to that project, then clicking Project-> Make Target -> Build

I get a dialog box to fill out a couple things,
Make Target: (Im not sure what this should be, but I have tried several things such as "all" "clean" "sharedlib_win32" and leaving it blank)

Build command: the default is "make" so I just left it as that.

When I actually build it, I get random errors such as

Code: Select all

..\bzip2\bzip2.c:556:4: error: 'BZFILE' undeclared (first use in this function)
..\bzip2\bzip2.c:556:12: error: 'bzf' undeclared (first use in this function)
..\bzip2\bzip2.c:559:19: error: 'BZ_MAX_UNUSED' undeclared (first use in this function)
..\bzip2\bzip2.c:559:12: warning: unused variable 'unused'
or missing file errors such as

Code: Select all

..\libpng\/png.h:493:18: fatal error: zlib.h: No such file or directory
Would anyone like to help me compile Irrlicht?
while(signatureEmpty){cout<<wittyComment();}
Bonaducci
Posts: 11
Joined: Fri Aug 03, 2012 1:22 am
Location: Wrocław, Poland

Re: Help compiling irrlicht

Post by Bonaducci »

So here we go again.
I have the same problem now. I'm trying to compile Irrlicht from source but unfortunately I have the same 3 errors with bzip2. Surely there is solution, but someone should say it loudly.

I'm using Windows 7 and QT based on MinGW.

//After commenting bzip2 I see a lot of next errors with various configuration things. Found several install files with half-instruction about configuring it but it's now enough to know how to make it work.

However, can anyone tell me, why there is no precompiled MinGW version? It's not difficult for irrlicht developers to build it once, but quite problematic for a lot of users to wonder how they should do it themselves.
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Re: Help compiling irrlicht

Post by hybrid »

Maybe just use a supported IDE, such as code::blocks. This supports mingw and Irrlicht comes with project files which work right out of the box. Here it looks as if some include files are not used at all, or at least the wrong ones. When using a Makefile you have to make sure you meet the correct makefile targets, such as win32 or sharedlib_win32. You can also find a mingw compilation in the FAQ forum which even supports DirectX. However, most SDKs even come with a mingw version precompiled, just with out DX support.
CuteAlien
Admin
Posts: 9929
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: Help compiling irrlicht

Post by CuteAlien »

I remember I recently fixed something in the Makefile for Windows, but only in svn trunk version I think.
But in the error above I would say that looks suspicious: "..\libpng\/png.h" - either / or \ should be used, both together probably doesn't work.
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
Bonaducci
Posts: 11
Joined: Fri Aug 03, 2012 1:22 am
Location: Wrocław, Poland

Re: Help compiling irrlicht

Post by Bonaducci »

I had only this errors

Code: Select all

..\bzip2\bzip2.c:556:4: error: 'BZFILE' undeclared (first use in this function)
..\bzip2\bzip2.c:556:12: error: 'bzf' undeclared (first use in this function)
..\bzip2\bzip2.c:559:19: error: 'BZ_MAX_UNUSED' undeclared (first use in this function)
I'd have to look inside c::b project to see how it works. Simply something is missing in includes or in compiler params. But I found another solution, so. If someone have similar problem, he can try this: http://irrlicht.sourceforge.net/forum/v ... =1&t=46778
Post Reply