All of lore.kernel.org
 help / color / mirror / Atom feed
From: A Large Angry SCM <gitzilla@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Steffen Prohaska <prohaska@zib.de>, Pascal Obry <pascal@obry.net>,
	git@vger.kernel.org
Subject: Re: [PATCH] Makefile: fix misdetection of relative pathnames
Date: Thu, 05 Feb 2009 17:16:13 -0500	[thread overview]
Message-ID: <498B652D.8060708@gmail.com> (raw)
In-Reply-To: <7vhc39guv2.fsf@gitster.siamese.dyndns.org>

Junio C Hamano wrote:
> A Large Angry SCM <gitzilla@gmail.com> writes:
> 
>> In 026fa0d5ad9538ca76838070861531c037d7b9ba, "Move computation of
>> absolute paths from Makefile to runtime (in preparation for
>> RUNTIME_PREFIX)", the following change was made to the Makefile. The
>> problem is that $(abspath names...) is a relatively recent addition to
>> GNU make and when used in an older GNU make, the test always fails
>> resulting incorrect installation dirs for the templates and commands.
>>
>> The new test is also wrong; (for *nix systems) in that it really wants
>> to test if the first character is a '/'
> 
> Ok, here is the final one from me that I am considering to commit, but it
> would be nice to hear success/failure feedback from people who had trouble
> with Steffen's changes.  I'd also like to hear from people who have been
> happy with Steffen's changes that this does not break things for them.
> 
> -- >8 --
> 
> The installation rules wanted to differentiate between a template_dir that
> is given as an absolute path (e.g. /usr/share/git-core/templates) and a
> relative one (e.g. share/git-core/templates) but it was done by checking
> if $(abspath $(template_dir)) and $(template_dir) yield the same string.
> 
> This was wrong in number of ways.
> 
>  * The user can give template_dir with a trailing slash from the command
>    line to invoke make, or in the included config.mak.  A directory path
>    ought to mean the same thing with or without such a trailing slash but
>    use of $(abspath) means with an absolute path with a trailing slash
>    fails the test.
> 
>  * The compilation could be done inside /usr directory with a relative
>    pathname share/git-core/templates and it will be mistaken as an
>    absolute path.
> 
>  * Versions of GNU make older than 3.81 do not have $(abspath) to begin
>    with.
> 
> This changes the detection logic to see if the given path begins with a
> slash.
> 
> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Tested-by: A Large Angry SCM <gitzilla@gmail.com>

      parent reply	other threads:[~2009-02-05 22:17 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-01 18:24 026fa0d5ad Breaks installs with absolue $(gitexecdir) and $(template_dir) variables using older GNU makes A Large Angry SCM
2009-02-05  7:04 ` Junio C Hamano
2009-02-05  7:13   ` Steffen Prohaska
2009-02-05  7:35 ` Junio C Hamano
2009-02-05  7:38   ` Pascal Obry
2009-02-05  7:53     ` Junio C Hamano
2009-02-05  7:57       ` Pascal Obry
2009-02-05  8:01       ` Junio C Hamano
2009-02-05  7:44   ` Junio C Hamano
2009-02-05  8:18 ` [PATCH] Makefile: fix misdetection of relative pathnames Junio C Hamano
2009-02-05 12:27   ` Johannes Sixt
2009-02-05 17:19     ` Junio C Hamano
2009-02-05 22:16   ` A Large Angry SCM [this message]

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

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

  git send-email \
    --in-reply-to=498B652D.8060708@gmail.com \
    --to=gitzilla@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=pascal@obry.net \
    --cc=prohaska@zib.de \
    /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.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.