unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: Tomi Ollila <tomi.ollila@iki.fi>
To: Felipe Contreras <felipe.contreras@gmail.com>, notmuch@notmuchmail.org
Subject: Re: [PATCH] vim: simplify build
Date: Wed, 18 Apr 2012 16:11:02 +0300	[thread overview]
Message-ID: <m2ty0hxk0p.fsf@guru.guru-group.fi> (raw)
In-Reply-To: <1334751115-7216-1-git-send-email-felipe.contreras@gmail.com>

On Wed, Apr 18 2012, Felipe Contreras <felipe.contreras@gmail.com> wrote:

> There should be no functional changes, except that you don't need to
> make the directories before installing.
>
> Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
> ---

Hmm, Where is $(PWD) make variable documented; I found only $(CURDIR)
anyway, te following test makefile works OK.

all:
        echo $(PWD)
        echo $(CURDIR)

(i.e. both echo the current directory)

If this is not an issue, then LGTM.

Tomi

>  vim/Makefile |   19 +++++++++----------
>  1 file changed, 9 insertions(+), 10 deletions(-)
>
> diff --git a/vim/Makefile b/vim/Makefile
> index 89e18be..e7b7faa 100644
> --- a/vim/Makefile
> +++ b/vim/Makefile
> @@ -1,11 +1,11 @@
>  .PHONY: all help install link symlink
>  
> -FILES     = plugin/notmuch.vim \
> -	    $(wildcard syntax/notmuch-*.vim)
> +files = plugin/notmuch.vim \
> +	$(wildcard syntax/notmuch-*.vim)
> +prefix = $(HOME)/.vim
> +destdir = $(prefix)/plugin
>  
> -PREFIX    = $(shell ls -d ~/.vim/)
> -
> -OUT_FILES = $(FILES:%=${PREFIX}/%)
> +INSTALL = install -D -m644
>  
>  all: help
>  
> @@ -16,9 +16,8 @@ help:
>  	@echo "    make install     - copy plugin scripts and syntax files to ~/.vim"
>  	@echo "    make symlink     - create symlinks in ~/.vim (useful for development)"
>  
> -install: ${OUT_FILES}
> -link symlink:
> -	${MAKE} SYMLINK=1 install
> +install:
> +	@for x in $(files); do $(INSTALL) $(PWD)/$$x $(prefix)/$$x; done
>  
> -${OUT_FILES}: ${PREFIX}/%: %
> -	$(if ${SYMLINK},ln -fs,cp) `pwd`/$< $@
> +link symlink: INSTALL = ln -fs
> +link symlink: install
> -- 
> 1.7.10
>
> _______________________________________________
> notmuch mailing list
> notmuch@notmuchmail.org
> http://notmuchmail.org/mailman/listinfo/notmuch

  reply	other threads:[~2012-04-18 13:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-18 12:11 [PATCH] vim: simplify build Felipe Contreras
2012-04-18 13:11 ` Tomi Ollila [this message]
2012-04-18 13:41   ` Felipe Contreras
2012-04-18 14:58     ` David Bremner
2012-04-18 15:40       ` Tomi Ollila
2012-04-18 15:57         ` Felipe Contreras
2012-04-18 16:03           ` Tomi Ollila
2012-04-21  2:21             ` Felipe Contreras

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2ty0hxk0p.fsf@guru.guru-group.fi \
    --to=tomi.ollila@iki.fi \
    --cc=felipe.contreras@gmail.com \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).