Hi All,
I now have my wiki account, and have started writing a document targetting people who're new to swarm, an Induction.
To make this a more pleasant experience for people, I've written a set of Makefiles to drop into trunk - which are by no means perfect or complete, but they're a good start.
The master makefile is OS-independent and looks like so...
PROJECT := Swarm
OS := $(shell uname -s)
all: build;
include ${OS}.Makefile
build: .${OS}_build
install: .${OS}_build .${OS}_install
x: ${OS}_x
info: ${OS}_info
clean: ${OS}_clean
-rm -f .${OS}_*
################################################################################
.PHONY: all clean info .${OS}_build .${OS}_install ${OS}_clean ${OS}_info ${OS}_x
Next, we need a OS-specific makefile per supported OS, I've thus far written one for Mac OS X Snow...
SDK := macosx10.6
BASE := swarm/macosx/SwarmOSX
PRODUCT := ${HOME}/Library/Frameworks/Swarm.framework
.Darwin_build:
cd swarm && ./autogen.sh
cd swarm && ./configure --enable-openstep --without-jdkdir
cd ${BASE} && xcodebuild \
-configuration Release \
-sdk ${SDK} \
-parallelizeTargets \
-project ${PROJECT}.xcodeproj \
-alltargets
cd ${BASE} && xcodebuild \
-configuration Debug \
-sdk ${SDK} \
-parallelizeTargets \
-project ${PROJECT}.xcodeproj \
-alltargets
touch $@
.Darwin_install: ${PRODUCT}
${PRODUCT}:
test ! -d $@ || rm -rf $@
cp -R ${BASE}/build/Release/address@hidden ${PRODUCT}
Darwin_x:
open ${BASE}/${PROJECT}.xcodeproj
Darwin_info:
xcodebuild -showsdks
Darwin_clean:
cd ${BASE} && xcodebuild \
-configuration Debug \
-alltargets \
clean
cd ${BASE} && xcodebuild \
-configuration Release \
-alltargets \
clean
...I'm aware that "Darwin" != "Snow Leopard v10.6" and other subtleties, but this is just a start, I'll clean it up as I start adding Linux support.
The point for this is to allow the user to do a checkout, run make, make install, and have a functional framework to work with, and similarly, run clean, and really get in return an actual "clean" source repository. At the moment, clean (swarm distclean) seems to delete even files that are checked out of subversion!
Is everyone okay with this?
Nima
_______________________________________________