diff -r faab25d520dd -r f28ad4577863 README --- a/README Fri Jan 27 16:18:02 2012 +0000 +++ b/README Mon Jan 30 09:11:07 2012 +0000 @@ -54,11 +54,56 @@ Mac --- -I think this should be quite similar to Linux, doing something like this: +The least intrusive means to build on a Mac is to use Homebrew: -% sudo port install gcc pkgconfig glib2-devel -% ./configure -% make -% sudo make install +http://mxcl.github.com/homebrew/ -It may also be possible to use fink instead of macports. +Install Homebrew according to its instructions. + +If you are building bookloupe for your own use, you can use dynamic linking +like this: + +$ brew install glib + +and then install bookloupe using: + +$ ./configure +$ make +$ make install + +If you want to build bookloupe for other people to use, you will probably +want to link staticly. To do this you need to edit the formula for glib +and each of its dependencies (gettext and libffi) using something like: + +$ brew edit gettext + +Each time find the args statement which includes --prefix and insert +--disable-shared,for example change: + +args = ["--disable-dependency-tracking", "--disable-rebuilds", + "--prefix=#{prefix}", + "--disable-dtrace"] + +to + +args = ["--disable-dependency-tracking", "--disable-rebuilds", + "--disable-shared", + "--prefix=#{prefix}", + "--disable-dtrace"] + +and then + +$ brew install glib + +before installing bookloupe as normal, but with the extra flag to configure: + +$ ./configure --disable-shared +$ make +$ make install + +Note that if you have previously used dynamic linking this may not work. +(Homebrew doesn't seem to create .la files in a form that libtool can use +when it is asked to prefer static libraries to dynamic ones.) Removing the +dynamic libraries first will solve this problem. + +It may also be possible to use fink or macports.