Installing DeSmuME from source on OS X

From DeSmuME
(Difference between revisions)
Jump to: navigation, search
(Build Compatibility)
Line 202: Line 202:
  
 
=== Build Compatibility ===
 
=== Build Compatibility ===
TBD
+
The table below lists a summary of both binary and operating system compatibility for all possible builds.
  
 
{| class="wikitable" style="text-align: center;"
 
{| class="wikitable" style="text-align: center;"
! scope="col" width="140" |
+
! scope="col" width="150" |
! scope="col" width="100" | Standard App (Xcode 3)
+
! scope="col" width="150" | OS X App
! scope="col" width="100" | Standard App (Xcode 4)
+
! scope="col" width="150" | OS X App (Final Release)
! scope="col" width="100" | Official-like App (lipo)
+
! scope="col" width="150" | OS X App (Legacy)
! scope="col" width="100" | Legacy App (Xcode 3 Legacy)
+
! scope="col" width="150" | OpenEmu Plug-in (Xcode 4)
! scope="col" width="100" | OpenEmu Plug-in (Xcode 4)
+
 
|-
 
|-
 
! scope="row" | PowerPC, 32-bit
 
! scope="row" | PowerPC, 32-bit
 +
| Yes[1]
 
| Yes
 
| Yes
| No
+
| Yes[1]
| Yes
+
| Yes
+
 
| No
 
| No
 
|-
 
|-
 
! scope="row" | PowerPC, 64-bit
 
! scope="row" | PowerPC, 64-bit
 +
| Yes[1]
 
| Yes
 
| Yes
| No
+
| Yes[1]
| Yes
+
| Yes
+
 
| No
 
| No
 
|-
 
|-
Line 229: Line 226:
 
| Yes
 
| Yes
 
| Yes
 
| Yes
| Yes
+
| Yes[1]
| Yes
+
 
| No
 
| No
 
|-
 
|-
Line 236: Line 232:
 
| Yes
 
| Yes
 
| Yes
 
| Yes
| Yes
+
| Yes[1]
| Yes
+
 
| Yes
 
| Yes
 
|-
 
|-
Line 243: Line 238:
 
| No
 
| No
 
| No
 
| No
| No
+
| Yes[1]
| Yes
+
 
| No
 
| No
 
|-
 
|-
Line 250: Line 244:
 
| Yes
 
| Yes
 
| Yes
 
| Yes
| Yes
+
| Yes[1]
| Yes
+
 
| No
 
| No
 
|-
 
|-
 
! scope="row" | OS X v10.6 (Snow Leopard)
 
! scope="row" | OS X v10.6 (Snow Leopard)
| Yes
 
 
| Yes
 
| Yes
 
| Yes
 
| Yes
Line 262: Line 254:
 
|-
 
|-
 
! scope="row" | OS X v10.7 (Lion)
 
! scope="row" | OS X v10.7 (Lion)
| Yes
 
 
| Yes
 
| Yes
 
| Yes
 
| Yes
Line 269: Line 260:
 
|-
 
|-
 
! scope="row" | OS X v10.8 (Mountain Lion)
 
! scope="row" | OS X v10.8 (Mountain Lion)
| Unknown
+
| Yes
| Unknown
+
| Yes
| Unknown
+
| Yes
| Unknown
+
| Yes
| Unknown
+
 
|}
 
|}
  
 +
1. Available only by configuration in Xcode 3.
  
 
=== Feature Comparison of App Builds ===
 
=== Feature Comparison of App Builds ===

Revision as of 01:27, 13 March 2013

Contents

About the Build Targets

DeSmuME for OS X may be built using several different configurations. Each build configuration is listed in an Xcode project as a "build target." The Xcode project files (provided with the DeSmuME source,) provide several build targets to suit your needs. Many build targets are similar to each other, and so they have been organized into the following categories, based on what the build target produces.


OS X App

These build targets produce a self-contained OS X application package (or "app bundle"). These builds use our official OS X frontend to run the DeSmuME emulator, and are designed for the debugging and testing of pre-release builds. These app bundles are compatible with OS X v10.6 or later. (Also compatible with OS X v10.5 if building from the Xcode 3 project).

Build Target Goals:

  • Fully featured.
  • Widest build compatibility with Xcode versions running different OS X versions.
  • Quick debug-and-test of code changes.

