README
changeset 10 f28ad4577863
parent 6 faab25d520dd
child 19 05d082ebf685
     1.1 --- a/README	Fri Jan 27 16:18:02 2012 +0000
     1.2 +++ b/README	Mon Jan 30 09:11:07 2012 +0000
     1.3 @@ -54,11 +54,56 @@
     1.4  Mac
     1.5  ---
     1.6  
     1.7 -I think this should be quite similar to Linux, doing something like this:
     1.8 +The least intrusive means to build on a Mac is to use Homebrew:
     1.9  
    1.10 -% sudo port install gcc pkgconfig glib2-devel
    1.11 -% ./configure
    1.12 -% make
    1.13 -% sudo make install
    1.14 +http://mxcl.github.com/homebrew/
    1.15  
    1.16 -It may also be possible to use fink instead of macports.
    1.17 +Install Homebrew according to its instructions.
    1.18 +
    1.19 +If you are building bookloupe for your own use, you can use dynamic linking
    1.20 +like this:
    1.21 +
    1.22 +$ brew install glib
    1.23 +
    1.24 +and then install bookloupe using:
    1.25 +
    1.26 +$ ./configure
    1.27 +$ make
    1.28 +$ make install
    1.29 +
    1.30 +If you want to build bookloupe for other people to use, you will probably
    1.31 +want to link staticly. To do this you need to edit the formula for glib
    1.32 +and each of its dependencies (gettext and libffi) using something like:
    1.33 +
    1.34 +$ brew edit gettext
    1.35 +
    1.36 +Each time find the args statement which includes --prefix and insert
    1.37 +--disable-shared,for example change:
    1.38 +
    1.39 +args = ["--disable-dependency-tracking", "--disable-rebuilds",
    1.40 +           "--prefix=#{prefix}",
    1.41 +           "--disable-dtrace"]
    1.42 +
    1.43 +to
    1.44 +
    1.45 +args = ["--disable-dependency-tracking", "--disable-rebuilds",
    1.46 +           "--disable-shared",
    1.47 +           "--prefix=#{prefix}",
    1.48 +           "--disable-dtrace"]
    1.49 +
    1.50 +and then
    1.51 +
    1.52 +$ brew install glib
    1.53 +
    1.54 +before installing bookloupe as normal, but with the extra flag to configure:
    1.55 +
    1.56 +$ ./configure --disable-shared
    1.57 +$ make
    1.58 +$ make install
    1.59 +
    1.60 +Note that if you have previously used dynamic linking this may not work.
    1.61 +(Homebrew doesn't seem to create .la files in a form that libtool can use
    1.62 +when it is asked to prefer static libraries to dynamic ones.) Removing the
    1.63 +dynamic libraries first will solve this problem.
    1.64 +
    1.65 +It may also be possible to use fink or macports.