Commit graph

217 commits

Author SHA1 Message Date
Jeffrey C. Ollie
d98718d104 Improve installation of emacs mode.
1) Add a separate targets to build and install emacs mode.

2) Don't hardcode the installation directory, instead use emacs'
   pkg-config module.

3) Install a byte compiled version of the emacs mode.

4) Install the emacs mode in emacs' site-lisp directory.  Put
   "(require 'notmuch)" in your .emacs to load it automatically.

5) Ignore byte-compiled emacs files.

Signed-off-by: Jeffrey C. Ollie <jeff@ocjtech.us>
Reviewed-by: Ingmar Vanhassel <ingmar@exherbo.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
2009-11-20 10:34:29 +01:00
Peter Wang
ddac17343a Put $(LDFLAGS) after the list of object files.
Some linkers on some systems are particularly picky about the order of
arguments in order to properly linkt. So this fixes failures on some
systems.
2009-11-19 18:05:22 +01:00
Ingmar Vanhassel
aa8c2224ee Makefile: Create elisp install directory explicitly
When doing a DESTDIR install, this directory likely won't exist, and
installing notmuch.el will fail.

See 0d4b5292
2009-11-19 12:24:11 +01:00
Carl Worth
0d4b529297 Makefile: Actually install the emacs mode.
Should have been doing this a long time ago.
2009-11-19 00:27:34 +01:00
Stewart Smith
b032cf98f5 Fix linking with gcc to use g++ to link in C++ libs.
Previously, Ubuntu 9.10, gcc 4.4.1 was getting:

/usr/bin/ld: lib/notmuch.a(database.o): in function global
constructors keyed to BOOLEAN_PREFIX_INTERNAL:database.cc(.text+0x3a):
error: undefined reference to 'std::ios_base::Init::Init()'
2009-11-18 05:34:02 -08:00
Jan Janak
835e3a6977 Older versions of install do not support -C.
Do not use -C cmdline option of install, older versions, commonly found in
distributions like Debian, do not seem to support it. Running make install
on such systems (tested on Debian Lenny) fails.

Signed-off-by: Jan Janak <jan@ryngle.com>
2009-11-18 02:41:15 -08:00
Carl Worth
544df2f517 Makefile: Fix missing dependency for notmuch.1 manual page.
The Makefile was failing to regnerate the notmuch.1.gz file when
notmuch.1 was updated, (so stale documentation could potentially be
installed).
2009-11-17 21:04:31 -08:00
Ingmar Vanhassel
e8c9c3e6a5 Makefile: Manual pages shouldn't be executable 2009-11-17 13:11:20 -08:00
Carl Worth
e12a6b91ac Makefile: Change default install prefix from /usr to /usr/local
We'll be a much more polite package this way. And the user can change
the prefix by editing Makefile.config. Still to be done is to make
configure write out Makefile.config and to add a --prefix option to
configure.
2009-11-17 13:05:16 -08:00
Carl Worth
9c2d0714fe Makefile: Prefer directories as the target for install commands.
I was confusing myself with some rules installing to directories and
some installing to files. We do still install to a filename when
simultaneously renaming, (such as notmuch-completion.bash to notmuch).
2009-11-17 12:59:32 -08:00
Ingmar Vanhassel
81c9640b86 Makefile: Create installation directories explicitly
Previously, notmuch.1.gz was installed as /usr/share/man/man1 (a file).
2009-11-17 12:34:04 -08:00
Carl Worth
37bdd89870 notmuch new: Unbreak after the addition of notmuch-config.
Pull in the code from add-files.c now that notmuch_new_command is
the only user, (we no longer have notmuch_setup_command adding any
messages).
2009-11-11 19:50:15 -08:00
Carl Worth
305e76bc0a notmuch: Add a configuration system.
This will allow for things like the database path to be specified
without any cheesy NOTMUCH_BASE environment variable. It also will
allow "notmuch reply" to recognize the user's email address when
constructing a reply in order to do the right thing, (that is, to use
the user's address to which mail was sent as From:, and not to reply
to the user's own addresses).

With this change, the "notmuch setup" command is now strictly for
changing the configuration of notmuch. It no longer creates the
database, but instead instructs the user to call "notmuch new" to do
that.
2009-11-11 17:01:55 -08:00
Keith Packard
357aba3ec8 notmuch reply: Add (incomplete) reply command
Reviewed-by: Carl Worth <cworth@cworth.org>

Keith wrote all the code here against notmuch before notmuch.c was
split up into multiple files. So I've pushed the code around in
various ways to match the new code structure, but have generally tried
to avoid making any changes to the behavior of the code.

I did fix one bug---a missing call to g_mime_stream_file_set_owner in
show_part which would cause "notmuch show" to go off into the weeds
when trying to show multiple messages, (since the first stream would
fclose stdout).
2009-11-10 13:32:02 -08:00
Carl Worth
50144f95ca notmuch: Break notmuch.c up into several smaller files.
Now that the client sources are alone here in their own directory,
(with all the library sources down inside the lib directory), we can
break the client up into multiple files without mixing the files up.
The hope is that these smaller files will be easier to manage and
maintain.
2009-11-10 12:03:05 -08:00
Carl Worth
1a6208bfbd Makefile: Simplify setting of CFLAGS, etc.
We were previously using separate CFLAGS and NOTMUCH_CFLAGS variables
in an attempt to allow the user to specify CFLAGS on the command-line.

However, that's just a lot of extra noise in the Makefile when we can
instead let the user specify what is desired for CFLAGS and then use
an override to append the things we require. So our Makefile is much
neater now.
2009-11-10 08:27:48 -08:00
Carl Worth
c5dccd851a Implement a non-recursive make.
The idea here is that every Makefile at each lower level will be an
identical, tiny file that simply defers to a top-level make.

Meanwhile, the Makefile.local file at each level is a Makefile snippet
to be included at the top-level into a large, flat Makefile. As such,
it needs to define its rules with the entire relative directory to
each file, (typically in $(dir)). The local files can also append to
variables such as SRCS and CLEAN for files to be analyzed for
dependencies and to be cleaned.
2009-11-10 07:24:10 -08:00