README
author ali <ali@juiblex.co.uk>
Sat Feb 18 21:23:39 2012 +0000 (2012-02-18)
changeset 26 d9f14c625111
parent 10 f28ad4577863
child 95 d13e2582c2b5
permissions -rw-r--r--
Add testcase for he/be jeebies
     1                                    bookloupe
     2                                    =========
     3 
     4 General installation instructions can be found in INSTALL. The following
     5 aim to give a quick overview and some help for specific systems. Documentation
     6 for bookloupe itself can be found in doc/bookloupe.txt and for the test
     7 framework in doc/loupe-test.txt.
     8 
     9 Linux
    10 -----
    11 
    12 You should be able to use the standard:
    13 
    14 % ./configure
    15 % make
    16 % sudo make install
    17 
    18 If you get an error about no package 'glib-2.0' found, then you need to
    19 install the development package for glib2. Under Fedora, RHEL and friends
    20 that would be:
    21 
    22 % sudo yum install gcc pkgconfig glib2-devel
    23 
    24 Under Debian, Ubuntu and friends that would be:
    25 
    26 % sudo apt-get install gcc pkgconfig glib2-devel
    27 
    28 Microsoft Windows
    29 -----------------
    30 
    31 It should be possible to use either MSYS (http://www.mingw.org/wiki/MSYS)
    32 or cygwin (http://www.cygwin.com/) to build on a Windows machine. You'll
    33 need a copy of the development package for glib and its dependencies
    34 from http://www.gtk.org/download/win32.php.
    35 
    36 It's much easier to build using a cross-compiler from Linux, if you have
    37 access to such a system. Under Fedora, RHEL and friends you can do this
    38 with:
    39 
    40 % sudo yum install mingw32-gcc pkgconfig mingw32-glib2-static \
    41   mingw32-gettext-static mingw32-iconv-static
    42 % ./configure --host=i686-w64-mingw32 --disable-shared \
    43   --bindir=/bookloupe --datadir=/
    44 % make
    45 % mkdir build
    46 % make install DESTDIR=`pwd`/build
    47 
    48 The contents of the build/bookloupe directory can then be copied to a
    49 Microsoft Windows machine.
    50 
    51 Depending on the version of mingw32-gcc you use, you may need to specify a
    52 different host type. If you're not sure look and see what the cross-compiler
    53 is called (eg., i686-pc-mingw32-gcc) and use the prefix as the host type.
    54 
    55 Mac
    56 ---
    57 
    58 The least intrusive means to build on a Mac is to use Homebrew:
    59 
    60 http://mxcl.github.com/homebrew/
    61 
    62 Install Homebrew according to its instructions.
    63 
    64 If you are building bookloupe for your own use, you can use dynamic linking
    65 like this:
    66 
    67 $ brew install glib
    68 
    69 and then install bookloupe using:
    70 
    71 $ ./configure
    72 $ make
    73 $ make install
    74 
    75 If you want to build bookloupe for other people to use, you will probably
    76 want to link staticly. To do this you need to edit the formula for glib
    77 and each of its dependencies (gettext and libffi) using something like:
    78 
    79 $ brew edit gettext
    80 
    81 Each time find the args statement which includes --prefix and insert
    82 --disable-shared,for example change:
    83 
    84 args = ["--disable-dependency-tracking", "--disable-rebuilds",
    85            "--prefix=#{prefix}",
    86            "--disable-dtrace"]
    87 
    88 to
    89 
    90 args = ["--disable-dependency-tracking", "--disable-rebuilds",
    91            "--disable-shared",
    92            "--prefix=#{prefix}",
    93            "--disable-dtrace"]
    94 
    95 and then
    96 
    97 $ brew install glib
    98 
    99 before installing bookloupe as normal, but with the extra flag to configure:
   100 
   101 $ ./configure --disable-shared
   102 $ make
   103 $ make install
   104 
   105 Note that if you have previously used dynamic linking this may not work.
   106 (Homebrew doesn't seem to create .la files in a form that libtool can use
   107 when it is asked to prefer static libraries to dynamic ones.) Removing the
   108 dynamic libraries first will solve this problem.
   109 
   110 It may also be possible to use fink or macports.