Undefined reference to ‘createDevice’ – Irrlicht engine compilation

irrlicht engine error createdevice

irrlicht engine error createdevice

Extending openCV from pure 2D world to 3D environments seems challengeable – the first one is to find out the a 3D engine to support 3D rendering, based on the data gained from openCV. Irrlicht engine is seemed as a good option, as it provides good supports to 3D rendering with open source codes. However, compiling the engine for ubuntu & eclipse use is not an easy job. When I tried to run the first helloworld example, the problem popped up – Undefined reference to 'createDevice()'.


This is caused by the lack of library file link – this can be the result of incorrent type of library path, or an incorrect link of library files. Typically, irrlicht needs self compilation to get the library file in Linux. The compilation instructions give clear steps to do the job, which generates the lib file – libIrrlicht.a. Unfortunately linking this lib in the project does not work, even worse it generates hundreds of undefined reference to ... errors. irrlicht compilation errors

A lot googling was done to find out the cause of this error, with no helpful info in conanical irrlicht forum. While re-checking the instructions of irrlicht compilation, something was noticed:

irrlicht compile instruction

A shared library may be a choice, instead of generating the lib in irrlicht folder, so make sharelib && sudo make install, the lib files as well as included head files were installed in /usr/local/include/irrlicht and /usr/local/lib. Linking these to the irrlicht project – bingo – it worked, all errors gone!!!

Author: Andol Li

A HCI researcher, a digital media lecturer, an information product designer, and a python/php/java coder.

One Comment On “ Undefined reference to ‘createDevice’ – Irrlicht engine compilation”

Leave a comment
Due to technical adjustments, the comment function is shortly closed and will be re-openning soon. Thanks.

Copyrights 2006-2018 © All rights reserved
Theme Tree2, re-designed by Andol Li, powered by WordPress and Bootsrap
WWW.ANDOL.ME | 浙ICP备15040508号-1
公安备案图标 浙公网安备33010602004018号
Back to top