Advantages:

  • Can be built on machines running OS X v10.5 or later, and Xcode 3.1.4 or later.
  • Binaries can be configured to run in debug mode or in release mode.
  • Binaries can be configured for PowerPC or Intel compatibility.
  • Building the app is faster than the final release build.

Disadvantages:

  • Binary compatibility with OS X v10.5 requires Xcode 3 to build.


OS X App (Final Release)

There is only one build target of this kind, and is only used for final release builds. It also produces an app bundle like the usual debug-and-test builds, but has the widest compatibility of all the builds.

Build Target Goals:

  • Fully featured.
  • Widest binary compatibility.
  • Fastest performance.

Advantages:

  • Produces the fastest running binaries compared to all other build targets.
  • Produces a universal binary that supports both 32-bit and 64-bit.

Disadvantages:

  • Must be built on a machine running the latest version of OS X and Xcode.
  • Building the app for release takes more steps than other builds.
  • Binary compatibility with OS X v10.5 and PowerPC requires Xcode 3 to build.


OS X App (Legacy)

These build targets produce a self-contained OS X application package that uses our legacy OS X frontend to run the DeSmuME emulator. These build targets are deprecated, but continue to exist for historical reasons, and also for people who need an app bundle that can run on OS X v10.4.

Build Target Goals:

  • Binary compatibility with OS X v10.4.
  • Retain legacy code for historical reference.

Advantages:

  • Can be built on machines running OS X v10.5 or later.
  • The build app is backwards compatible with OS X v10.4.
  • Binaries can be configured for PowerPC or Intel compatibility.

Disadvantages:

  • These builds are deprecated. We no longer do any active development work on the legacy code.
  • Built applications use the legacy user interface, which does not expose all of DeSmuME's current features to the user.
  • Requires Xcode 3 to build.
  • Produces the slowest running binaries compared to all other build targets.


OpenEmu Plug-in

