Date: Mon, 10 Jun 2013 17:15:40 +1000 (AEST) From: John Marshall <john.marshall@riverwillow.com.au> To: FreeBSD-gnats-submit@freebsd.org Subject: ports/179450: [PATCH] security/gnupg does not detect curl-config when --with-libcurl=PATH Message-ID: <201306100715.r5A7Fea1025106@rwpc15.mby.riverwillow.net.au> Resent-Message-ID: <201306100740.r5A7e1Fx053886@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 179450 >Category: ports >Synopsis: [PATCH] security/gnupg does not detect curl-config when --with-libcurl=PATH >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Jun 10 07:40:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: John Marshall >Release: FreeBSD 9.1-RELEASE-p2 i386 >Organization: Riverwillow Pty Ltd >Environment: System: FreeBSD rwpc15 9.1-RELEASE-p2 FreeBSD 9.1-RELEASE-p2 #0 r249036: Wed Apr 3 22:47:35 AEDT 2013 root@rwpc15:/usr/obj/build/src/sys/RWPC15 i386 >Description: gnupg 2.0.20 introduces changes around handling DNS SRV record lookups for hkp keyservers, and makes compilation of the DNS SRV code conditional upon a minimum version of libcurl. If the FreeBSD port CURL option is set, the port's Makefile passes --with-libcurl=${LOCALBASE} to the gnupg configure script. The gnupg configure script's curl-config detection is broken for the --with-libcurl=PATH case, so the script doesn't find curl-config, cannot determine the version of the installed libcurl, and will not compile the DNS SRV code for its keyserver helper program (keyserver/gpgkeys_hkp.c) The attached patch fixes the broken curl-config detection in the gnupg configure script. I have sent a report upstream with a patch for the source of the problem in the underlying m4/libcurl.m4. >How-To-Repeat: Set CURL option; make configure; check config.log configure:9445: checking for /usr/local/bin/curl-config configure:9478: result: no Hack FreeBSD Makefile to pass a bare --with-config (no path); make clean; make configure; check config.log configure:9486: checking for curl-config configure:9504: found /usr/local/bin/curl-config configure:9516: result: /usr/local/bin/curl-config configure:9527: checking for the version of libcurl configure:9534: result: 7.24.0 configure:9541: checking for libcurl >= version 7.10 configure:9554: result: yes >Fix: The attached patch: - bumps the FreeBSD Makefile PORTREVISION - patches the gnupg configure script to detect an installed curl-config --- gnupg_r317847.diff begins here --- Index: security/gnupg/Makefile =================================================================== --- security/gnupg/Makefile (revision 320405) +++ security/gnupg/Makefile (working copy) @@ -2,6 +2,7 @@ PORTNAME= gnupg PORTVERSION= 2.0.20 +PORTREVISION= 1 CATEGORIES= security MASTER_SITES= ${MASTER_SITE_GNUPG} MASTER_SITE_SUBDIR= gnupg Index: security/gnupg/files/patch-configure =================================================================== --- security/gnupg/files/patch-configure (revision 0) +++ security/gnupg/files/patch-configure (working copy) @@ -0,0 +1,49 @@ +--- configure.orig 2013-05-10 23:56:32.000000000 +1000 ++++ configure 2013-06-08 21:03:45.000000000 +1000 +@@ -9440,45 +9440,7 @@ + if test -d "$_libcurl_with" ; then + LIBCURL_CPPFLAGS="-I$withval/include" + _libcurl_ldflags="-L$withval/lib" +- # Extract the first word of ""$withval/bin/curl-config"", so it can be a program name with args. +-set dummy "$withval/bin/curl-config"; ac_word=$2 +-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +-$as_echo_n "checking for $ac_word... " >&6; } +-if ${ac_cv_path__libcurl_config+:} false; then : +- $as_echo_n "(cached) " >&6 +-else +- case $_libcurl_config in +- [\\/]* | ?:[\\/]*) +- ac_cv_path__libcurl_config="$_libcurl_config" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path__libcurl_config="$as_dir/$ac_word$ac_exec_ext" +- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +- done +-IFS=$as_save_IFS +- +- ;; +-esac +-fi +-_libcurl_config=$ac_cv_path__libcurl_config +-if test -n "$_libcurl_config"; then +- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_libcurl_config" >&5 +-$as_echo "$_libcurl_config" >&6; } +-else +- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +-$as_echo "no" >&6; } +-fi +- ++ _libcurl_config="$withval/bin/curl-config" + + else + # Extract the first word of "curl-config", so it can be a program name with args. --- gnupg_r317847.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201306100715.r5A7Fea1025106>