Irrlicht 1.3.1 Autotools

Post those lines of code you feel like sharing or find what you require for your project here; or simply use them as tutorials.
Post Reply
anylo
Posts: 71
Joined: Mon Feb 20, 2006 11:14 am

Irrlicht 1.3.1 Autotools

Post by anylo »

Here's pre-pre-alpha (a.k.a. "laugh release") of the Irrlicht 1.3.1. Only core files are in this dist.

http://www.kolumbus.fi/anssi.ylonen/irr ... 3.1.tar.gz

Check wiki for required libraries, enable shared lib with

Code: Select all

./configure --enable-shared
install with

Code: Select all

sudo make install

and uninstall with

Code: Select all

sudo make uninstall
etc.

Bug reports etc. into this thread. I'll also try to add 01.HelloWorld example later tomorrow.

You don't know Autotools? Shame on you.

EDIT:
For a while link gave version which did not compile. It should be fixed now.
anylo
Posts: 71
Joined: Mon Feb 20, 2006 11:14 am

Post by anylo »

There's a "small" bug in that tarball. Library is not linked against any required libries (GL, png, jpeg, etc). :oops:

I'll make new version later today.
anylo
Posts: 71
Joined: Mon Feb 20, 2006 11:14 am

Post by anylo »

OK, here's pre-alpha (still "laugh version" status)

http://www.kolumbus.fi/anssi.ylonen/irr ... pha.tar.gz

Configure, compile and install.

Here's also small example how to use a static version of the library:

http://www.kolumbus.fi/anssi.ylonen/irr ... 0.0.tar.gz

Code: Select all

./configure --with-Irrlicht=/usr/local && make
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Could you provide just the files neeed for autoconf usage? It's pretty much work for nothing to extract them from the tarball.
Those files also look quite weird and hardly maintainable. What's required to update manually when, e.g., changing this stuff from 1.3.1 to latest SVN version of Irrlicht?
anylo
Posts: 71
Joined: Mon Feb 20, 2006 11:14 am

Post by anylo »

hybrid wrote:Could you provide just the files neeed for autoconf usage? It's pretty much work for nothing to extract them from the tarball.
Those files also look quite weird and hardly maintainable. What's required to update manually when, e.g., changing this stuff from 1.3.1 to latest SVN version of Irrlicht?
RTFM! :)

Ok, it's much easier than you expect. Core of everything is configure.ac (previously it was called configure.in). Version numbers, library depencies, flags etc. are in there. Then there's these Makefile.am files in each directory. Those are used to generate Makefile.in files, which are used to generate Makefiles. Sounds more complicated that it really is. Here's "skeleton" of the previous example:

http://www.kolumbus.fi/anssi.ylonen/irr ... ton.tar.gz

Code: Select all

tar xzvf irrexample-1.0.0-skeleton.tar.gz
cd irrexample-1.0.0-skeleton
autoreconf --verbose --force --install 
./configure --with-Irrlicht=/usr/local
make
Autoreconf does the real magic (it's basically autoconf, aclocal and automake put in together, so there's no need to use those).

Adding those into HEAD svn is just copying those previously mentioned files into their correct locations and checking if there's any (there is) changes in the file lists (take a look into that Irrlicht 1.3.1 package and check /include/Makefile.am and /source/Irrlicht/Makefile.am).
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Well, there's much more to make real use of autoconf tools. For example changing includes to make use of config.h. We need to add those --enable-something switches, make default settings, etc. The cross-compilation needs extra work I guess, right now the Makefile works also for win32 builds under Linux. and so on...
anylo
Posts: 71
Joined: Mon Feb 20, 2006 11:14 am

Post by anylo »

hybrid wrote:Well, there's much more to make real use of autoconf tools. For example changing includes to make use of config.h. We need to add those --enable-something switches, make default settings, etc. The cross-compilation needs extra work I guess, right now the Makefile works also for win32 builds under Linux. and so on...
Easiest way is to include config.h into IrrCompileConfig.h and change it so that if something is already defined in config.h then it won't be defined again. And if there's no config.h at all (building in Windows or something like that) then the original settings in IrrCompileConfig.h are used.

EDIT:
And remember, I've released pre-alpha version. Everything should be much better in alpha release. ;)
anylo
Posts: 71
Joined: Mon Feb 20, 2006 11:14 am

Post by anylo »

Implemented support for doxygen.

Code: Select all

./configure --enable-doxygen-pdf
make doxygen-doc
will create nice pdf of Irrlich API (~950 pages). And of course html-version.

Alpha is released when it's ready.
anylo
Posts: 71
Joined: Mon Feb 20, 2006 11:14 am

Post by anylo »

Code: Select all

  --enable-debug          Turn on debugging and compile time warnings
  --enable-pedantic       Turn on various compile time checkings
  --disable-opengl        Disable support for OpenGL
  --disable-software      Disable support for software video driver
  --disable-burningsvideo Disable support for Burning's video driver
  --enable-directx9       Enable support for DirectX9
  --disable-jpeg          Disable support for jpeg
  --disable-x11           Disable support for X11
  --disable-png           Disable support for png
  --disable-zlib          This disables the engine to read from compressed
                          .zip archives. If you disable this feature, the
                          engine can still read archives, but only
                          uncompressed ones
  --disable-doxygen-doc   don't generate any doxygen documentation
  --disable-doxygen-dot   don't generate graphics for doxygen documentation
  --enable-doxygen-man    generate doxygen manual pages
  --enable-doxygen-rtf    generate doxygen RTF documentation
  --enable-doxygen-xml    generate doxygen XML documentation
  --enable-doxygen-chm    generate doxygen compressed HTML help documentation
  --enable-doxygen-chi    generate doxygen seperate compressed HTML help index
                          file
  --disable-doxygen-html  don't generate doxygen plain HTML documentation
  --enable-doxygen-ps     generate doxygen PostScript documentation
  --enable-doxygen-pdf    generate doxygen PDF documentation
http://www.kolumbus.fi/anssi.ylonen/irr ... pha.tar.gz

Using local copy of zlib/jpeg/png libraries is not implemented. Yet. I tested this version quite slightly, so there's probably some bugs. I really hope that you test this and give me some information is this working or not. Hopefully it is. ;)

EDIT:
make doxygen-doc
anylo
Posts: 71
Joined: Mon Feb 20, 2006 11:14 am

Post by anylo »

Further testing revealed that support for X11 and Burning's video device flags were mixed.

And you cannot compile with --enable-pedantic:

Code: Select all

COSOperator.cpp:168: error: ISO C++ does not support 'long long'
COSOperator.cpp:170: error: ISO C++ does not support 'long long'
Post Reply