]> git.notmuchmail.org Git - notmuch/commitdiff
Makefile: Hard-code emacs_lispdir if emacs pkg-config file not available
authorCarl Worth <cworth@cworth.org>
Fri, 20 Nov 2009 12:07:42 +0000 (13:07 +0100)
committerCarl Worth <cworth@cworth.org>
Fri, 20 Nov 2009 12:07:42 +0000 (13:07 +0100)
Using pkg-config to find this variable is nice if it works. Go back to
the previously used value if it doesn't.

Makefile

index 9e44d90a3a35134cd7beb6d92b775fe0f77fb2e4..0411cbbed663c933fad48d434d9168ea4508995e 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -8,6 +8,10 @@ extra_cflags := $(shell pkg-config --cflags glib-2.0 gmime-2.4 talloc)
 extra_cxxflags := $(shell xapian-config --cxxflags)
 
 emacs_lispdir := $(shell pkg-config emacs --variable sitepkglispdir)
+# Hard-code if this system doesn't have an emacs.pc file
+ifeq ($(emacs_lispdir),)
+       emacs_lispdir = $(prefix)/share/site-lisp
+endif
 
 # Now smash together user's values with our extra values
 override CFLAGS += $(WARN_FLAGS) $(extra_cflags)