[ANNOUNCEMENT] Updated: curl 7.71.1-1

Ken Brown kbrown@cornell.edu
Mon Aug 10 19:14:16 GMT 2020


On 8/10/2020 1:33 PM, Brian Inglis wrote:
> On 2020-08-10 08:52, Ken Brown via Cygwin wrote:
>> On 8/9/2020 5:48 PM, Brian Inglis wrote:
>>> On 2020-08-09 12:28, Adam Dinwoodie wrote:
>>>> On Fri, 24 Jul 2020 at 13:56, Adam Dinwoodie wrote:
>>>>> In the failing case, the `/configure` stage includes the following
>>>>> text: `configure: Setting CURL_LDFLAGS to '-lcurl -lnghttp2 -lidn2
>>>>> -lssh -lpsl -lssl -lcrypto -lldap -llber -lbrotlidec -lbrotlidec
>>>>> -lz'`; in the working case using -7.66.0-1, the corresponding line is
>>>>> just `configure: Setting CURL_LDFLAGS to '-lcurl'`.
>> [...]
>>> Meanwhile, that info likely comes from:
>>>
>>> $ tail -vn15 /lib/pkgconfig/libcurl.pc
>>> ==> /lib/pkgconfig/libcurl.pc <==
>>> #
>>> prefix=/usr
>>> exec_prefix=/usr
>>> libdir=${exec_prefix}/lib
>>> includedir=${prefix}/include
>>> supported_protocols="DICT FILE FTP FTPS GOPHER HTTP HTTPS IMAP IMAPS LDAP LDAPS
>>> POP3 POP3S RTSP SCP SFTP SMB SMBS SMTP SMTPS TELNET TFTP"
>>> supported_features="SSL IPv6 UnixSockets libz brotli AsynchDNS IDN PSL NTLM
>>> NTLM_WB TLS-SRP HTTP2 HTTPS-proxy"
>>>
>>> Name: libcurl
>>> URL: https://curl.haxx.se/
>>> Description: Library to transfer files with ftp, http, etc.
>>> Version: 7.71.1
>>> Libs: -L${libdir} -lcurl
>>> Libs.private: -lnghttp2 -lidn2 -lssh -lpsl -lssl -lcrypto -lldap -llber
>>> -lbrotlidec -lbrotlidec -lz
>>> Cflags: -I${includedir}
>>>
>>> it looks like your git build should be using Libs for dynamic builds and adding
>>> Libs.private for static builds
> 
>> If you look at configure.ac in the git sources, you'll see that it uses
>> curl-config, not pkg-config.  The former reports:
>>
>> $ curl-config --libs
>> -lcurl -lnghttp2 -lidn2 -lssh -lpsl -lssl -lcrypto -lldap -llber -lbrotlidec
>> -lbrotlidec -lz
>>
>> Yaakov's build of earlier versions of curl used a patch 7.33.0-libdeps.patch to
>> prevent the unnecessary libs from being listed.  He even had a comment at the
>> beginning of the patch, explaining the reason for it: "These are needed only for
>> static linking, but we build with --disable-static".
> 
> I try to avoid looking at autotools plumbing if I can possibly avoid it! ;^>
> Someone cleaned up the approach used, as the patch did not apply and was dropped.

My point is that the patch shouldn't have been dropped.  It should have been 
modified to apply to the updated sources.  (I've done this.  See the attached.) 
As Yaakov wrote, the patch is needed to prevent 'curl-config --libs' from 
including libs that are only needed for static linking.

With the modified patch applied, curl-config gives the expected result:

$ curl-config --libs
-lcurl

> If you look at my later post, cygport git build and tests worked for me with no
> problems other than at first missing some package build dependencies

Those were not really build dependencies.  They only appeared to be needed 
because 'curl-config --libs' erroneously included libs that are only needed for 
static linking.

Ken
-------------- next part --------------
These are needed only for static linking, but we build with --disable-static

--- origsrc/curl-7.71.1/curl-config.in	2020-06-27 18:03:53.000000000 -0400
+++ src/curl-7.71.1/curl-config.in	2020-08-10 14:31:22.719684300 -0400
@@ -160,7 +160,7 @@ while test $# -gt 0; do
         else
            CURLLIBDIR=""
         fi
-        if test "X@ENABLE_SHARED@" = "Xno" -o "X@REQUIRE_LIB_DEPS@" = "Xyes"; then
+        if test "X@ENABLE_SHARED@" = "Xno" -o "X@REQUIRE_LIB_DEPS@" = "Xnothanks"; then
           echo ${CURLLIBDIR}-lcurl @LIBCURL_LIBS@
         else
           echo ${CURLLIBDIR}-lcurl
--- origsrc/curl-7.71.1/libcurl.pc.in	2020-06-27 18:03:53.000000000 -0400
+++ src/curl-7.71.1/libcurl.pc.in	2020-08-10 14:33:36.069651700 -0400
@@ -35,5 +35,4 @@ URL: https://curl.haxx.se/
 Description: Library to transfer files with ftp, http, etc.
 Version: @CURLVERSION@
 Libs: -L${libdir} -lcurl @LIBCURL_NO_SHARED@
-Libs.private: @LIBCURL_LIBS@
 Cflags: -I${includedir} @CPPFLAG_CURL_STATICLIB@


More information about the Cygwin mailing list