These build targets produce a plug-in bundle that is compatible with the OpenEmu application (http://openemu.org/). These build targets exist to prove that our DeSmuME source code is modular enough to be adapted easily into other applications. In this case, the plug-in contains the DeSmuME emulator backend, while OpenEmu acts as the frontend that runs the emulator.

Build Target Goals:

  • Compatibility with OpenEmu.
  • Proving good code modularity in the source.

Advantages:

  • Compatible with OpenEmu.
  • Built plug-ins are much smaller in size than full application builds.

Disadvantages:

  • Must be built on a machine running OS X v10.7 or later.
  • Binaries only run on machines with 64-bit Intel processors running OS X v10.7 or later.
  • The frontend is handled by a third-party application, which will not expose all of DeSmuME's features to the user.


Set Up the Build Environment

All DeSmuME build targets must be built using Apple's Xcode IDE. The Xcode project files, included in the desmume/src/cocoa directory of the source code, are supported for the following versions of Xcode:

Project File Name Supported Xcode Version
DeSmuME (Xcode 3).xcodeproj v3.1.4 (if running on Leopard); v3.2.6 (if running on Snow Leopard or later)
DeSmuME (Xcode 4).xcodeproj v4.3 or later
DeSmuME (Legacy).xcodeproj v3.1.4 (if running on Leopard); v3.2.6 (if running on Snow Leopard or later)

Xcode Setup

Refer to the following conditions to determine which Xcode version you need to install.


You must use Xcode 3 if any of the following conditions apply:

  • You are running OS X v10.5 or v10.6.
  • You are building a Legacy OS X App (can be configured to run on OS X v10.4).
  • You are building an OS X App that runs on OS X v10.5.
  • You are building an OS X App that runs on PowerPC processors.
  • You are building an OS X App for final release.


You must use Xcode 4 if any of the following conditions apply:

  • You are running OS X v10.7 or later.
  • You are building an OpenEmu Plug-in.
  • You are building an OS X App for final release.


Download Xcode 3

You can download Xcode 3 from the Apple Developer Connection website. Note that before you can download anything from the ADC website, you must log in using an Apple Developer ID. Once you are logged in, you may use the provided download links to download Xcode 3.


If you do not have an Apple Developer ID, you can register one for free.

If you are not already logged in to ADC, you can log in by accessing the ADC Downloads page.

Once you are logged in to ADC, you can use the following download links for Xcode 3.


Download Xcode 4

Downloading Xcode 4 is very easy! If you are running Lion or later and have any Apple ID, then you can download Xcode 4 directly from the Mac App Store.


Uninstall Previous Versions of Xcode

We highly recommend that you uninstall any previous versions of Xcode before you begin your installation. Doing so will better guarantee that you will have a clean build environment for DeSmuME. The easiest method for uninstalling Xcode is to use the uninstall-devtools script, located in the Library folder of your Xcode installation.

Note: You do not need to uninstall any versions of Xcode that are v4.3 or later. These versions of Xcode are self-contained application packages, which do not conflict with other Xcode versions.

To uninstall Xcode, open Terminal and type the following command into the command line:

sudo /Developer/Library/uninstall-devtools -mode=all

Note: You must be logged into an Administrator account to use this command.

Note: This command assumes that Xcode was installed at the default location, /Developer. The path to the uninstall-devtools script may be different if you did not use the default location when installing Xcode from before.


Set Up Xcode 3

Note: If you do not require the build options that Xcode 3 provides, then you may skip this step. See the Xcode Setup section for more details.

After Xcode 3 is downloaded, you will have a .dmg disk image containing a package installer. Start the Xcode 3 installation by opening the installer, and follow the onscreen instructions until you get to the installation list.

Once the installation list is shown, do the following:

  • If you are planning on making legacy builds, select the Mac OS X 10.4 SDK.
  • If you are planning on installing Xcode 4, then deselect the iOS SDK, which is listed under Essentials. Since Xcode 4 already has a newer version of the iOS SDK, installing the version included with Xcode 3 will be a waste of time and disk space.

Continue the installation as normal and let the installation finish.


Set Up Xcode 4

Note: When you download Xcode from the Mac App Store, Xcode should automatically install itself to the Applications folder once the download is complete. There are no additional steps. Pretty easy, right?

Download the DeSmuME Source Code

The DeSmuME source code is managed using Subversion (SVN) and is hosted on SourceForge. In this section, we describe two of the most common methods for downloading the source code. (In reality, there are many methods for downloading the source code, but those methods are beyond the scope of this document.)

Download via SourceForge Web Interface

These instructions will download the DeSmuME source code from the SourceForge Web Interface using your web browser.

1. Follow this link to DeSmuME's SourceForge Web Interface: http://desmume.svn.sourceforge.net/viewvc/desmume/

2. Click "Download GNU tarball" to start the download.

Download via Command Line

These instructions will download the DeSmuME source code to your desktop.

1. Open Terminal.app.

2. In the command prompt, enter the following exactly as shown:

svn co https://desmume.svn.sourceforge.net/svnroot/desmume ~/Desktop/desmume

Note: If you want to change the destination directory to a directory other than your desktop, change the "~/Desktop/desmume" part to the directory of your choice.

3. At this point, the download should start. However, if instead there is a message about an untrusted certificate, enter the following exactly as shown:

p

Build the DeSmuME Source

TBD

Standard App Build Using the Xcode 3 Project

TBD

Standard App Build Using the Xcode 4 Project

TBD

Official-like App Build Using lipo

TBD

Legacy App Build Using the Legacy Project

TBD

OpenEmu Plug-in Build Using the Xcode 4 Project

TBD

Appendix A: Comparison Charts of Different Builds

TBD

Build Compatibility

The table below lists a summary of both binary and operating system compatibility for all possible builds.

OS X App OS X App (Final Release) OS X App (Legacy) OpenEmu Plug-in (Xcode 4)
PowerPC, 32-bit Yes[1] Yes Yes[1] No
PowerPC, 64-bit Yes[1] Yes Yes[1] No
Intel, 32-bit Yes Yes Yes[1] No
Intel, 64-bit Yes Yes Yes[1] Yes
OS X v10.4 (Tiger) No No Yes[1] No
OS X v10.5 (Leopard) Yes Yes Yes[1] No
OS X v10.6 (Snow Leopard) Yes Yes Yes No
OS X v10.7 (Lion) Yes Yes Yes Yes
OS X v10.8 (Mountain Lion) Yes Yes Yes Yes

1. Available only by configuration in Xcode 3.

Feature Comparison of App Builds

TBD

Standard App (Xcode 3) Standard App (Xcode 4) Official-like App (lipo) Legacy App (Xcode 3 Legacy)
Relative Performance Fast Fastest Fastest Slow
User Interface Current Current Current Based on v0.9.7
Personal tools