Re: [PATCH] Makefile: Change library order for static linking

2015-09-22 Thread Junio C Hamano
Remi Pommarel writes: > I have one last question thought. Wouldn't it be nice if we had > configure to autodetect the need for -lssl with libcurl? Sure. I do not think anybody tried, but it would be nice. > We could make > configure to check for Curl_ssl_init function symbol in libcurl, > whic

Re: [PATCH] Makefile: Change library order for static linking

2015-09-22 Thread Remi Pommarel
On Mon, Sep 21, 2015 at 10:09:52AM -0700, Junio C Hamano wrote: > I think I said this already, but I found these bits from your patch > > - $(LIBS) $(CURL_LIBCURL) $(EXPAT_LIBEXPAT) > + $(CURL_LIBCURL) $(EXPAT_LIBEXPAT) $(LIBS) > > that first uses libcurl and then libs (wh

Re: [PATCH] Makefile: Change library order for static linking

2015-09-21 Thread Junio C Hamano
Remi Pommarel writes: > On Thu, Sep 17, 2015 at 03:08:25PM -0700, Junio C Hamano wrote: >> That is, for most people, linking with -lcrypto was sufficient, but >> some people needed to grab things from -lssl when they need to do >> so, because things in -lcrypto referred to what was only in -lssl.

Re: [PATCH] Makefile: Change library order for static linking

2015-09-18 Thread Remi Pommarel
On Thu, Sep 17, 2015 at 03:08:25PM -0700, Junio C Hamano wrote: > That is, for most people, linking with -lcrypto was sufficient, but > some people needed to grab things from -lssl when they need to do > so, because things in -lcrypto referred to what was only in -lssl. Oh I see what you mean, I m

Re: [PATCH] Makefile: Change library order for static linking

2015-09-17 Thread Junio C Hamano
Remi Pommarel writes: > On Thu, Sep 17, 2015 at 12:51:18PM -0700, Junio C Hamano wrote: >> IIRC historically the division between ssl and crypto was messy. >> Especially, I am not sure if the change to NEEDS_SSL_WITH_CRYPTO >> in this patch is correct for platforms that require that macro >> defi

Re: [PATCH] Makefile: Change library order for static linking

2015-09-17 Thread Remi Pommarel
On Thu, Sep 17, 2015 at 12:51:18PM -0700, Junio C Hamano wrote: > IIRC historically the division between ssl and crypto was messy. > Especially, I am not sure if the change to NEEDS_SSL_WITH_CRYPTO > in this patch is correct for platforms that require that macro > defined. I think it is correct as

Re: [PATCH] Makefile: Change library order for static linking

2015-09-17 Thread Junio C Hamano
Remi Pommarel writes: > Subject: Re: [PATCH] Makefile: Change library order for static linking s/Change/change/; But more importantly, I think you can do much better with the same space. Perhaps like this. Makefile: link libcurl before openssl and crypto > For static linking espe

Re: [PATCH] Makefile: Change library order for static linking

2015-09-17 Thread Remi Pommarel
On Thu, Sep 17, 2015 at 03:25:00PM -0400, Eric Sunshine wrote: > On Thu, Sep 17, 2015 at 5:12 PM, Remi Pommarel wrote: > > For static linking especially library order while linking is important. For > > example libssl contains symbol from libcrypto so the farmer should be linked > > I hope you me

Re: [PATCH] Makefile: Change library order for static linking

2015-09-17 Thread Eric Sunshine
On Thu, Sep 17, 2015 at 5:12 PM, Remi Pommarel wrote: > For static linking especially library order while linking is important. For > example libssl contains symbol from libcrypto so the farmer should be linked I hope you meant: s/farmer/former/ > before the latter. The global link order should

[PATCH] Makefile: Change library order for static linking

2015-09-17 Thread Remi Pommarel
For static linking especially library order while linking is important. For example libssl contains symbol from libcrypto so the farmer should be linked before the latter. The global link order should be libcurl then libssl then libcrypto then libintl and finally zlib. Signed-off-by: Remi Pommarel