Installing OGRE XCode template for iOS

This is the continuation of my previous blog Building OGRE for iOS. To install the template, you need to follow these steps.

OGRE XCode template

This will install the OGRE template for you. Let us create our first sample OGRE demo using the template we installed it now. To do that, open XCode and select the OGRE template and hit next.

OGRE XCode template

If you see the next attached screenshot carefully, for some reason, the XCode was not letting me add ‘/’ at the beginning of the root SDK path of OGRE. Just ignore it for now. Lets correct this later by making few changes in the XCode project settings.XCode project creation

Now, select the target ‘DemoApp’. Now, select ‘Header Search Paths’ under ‘Build Settings’ and add the missing ‘/’ . Also, make the same changes for ‘Library Search Paths’ too 🙂

OGRE demo app project settings

Now. it’s time to compile the app. If you have done everything right then you should see this error 🙂

 

Undefined symbols for architecture i386:
"boost::system::system_category()", referenced from:
__GLOBAL__I_a in main.o
__GLOBAL__I_a in OgreDemoApp.o
__GLOBAL__I_a in OgreFramework.o
boost::unique_lock<boost::recursive_mutex>::lock() in libOgreMainStatic.a(OgreConfigFile.o)
boost::recursive_mutex::recursive_mutex() in libOgreMainStatic.a(OgreConfigFile.o)
__GLOBAL__I_a in libOgreMainStatic.a(OgreConfigFile.o)
__GLOBAL__I_a in libRenderSystem_GLESStatic.a(OgreGLESPlugin.o)
...
"boost::system::generic_category()", referenced from:
__GLOBAL__I_a in main.o
__GLOBAL__I_a in OgreDemoApp.o
__GLOBAL__I_a in OgreFramework.o
__GLOBAL__I_a in libOgreMainStatic.a(OgreConfigFile.o)
__GLOBAL__I_a in libRenderSystem_GLESStatic.a(OgreGLESPlugin.o)
__GLOBAL__I_a in libOgreMainStatic.a(OgreLogManager.o)
__GLOBAL__I_a in libOgreMainStatic.a(OgreQuaternion.o)
...
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

To fix this error, add -lboost_system in the Other Linker Flags. That’s it…Compile and Run the program now. You should see the OGRE beast staring at you 🙂

OGRE Simulator beast

Advertisements