From 8c8079a8b14fac5e8ca6b682e5c76e08a824f2e7 Mon Sep 17 00:00:00 2001 From: Aaron Ecay Date: Sun, 11 Apr 2010 19:44:53 -0400 Subject: [PATCH] Add infrastructure for building shared library on OS X. This patch adds a configure check for OS X (actually Darwin), and sets up the Makefiles to build a proper shared library on that platform. Signed-off-by: Aaron Ecay --- Makefile.local | 2 +- configure | 13 +++++++++++++ lib/Makefile.local | 15 +++++++++++++-- 3 files changed, 27 insertions(+), 3 deletions(-) diff --git a/Makefile.local b/Makefile.local index 0f99e3f9..79ac50d4 100644 --- a/Makefile.local +++ b/Makefile.local @@ -199,7 +199,7 @@ notmuch_client_modules = $(notmuch_client_srcs:.c=.o) notmuch: $(notmuch_client_modules) lib/libnotmuch.a $(call quiet,CXX $(CFLAGS)) $^ $(FINAL_LIBNOTMUCH_LDFLAGS) -o $@ -notmuch-shared: $(notmuch_client_modules) lib/libnotmuch.so +notmuch-shared: $(notmuch_client_modules) lib/$(LINKER_NAME) $(call quiet,CXX $(CFLAGS)) $(notmuch_client_modules) $(FINAL_NOTMUCH_LDFLAGS) -o $@ notmuch.1.gz: notmuch.1 diff --git a/configure b/configure index 90a399ca..8af3dc9e 100755 --- a/configure +++ b/configure @@ -234,6 +234,15 @@ else have_emacs=0 fi +printf "Checking for Mac OS X (for shared library)... " +if [ `uname` = "Darwin" ] ; then + printf "Yes.\n" + mac_os_x=1 +else + printf "No.\n" + mac_os_x=0 +fi + if [ $errors -gt 0 ]; then cat <