Building Shoes on OS X (From Scratch)
Beware, these instructions are pretty long. First, try the BuildingShoes page for the quicker route to your own nightly build.
- Build pkg-config.
#!ShellExample $ ./configure --prefix=/tmp/dep $ make && make install $ export MACOSX_DEPLOYMENT_TARGET=10.3 $ export PATH=/tmp/dep/bin:$PATH $ export CFLAGS=-I/tmp/dep/include $ export LDFLAGS=-L/tmp/dep/lib $ export PKG_CONFIG_PATH=/tmp/dep/lib/pkgconfig
- Build libpng.
#!ShellExample $ cp scripts/makefile.darwin makefile $ make prefix=/tmp/dep $ make prefix=/tmp/dep install
Newer libpng (1.2.15 and up) use the same ./configure; make; make install seen below.
- Build libjpeg.
#!ShellExample $ ./configure --prefix=/tmp/dep --enable-shared $ ln -s `which glibtool` ./libtool $ make && make install
- Build giflib.
#!ShellExample $ ./configure --prefix=/tmp/dep $ make && make install
- Build gettext.
#!ShellExample $ ./configure --prefix=/tmp/dep $ make && make install
- Build Glib.
#!ShellExample $ ./configure --prefix=/tmp/dep $ make && make install
- Build pixman.
#!ShellExample $ ./configure --prefix=/tmp/dep $ make && make install
- Build Cairo >= 1.5.18. (To build on OSX, Cairo must have Quartz and CGFont support enabled:)
#!ShellExample ./configure --prefix=/tmp/dep --enable-quartz=yes --enable-quartz-font=yes --enable-xlib=no make && make install
- Build Pango. (BE SURE CAIRO IS BUILT WITH THE FLAGS ABOVE BEFORE PROCEEDING!)
#!ShellExample ./configure --prefix=/tmp/dep --with-x=no make && make install
- Build Ruby (with shared lib.)
#!ShellExample $ ./configure --prefix=/tmp/dep --enable-shared $ make && make install
- Install RubyGems.
#!ShellExample $ /tmp/dep/bin/ruby setup.rb
- gem install rake.
#!ShellExample $ /tmp/dep/bin/gem install rake
- Run rake.
#!ShellExample $ /tmp/dep/bin/rake
Cross-Compiling for PowerPC
To build all of the above for Mac OS X 10.3 (and higher) on PowerPC, run the configure script with some environment variable (as described in Technical Note TN2137.
#!ShellExample
$ env CFLAGS="-O -g -isysroot /Developer/SDKs/MacOSX10.3.9.sdk -arch ppc" \
LDFLAGS="-arch ppc" ./configure --prefix=/tmp/dep --disable-dependency-tracking
Building on OSX with MacPorts
Installing the dependencies using MacPorts is an alternative to the other methods. However, please keep in mind it isn't official supported.
First you have to install MacPorts.
#!ShellExample $ sudo port install cairo +no_x11 $ sudo port install pango +no_x11 $ sudo port install ruby rb-rubygems $ sudo gem install rake --include-dependencies
Now you have your dependencies set up and you can build Shoes.
#!ShellExample $ cd shoes $ rake $ Shoes.app/Contents/MacOS/shoes samples/timer.rb
