All of lore.kernel.org
 help / color / mirror / Atom feed
From: Erik Faye-Lund <kusmabite@gmail.com>
To: Marat Radchenko <marat@slonopotamus.org>,
	msysGit <msysgit@googlegroups.com>,
	 Pat Thoyts <patthoyts@gmail.com>
Cc: GIT Mailing-list <git@vger.kernel.org>
Subject: Re: git version 1.9.0 missing git-http-push?
Date: Mon, 28 Apr 2014 11:43:22 +0200	[thread overview]
Message-ID: <CABPQNSYsrSy2iONZOA5gjruBqGwEy6Tc1K+5_zYq3q=EMgzE9Q@mail.gmail.com> (raw)
In-Reply-To: <CABPQNSZh1GePGwm6_cC9Zf7N1LaeiavbnOxG4JoWMAab4GcfQQ@mail.gmail.com>

On Mon, Apr 28, 2014 at 11:01 AM, Erik Faye-Lund <kusmabite@gmail.com> wrote:
> On Mon, Apr 28, 2014 at 10:48 AM, Erik Faye-Lund <kusmabite@gmail.com> wrote:
>> So it seems that 08900987 ("Decide whether to build http-push in the
>> Makefile") makes a bad assumption about the availability of
>> curl-config on new libcurl installations; it's not present on "stock"
>> Windows builds.
>
> I wonder, though. That check is over 8 years old. Are that old systems
> (that haven't been upgraded) still able to build Git? Even my old
> RedHat 5 setup has curl 7.15.5...
>
> Perhaps the following is the right thing to do? If not, perhaps we
> could move this complication to configure.ac, which could get the
> version number from the header-file instead? That way, quirks only
> affect quirky systems...

And here's a stab at that. Not really tested, as I don't have an
affected system, so it's probably broken somehow ;)

But if someone want's to pick it up, at least there's a starting-point.

---

diff --git a/Makefile b/Makefile
index 29a555d..b94f830 100644
--- a/Makefile
+++ b/Makefile
@@ -1133,11 +1133,8 @@ else
  REMOTE_CURL_NAMES = $(REMOTE_CURL_PRIMARY) $(REMOTE_CURL_ALIASES)
  PROGRAM_OBJS += http-fetch.o
  PROGRAMS += $(REMOTE_CURL_NAMES)
- curl_check := $(shell (echo 070908; curl-config --vernum)
2>/dev/null | sort -r | sed -ne 2p)
- ifeq "$(curl_check)" "070908"
- ifndef NO_EXPAT
- PROGRAM_OBJS += http-push.o
- endif
+ ifndef NO_CAPABLE_CURL
+ PROGRAM_OBJS += http-push.o
  endif
  ifndef NO_EXPAT
  ifdef EXPATDIR
diff --git a/configure.ac b/configure.ac
index 2f43393..47991c0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -513,6 +513,16 @@ AC_CHECK_LIB([curl], [curl_global_init],
 [NO_CURL=],
 [NO_CURL=YesPlease])

+AC_COMPILE_IFELSE(
+ [AC_LANG_PROGRAM([#include <curlver.h>],
+ [#if LIBCURL_VERSION_NUM < 0x070908
+#error version too old
+#endif
+ ])],
+ [NO_CAPABLE_CURL=YesPlease],
+ [NO_CAPABLE_CURL=])
+GIT_CONF_SUBST([NO_CAPABLE_CURL])
+
 GIT_UNSTASH_FLAGS($CURLDIR)

 GIT_CONF_SUBST([NO_CURL])

-- 
-- 
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.

You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en

--- 
You received this message because you are subscribed to the Google Groups "msysGit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

  reply	other threads:[~2014-04-28  9:44 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-28  6:19 git version 1.9.0 missing git-http-push? Silvola Tuomas
2014-04-28  7:36 ` Marat Radchenko
2014-04-28  8:48   ` Erik Faye-Lund
2014-04-28  9:01     ` Erik Faye-Lund
2014-04-28  9:43       ` Erik Faye-Lund [this message]
2014-04-28 13:12       ` Erik Faye-Lund
2014-04-28 13:20       ` Johannes Schindelin
2014-04-28 13:24         ` Erik Faye-Lund
2014-04-28 13:47         ` Marat Radchenko
2014-04-28 13:53           ` Erik Faye-Lund
2014-04-28 18:31     ` Junio C Hamano
2014-04-28 18:39       ` 'Dave Borowitz <dborowitz@google.com>' via msysGit
2014-04-28 19:02         ` Erik Faye-Lund
2014-04-28 19:40         ` Junio C Hamano
2014-04-28 19:42           ` 'Dave Borowitz <dborowitz@google.com>' via msysGit

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='CABPQNSYsrSy2iONZOA5gjruBqGwEy6Tc1K+5_zYq3q=EMgzE9Q@mail.gmail.com' \
    --to=kusmabite@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=marat@slonopotamus.org \
    --cc=msysgit@googlegroups.com \
    --cc=patthoyts@gmail.com \
    /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.