Note that Xapian is currently only available in versions targeted for UNIX systems.
tar zxvf xapian-core-<versionnumber>.tar.gz
tar zxvf xapian-examples-<versionnumber>.tar.gz
These commands should unpack the archives into separate subdirectories
("xapian-core" and "xapian-examples").
These tools generate a shell script called "configure" for each of the archives, which you should run to set up the code for compilation.
A typical build would be done using the commands:
cd xapian-core ./configure make make installVarious options may be given to the configure script: see the installation documentation within the archive for more details.
By default, Xapian will be installed in directories under
/usr/local
. This can be altered using the --prefix option
to configure.
cd xapian-examples ./configure makeNote that we do not currently recommend attempting to install the examples.
configure
should automatically find the installed Xapian
library: if it doesn't you may need to specify the path to the
xapian-config
script, by using the
--with-xapian-config
option to configure.
Note: you must install the Xapian library to be able to link applications with it. In the past we've attempted to allow linking against uninstalled builds of the library, but it's very hard to do it reliably and portably. If you don't have the rights to install libraries in /usr/local/lib (or similar) then you can build Xapian to install under your home directory.
Supposing you had unpacked both xapian and xapian-examples in the same directory, you could use:
cd xapian-core ./configure --prefix=`pwd`/tempinstall --disable-shared make make install cd ../xapian-examples ./configure --with-xapian-config=`pwd`/../xapian-core/tempinstall/bin/xapian-config make
Check the documentation within the xapian-examples archive for more details on building and running the examples.
The other drawback of CVS is that you will need to generate your own configure script and makefiles. This can be done using the GNU autoconf, automake, and libtool packages: you must have these installed if you wish to work from CVS.
We provide a useful script (buildall
) to run all the necessary
scripts to generate the project Makefiles. Simply run ./buildall
to run all the necessary scripts. This will produce a source tree like the
ones in the distribution tarballs, which you can run configure and make on
in the usual way.