Main Page | Recent changes | View source | Page history

Printable version | All content dual-licensed under the GNU FDL and the Creative Commons Share-alike Attribution license. | Privacy policy

Not logged in
Log in | Help
 

Guides/MacOSX/QuickInstall

From SwarmWiki

Contents

Quick-Installation Guide for Swarm on Mac OS X Snow Leopard

This page is designed to get you up and running with the Swarm framework, and then instate some confidence by having you get your first "Hello World" Swarm application up and running.

Note: This process hides much of the complexities of configuring, building, and installing Swarm, so if you know what you're doing, you can safely skip this Induction process.

Note: This document has been tested with the latest checkout of the source, which at the time of this writing, is r7903. This means that this document...

  • Will work for this version of the source code
  • Will probably work for versions above
  • Will NOT work for versions below

Installing the Swarm Framework from Source in 4 Easy Steps

Step 1/4 - Install Prerequisite Software

The very first thing you need to do is to get yourself an ADC (Apple Developer Connection) account, and then download and install Xcode (or alternatively, install it from your Snow Leopard DVD).

The next thing you will need is GNU sed.

Note: Without GNU sed, your compilation will fail.

Note: Make sure that your installed GNU sed is the first in the path. Unfortunately, it appears that even though Autoconf does discover the correct sed if it's installed and not first in your PATH, the non-GNU sed /usr/bin/sed still ends up being used in the following section of the compilation...

PhaseScriptExecution "Run Script" build/Swarm.build/Release/Swarm.build/Script-D6EAF86B0981C20400EE3B51.sh
    ...
    setenv SED /usr/bin/sed
    ...

Step 2/4 - Get the Swarm Source Code

The second thing you need to do is to get the source code on your target system. The swarm source is currently maintained in subversion, and the online book is freely available as a PDF document here.

To get started, we will first setup a few environment variables which we will refer back to for the remainder of the document.

% setenv STAGING ${HOME}/devel
% setenv TRUNK Swarm

Now we will chdir into our defined staging area...

% cd ${STAGING}

Next, if you are a Swarm developer, you {c,w,sh}ould already have a ssh account with Savannah, in which case you would checkout a read/write copy...

% svn co svn+ssh://<username>@svn.savannah.nongnu.org/swarm/trunk ${TRUNK}

If you're not a developer, you can instead checkout a readonly copy of the source, you can either use the svn protocol...

% svn co svn://svn.savannah.nongnu.org/swarm/trunk ${TRUNK}

...or, you can use http (which is a little slower)...

% svn co http://svn.savannah.nongnu.org/svn/swarm/trunk ${TRUNK}

For the most upto date set of instructions for checking out the project source code, see the Savannah SVN page.

Step 3/4 - Quick Configuration

Now that you have the code and the SDK from Apple, you can start configuring your build environment.

You now need to decide if you want the framework installed for your own use only, or for all users of the machine you're installing it on. If you are installing it for yourself, you don't need to do anything (as that is the default behaviour).

If you'd like to make the framework available for all users however, you will need to have superuser access (via sudo or otherwise), and you will need to set the PRODUCT environment variable...

Let's have a look at this in practice; First we'll look at the available options...

% cd ${STAGING}/${TRUNK}/swarm/macosx
% make
Makefile for the impatient...

    make info
    make build
    make install
    make clean

%

And to see the build settings...

% make info
ProductName:	Mac OS X
ProductVersion:	10.6.2
BuildVersion:	10C540

Mac OS X SDKs:
	Mac OS X 10.5                 	-sdk macosx10.5
	Mac OS X 10.6                 	-sdk macosx10.6

Installation settings...

    PRODUCT=/Users/xerxes/Library/Frameworks/Swarm.framework

%

Say we prefer to install in the system-wide area instead...

% setenv PRODUCT /Library/Frameworks/Swarm.framework
% make info
ProductName:	Mac OS X
ProductVersion:	10.6.2
BuildVersion:	10C540

Mac OS X SDKs:
	Mac OS X 10.5                 	-sdk macosx10.5
	Mac OS X 10.6                 	-sdk macosx10.6

Installation settings...

    PRODUCT=/Library/Frameworks/Swarm.framework

%

We've now configured the installation destination to be the system-wide area.

Step 4/4 - Quick Build & Install

You're now ready to go. Follow me...

% cd ${STAGING}/${TRUNK}/swarm/macosx

Now go ahead and build, then install...

% make build install

That's all!

Swarm Applications

Heatbugs


[Main Page]
Main page
About SwarmWiki
News
Recent changes
Random page
Help

View source
Discuss this page
Page history
What links here
Related changes

Special pages