# [PATCH] contrib/subtree: Fix make install target

2 messages from 2013-07-30 to 2013-07-30. Participants: Michal Sojka, Junio C Hamano.
Thread: https://gitlist.dev/t/34567

## Michal Sojka, 2013-07-30 08:16

Subject: [PATCH] contrib/subtree: Fix make install target
Message-ID: <1375172169-26582-1-git-send-email-sojkam1@fel.cvut.cz>
URL: https://gitlist.dev/e/1375172169-26582-1-git-send-email-sojkam1%40fel.cvut.cz

```
If the libexec directory doesn't exist, git-subtree gets installed as
$prefix/share/libexec/git-core file. This patch creates the directory
before installing git-subtree file into it.

Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
---
 contrib/subtree/Makefile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/contrib/subtree/Makefile b/contrib/subtree/Makefile
index b507505..435b2de 100644
--- a/contrib/subtree/Makefile
+++ b/contrib/subtree/Makefile
@@ -30,6 +30,7 @@ $(GIT_SUBTREE): $(GIT_SUBTREE_SH)
 doc: $(GIT_SUBTREE_DOC)
 
 install: $(GIT_SUBTREE)
+	$(INSTALL) -d -m 755 $(DESTDIR)$(libexecdir)
 	$(INSTALL) -m 755 $(GIT_SUBTREE) $(DESTDIR)$(libexecdir)
 
 install-doc: install-man
-- 
1.8.3.2

```

## Junio C Hamano, 2013-07-30 14:51

Subject: Re: [PATCH] contrib/subtree: Fix make install target
Message-ID: <7vob9kxfr1.fsf@alter.siamese.dyndns.org>
URL: https://gitlist.dev/e/7vob9kxfr1.fsf%40alter.siamese.dyndns.org
In-Reply-To: <1375172169-26582-1-git-send-email-sojkam1@fel.cvut.cz>

```
Michal Sojka <sojkam1@fel.cvut.cz> writes:

> If the libexec directory doesn't exist, git-subtree gets installed as
> $prefix/share/libexec/git-core file. This patch creates the directory
> before installing git-subtree file into it.
>
> Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
> ---

Will queue, as it is obviously correct.  Thanks.

I however wish somebody steps up to start properly maintaining this
part of the contrib ;-).

>  contrib/subtree/Makefile | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/contrib/subtree/Makefile b/contrib/subtree/Makefile
> index b507505..435b2de 100644
> --- a/contrib/subtree/Makefile
> +++ b/contrib/subtree/Makefile
> @@ -30,6 +30,7 @@ $(GIT_SUBTREE): $(GIT_SUBTREE_SH)
>  doc: $(GIT_SUBTREE_DOC)
>  
>  install: $(GIT_SUBTREE)
> +	$(INSTALL) -d -m 755 $(DESTDIR)$(libexecdir)
>  	$(INSTALL) -m 755 $(GIT_SUBTREE) $(DESTDIR)$(libexecdir)
>  
>  install-doc: install-man

```
