From 3f95bba370379d287b34fdc637d353c4c416acc4 Mon Sep 17 00:00:00 2001 From: Tomi Ollila Date: Mon, 2 Sep 2013 22:37:16 +0300 Subject: [PATCH] [PATCH] emacs: target notmuch-one.el[c] -- emacs client in one .el[c] file --- 70/1f0e9d59d74b002525934de27e2f3b5322e029 | 113 ++++++++++++++++++++++ 1 file changed, 113 insertions(+) create mode 100644 70/1f0e9d59d74b002525934de27e2f3b5322e029 diff --git a/70/1f0e9d59d74b002525934de27e2f3b5322e029 b/70/1f0e9d59d74b002525934de27e2f3b5322e029 new file mode 100644 index 000000000..5b5833438 --- /dev/null +++ b/70/1f0e9d59d74b002525934de27e2f3b5322e029 @@ -0,0 +1,113 @@ +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 B75D8431FCB + for ; Mon, 2 Sep 2013 12:37:35 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: 0 +X-Spam-Level: +X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] + 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 2gRLT0pZwEUs for ; + Mon, 2 Sep 2013 12:37:29 -0700 (PDT) +Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) + by olra.theworths.org (Postfix) with ESMTP id 6AC54431FC7 + for ; Mon, 2 Sep 2013 12:37:29 -0700 (PDT) +Received: by guru.guru-group.fi (Postfix, from userid 501) + id A6DA7100063; Mon, 2 Sep 2013 22:37:17 +0300 (EEST) +From: Tomi Ollila +To: notmuch@notmuchmail.org +Subject: [PATCH] emacs: target notmuch-one.el[c] -- emacs client in one .el[c] + file +Date: Mon, 2 Sep 2013 22:37:16 +0300 +Message-Id: <1378150636-26822-1-git-send-email-tomi.ollila@iki.fi> +X-Mailer: git-send-email 1.8.0 +Cc: tomi.ollila@iki.fi +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: Mon, 02 Sep 2013 19:37:35 -0000 + +Added Makefile recipes to create notmuch emacs client in just one +.el[c] file. + +This is an experimental feature and not built by default. + +This is useful for example when one wants to build the latest +emacs client and then distribute the elisp file to many machines. + +This is also useful for (initial) testing: + + make emacs/notmuch-one.elc + emacs -q -l emacs/notmuch-one.elc -f notmuch + +can be used to quickly experiment with new development. +--- + +I've used one-file notmuch.elc since Fri Nov 4 11:03:33 2011 +0200 +when I created perl script to combine all .el files together +and had only minor problems (if any, cannot be sure). + +I build notmuch.elc in one machine and then distribute it to 2 +others. + +Now with the .eldeps target Austin created the same can be done +by utilizing the dependency information it provied. + +Now I build notmuch using something like the following sequence: + + ./configure --without-emacs + make + make install + make emacs/notmuch-one.elc + cp emacs/notmuch-one.elc ~/local/elisp-ext/notmuch.elc + +... but most often I do last 2 of the above and then continue with: + + scp ~/local/elisp-ext/notmuch.elc host2:local/elisp-ext + scp ~/local/elisp-ext/notmuch.elc host3:local/elisp-ext + + emacs/Makefile.local | 14 ++++++++++++++ + 1 file changed, 14 insertions(+) + +diff --git a/emacs/Makefile.local b/emacs/Makefile.local +index a910aff..9e3d409 100644 +--- a/emacs/Makefile.local ++++ b/emacs/Makefile.local +@@ -46,6 +46,20 @@ endif + install: install-emacs + endif + ++# Unsupported hack to provide notmuch emacs client in one *.elc file. ++# It probably works -- or then it fails mysteriously. YMMV. ++# Enter `make emacs/notmuch-one.elc' in top level directory to build it. ++ifeq ($(HAVE_EMACS),1) ++$(dir)/notmuch-one.el: $(emacs_sources) ++ rm -f $(emacs_bytecode) # XXX ++ make -n all WITH_EMACS=1 | sed -n '/printf.*EMACS/ s/.* //p' | \ ++ xargs grep -vh '(declare-function.*"notmuch' > '$@' || : ++ { echo ';; Local Variables:'; \ ++ echo ';; byte-compile-warnings: (not cl-functions)'; \ ++ echo ';; End:'; } >> '$@' ++endif ++CLEAN+=$(dir)/notmuch-one.el $(dir)/notmuch-one.elc ++ + .PHONY: install-emacs + install-emacs: + mkdir -p "$(DESTDIR)$(emacslispdir)" +-- +1.8.0 + -- 2.26.2