git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alex Riesen <raa.lkml@gmail.com>
To: Brian Gernhardt <brian@gernhardtsoftware.com>
Cc: Git List <git@vger.kernel.org>, Junio C Hamano <gitster@pobox.com>
Subject: Re: [PATCH] Makefile: Add NEEDS_CRYPTO_WITH_SSL
Date: Mon, 24 Aug 2009 11:45:13 +0200	[thread overview]
Message-ID: <81b0412b0908240245l33b04322l923084362197406a@mail.gmail.com> (raw)
In-Reply-To: <1250354813-81349-1-git-send-email-brian@gernhardtsoftware.com>

On Sat, Aug 15, 2009 at 18:46, Brian
Gernhardt<brian@gernhardtsoftware.com> wrote:
>
>  After adding BLK_SHA1 to my config.mak, git-imap-send started giving me link
>  errors:
>
>  Undefined symbols:
>    "_ERR_get_error", referenced from:
>        _ssl_socket_perror in imap-send.o
>    "_ERR_error_string", referenced from:
>        _ssl_socket_perror in imap-send.o
>
>  Some investigation led me to the fact that BLK_SHA1 removes LIB_4_CRYPTO from
>  EXTLIBS.  That let me find the missing functions in libcrypto.  At first I
>  considered making NEEDS_SSL_WITH_CRYPTO add -lcrypto to the SSL build flags
>  but decided to go this route in case there are platforms that need it one way
>  around and not the other.

As imap-send is the only one which uses the symbols, why not just add
LIB_4_CRYPTO
to its linking command? Like in the broken GMail-patch below:

diff --git a/Makefile b/Makefile
index 02ff867..33971f3 100644
--- a/Makefile
+++ b/Makefile
@@ -1503,7 +1503,7 @@ git-%$X: %.o $(GITLIBS)

 git-imap-send$X: imap-send.o $(GITLIBS)
 	$(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) \
-		$(LIBS) $(OPENSSL_LINK) $(OPENSSL_LIBSSL)
+		$(LIBS) $(OPENSSL_LINK) $(OPENSSL_LIBSSL) $(LIB_4_CRYPTO)

 http.o http-walker.o http-push.o: http.h

  reply	other threads:[~2009-08-24  9:45 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-15 16:46 [PATCH] Makefile: Add NEEDS_CRYPTO_WITH_SSL Brian Gernhardt
2009-08-24  9:45 ` Alex Riesen [this message]
2009-08-24 14:22   ` Brian Gernhardt
  -- strict thread matches above, loose matches on Subject: below --
2009-09-08 13:54 Brian Gernhardt
2009-09-08 20:19 ` Junio C Hamano
2009-09-09  0:40   ` Brian Gernhardt

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=81b0412b0908240245l33b04322l923084362197406a@mail.gmail.com \
    --to=raa.lkml@gmail.com \
    --cc=brian@gernhardtsoftware.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.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 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 NNTP newsgroup(s).