4 Welcome to Notmuch, a system for indexing, searching and tagging your email.
6 We hope that the process of building and installing notmuch is quick
7 and smooth so that you can soon be reading and processing your email
8 more efficiently than ever.
10 If anything goes wrong in the configure process, you can override any
11 decisions it makes by manually editing the Makefile.config file that
12 it creates. Also please do as much as you can to figure out what could
13 be different on your machine compared to those of the notmuch
14 developers. Then, please email those details to the Notmuch list
15 (notmuch@notmuchmail.org) so that we can hopefully make future
16 versions of notmuch easier for you to use.
18 We'll now investigate your system to verify that all required
19 dependencies are available:
25 if pkg-config --version > /dev/null 2>&1; then
31 printf "Checking for Xapian development files... "
32 if xapian-config --version > /dev/null 2>&1; then
35 cxxflags="${cxxflags} $(xapian-config --cxxflags)"
36 ldflags="${ldflags} $(xapian-config --libs)"
40 errors=$((errors + 1))
43 printf "Checking for GMime 2.4 development files... "
44 if pkg-config --modversion gmime-2.4 > /dev/null 2>&1; then
47 cflags="${cflags} $(pkg-config --cflags gmime-2.4)"
48 ldflags="${ldflags} $(pkg-config --libs gmime-2.4)"
52 errors=$((errors + 1))
55 printf "Checking for talloc development files... "
56 if pkg-config --modversion talloc > /dev/null 2>&1; then
59 cflags="${cflags} $(pkg-config --cflags talloc)"
60 ldflags="${ldflags} $(pkg-config --libs talloc)"
65 errors=$((errors + 1))
68 printf "Checking for valgrind development files... "
69 if pkg-config --modversion valgrind > /dev/null 2>&1; then
72 cflags="${cflags} $(pkg-config --cflags valgrind)"
74 printf "No (but that's fine).\n"
78 if pkg-config --modversion emacs > /dev/null 2>&1; then
79 emacs_lispdir=$(pkg-config emacs --variable sitepkglispdir)
81 emacs_lispdir='$(prefix)/share/emacs/site-lisp'
84 if [ $errors -gt 0 ]; then
87 *** Error: The dependencies of notmuch could not be satisfied. You will
88 need to install the following packages before being able to compile
92 if [ $have_xapian -eq 0 ]; then
93 echo " Xapian library (including development files such as headers)"
94 echo " http://xapian.org/"
96 if [ $have_gmime -eq 0 ]; then
97 echo " GMime 2.4 library (including development files such as headers)"
98 echo " http://spruce.sourceforge.net/gmime/"
100 if [ $have_talloc -eq 0 ]; then
101 echo " The talloc library (including development files such as headers)"
102 echo " http://talloc.samba.org/"
106 On a modern, package-based operating system such as Debian, you can
107 install all of the dependencies with the following simple command
110 sudo apt-get install libxapian-dev libgmime-2.4-dev libtalloc-dev
112 On other systems, a similar command can be used, but the details of the
113 package names may be different, (such as "devel" in place of "dev").
116 if [ $have_pkg_config -eq 0 ]; then
118 Note: the pkg-config program is not available. Both this configure
119 script and the Makefile of notmuch use pkg-config to find the
120 compilation flags required to link against the various libraries
121 needed by notmuch. It's possible you simply need to install pkg-config
122 with a command such as:
124 sudo apt-get install pkg-config
126 But if pkg-config is not available for your system, then you will need
127 to manually edit the notmuch Makefile to set the variables such as
128 CFLAGS and LDFLAGS to the correct values without calling pkg-config.
133 When you have installed the necessary dependencies, you can run
134 configure again to ensure the packages can be found, or simply run
135 "make" to compile notmuch.
141 printf "Checking for getline... "
142 if gcc -o config/have_getline config/have_getline.c > /dev/null 2>&1
147 printf "No (will use our own instead).\n"
150 rm -f config/have_getline
154 All required packages were found. You may now run the following
155 commands to compile and install notmuch:
162 # construct the Makefile.config
163 cat > Makefile.config <<EOF
165 emacs_lispdir=${emacs_lispdir}
166 HAVE_GETLINE = ${have_getline}
167 override CFLAGS += ${cflags} -DHAVE_VALGRIND=${have_valgrind} -DHAVE_GETLINE=\$(HAVE_GETLINE)
168 override CXXFLAGS += ${cflags} ${cxxflags}
169 override LDFLAGS += ${ldflags}