[prev in list] [next in list] [prev in thread] [next in thread]
List: git
Subject: Re: [PATCH] Windows: set gitexecdir = $(bindir)
From: Johannes Sixt <johannes.sixt () telecom ! at>
Date: 2008-07-19 19:31:44
Message-ID: 200807192131.44441.johannes.sixt () telecom ! at
[Download RAW message or body]
On Samstag, 19. Juli 2008, Junio C Hamano wrote:
> Johannes Sixt <johannes.sixt@telecom.at> writes:
> > Take as an example 'git pull'.
> >
> > - The first call to git will derive the exec-path
> > $prefix/bin/../libexec/git-core and prepend it to $PATH.
> >
> > - Calls to builtin git commands from inside 'git pull' will then derive
> > the exec-path $prefix/bin/../libexec/git-core/../libexec/git-core, that
> > is $prefix/libexec/libexec/git-core, and prepend it to $PATH as well.
> > That directory does not exist - usually - and it does not hurt. But it
> > feels dirty and potentially dangerous.
>
> You run "git" with an argument "pull". It needs to figure out where
> "git-pull" is, it checks where it came from and adds ../libexec/git-core/.
> Then it runs "git-pull" script.
>
> Then the script may have a call to "git ls-files -u" or "git-merge".
>
> - The former case, "git" again needs to find out where "git-ls-files"
> is.
>
> If "git" is found as bin/git and not as libexec/git-core/git, this
> should be perfectly fine, isn't it? Perhaps we install a duplicate
> copy there by mistake, which is what we need to fix?
Yes, there's libexec/git-core/git. There reason might be that the install
target is simpler to write (to create the hardlinks) just in case $(bindir)
and $(gitexecdir) are not on the same mount.
> - The latter case (our scripts source git-sh-setup so they have libexec
> one in the PATH when they are started) would find "git-merge" directly
> and runs it.
>
> In either case, the programs "git-ls-files" and "git-merge" do not need to
> do the same discovery -- are we giving them enough clues when we run them
> to let them avoid that?
Probably the only clue is the name itself, like Steffen proposed.
I'll see how I can improve my earlier exec-path patch series.
-- Hannes
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic