Print
Image

Introduction

Getting the Ogre 1.8 Tutorials to compile and run on OS X using Xcode 4 can be difficult. This topic covers the complete list of steps used to get your own project (or the Tutorials) up and running quickly.

Install Ogre SDK prebuilt version with prebuilt dependencies

  1. Download and install Ogre SDK prebuilt binary from http://www.ogre3d.org/download/source.(external link) You can install the SDK anywhere on your computer.
  2. Download and install Ogre prebuilt dependencies from http://sourceforge.net/projects/ogre/files/ogre-dependencies-mac/1.8/.(external link)
    1. After extracting the dependencies, move the entire Dependencies folder from the archive into the root of the Ogre SDK.
  3. Download and install the NVIDIA CG framework from http://developer.nvidia.com/cg-toolkit-download.(external link) Follow the direction from NVIDIA to get everything installed correctly. Once it is installed you should be able to find Cg.framework in /Library/Frameworks.
  4. Download and install the Xcode 4 templates from http://sourceforge.net/projects/ogre/files/ogre-dependencies-mac/1.8/(external link)
    1. During the install, you can choose to skip the iOS SDK location if you want.
  5. Open Xcode and create a new project using the Ogre OS X template.
  6. On the left side in the navigator, select the project. You should be presented with project and target settings. Under either the project or target(it doesn't matter), select Build Settings near the top center of the window. Now down near the bottom you should see a button labeled Add Build Setting, click on it and choose User-Defined Setting. Name this new setting OGRE_SDK_ROOT and set the value to the path where you installed the Ogre SDK. For example: ~/OgreSDK
    1. Navigate to the project you created.
  7. Build and run the tutorial framework. You should see the Ogre head demonstration.

If you run into build errors you might need to try installing the dependencies to your system rather than using the pre-built dependencies. Here are the steps to do this...

Install Ogre dependencies to your system

  1. Install Dependencies via macports (option 2 at http://www.ogre3d.org/tikiwiki/Prerequisites?tikiversion=Mac+OS+X+%26+iOS)(external link)
  2. Download and install the NVIDIA CG framework from http://developer.nvidia.com/cg-toolkit-download.(external link) If you already completed this using the previous directions, there's no need to do it again.
  3. Download and install OIS from http://sourceforge.net/projects/wgois/files/Source%20Release/1.3/(external link)
    1. Patch OIS with the following 64 bit patch:
      1. Download the "Cocoa and 64 bit support" patch from http://sourceforge.net/tracker/?atid=775955&group_id=149835&func=browse(external link)
      2. Download the source for OIS from http://sourceforge.net/scm/?type=svn&group_id=149835(external link)
      3. In a terminal, cd into the OIS source you checked out and use the Unix patch tool to apply your patch (patch -p0 -i cocoa.diff)
  4. Build and run your Xcode template again.

 


Contributors to this page: masterfalcon419 points  and marcwren61 points  .
Page last modified on Monday 25 of March, 2013 06:34:00 UTC by masterfalcon419 points .


The content on this page is licensed under the terms of the Creative Commons Attribution-ShareAlike License.
As an exception, any source code contributed within the content is released into the Public Domain.