Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id C2A28431FD0 for ; Sun, 23 Oct 2011 07:44:48 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.7 X-Spam-Level: X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id MD7nOI2YmJ-C for ; Sun, 23 Oct 2011 07:44:48 -0700 (PDT) Received: from mail-bw0-f53.google.com (mail-bw0-f53.google.com [209.85.214.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id E7CC0431FB6 for ; Sun, 23 Oct 2011 07:44:47 -0700 (PDT) Received: by bke11 with SMTP id 11so7677022bke.26 for ; Sun, 23 Oct 2011 07:44:46 -0700 (PDT) Received: by 10.223.63.130 with SMTP id b2mr38789952fai.35.1319381086268; Sun, 23 Oct 2011 07:44:46 -0700 (PDT) Received: from localhost (abst122.neoplus.adsl.tpnet.pl. [83.8.139.122]) by mx.google.com with ESMTPS id 5sm6845665fad.9.2011.10.23.07.44.43 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 23 Oct 2011 07:44:44 -0700 (PDT) From: =?UTF-8?q?Amadeusz=20=C5=BBo=C5=82nowski?= To: notmuch@notmuchmail.org Subject: [PATCH] Prefix lib/notmuch.h and lib/gen-version-script.sh with $(srcdir) Date: Sun, 23 Oct 2011 16:44:01 +0200 Message-Id: <1319381041-15800-1-git-send-email-aidecoe@aidecoe.name> X-Mailer: git-send-email 1.7.7 X-Mailman-Approved-At: Mon, 24 Oct 2011 11:32:10 -0700 Cc: =?UTF-8?q?Amadeusz=20=C5=BBo=C5=82nowski?= X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 23 Oct 2011 14:44:48 -0000 lib/notmuch.h and lib/gen-version-script.sh couldn't have been found when building out of sources directory. --- lib/Makefile.local | 13 +++++++------ 1 files changed, 7 insertions(+), 6 deletions(-) diff --git a/lib/Makefile.local b/lib/Makefile.local index ea20b2b..be51eaa 100644 --- a/lib/Makefile.local +++ b/lib/Makefile.local @@ -41,6 +41,11 @@ endif dir := lib extra_cflags += -I$(srcdir)/$(dir) -fPIC +# The (often-reused) $dir works fine within targets/prerequisites, +# but cannot be used reliably within commands, so copy its value to a +# variable that is not reused. +lib := $(dir) + libnotmuch_c_srcs = \ $(notmuch_compat_srcs) \ $(dir)/filenames.c \ @@ -68,8 +73,8 @@ $(dir)/libnotmuch.a: $(libnotmuch_modules) $(dir)/$(LIBNAME): $(libnotmuch_modules) notmuch.sym $(call quiet,CXX $(CXXFLAGS)) $(libnotmuch_modules) $(FINAL_LIBNOTMUCH_LDFLAGS) $(LIBRARY_LINK_FLAG) -o $@ -notmuch.sym: lib/notmuch.h $(libnotmuch_modules) - sh lib/gen-version-script.sh $< $(libnotmuch_modules) > $@ +notmuch.sym: $(srcdir)/$(dir)/notmuch.h $(libnotmuch_modules) + sh $(srcdir)/$(lib)/gen-version-script.sh $< $(libnotmuch_modules) > $@ $(dir)/$(SONAME): $(dir)/$(LIBNAME) ln -sf $(LIBNAME) $@ @@ -79,10 +84,6 @@ $(dir)/$(LINKER_NAME): $(dir)/$(SONAME) install: install-$(dir) -# The (often-reused) $dir works fine within targets/prerequisites, -# but cannot be used reliably within commands, so copy its value to a -# variable that is not reused. -lib := $(dir) install-$(dir): $(dir)/$(LIBNAME) mkdir -p "$(DESTDIR)$(libdir)/" install -m0644 "$(lib)/$(LIBNAME)" "$(DESTDIR)$(libdir)/" -- 1.7.7