-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathREADME_macosx
56 lines (42 loc) · 1.94 KB
/
README_macosx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
1- How to build on Mac OS X
===========================
The Mac OS X version of djvulibre can be built in one of two ways:
- the Unix way
- the Xcode way
These instructions are to help setup and build djvulibre for a
multi-architecture binary (ppc, i386). Your milage with the following
configure options (note: libjpeg.a and libtiff.a are installed
universal on the machine this was tested with.)
We recommend that you first install macports with the
libraries zlib, libpng, jpeg and tiff with option +universal.
The commands to install these libraries are
$ sudo port install zlib +universal
$ sudo port install libpng +universal
$ sudo port install jpeg +universal
$ sudo port install tiff +universal
Then you can run configure
./configure \
--enable-static=yes \
--disable-desktopfiles \
--with-extra-includes=/usr/include \
--with-extra-libraries=/usr/lib \
CFLAGS="-arch ppc -arch i386" \
CXXFLAGS="-arch ppc -arch i386" \
LDFLAGS="-arch ppc -arch i386"
The --with-extra-include and --with-extra-libraries are here
to favor system libraries (in /usr) over those that come with macports.
Then you can compile with
$ make
Running "make install" will install djvulibre in directory /usr/local.
Note that the produced libraries will depend on the macports jpeg and tiff
libraries. You can change that using the command "install_name_tool"
and other macosx tricks...
Alternatively you can just open the macosx/DjVuLibre/DjVuLibre.xcodeproj
and build everything using Xcode. This can be painful if you do not have
the same version of Xcode as the one we used to generate that file.
In Leon's opinion, this is hell. Jeff agrees, those dyld dependancies
trap us forever in the eighth circle.
Note that the macosx directory contains a few useful tools
that are not compiled using the main makefile:
The djvu.mdimporter program is a spotlight importer for djvu metadata.
The djvu.qlgenerator program generates quicklook data (leopard only).