Skip to content
joshfisher edited this page Feb 21, 2011 · 28 revisions

install on OS X
mkdir /Potion/poFramework
git clone [email protected]:Potion/poFramework4.git

download boost-1.45 and unzip into /Potion/Boost

cd /Potion/Boost/boost_1_45_0
./bootstrap.sh --show-libraries
./bjam --layout=versioned --with-system --with-filesystem --with-date_time --with-thread --with-regex --with-serialization toolset=darwin macosx-version=10.6 macosx-version-min=10.5 runtime-link=shared link=static threading=multi variant=release,debug architecture=x86 address-model=32 stage

i’m building everything specifically for 10.5 and i386 rather than 10.6 and x86_64

Boost

boost build command line for os x and v1.45

./bjam --layout=versioned toolset=darwin macosx-version=10.6 macosx-version-min=10.5 runtime-link=shared link=static threading=multi variant=release,debug architecture=x86 address-model=32 stage

add `—with-LIBRARY_NAME` to the command line to build specific libs. i’ve been using test, date_time, filesystem, system, thread, python, regex, and serialization

doesn’t seem that bad:
Building boost for iOS

FreeImage

freeimage version 3.14.1
had to modify the freeimage makefile:
here’s the patch:

*** Makefile.osx	2011-01-05 11:59:48.000000000 -0500
--- Makefile.osx.bk	2011-01-05 11:53:16.000000000 -0500
***************
*** 56,67 ****
  
  dist: FreeImage
  	cp *.a Dist
  	cp Source/FreeImage.h Dist
  
! FreeImage: $(STATICLIB)
  
! $(STATICLIB): $(STATICLIB)-i386
! 	$(LIPO) -create $(STATICLIB)-i386 -output $(STATICLIB)
  
  $(STATICLIB)-ppc: $(MODULES_PPC)
  	$(LIBTOOL) -arch_only ppc -o $@ $(MODULES_PPC)
--- 56,68 ----
  
  dist: FreeImage
  	cp *.a Dist
+ 	cp *.dylib Dist
  	cp Source/FreeImage.h Dist
  
! FreeImage: $(STATICLIB) $(SHAREDLIB)
  
! $(STATICLIB): $(STATICLIB)-ppc $(STATICLIB)-i386 $(STATICLIB)-x86_64
! 	$(LIPO) -create $(STATICLIB)-ppc $(STATICLIB)-i386 $(STATICLIB)-x86_64 -output $(STATICLIB)
  
  $(STATICLIB)-ppc: $(MODULES_PPC)
  	$(LIBTOOL) -arch_only ppc -o $@ $(MODULES_PPC)

apply with: patch < Makefile.osx.patch from the same directory where Makefile.osx lives

Freetype

version 2.4.4

export CFLAGS="-isysroot /Developer/SDKs/MacOSX10.5.sdk -arch i386 -mmacosx-version-min=10.5"
export LDFLAGS="-isysroot /Developer/SDKs/MacOSX10.5.sdk -arch i386"
./configure --without-zlib --prefix $(pwd)/stage
make
make install
Clone this wiki locally