I'm new to OGRE (Game Programming at all) and I want to setup OGRE with Code::Blocks on Mac OS X.
I downloaded the latest prebuilt SDK (1.6.1) + latest Code::Blocks (8.02-p2) for OS X.
Then Copied C::B to /Developer/Applications, and OGRE SDK to /Developer.
I open Samples.xcodeproj with Xcode and build all the bundled samples. Most of them runs and works fine.
The included readme says: for size reasons, these examples using relative folder structure to find and load there dependencies. and there is no need to copy them into /Library/Frameworks anymore (If you copy the binary (bundled .app) file to other place it crashes, because of dependencies lack).
I did not like Xcode and I planned to use Eclipse/CDT with OGRE, but found C::B is more faster, efficient and reliable C++ IDE. Since it has "Ogre Project" template, I thought configuring project became more easier.Getting Started
This distribution contains the precompiled SDK release of OGRE for Mac OS X. Just drag the 'OgreSDK' folder to the location on your drive where you want to install the SDK. Please do drag the entire folder rather than opening it and copying any subfolders, since the internal folder structure is relevant when building the samples.
Important:If you have used a previous version of OGRE, make sure you remove Ogre.framework, CEGUI.Framework, Cg.framework and OgreCEGUIRenderer.framework from your /Library/Frameworks folder or any other 'root' folder. From version 1.4.5, all frameworks are referenced and deployed locally which is much more flexible when dealing with multiple versions, and also reflects how you would want to deploy an end application (see below).
But when I fire up C::B and create an new Ogre Project, It asked me for SDK and It has two options (the first one is hidden, I scrolled up suddenly, then it appears, maybe it refers to wxWidgets problem on OS X):
Code: Select all
"I have a folder with the OGRE source code"
"I have installed a pre-made OGRE SDK"
It generates a main.cpp file that contains an sample application (exactly like generated code from Visual C++ OGRE wizard plug-in). When I build the project it gives me a bunch of errors like this:
Code: Select all
||=== ogreTest, Debug ===|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|5|error: Ogre.h: No such file or directory|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|12|error: ExampleApplication.h: No such file or directory|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|52|error: windows.h: No such file or directory|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|23|error: expected class-name before '{' token|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp||In member function 'void SampleApp::createScene()':|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|35|error: 'mSceneMgr' was not declared in this scope|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|38|error: 'Light' was not declared in this scope|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|38|error: 'myLight' was not declared in this scope|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|39|error: 'Light' is not a class or namespace|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|39|error: 'LT_POINT' was not declared in this scope|
/Users/msbabaei/Desktop/ogreProjects/ogreTest/main.cpp|53|error: 'INT' does not name a type|
||=== Build finished: 10 errors, 0 warnings ===|
I think there's must be a way to apply this on a single project or IDE itself.
Any help would be appreciated!