NextPrevUpTopContentsIndex

24.9 Universal binaries on Mac OS X

The supplied 32-bit LispWorks for Macintosh images are universal binaries, which run the correct native architecture on PowerPC and Intel-based Macintosh computers by default.

A running Lisp image only supports one architecture, chosen when the image was started. On a PowerPC based Macintosh, this is always the PowerPC architecture. On an Intel-based Macintosh, it can be either the native Intel architecture or the PowerPC architecture (using Rosetta).

Functions such as save-image and deliver mentioned in Creating a new executable with code preloaded create an image containing only the running architecture and functions that operate on fasl files such as compile-file and load only support the running architecture.

To build a universal binary application from LispWorks for Macintosh 5.x, you will need to install LispWorks on an Intel-based Macintosh computer.

Building a new universal binary requires three steps:

  1. Build the application for PowerPC.
  2. This can be done on your Intel machine using Rosetta

  3. Build the application for Intel.
  4. Combine the two applications to make a universal binary.

These steps can be automated on a single Intel-based Macintosh by creating a script that compiles and loads the application and then saves the image. Loading this by running LispWorks with the -build command line argument would save an image containing a single architecture, but you can use the same script to save a universal binary by calling save-universal-from-script as described in the LispWorks Reference Manual .

Note: You may install LispWorks on multiple machines for use at the same time only if you own multiple LispWorks licenses.


LispWorks User Guide - 11 Mar 2008

NextPrevUpTopContentsIndex